Easier way to display a frame for a give time?
BlitzPlus Forums/BlitzPlus Beginners Area/Easier way to display a frame for a give time?
| ||
I am having trouble displaying a frame for a certain time, 1.) this way is a lot of work and posses the problem of 2.) that I cannot use the same key so that when my character faces the other way, he can perform another frame |
| ||
If KeyHit(spacekey) And player\direction = DIRECTIONRIGHT player\direction = DIRECTIONSWORDRIGHT ;facce him left player\frame = 4 counter = True EndIf If counter = True count = count + 1 EndIf If count = 3 counter = False count =0 player\direction = DIRECTIONRIGHT player\frame = 0 EndIf I have a character facing one way, and when I press space bar, he goes to a frame with a sword the direction he was facing, but when I press the left key and he faces the other way, when I press spacebar he doesnt do anything, Please help me fix this problem |