Make a Platformer in GameMaker! Part 4 (Coyote Time)

Поделиться
HTML-код
  • Опубликовано: 28 сен 2024
  • Part 4 of 9! Don't skip this one it's important! You can also download the fully finished project file for this series on my Patreon!
    Patreon: / peytonburnham
    Wishlist Starcross Starcade Special! store.steampow...
    Rose of Starcross Trailer: https: // • Rose of Starcross Kick...
    Starcross Starcade Special Trailer: • Starcross Starcade Spe...
    My tweets: / peydinburnham
    Rose of Starcross Demo: peytonburnham....
    Discord: / discord
    My twitch: / peydinburnham

Комментарии • 47

  • @matthewlawton9241
    @matthewlawton9241 7 месяцев назад +20

    "The coyote man, he tries to hit the chikin and he misses"...
    ~chef's kiss~

  • @coxyofnewp
    @coxyofnewp 7 месяцев назад +3

    This is just what I needed to help me get my movement sorted for a platformer I been wanting to make for a while.. Many thanks and keep up the amazing content..

  • @wumfumblus
    @wumfumblus 7 месяцев назад +4

    been loving this series so far! excited to see the next vid!!

  • @InkedSpectre
    @InkedSpectre 7 месяцев назад +10

    as someone who is returning to GM after 4 years this series is extremely helpful to see what has changed in movement and collisions. So a huge thank you from me

  • @katincko
    @katincko 4 месяца назад +1

    may God bless u bro, this is one of the only coding tutorials that i understood completely. Thanks brah

  • @DJaycerOfficial
    @DJaycerOfficial 7 месяцев назад +2

    You’ve reminded me that I hate the word coyote.
    Either way I now know what coyote time is. And its origin.

  • @Milu_Indie
    @Milu_Indie 5 месяцев назад

    "People don't like me, so in my video I do whatever I want hahahah very cool!"

  • @funmaster8459
    @funmaster8459 7 месяцев назад +3

    Thank u so much

  • @SouryaLeFunentoi
    @SouryaLeFunentoi 7 месяцев назад +3

    Let's gooooo!

  • @Clownin-round
    @Clownin-round 23 дня назад

    I put in all the code for the first half of the video to get the coyote jump working, but neither the hang time nor the jump buffer are doing anything. I might be blind or something

  • @o2arya104
    @o2arya104 5 месяцев назад +1

    Man m running into a problem with the collisions when my pink square sometimes gets stucks in the walls while jumping and wouldn't move until told to move in the opposite direction. Don't know where i messed up. Pls help!

    • @lazydust1100
      @lazydust1100 3 месяца назад +1

      Tbh, i don’t know how to solve it. I think you should pay a big attention to the variables(specially about the coyote´s variables bc it could be very easy to confuse each of them) as i has a similar problem to yours and i saw that i confuse the coyoteJumpFrames variable with the coyoteJumpTimer.
      It was five minutes ago that i figure it out 😂

  • @HauteOroute
    @HauteOroute 6 месяцев назад

    Making our first game step by step with you is a real please to do! Impressive how fast you manage to analyse what''s wrong in your code when you do a mistake. Do you use the debug mode sometimes to see what's happening? I'm struggling a bit with this part.

  • @seabeast3965
    @seabeast3965 7 месяцев назад +12

    You rock for making this series! This is already the best platformer tutorial I've come across for gamemaker, absolutely stoked to be following along with this 👏

  • @johnniefinney3266
    @johnniefinney3266 7 месяцев назад +3

    I'm just curious if you had some videos or RUclipsrs that could educate on art/drawing sprites.
    The thing about your series is that I've seen pretty much everyone of your videos and even have some bookmarked basically to where my problem lies not in the mechanics but the art because Im terrible at sprites

    • @peytonburnham4316
      @peytonburnham4316  7 месяцев назад +1

      I don’t personally have any videos or have first hand experience with pixel art youtubers but there should be plenty!! I would just say do a little bit of searching for tutorials and ALSO take looks back at your favorite pixel art games and really look at how they’re drawn and animated!

    • @johnniefinney3266
      @johnniefinney3266 7 месяцев назад

      @@peytonburnham4316 thanks

  • @AnthonyGourmand
    @AnthonyGourmand 5 месяцев назад +2

    Hey I watched your tutorial on the coyote jump and I wanted to try doing it solo before watching how you did it but I realized that you put a lot more variables than I thought so I wanted to know if what you think knowing that the result is the same. So her was my code :
    for the create section:
    coyotejump = 5;
    coyoteHangFrame = coyotejump;
    For the step section:
    //Coyote jump
    if !place_meeting(x, y + 1, obj_wall) && coyoteHangFrame > 0 { coyoteHangFrame-=1;}
    //count jump if you fall into the air
    if !place_meeting(x, y + 1, obj_wall) && jump_count =0 && coyoteHangFrame=0 { jump_count = 1}
    else if place_meeting(x, y + 1, obj_wall){jump_count =0; coyoteHangFrame =coyotejump}
    //Multiple jump
    if jump_count < max_jump && space_key
    {
    jump_count += 1
    yspeed = -power_jump;
    }

  • @azuli4440
    @azuli4440 7 месяцев назад +3

    HELLO

  • @dennyforthewin
    @dennyforthewin 7 месяцев назад +2

    Thanks for posting this series. Its been fun and easy to follow along.

  • @lost50
    @lost50 2 месяца назад +1

    Peyton, did you realize the pink square's bottom is slightly below the platform's top?

    • @lksxxtodin5292
      @lksxxtodin5292 2 месяца назад

      That's a sub pixel problem. Gamemaker is drawing on the application surface (that are the size of the screen most of the time), so one pixel in the surface is the size of many pixels because of our resolution.
      So, lets say, the application's dimensions are 1280 width and 720 height and our camera is 320 width and 180 height, so the size of one pixel in camera will be actually 4 pixels in the application, and if I am 1.5 pixels down (because of the _subPixel variable), there are space in the application for it, but in reality they are just fine.
      Hope you get it! I'm not so good at teaching

    • @lost50
      @lost50 2 месяца назад

      @@lksxxtodin5292 it can easily be fixed. If player bbox_bottom is > platform.bbox_top, then set player y = platform.bbox_top

    • @lost50
      @lost50 2 месяца назад

      @@lksxxtodin5292 fix: if player.y > ground.bbox_top, then player.y = ground.bbox_top

  • @lksxxtodin5292
    @lksxxtodin5292 2 месяца назад +1

    if you set the coyoteHoldFrames to zero then the jump just stop working. That's because every time you add the gravity you change onGround to false, that would be every frame. You could make a simple check like:
    if ( coyoteHangFrames >= 0)
    {
    setOnGround(false);
    }

  • @skippy1500
    @skippy1500 9 дней назад

    I finished this tutorial and the player doesn’t have a delay and I can double jump when falling of a ledge even though I set my jumps to only 2. Anyone know what might’ve caused this?

  • @ethanstefura5359
    @ethanstefura5359 Месяц назад

    I spent about 20 mins rewatching trying to understand where i went wrong...
    This is what I caught after three full reviews of the step event + create event:
    //Y Movement
    //Gravity
    if (coyoteHangTimer > 0)
    {
    //Count the timer down
    coyoteHangTimer--;
    } else {
    //Apply gravity to the player
    yspd += grav;
    //we've realized we're no longer on the ground
    setOnGround(false);
    }
    yspd += grav;
    Just a reminder to everyone to take a break from looking at your code once in awhile when you're trying fix or find a problem. Otherwise you might end up as a goof like me!!

  • @SpaceBittt
    @SpaceBittt 3 месяца назад

    the Coyote Time isnt working because im adding gravity everytime im not jumping but, if i make variable jumping just cut of the JumpHoldTimer, it won,t actually be a variable jump height, and i have no idea why, even tho the code's the same

  • @CraigHodson-e8m
    @CraigHodson-e8m 17 дней назад

    1 spelling mistake cost me an hour again, at least it works now. on to the next

  • @Sentientashtray
    @Sentientashtray 7 месяцев назад +2

    Hell yeah

  • @XaraHollowKnight
    @XaraHollowKnight Месяц назад +1

    my character is stuck on the ground now how do i fix this

    • @CraigHodson-e8m
      @CraigHodson-e8m 17 дней назад

      did you figure this out? ive got jumpMax of 2, it lets me jump once, then no more jumping

    • @XaraHollowKnight
      @XaraHollowKnight 16 дней назад

      @@CraigHodson-e8m nope, i just removed coyote time all together. my character's floaty anyway, it'd be hard to notice

    • @CraigHodson-e8m
      @CraigHodson-e8m 16 дней назад

      @@XaraHollowKnight I figured it out. I had an "x" where there should have been a "y".

    • @XaraHollowKnight
      @XaraHollowKnight 16 дней назад

      @@CraigHodson-e8m OOOOHHHHh, nice

    • @dparon127
      @dparon127 11 дней назад

      I'm having the same issue, I hit space to jump and it comes up as illegal array use
      at gml_Object_Obj_o_Player_Step_0 (line 84) - if yspd > termvel { yspd = termvel}

  • @orions2908
    @orions2908 3 месяца назад

    I'm able to double jump now for some reason, despite setting the jumpMax to 1

    • @orions2908
      @orions2908 3 месяца назад +1

      nevermind setting onGround to false after initiating the jump fixed

  • @ShaolinMonkster
    @ShaolinMonkster 7 месяцев назад +1

    What a legend.

  • @matthewlawton9241
    @matthewlawton9241 7 месяцев назад +1

    This video appears to have broken the jump buffer. It no longer functions for me no matter how large I make it...

    • @peytonburnham4316
      @peytonburnham4316  7 месяцев назад +1

      Good catch!! It's actually not broken but may not be working how you expect it to, which is something I wish I had noticed. As long as you're holding the button, the buffer still works, so you still don't have to be as precise with your button timing, but if you just want to tap the button, basically the jumpHoldTimer will be reset the second the player hits the ground. So if you want to change that behavior just move the code commented as "//Cut off the jump by releasing the jump button" (where we set the jumpHoldTimer to 0) AFTER the next little bit of code labeled as "Jump based on the timer/holding the button" and that'll fix it! Thanks for pointing this out to me!

    • @matthewlawton9241
      @matthewlawton9241 7 месяцев назад +1

      @@peytonburnham4316Thank you so much for replying! And for this series, it's been incredible!

    • @matthewlawton9241
      @matthewlawton9241 7 месяцев назад

      @@peytonburnham4316 Not that you probably needed it said, but for my fellow new coders, this worked perfectly!

  • @alexschamban5599
    @alexschamban5599 2 месяца назад

    This series is by far the best and most well put together gamemaker tutorial I have come across! thank you so much