K
khaim0919
Guest
I am trying to make a tree grow and end up stopping. Previously I've done this with multiple different sprites but I think that an animation would look more organised.
if (image_index = X){
image_speed = 0
}
if (image_index = 3) {
image_speed = 0;
}
if (mbleft = true) and (place_meeting(x,y,Object_Mouse)) and (image_speed = 0) {
instance_destroy();
}
This is what I currently have. its a 4 frame animation. It does not trigger whats inside the first if statement at all.
I just tried using this and it set the image speed to 0 when the first frame played on the second loop.The instance variable image_index stores the current frame.
The instance event Animation End will be called when an instance sprite passes the last frame. I recommend using the Event rather than manually tracking image_index.