Game Development Reference
In-Depth Information
Finding out how many subimages a sprite has
The
image_number
variable holds all the subimages a sprite has. This creates an easy
way of making dynamic code that works even if you add or remove frames from a sprite.
The following is the example code:
image_index=image_number-1; //sets the index to the last
frame