How to Create 2 Awesome Power Ups in GameMaker

Поділитися
Вставка
  • Опубліковано 23 гру 2024

КОМЕНТАРІ • 94

  • @paininmyava
    @paininmyava Рік тому +59

    The asset download for this video does not work

  • @AmallahGaming
    @AmallahGaming Рік тому +14

    Thanks for the tutorials! I had to rewind a fair bit for this one and your sound effects one because I had trouble keeping up, but I feel that's only because it's my second day working in GameMaker. But rewinding helped me a lot anyway as I started understanding different concepts better hearing them repeated again.

    • @GameMakerEngine
      @GameMakerEngine  Рік тому +3

      Glad it's working for you :). Have you worked in any other game engines before? We have a blog to help people get started if the are coming from Unity: gamemaker.io/en/tutorials/moving-from-unity-to-gamemaker

    • @AmallahGaming
      @AmallahGaming Рік тому +1

      @@GameMakerEngine I'm just a QA in a studio that currently uses Unity, so I've never used it before myself, I just wanted to toy around with things and see what I could make. I used GameMaker for a class back in high school (2012ish) and it's a LOT different now than it was back then. Not in a bad way of course, I was pretty pleased seeing all the changes and improvements. Next I'll be trying out the Hero's Trail tutorial and try to customize it a lot more than I did with this one.
      Keep up the good work!

    • @oreoicecream1829
      @oreoicecream1829 3 місяці тому

      @@GameMakerEngine please help me when i try to run the game it won't run and in the compile error tab it shows this --> Object: obj_powerup_spread Event: Create at line 12 : invalid token \

  • @sgtsuper1
    @sgtsuper1 10 місяців тому +1

    After this tutorial is there one to maybe at a 2nd player or anything else?

    • @GameMakerEngine
      @GameMakerEngine  10 місяців тому +2

      This is the final video we have in this tutorial series. If you go on GM's channel page you can see 2 playlists with stand-a-lone tutorials you can adapt them to add onto this game.
      Then there are also interviews with Game Devs about how they made their game, life coaching sessions and stuff like that :).
      ua-cam.com/channels/OvndqCF3iN2SksQDwR95wg.html

    • @sgtsuper1
      @sgtsuper1 10 місяців тому +1

      @@GameMakerEngine cheers

  • @GameMakerEngine
    @GameMakerEngine  Рік тому +20

    Want to make power-ups in your video game? Watch this tutorial to turn your frail spaceship into an invincible rock blaster.
    Downloads:
    * Assets: coal.gamemaker.io/sites/5d75794b3c84c70006700381/assets/649c22b24f6bf54116bb283e/Space_Rocks_Powerups_Sprites.zip
    * Starting project (GML Visual): yoyo-www-cms.s3.amazonaws.com/sites/5d75794b3c84c70006700381/assets/649c2af44f6bf54116bb2849/SpaceRocks_GMLVisual.yyz
    * Starting project (GML Code): yoyo-www-cms.s3.amazonaws.com/sites/5d75794b3c84c70006700381/assets/649c2af44f6bf54116bb2848/SpaceRocks_GMLCode.yyz
    Tutorial series:
    1. Base game: ua-cam.com/video/nwlvT-L9vFg/v-deo.html
    2. Main Menu: ua-cam.com/video/Us5GSddVedY/v-deo.html
    3. Music and SFX: ua-cam.com/video/NGNJWpiVS1M/v-deo.html
    4. Power Ups: ua-cam.com/video/xeXsRRYSQ78/v-deo.html

  • @KindergartenThug
    @KindergartenThug Рік тому +7

    The download link for the assets seems to be broken. Leads to a page only showing XML.

  • @eunit08
    @eunit08 Рік тому +6

    Great tutorial. You can add a powerup that lets the player shoot bullets from behind

  • @cliffbowman6816
    @cliffbowman6816 Рік тому +5

    "Teleport" ship to a random location would be a common and fairly simple powerup to add - but how could one code a "teleport to safe location" to prevent the ship from coming out of hyperspace either in a rock or surrounded by rocks that will destroy it instantly?
    Another good powerup is a shield - drawing a circle around the player ship and "bouncing" off of rocks instead of passing through them or exploding. Need to take into account a situation where rocks surround player ship so there is nowhere to bounce TO - bounce rocks away from player instead/as well?
    It'd be interesting to see a shader being used to add "glow" to all the non-text elements in the game room, but that might be a bit beyond the scope of this particular tutorial series,
    BTW, loving the new "Space Rocks" tutorials - the first one simply blew me away with how little effort is required to produce an actually playable foundation for a game.

    • @cliffbowman6816
      @cliffbowman6816 Рік тому

      Come to think of it I would probably have an obj_teleport with an oversized sprite and collision mask. Never draw the sprite, but this object would be spawned at a random location when the user uses the teleport power up. On creation it would check for collisions and relocate if there is one, until there is no collision - then recreate the ship/player object there and destroy the obj_teleport object

    • @schl4u
      @schl4u 3 місяці тому

      I know this is an old comment but in case anyone is wondering: You can use the place_meeting() function to check if the space is safe before teleporting your spaceship.

  • @Zenith2863
    @Zenith2863 Рік тому +5

    i'd like to see a powerup that puts a shield around the ship, protecting it from a hit from an asteroid, if you make another one of these. maybe a lives system as well?
    i think another neat small touch would be to add a little engine flame sprite and/or sound effect to the ship when you're moving forward.
    i'm a beginner so i don't really know, but for the shield, i guess you'd create a sprite, and make it so that when the powerup variable is 3, it would create an instance of the shield around the ship, on a 10 second timer. add collision on the rock so that hitting the shield destroys it (or changes its direction of movement), removes the shield, and maybe gives the ship some s so the powerup doesnt feel janky.

    • @GameMakerEngine
      @GameMakerEngine  Рік тому +5

      Sounds like a cool idea

    • @DaWaffleH8ter
      @DaWaffleH8ter 11 місяців тому +3

      Did you ever get the shield to work for this? I'm currently trying to get that made but can't get the shield object to stay with the player. Any help would be appreciated :)

    • @ponjoh90
      @ponjoh90 11 місяців тому

      @@DaWaffleH8ter
      Hi! I did this by adding this in the "Draw GUI" event for my obj_shield. You could probably just draw another sprite on top of the obj_player instead if you don't want the shield to be a separate object (but I don't know how)
      if (instance_number(obj_player) > 0) // this check is to see if the player is still alive since I both the ship and the shield sometimes colided with the rock, and then I died and then tried to access obj_player, if you make the player invinvible during power_up == 3 this won't be a problem.
      {
      x = obj_player.x - sprite_width / 2;
      y = obj_player.y - sprite_height / 2;
      }

    • @ponjoh90
      @ponjoh90 11 місяців тому

      For anyone else curious. To add a sprite on top of the player, instead of the entire object, add tis code to obj_player.Draw (not Draw GUI).
      You need to have a spr_shield2 sprite for it to work.
      if (powerup == 4)
      {
      draw_sprite(spr_shield2, -1, x, y);
      }

    • @gearsgroundup
      @gearsgroundup 6 місяців тому

      @@DaWaffleH8ter I actually just implemented this.
      I duplicated the obj_bullet collision event that was on the obj_rock. That way it works just like the projectile bullet but now it is a scaling in size ring.
      I referred. to this new circle object as obj_halo.
      On the obj_halo I have the following:
      Create event:
      image_xscale = 1;
      image_yscale = 1;
      Step event:
      image_xscale += .03;
      image_yscale += .03;
      x = obj_ship.x;
      y = obj_ship.y;

  • @brandonbark9138
    @brandonbark9138 6 місяців тому +1

    If you are having issues with the asset download, be sure that you right click + unzip the files after downloading. Then go to tools + import local package in Game Maker to select the images. :)

  • @deathincarnatesplace
    @deathincarnatesplace Рік тому +2

    Add a thrust to it for the ship but using rings like it is magnetic. also i don't remember engine sounds but asteroids has one.

  • @TheRealGamingProductions
    @TheRealGamingProductions 8 місяців тому +1

    Thanks for the tutorials. and the link did not work but it more fun to make one. so it make it fun

  • @masterrocket31
    @masterrocket31 Рік тому +6

    thank you so much. this tutorial helped out so mush. I love how you have both GML visual and code side by side. most other people doing tutorials do not do this.

  • @64bitrobot
    @64bitrobot 4 місяці тому +3

    my favorite part of this tutorial was the confirmation of the existance of delta_time.

  • @OxyWorgon
    @OxyWorgon Рік тому +1

    I had some trouble downloading the sprites.
    So I used a picture of jam for spread and me doing a funny face for the invincibility sprite.

  • @allfenom
    @allfenom Рік тому +3

    Loving these videos!!

  • @meghnaadvijayakar178
    @meghnaadvijayakar178 Рік тому +1

    I can't seem to get the sprites, and when I tried on the official website, the sprite download didn't seem like it was in the right format as it was something called YYMPS.

    • @meghnaadvijayakar178
      @meghnaadvijayakar178 Рік тому

      Please help me quickly.

    • @ryanandrews7761
      @ryanandrews7761 Рік тому +1

      yymps is a format that GameMaker Studio accepts. In fact, it's a format that *only* GameMaker Studio accepts.

    • @Morathan01
      @Morathan01 8 місяців тому

      @@meghnaadvijayakar178 YYMPS is the right format now you need to drag and drop it into gamemaker and then import all

  • @FanGameFishing
    @FanGameFishing Рік тому

    I feel like I followed everything pretty well however after 10 seconds has passed or longer the power up still doesn’t appear!

    • @radekaszek1048
      @radekaszek1048 11 місяців тому +1

      I had a similar problem, but in my case it looked like sometimes power ups were creating and sometimes weren't. What worked for me was cutting part of the code responsible for destroying rocks (all the if-else statement) and paste it at the end of the collision event.

    • @rowgue
      @rowgue 11 місяців тому

      @@radekaszek1048 Can confirm, this is due to the order - Using the visual code I just Cut+Pasted it at the bottom at then it worked

  • @mascarademermelada8746
    @mascarademermelada8746 Рік тому +4

    Next part = How to add Hp to rocks, to ship and implement a pause menu :)))

    • @ee-ye8sn
      @ee-ye8sn 5 місяців тому

      To add hp make a variable that decreases each time the rock is shot, then once the variable is equal to 0, destroy it.

  • @colinwilson7988
    @colinwilson7988 6 місяців тому +2

    Asset Download is broken.
    This XML file does not appear to have any style information associated with it. The document tree is shown below.
    AccessDenied
    Access Denied
    GRZJ7CD8VZAX8J4P
    gHuEffzOj7zj4gwzMYvvg9zpW2NvxFmiXuKrtXxmcr7zKtxZLOK/gfZptt22HUfJZlkpm62EvKo=

  • @giovanipaulo5801
    @giovanipaulo5801 6 місяців тому +1

    the download for actives does not work

  • @DecksandGames-jb1fc
    @DecksandGames-jb1fc 7 місяців тому

    For powerup, I just get idea for spread shooting of 100 bullets or more/less. I test it with 5 and looks cool, but will be kind of same I guess, with 100 just like with 4. Just will have larger range. Maybe some kind of laser just like in Breakout game or maybe to add some lives?

  • @victormanuelmartinezaparic3000

    assets link down or something , great videos btw

  • @aliezz9207
    @aliezz9207 8 місяців тому +1

    so thanks a lot because u helped me to do what i dreamt for

  • @aliceschrock7013
    @aliceschrock7013 Рік тому +2

    For some reason even though it seems all the code is exact it wont spawn in the power ups randomly (using gml code)

    • @HazMatch3
      @HazMatch3 Рік тому +2

      I am also running into this issue!

    • @masterrocket31
      @masterrocket31 Рік тому +3

      how do you add the second power up as an additional option in GML code? im having the same problem.
      Edit: did some fiddling around and got it to work. the code should look like this for having both powerups spawning from rocks in the obj_rock collusion with obj_bullet section. hope this helps.
      if (obj_game.powerup_time < 0)
      {
      var _obj =choose(obj_powerup_spread, obj_powerup_ghost);
      instance_create_layer(x, y, "Instances", _obj);
      obj_game.powerup_time = 20;
      }

    • @ShootFirstNS
      @ShootFirstNS 5 місяців тому +1

      ​@@masterrocket31 Thanks for this

  • @ballhairburger391
    @ballhairburger391 4 місяці тому

    How do I make it so it chooses between the spread and the ghost?

  • @joineryt
    @joineryt 10 місяців тому

    Hey, the sprites for this series of Tutorials are not available anymore. The links are broken. Could you check the links?

  • @KetchupKidKyle
    @KetchupKidKyle Рік тому +1

    Sprites are not on available on the site for download.

    • @KetchupKidKyle
      @KetchupKidKyle Рік тому

      Love the tutorial though!

    • @IXXIMASONIXXI
      @IXXIMASONIXXI 11 місяців тому

      Yeah, access denied so I ended up making my own sprits in the engine myself :)

  • @antoniosebastian1582
    @antoniosebastian1582 Рік тому

    This XML file does not appear to have any style information associated with it. The document tree is shown below.

  • @Tuxedo730
    @Tuxedo730 6 місяців тому

    When I put in the code for the first power up and get into the game and pick it up it just starts shooting really fast for 10 seconds I don’t have to click anything please help

    • @ThatGamingJay
      @ThatGamingJay 5 місяців тому +1

      you have the { bracket somewhere in that code that doesn't have a } to match with it, so just delete the { open one and it should work!

  • @Bombito_
    @Bombito_ 7 місяців тому +1

    it appears to be a problem with the link of the assets, it says "
    AccessDenied
    Access Denied
    VQ27YXX01YZGPT0G
    dmaQJhpGDT6BKsM5fc4ubMJyF0CJsyc6ioNsNPS899vVIWSNkc4oFhlnpSucaHY3zL3gL+vAZa0=
    "

  • @danrobert7241
    @danrobert7241 Рік тому

    This was great! I must have made some weird error though because my timer is only on until I collect a powerup, and then it turns off.

  • @GabrielZilva
    @GabrielZilva 9 місяців тому

    excelente tutorial, excelente professor, documentei todo o jogo no meu caderno e agora vou treinar

  • @IanHollis
    @IanHollis 6 місяців тому

    My power-ups spawn every time a rock is destroyed, and only changed the colour of the ship and add the timer. They don't actually work as expected.

    • @ermenher8381
      @ermenher8381 3 місяці тому

      I had to assign variable powerup_time in obj_game step event to powerup_time - delta_time / 1000000 instead of just - delta_time / 1000000

  • @ricky_3
    @ricky_3 Рік тому

    hey i want to change the colour of sprite with the use of points like after 1000 points the ship turns red or purple how to do that

    • @GameMakerEngine
      @GameMakerEngine  Рік тому +2

      Hey, in the Step event you can add a simple condition:
      if (obj_game.points >= 1000)
      {
      image_blend = c_red;
      }
      In GML Visual, you can use an If Variable condition to make the same comparison, and then use Set Instance Colour to change its colour.

  • @ain23dev
    @ain23dev Рік тому

    i have a weird error at dowloading assets

  • @Rcprobot
    @Rcprobot 8 місяців тому

    The assets won't import for this and the sound assets form the other tutorial don't even download

    • @GameMakerEngine
      @GameMakerEngine  8 місяців тому

      They are working for others, maybe try a different browser and clear cookies etc

  • @schmiddiletsplay
    @schmiddiletsplay Рік тому

    How i can add new enemies

  • @CoolMonkey_at_his_PRIME
    @CoolMonkey_at_his_PRIME 5 місяців тому +1

    assets aint working

  • @Jkkrma
    @Jkkrma Рік тому

    Hey may i ask what font do you use

  • @VileAce
    @VileAce Рік тому

    Asset link not valid

  • @SchmiddiGameas
    @SchmiddiGameas Рік тому

    how i can add a ingameshop?

    • @GameMakerEngine
      @GameMakerEngine  Рік тому

      A step in this direction could be our inventory tutorial: ua-cam.com/video/3FGMKQ_8bIc/v-deo.html

    • @SchmiddiGameas
      @SchmiddiGameas Рік тому

      @@GameMakerEngine i work with Visual

  • @shawn14isme
    @shawn14isme 8 місяців тому

    asset link brooken

  • @user-ky9ur8gm2f
    @user-ky9ur8gm2f Рік тому

    AccessDenied for Assets file :(

  • @treesaretough
    @treesaretough 3 місяці тому

    thank you

  • @olioliolioli5909
    @olioliolioli5909 Рік тому

    Can you please now make it that ou can die with lives and make a new level with enemies? There is a previous tutorial on it but its a very old one and it doesn't work. I like the one you've created with menus and wanna stick to it.
    Cheers

  • @dumpanimator
    @dumpanimator Рік тому

    Thx but i don't know why i feel old game maker feel easier

    • @DecksandGames-jb1fc
      @DecksandGames-jb1fc 7 місяців тому

      This GameMaker has more options to add, and kind of easier to import materials in it. The old one could be kind of easier but limited.

  • @sgtsuper1
    @sgtsuper1 10 місяців тому

    Why am I pinned?

  • @danseptemstudio
    @danseptemstudio 11 місяців тому

  • @bobjohnson2446
    @bobjohnson2446 Рік тому

    First

  • @عبدالرحمن-و2ك9ز

    You said, I testify that there is no God but Allah alone; He has no partners.

  • @tree9845
    @tree9845 Місяць тому

    This no longer works:
    if (obj_game.powerup_time < 0)
    {
    var _obj = choose(obj_powerup_spread);
    instance_create_layer(x, y "Instances", _obj);
    obj_game.powerup_time = 20;
    }
    I haven't figured out a solution yet.

    • @polskijak1545
      @polskijak1545 27 днів тому +1

      Well, I used the code from the video even today and everything works for me. Maybe check to see if you made any mistakes earlier?

  • @mathewnyonyony7855
    @mathewnyonyony7855 Рік тому

    Nice video, I enjoyed the tutorial. May I have your email address please so that I inbox you. Thanks

  • @MalakAmr-gt8gd
    @MalakAmr-gt8gd 7 місяців тому

    the asset link is broken