Login Page - Create Account

Support Board


Date/Time: Wed, 12 Feb 2025 19:10:30 +0000



Post From: endlessly growing indicator value

[2020-11-06 17:24:41]
jomo88 - Posts: 47
For anyone who might be searching for this later on...

My problem was I was using statements like this... sc.Subgraph[0][BarIndex] += 1.0; For example...

for (int BarIndex = sc.UpdateStartIndex; BarIndex < sc.ArraySize; BarIndex++)
{
if (blahblah > 0)
{
sc.Subgraph[0][BarIndex] += 1.0;
}
}

My solution was to create a temporary holder for sc.Subgraph[0][BarIndex] and add it after the if statements

float temp_sum;
for (int BarIndex = sc.UpdateStartIndex; BarIndex < sc.ArraySize; BarIndex++)
{
if (blahblah > 0)
{
temp_sum += 1.0;
}
sc.Subgraph[0][BarIndex] = temp_sum;
}
Date Time Of Last Edit: 2020-11-06 17:26:16