B
buhalda
Guest
The catapult has a create event which makes the loading animation play ( sprite_index = spr_catapult_load; image_index = 0;, image_speed = 0.25 Thats it. In the step event, it goes like : if sprite_index = spr_catapult_load { if image_index = 15 (which is the last subimage) {sprite_index = spr_catapult_fire; image_index = 0; }}
But for some reason the same loading animation keeps playing and the step event doesnt want to change the sprite of the object when it reaches the last subimage of the loading animation.
My code looks like this:
Create:
sprite_index = spr_catapult_load;
image_index = 0;
image_speed = 0.25;
Step:
if sprite_index = spr_catapult_load
{
if image_index = 15
{
sprite_index = spr_catapult_fire;
(and it should have executed this code above, but for some reason it doesnt do it even when its on the last subimage 15 )
}
}
But for some reason the same loading animation keeps playing and the step event doesnt want to change the sprite of the object when it reaches the last subimage of the loading animation.
My code looks like this:
Create:
sprite_index = spr_catapult_load;
image_index = 0;
image_speed = 0.25;
Step:
if sprite_index = spr_catapult_load
{
if image_index = 15
{
sprite_index = spr_catapult_fire;
(and it should have executed this code above, but for some reason it doesnt do it even when its on the last subimage 15 )
}
}