Gamestudio Links
Zorro Links
Newest Posts
Change chart colours
by 7th_zorro. 05/11/24 09:25
Data from CSV not parsed correctly
by dr_panther. 05/06/24 18:50
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
3 registered members (AndrewAMD, degenerate_762, ozgur), 1,311 guests, and 0 spiders.
Key: Admin, Global Mod, Mod
Newest Members
Hanky27, firatv, wandaluciaia, Mega_Rod, EternallyCurious
19051 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Invalid Array Index Problem #129938
05/14/07 22:09
05/14/07 22:09
Joined: Aug 2003
Posts: 169
Tennessee, US
Ahriman Offline OP
Member
Ahriman  Offline OP
Member

Joined: Aug 2003
Posts: 169
Tennessee, US
I am having a problem within the engine...sometimes my code below will result in a Invalid Array Index Error. Which I know cant be right but maybe I am missing something. If anyone could please take a look and if you see something that would cause that problem give me a hand. I would really appreciate it. I can post more of the code if needed but these are the lines that will return the error so I just included this loop

Code:
 while(1)
{
CurSPartPos[SwordPartCount] = PrevSwordPartIn1.x + cos(CurSPartAng.pan) * cos(CurSPartAng.tilt) * SwordPartCount2;SwordPartCount += 1;
CurSPartPos[SwordPartCount] = PrevSwordPartIn1.y + sin(CurSPartAng.pan) * cos(CurSPartAng.tilt) * SwordPartCount2;SwordPartCount += 1;
CurSPartPos[SwordPartCount] = PrevSwordPartIn1.z + sin(CurSPartAng.tilt) * SwordPartCount2;SwordPartCount += 1;SwordPartCount2 += 0.1;

CurSPartFade[CurSPartFadeCount] = CurSPartFade[CurSPartFadeCount - 1] + CurSPartFadeAmount;
CurSPartFadeCount += 1;
if((SwordPartCount / 3) >= Partthistime){SwordPartCount = 0;CurSPartFadeCount = 0;break;}
}



Re: Invalid Array Index Problem [Re: Ahriman] #129939
05/15/07 00:16
05/15/07 00:16
Joined: Aug 2003
Posts: 169
Tennessee, US
Ahriman Offline OP
Member
Ahriman  Offline OP
Member

Joined: Aug 2003
Posts: 169
Tennessee, US
Nevermind I think I figured it out...


Moderated by  HeelX, Lukas, rayp, Rei_Ayanami, Superku, Tobias, TWO, VeT 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1