Advertisement
Guest User

Animation with image_index

a guest
Jun 7th, 2019
139
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. if vspeed_ < 0 sprite_index = sprSquidSwim else sprite_index = sprSquidFall
  2. image_speed = 0
  3. image_index = 0
  4.  
  5. if round(image_index + image_speed * sprite_get_speed(sprite_index)) < image_number {
  6.     image_index += [ANIMATION SPEED; just mess with this a bit until it looks right; should be <= 1]
  7. } else {
  8.     image_index = image_number
  9. }
  10.  
  11. draw_self()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement