Advertisement
Guest User

Untitled

a guest
Aug 30th, 2016
65
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.74 KB | None | 0 0
  1. f(move)
  2. {
  3. hsp = lengthdir_x(spd, dir);
  4. vsp = lengthdir_y(spd, dir);
  5. if(place_meeting(x + hsp, y + vsp, obj_bubble))
  6. {
  7. vsp = 0;
  8. hsp = 0;
  9. indexes = scr_gameSpace_to_arraySpace(x, y);//get indexes
  10. gameLocation = scr_arraySpace_to_gameSpace(indexes[0], indexes[1]);//get snap location
  11. move = false;
  12. x = gameLocation[0];
  13. y = gameLocation[1];
  14. obj_control.IndexFilled[indexes[0], indexes[1]] = self.id;
  15. scr_check_surrounding(indexes[0], indexes[1], color);
  16. scr_remove_same();
  17. obj_shooter.prepNextBubble = true;
  18. }
  19. if (place_meeting(x + hsp, y + vsp, obj_wall)) dir = 180 - dir;
  20.  
  21. //move bubble
  22. x += hsp;
  23. y += vsp;
  24. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement