Advertisement
helo12

gml code

Nov 25th, 2015
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. this is in the create event
  2. wave=0;
  3. deploy=false;
  4. token=0;
  5. spawn=false;
  6.  
  7. alarm[0]
  8. spawn =true
  9.  
  10.  
  11. this is in the step event so its checked every step[
  12. if (true){
  13.     if (spawn and token>0){
  14.     alarm[0]=15;
  15.    
  16.     instance_create(view_wview,view_hview,obj_zombie_duck)
  17.     spawn=false;
  18.     token-=token;
  19.         }
  20.     }
  21.  
  22.  
  23. this is in the global left mouse button so whenever the left button is clicked this is run
  24. if !instance_exists(obj_zombie_duck) then with (obj_wave_controller) {
  25. wave+= wave;
  26. token = floor(3.5*wave);
  27. deploy=true;
  28. spawn=true;}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement