Um... Nframes glitch?

Non-platform specific questions.

Um... Nframes glitch?

Postby Hblade » Sat May 01, 2010 4:19 pm

FIXED:

A save and reload of the ged somehow fixed it :O


Alright so heres the thing, I'm using a scrip where if the tmp variable is equal to the nframes (number of frames in an animation), then animpos will be equal to 0 but for some reason it automatically makes it the last frame... wtf? My code:
Code: Select all
if (tmp == nframes)
{
    animpos = 0;
}
if (tmp == -1)
{
    animpos = nframes - 1;
}


EDIT: Somehow, the second "if" statement was causing the tmp variable to fly down wtf?
Subscribe to my YouTube? - Yes| No
User avatar
Hblade
 
Posts: 4455
Joined: Fri Dec 08, 2006 11:14 pm
Score: 181 Give a positive score

Re: Um... Nframes glitch?

Postby Thanx » Sat May 01, 2010 4:22 pm

first of all I'd recommend using else if, instead of another simple if statement, on the other hand idk, you should be making sure tmp is the value you expect it to be, and the other thing is to check whether there could be any other code causing the change to be overwritten. Hope that helps! :wink:
http://www.youtube.com/watch?v=XyXexDJBv58
http://www.youtube.com/watch?v=Be4__gww1xQ
These are me and playing the piano (second one with a friend/fellow student)
Hope you watch and enjoy!
User avatar
Thanx
 
Posts: 314
Joined: Sat Jan 26, 2008 10:07 pm
Location: Home sweet home! :)
Score: 24 Give a positive score

Re: Um... Nframes glitch?

Postby Hblade » Sat May 01, 2010 4:24 pm

I fixed it but thanks :D

it worked when I saved it and reloaded the ged for some reason
Subscribe to my YouTube? - Yes| No
User avatar
Hblade
 
Posts: 4455
Joined: Fri Dec 08, 2006 11:14 pm
Score: 181 Give a positive score


Return to General

Who is online

Users browsing this forum: No registered users and 1 guest

cron