• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!

GameMaker An improved spcare rocks. HELP!

S

stefanodon12

Guest
I recently finished the game rocks 3-part tutorial and now im adding whatever i want. Ireally need some help on implementing 3 powerups:

- A shotgun that always shoots 3 bullets for 15 seconds;
- A fast gun that works as a normal keboard_check as opposed to keyboard_check_pressed (i dont know how to switch between the two) that lasts 15 seconds;
- A wheel-like upgrade that lets you shoot for 15 seconds in all 8 directions;

I made a single powerup object that also includes an 1up and shield which are working fine, the problems are the ones that generally temper for a set period of time with the keyboard check and amount of bullets;
It works based on a switch statement that checks for the sprite_index, changing accordingly.

I also tried implementing a pause screen and succeded, but i wanted it to be opaque and not restart the game everytime i get back to the game.

Please im new to this!
 
S

stefanodon12

Guest
you can use alarms for your bullet timers
Could you elaborate a bit? I wanna change the normal keyboard check press for normal shooting into a keyboard press, so in fires indefinitely...
 

Tyg

Member
if you make an alarm event on your player object or gun, in the alarm just set a var like powered_up to false
now when you pick the item set the powerered_up var to true and set the alarm timer....the var powered_up will be true until the alarm goes off..like 15 seconds or whatever you set it to
now in your step event you can have ...if powered_up then case some powerup type case 1 3 bullets, case 2 8 bullets..i can make some quick code if you dont understand

There are standard events on an object like keyup keydown or keypress
 
Last edited:
S

stefanodon12

Guest
I got it mostly, but for the shotgun and wheel, could I create a repeat that changes the angle for each instance? Like for the wheel to make it shoot from 0 degrees all the way to 315 degrees?
 
Top