Why Slopes are Shockingly Difficult for Indie Game Devs

Поделиться
HTML-код
  • Опубликовано: 25 окт 2024

Комментарии • 1,5 тыс.

  • @InboundShovel
    @InboundShovel  2 месяца назад +83

    If you're interested, here's where you can wishlist Isadora's Edge on Steam! store.steampowered.com/app/3125320/Isadoras_Edge/
    And you can follow the Kickstarter here: www.kickstarter.com/projects/inboundshovel/isadoras-edge
    Thank you!

    • @lukchem
      @lukchem 2 месяца назад +3

      Are you making this game only for Windows or other platforms like macOS too?

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

      I second @lukchem - I hope you create a macOS build!

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

      So glad I found this video now. I prototyped some different terrain, some with slopes and immediately noticed when going down hill triggers my falling animation. This video is very inspiring and informative. Thank you.

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

      How have I never heard of this game before, till I got showed this Vid by The Girl from Arkanya's Dev...? :O
      It's on my Radar now. :) (Though the intended to be terrifyingly hard Bosses scares me more than a lot... that sounds like Dark Souls territory, which is a Realm of the Player Gods a skill-less idiot like me will never belong... 😔 )

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

      Some games rather than fix the NPC interactions with slopes just turn it into a feature. I do admit that this solution isn't right for all game designs.

  • @Baekstrom
    @Baekstrom 2 месяца назад +2195

    Just put them on a parallax layer in the background. I'm sure that the players will remember the game as having slopes, even though they never actually interacted with one.

    • @KsavirResh
      @KsavirResh 2 месяца назад +251

      Brilliant!

    • @InboundShovel
      @InboundShovel  2 месяца назад +651

      Now we're cookin

    • @glacierwolf2155
      @glacierwolf2155 2 месяца назад +126

      Slopen't

    • @ezpz4646
      @ezpz4646 2 месяца назад +22

      Pay him!! 😂😂😂​@@InboundShovel

    • @JonathanMeyer-o4m
      @JonathanMeyer-o4m 2 месяца назад +91

      this is literally what Hollow Knight does, it's brilliant

  • @theOtherMichael
    @theOtherMichael 2 месяца назад +353

    It's probably too late for this advice, but I think a lot of your physics problems aren't actually to do with slopes. Instead, I think it's because you're using a physics-based player controller instead of a kinematic one. Issues like speed on slopes, snapping and slopes, and so on are a lot easier to handle when you're not fighting physics.
    You wouldn't, for example, have to adjust player speed just to un-break running on slopes. You would simply move the player horizontally, then snap them to the slope. They get the vertical motion for free, and adjusting run speed on slopes becomes opt-in. Sure, you're handling gravity and momentum yourself, but that's often less work than fighting physics every time you fix a new edge case.
    None of this is to mention features like coyote time, asymmetrical jump arcs, and input buffering, all of which are easier to implement when your controller is the only thing driving player motion.

    • @hollenwanderer
      @hollenwanderer 2 месяца назад +70

      Yep, pretty much write your own simplified physics that fits the game logic, this is pretty much how every classic sidescroller did it. Unfortunately engines like Unity tend to encourage beginner developers down the path of yeah, using a full rigid body simulation which is just completely silly for a game like the one this guy is making.

    • @RipVanFish09
      @RipVanFish09 2 месяца назад +22

      100 percent. I would always recommend writing your own movement and game physics. Sure, it takes more time and effort, but it makes many things way easier and gives you so much more control over everything.

    •  2 месяца назад +13

      I scrolled down specifically to find this comment. Sliding down a slope would be extra work if you wrote minimal physics from scratch, rather than something you need to work around.

    • @lukefortune8314
      @lukefortune8314 2 месяца назад +19

      thank you. I hoped someone would notice the severe over-engineering here.

    • @YourLocalZombie
      @YourLocalZombie 2 месяца назад +9

      Commander Keen 4-6 and Keen Dreams and all the fan games built on the KEEN4 engine since 1992: Has isometric perspective and slopes with climbing (except Keen Dreams which didn't have climbing) and occasional fake z-axis movement. Enemies have the same abilities. The key: they didn't have enough memory for real physics, so they didn't do real physics.

  • @AZaqZaqProduction
    @AZaqZaqProduction 2 месяца назад +940

    One benefit to slopes is that if it's too obvious that a game world is built to a grid, that will make it feel a little too gamey. With more varied terrain, it can feel a lot more natural.

    • @RedMattis
      @RedMattis 2 месяца назад +142

      I agree. Enemies with floating feet has been a thing in both 2D and 3D for ages. Just like the player character standing with one side off a ledge. Generally people just accept it since it is still generally better than everything feeling blocky and inorganic.

    • @SpaceE1f-Jiro
      @SpaceE1f-Jiro 2 месяца назад +69

      @@RedMattis Exactly. I can look past a character floating slightly if it means a more organic looking world.

    • @Juke172
      @Juke172 2 месяца назад +44

      just don't use tilemap and tileset everywhere. even if it's blocky world. hide the fact it's using tilemap by covering the world full of decorative sprites etc. no need for slopes.

    • @doughboywhine
      @doughboywhine 2 месяца назад +17

      I mean if you implement only slight slopes it won't be very noticeable that the player & enemies are floating off it, while still adding to the game looking natural

    • @RedMattis
      @RedMattis 2 месяца назад +36

      @@Juke172 Or better yet, use slopes but put stuff in front of the slopes like stair rails, bushes in forests, etc. to hide the floatiness.
      But yeah, I mean you can skip slopes, but it is still noticeable and gives the game a precision-platformer vibe whether you want it or not.

  • @mrwizard5012
    @mrwizard5012 2 месяца назад +614

    "You cant do that on a slope! The foot is off the ground!"
    Meanwhile, all the classic platform games: *_(supports full weight on single toe)_*

    • @pegasBaO23
      @pegasBaO23 2 месяца назад +70

      Mario and Sonic didn't skip calf days

    • @whynologin
      @whynologin 2 месяца назад +18

      Castlevania Adventure even has you jump from ledges when not even a pixel is left touching the ledge. You can't finish stage 1 if you don't jump that late. Go check out some walkthroughs at 0.25 speed and you'll see it very clearly.

    • @Channel9001
      @Channel9001 2 месяца назад +24

      @@whynologin I think they call that "Coyote time", a reference to Wile E. Coyote not falling until he looks down. Basically it means the programmers put in a little space at the ends of ledges where your characters looks like they aren't standing on the ground anymore, but you can still jump. It makes long, last-second jumps more forgiving.

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

      @@Channel9001 Which is what made it so weird. Instead of implementing it to be more forgiving you are required to make jumps like or you wouldn't be able to reach the next platform.
      They could have either just made you jump farther or decreased the space between platforms, but for some reason decided to go with that.😕

    • @BxPanda7
      @BxPanda7 2 месяца назад +13

      @@whynologin It's a similar concept to having the last 20% of your health be equal to the other 80% of your health in modern games, you could have just given more health, or made the enemies do less damage, but you would have lost that cool factor of feeling like you just barely made it trough with only a sliver of health remaining and the adrenaline rush of feeling like you're about to die wouldn't have been part of the experience, making it more dull.
      A good game can easily be designed in a way that will look harder than it actually is and make you feel better than you really are to keep you hooked instead of making the game easier and less enjoyable.

  • @lowsketchblue
    @lowsketchblue 2 месяца назад +612

    Ok, as someone that has been working in a Sonic fangame that has lots of slopes, here's how I did it for anyone who wants to try, aswell as some opinion as to why you SHOULD implement them :)
    1. Ground Sticking
    Shoot a raycast from the players center of the body, not its feet/base. If it touches the ground then it's considered on ground, and we get it's normal.
    Align the players collider with the ground normal, if you don't want to visually rotate your character, create it in a separate object (or detach it when it starts) and give it a script that manages it's own rotation, by either copying the collider rotation, or doing whatever you want.
    Lerp the character rotation so it doesn't snap whenever there is a change in slope.
    Set the players position in the raycast hit point + the ground normal times whatever height you want.
    2. Fix velocity
    If you're using rigidbody forces to move your collider, within the ground sticking process, project the velocity vector towards the ground plane. Unity has a function to easily do this, where you just give the velocity and ground normal as parameters (any other engine should have a similar function).
    To maintain your speed during the projection, create a temporal variable to store your speed, project the velocity, normalize it, and multiply it by the store speed. Finally make the rigidbody velocity this new created velocity vector.
    Convex edge cases can be solved by making the raycast long enough until there aren't any false negatives.
    As for concave cases, I made it so we shoot a raycast in the velocity direction (or the players forward direction) to check if there is a slope in front of us, making sure it isn't a wall by checking its angle and if it is a slope we can be on, project the speed on the new normal that its ahead of us (this is only necessary in games were the player goes in a variable running speed, like sonic games, in most games with set speeds this step can be skipped).
    3. Air movement
    For jumping, we create a function that whenever we jump, we deactivate the ground sticking by 0.2 seconds or so.
    Gravity can be applied whenever we're not grounded, there is no need to apply gravity otherwise.
    3. Visuals
    Personally, I haven't dealt with this myself, but here's my idea.
    Create a few standing animations depending on the angle of the slope (as few as two or as many as you want), and when running (detecting the rigidbody speed more than 0 or any other method) align the character rotation to the ground. The snapping to the ground normal/ to the up vector could be well hidden with a settle animation or running start frames, if it's still to noticeable. (Important in case you're making a 3D game, there's a technique called inverse kinematics to make sure that the feet are always glued to the ground).
    This should work pretty well with any type of floor perspective you use.
    4. Enemy behavior
    The same for the enemies, if anything with less steps to fix the velocity as they don't have to be this precise. Aligning the enemies to the floor normal should fix any "floating" animations, if you're still not convinced that a big enemy would be almost sideways, just make a limit to the slope angle they'll be willing to walk on.
    More as an opinion piece now, I don't think that there has to be specific cases where slope are used for them to be important, I think it still adds value to having them for the sake of versatility at the time of creating levels, like creating a difficulty curve at the time of presenting challenges (slopes can make any challenge easier or harder to beat), creating variation on environmental gameplay (like more natural environments can have more slopes, and more mechanical/urban have less), and often times not implementing them it's just going to be more workload for the level designers. Not saying that every game should have them, the point of the video still stands.
    That's all, sorry for the probably bad english, not a native speaker, lol.

    • @unique_two
      @unique_two 2 месяца назад +23

      I love this writeup! I was thinking throughout the video that sonic games have slopes and really benefit from them. Any tricks to keep the art complexity low? For example Sonic turns into a ball shape sometimes, is that to keep art complexity low?

    • @amandaslough125
      @amandaslough125 2 месяца назад +19

      ​@@unique_twoSonic being a ball obviously makes things easier, since he's just rolling through stuff. But overall the sprites just rotate with the floor. Even in loops and such. You just have to take into account inertia and such when jumping or getting hit (enemies aren't usually near loops though).

    • @grudley
      @grudley 2 месяца назад +13

      One solution to visuals would be to use some kind of skeleton based procedural animation rather than sprites. You'd have to make that decision very early on tho

    • @gabrieldesouza112
      @gabrieldesouza112 2 месяца назад +4

      This is a really complete explanation, why nto make a documente or a video about it?

    • @mozvi1436
      @mozvi1436 2 месяца назад +8

      About the ground sticking, imo it depends a lot on your game mechanics. I'm thinking about games like Celeste specifically where the devs added a ton of leeway for the player when they're on a ledge. In celeste, only one of the bottom pixels of the hitbox is required to touch the ground for you to be in ground state, and you're also snapped to the ground if your vertical position is ±2 pixels off the ground. Raycasting from only the middle of your character might break things like that. Celeste doesn't use slopes however, so that solution wouldn't apply in it anyways 😅
      Anyways, thank you for the good advice!

  • @RoboBoddicker
    @RoboBoddicker 2 месяца назад +286

    Everyone talking about Sonic, forgetting that Mario Bros 3 had full-on slope physics on the NES :D

    • @hexidecimark
      @hexidecimark 2 месяца назад +37

      Sonic's slopes are much more robust than SMB3's and also much, much more flexible. The SMB series is also plagued with really janky implementations that tend to feature incomplete solutions that rely specifically on the game **being mario**, and the level design being from mario.
      Even in SMW, the slope code includes subroutines to physically teleport mario up and out of slopes, which calls for two tiles or mario can literally just walk through the floor and die.

    • @RoboBoddicker
      @RoboBoddicker 2 месяца назад +6

      @@hexidecimark lol good shit. Of course, Sonic developers got to shortcut around animation issues by rotating sprites - or literally just turning Sonic into a ball :)

    • @hexidecimark
      @hexidecimark 2 месяца назад +14

      @@RoboBoddicker The rotation is part of their solution- mario uses a flowchart for physics interactions and lots of teleports, sonic actually has a primordial physics engine that relies on a mixture of sonic's H shaped physics sensor grid (flips are due to either gravity variables or the middle bar of the H finding a tile under specific circumstances), a lot of different speed variables, and loading tile data in a specific way.
      Implementing mario's setup would have been much simpler, but any new interactions have to be stapled onto the flowchart and get nullified under very odd short-stop conditions (coin collection is baked into collisions, but collisions can't be calculated in the same tick that a coin is collected during), then made up for by a bunch of extra flowchart that specifies rules for corrective teleportations warps to combat subpixel miscalculations.
      Sonic's setup can be used in virtually any 2D environment, and this is why stages allow for so many varied gimmicks.

    • @npc_blob1609
      @npc_blob1609 2 месяца назад +14

      @@RoboBoddicker Genesis Sonic games didn't get to shortcut by rotating sprites. They had to make separate angled ones. Sonic Advance on GBA did rotate its sprites in realtime, and Sonic Rush uses 3D models.

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

      @@npc_blob1609 Wow crazy. I just assumed they were doing sprite rotation as a fancy new 16-bit trick.
      I honestly wouldn't understand a thing about NES or Genesis code to look at it, so thank you guys for schooling me :D

  • @Crits-Crafts
    @Crits-Crafts 2 месяца назад +584

    "it's over Anikin I have the high ground"
    "You underestimate the power of the slope"

  • @globalistgamer6418
    @globalistgamer6418 2 месяца назад +343

    I think the main problem for modern indie games here is an over-reliance on generic, built-in physics engines that weren't designed for 2D platforming, rather than having the gameplay programmer create bespoke physics suited to the game, similar to the development process for 16-bit titles. Mega Man X was mentioned in the video, as well as Sonic frequently in the comments, but also games like Super Mario World (or even SMB3 on the NES), Gunstar Heroes, Kirby Superstar and many other memorably used slopes to great effect without a perspective artstyle, while restricting larger or awkward enemies to areas without them.
    Regarding metroidvanias specifically, I think slopes are very valuable for both enabling physically varied and distinctive level geometry as well as the ability to compress map layouts by supporting smooth bi-directional connections between rooms that aren't orthogonal to each other. In Super Metroid, the room to the left of where you get the Speed Booster, which serves as its only entrance and exit, is a good example: because the room slants diagonally upwards, the player is able to just barely escape the vertical rising lava that is triggered by obtaining the power-up merely by running directly left, immediately demonstrating the value of the new ability, something that wouldn't be possible if the transition was manged by a series of elevated ledges. On the other hand, looking at something like Hollow Knight, while that game's eventual monotonous nature is primarily due to the size of the world being too large and the low cadence of ability acquisition after the first few hours, lacking slopes is still a notable secondary issue, as their addition could have gone a considerable way to diversify level design on either a micro level or between biomes.

    • @JonnyRobbie
      @JonnyRobbie 2 месяца назад +47

      Thats my thought too. Bloke is creating a generic pixel art platformer #42069 and is looking for excuses to make it even more genericer.

    • @oliverholm3973
      @oliverholm3973 2 месяца назад +35

      Yeah I mean the main crux of the issue really is just the overabundance of game devs, even in the industry, who just don't know how to do things on their own. They are too comfortable relying on the tools that are fed to them. Nothing wrong with that if you're just making games for a hobby, but if you wanna make a commercial product, strap up and actually learn the necessary mathematics and computer science to understand the tiny details that make or break the game feel and performance.

    • @Senae
      @Senae 2 месяца назад +25

      it's wild that dude brings up Mega Man X (a game with an art style similar to his own) but later when talking about the art problems, only talks about Mega Man X4 a completely different art style, which a lot of people specifically dislike BECAUSE of the perspective!
      Like, from an art perspective, the simplest solution feels like it would just be to make the slopes hitbox actually start a little bit offset from the art, so the sprite starts descending earlier. it'll still look jank, but that's basically how it works in MMX and my dude literally cited that as a reason to use slopes so like...
      (yes, slopes also provide a complicated programming problem, but there's footage of that being solved for this project already so like...)

    • @nspade9252
      @nspade9252 2 месяца назад +4

      @@Senae I will say that making the "origin" of slope collision be the center of an object's collision is definitely trickier and has a lot more potential points of failure than just using the left/right edges, but plenty of devs have pulled it off since basically the start and it's definitely worth the effort for how much fun the result is.

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

      I agree, and I don't think alot of modern engines are helping. Godot for instance, has a lot of ups and downs but one of the biggest issues I ran into when I tried it out is that it seems to completely reject basic attemps at pixel-based movement. Manually altering position frame by frame with the simplest code would cause some pretty crazy stutter.

  • @misk-ivus2990
    @misk-ivus2990 2 месяца назад +290

    If I recall correctly, Castlevania Symphony of the night only used slopes in...
    A. Rooms where the enemies don't interact with terrain.
    B. Rooms with enemies that are specifically made to interact with slopes in specific ways. (like the dragon skulls that roll down stairs.)
    And if there are any normal enemies in the rooms, they just don't go on the stairs or don't stay grounded. Clearly, even the devs of that game struggled with slopes. In fact, the entire early Castlevania series made stairs something that only the player interacts with.
    I've been brainstorming and making ideas for video games for years, and only ONCE have I ever thought about slopes, and it's a boss fight where the boss is stationary and uses attacks that don't interact with terrain XD

    • @Russian_engineer_bmstu
      @Russian_engineer_bmstu 2 месяца назад +22

      then area of sorrow had a lot of rooms where stairs and slopes were combined for great effect on a platform with calculating power of less then half of a modern calculator
      disk armor, sucubi, those rolling lion things, valkeries , dog dudes, were all used in both rooms with and without slopes
      also, in sotn there ARE rooms with slopes and enemies not designed for them, but in the inverted castle, where archways turn into bowls of death etc

    • @Trazynn
      @Trazynn 2 месяца назад +4

      Seems like Metroid Dread also only uses slopes where enemies aren't touching them.

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

      @@Russian_engineer_bmstu There's a lot of NES games with slopes, hardware that's significantly weaker than the Nintendo DS. Like Super Mario Bros 3, Castlevania series, Super C (Contra 2) and the Wizards & Warriors series for some examples.
      Then you have crazy NES games like Gimmick! which includes a physics engine, but this is possible thanks to expansion hardware included in the game cartridge.

  • @sitnamkrad
    @sitnamkrad 2 месяца назад +37

    You are absolutely correct that if you don't really have a purpose for something in your game, it should be taken out. But I think a lot of the issues you are facing are due to you actually using the physics engine to do movement. In many of the games you have given as example, they only use simple collision checks and give the character a certain speed until collision says "no". Gravity would be a simple acceleration purely affecting the Y axis without any regard for slopes. A lot of the fixes you mentioned here are in fact extra steps to counteract previous steps that the physics engine did for you, that it shouldn't have been doing in the first place for your style of game. I highly recommend looking up some videos on how these classic games do movement and collision detection. It can be a huge help in creating the way the controls feel in these classic games.

  • @spindash64
    @spindash64 2 месяца назад +269

    Laugh-cries in Sonic-type physics
    But seriously, not only am i locked into using slopes, not only do i need to fight with the engine to get accurate collision angles, i need to also build LOOPS. Aka, slopes that go completely upside down, and also switch collision layer so you can phase thru a part that was previously solid.... AND build Rails, which are all of the above, and also semi-solid relative to player rotation
    The problem with trying to be faster than light is that you can only live in darkness

    • @Twisted_Logic
      @Twisted_Logic 2 месяца назад +21

      Honestly, from my own experience trying to make that style of game, I'd say just script the top half of the loop so if you're going above a certain speed it plays a canned animation of you going around it

    • @yet0another0account
      @yet0another0account 2 месяца назад +20

      ​​@@Twisted_Logicthat sucks since jumping off a loop early to gain speed is a well known mechanic.

    • @spindash64
      @spindash64 2 месяца назад +21

      ​​@@Twisted_Logic
      Automation is the enemy for this project: actions MUST be able to chain their momentum into one another, and this isnt even considering how i would make rail grinding work without slope physics. And make no mistake, the PHYSICS to those rails are critical

    • @theapexsurvivor9538
      @theapexsurvivor9538 2 месяца назад +3

      My thoughts on a solution would be to make precisely 0 "ground" loops, and instead just make two rail loops with one using the grind animation, and the other using the run animation. For the actual rail mechanics, give the player a footbox if they don't already, and if the footbox collides with the rail it'll mount a sliding platform that inherits momentum from the player, follows the spline used for the rail, and can be dismounted with a jump or by reaching the end of the rail.
      It's a little obnoxious, but it also means you can create flat rails and momentum puzzles by using the components in different ways (nothing like having spring platforms and quarter pipes to encourage fast gameplay, and ice to be hell on earth)
      Getting the passing section to work will pretty much always come with some hassles and jank, but I'd probably just have the platform automatically ride any rail sufficiently close to it regardless of layer, and have it prioritise rails on the same layer over rails on a different layer, then just have the rail be on the front for the first quarter, briefly overlap with the one for the rest of the loop in the back (forcing the player into the background) then have a front layer exit from the end of the loop out about as far as the player can jump (or just have the player default to the front layer when they dismount, but that might result in some jank and clipping problems).

    • @archierm
      @archierm 2 месяца назад +12

      Sonic games are physic simulators disguising themselves as platformers lol

  • @Yasokiii
    @Yasokiii 2 месяца назад +19

    3:16 literally all of those things are realistic tho, and would make slopes interesting instead of just something that acts exactly like normal ground but doesn't look like it. Having it take longer to come up, and you slide down fast, could be great for trying to escape an enemy, or sliding into a trap area full of them.

  • @kip9631
    @kip9631 2 месяца назад +179

    It is a slippery slope to frustration

  • @nmay231
    @nmay231 2 месяца назад +27

    I've never wanted to make a game with slopes more than after watching this video

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

      You and me both!

    • @matheus-pese
      @matheus-pese 2 месяца назад +1

      same. lol

    • @hiiambarney4489
      @hiiambarney4489 Месяц назад +7

      It's because his reasoning is so far from the reality. It kinda upsets me a bit.

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

      @@hiiambarney4489 how

  • @timseguine2
    @timseguine2 2 месяца назад +276

    Actually, it makes physical sense to move up a slope more slowly and down a slope more quickly. So that isn't really something you necessarily have to "fix". And that somewhat mitigates the edge guarding problem you were talking about.

    • @n3ppy632
      @n3ppy632 2 месяца назад +54

      Yeah but it doesn’t feel “right” gameplay-wise.

    • @timseguine2
      @timseguine2 2 месяца назад +47

      @@n3ppy632 probably because I think most people wouldn't expend constant effort in a similar situation so it feels floaty or unresponsive. Still I think it could feel fine if you make the effect more subtle. Especially if your movement system has momentum.

    • @samamies88
      @samamies88 2 месяца назад +24

      @@n3ppy632 depends on a game.. for exampe... didn't sonic have this slow down when going up and higher speed when going down (didn't matter if you were ball or still running)? or am i just remembering this incorrectly. Also iirc super mario bros 3 also slowed mario down when running uphill a slope (1st world had few stages that had them... after that iirc it was mostly used in cave levels and pipe shortcut mid-sections and iirc people mostly wanted to just spam jump when going up.. so yes it didn't feel good to go up but going down... there were 2 options: either you kept running which i think accelerates you faster or if you crouch in slope you actually slide down and most enemy types are deleted). Sonic especially didn't suffer from having sloped affecting your moving physics. Mario maybe did but the levels were created in ways that allowed players to have fun with them (there were enemies often near bottom of these longer slopes and sliding on them to knock em out was entertaining).
      It is all about how you design the levels and physics around the whole game. I do agree that some games would suffer from these as going up especially might not feel good if it is slow. But also it is totally possible to make slopes have purpose.

    • @InboundShovel
      @InboundShovel  2 месяца назад +78

      Yeah, this is true! However, the math I did to "fix" it actually just lessened the impact of the slopes. You still moved a little faster down the slope, and a little faster up the slope - based on the angle of the slope. The default physics was just /too much/ of an effect, which made it feel super weird to play!

    • @ringkichard
      @ringkichard 2 месяца назад +30

      ​@InboundShovel I feel like this is maybe an important lesson? It's a lot of work to make slopes behave like normal platforms... and the reward is that slopes are now normal platforms.
      All the cool stuff you can do with slopes is because they're different from flat platforms: ice slopes, launch ramps, rail grinding, loop-de-loops, momentum conservation during elevation changes, pendulum enemies that hug the ground, etc.
      Don't spend all the time to make slopes the same when you could be spending time to make them different.

  • @Nathouuuutheone
    @Nathouuuutheone 2 месяца назад +27

    Alternative: make floors basically work like defined paths and link together. Players and enemies can move freely along paths, and then can break free by going aerial. Path segments are given properties that affect jumping, landing, acceleration, friction, and so on.

    • @theapexsurvivor9538
      @theapexsurvivor9538 2 месяца назад +6

      Adds support for stuff like curves and consequently quarter pipes and loops, perfect for Sonic style games.

    • @HenryLoenwind
      @HenryLoenwind 2 месяца назад +6

      And when using tile-based levels, you get those paths automatically. All that raycasting is overkill when you simply can look at the tile grid...

  • @NavnikBHSilver
    @NavnikBHSilver 2 месяца назад +50

    The bottom line I feel is more "Always have a critical mindset about non-essential features that might cost a lot of work", than it is about slopes.
    I genuinely wish I could be like that because if I have a clear idea in mind when it comes to user experience, I will work towards that goal, regardless of complications.

    • @todesziege
      @todesziege 2 месяца назад +8

      It is always valid to ask the question "why does this exist?"

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

      That should be question 1, the second question should be "am I using the right tools for this job?"
      If you don't need them, don't use them. If you _do_ need or want them, make sure you're using tools that facilitate that. Using a character controller designed for flat platforms only is not going to be a great time when dealing with slopes. Use a solution designed from the start to support slopes.

  • @RicardoRebelo99
    @RicardoRebelo99 2 месяца назад +17

    I wonder how the folks at Moon Studios handled this issue with Ori. One of the things that stood out the most for me while playing Ori, is how fluid and beautiful it is. And it does have a lot of slopes, of different heights and angles.

    • @manoflead643
      @manoflead643 2 месяца назад +9

      Most likely, they didn't treat surfaces as dumb collision hulls. Treat it as a path. Why on earth would you do raycasts when you're on the floor? When Ori is on the ground (or climbing a wall), it's just following that path. In ori 1, I'm fairly sure Ori's just rotated to follow it too, and no floor is particularly steep, and the point where it becomes a wall is surprisingly shallow.
      Ori 1 probably had to do that because, well, 2d animation. All the slopes are shallow, and really what the effect is for, is detailing its surfaces. The Ginso Tree in particular makes it super obvious, when you slide past or run over a knot in the wood. Actual physics would have Ori flung away from the wall, you know? Very nice, fantastic effect, but there's never a 45 degree slope.
      Ori 2 can get away with a lot more because Ori's a 3d model, and therefore they can adjust the legs in real time, and therefore afford steeper slopes. Don't think they did, though, because, like... platforms are more fun to jump up, y'know?

  • @Widdy123
    @Widdy123 2 месяца назад +123

    This video was coincidentally uploaded right when I was currently struggling with slope physics for my own game (specifically how they affect acceleration), too bad they‘re absolutely integral in mine. I have no clue what to take away from this.

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

      Hi, just curious! What type of game are you making that absolutely *needs* slopes? :o

    • @Widdy123
      @Widdy123 2 месяца назад +6

      @@fochti 3D Platformer

    • @HaydenTheEeeeeeeeevilEukaryote
      @HaydenTheEeeeeeeeevilEukaryote 2 месяца назад +6

      @@Widdy123others have solved it, so with the internet youll be able to as well. It may still be hard and take a while, like you may even have to rewrite the physics to be cleaner but i think youll be able to get it working

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

      @@HaydenTheEeeeeeeeevilEukaryote I‘ve already figured out the acceleration part, I just gotta figure out how to stick the player to them at the right times and how they affect jumps

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

      @@Widdy123 i wish i could do something to actually help lol, i cant even give vague advice as i myself struggle with everything coding

  • @HoloTheDrunk
    @HoloTheDrunk 2 месяца назад +36

    The real root issue is using physics-based movement in a game where you don't want your player to effectively be a ball that rolls around. I'm exaggerating a bit for comedic effect but that's essentially it: if you want physics, momentum, etc... use the physics system to move around, but if you want a snappy platformer you're better off handling things yourself.

  • @WeavileGuy
    @WeavileGuy 2 месяца назад +116

    this reminds me of a video essay i watched about hollow knight by ceave perspective that has a segment discussing how one of the reasons such a small team was able to make a game that big was because the game doesn't have any slopes, and therefore doesn't have to worry about all these problems

    • @T4ll4hassee
      @T4ll4hassee 2 месяца назад +22

      Makes me wonder if Silksong will have slopes and that's why it takes them that long........huffs copium

    • @Juke172
      @Juke172 2 месяца назад +3

      @@T4ll4hassee nah. it's taking long because they are writing lore for it. xD

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

      @@T4ll4hassee its because silksong is a myth

    • @sadsongs7731
      @sadsongs7731 2 месяца назад +3

      @@Juke172 These item descriptions aren't going to write themselves.

    • @Cube-xm6vt
      @Cube-xm6vt 2 месяца назад +2

      I don't think slopes would take that much to add into hollow knight. The knight's idle animation is very "straight" unlike OP's animations, where the character has the legs spread very wide, so making the knight stand on slopes wouldn't look weird. Most enemies are also confined to small areas, stationary, or fly, so there's no need for them to go on slopes (though most of them also wouldn't look too weird on slopes).
      As for the physics, honestly I don't think it's as hard as OP makes it seem. You can just get the ground normal (which in godot and unity is included in the raycast results) and if it isn't pointing straight up then you know it's a slope. You can also use the normal to rotate the movement vector according to the slope angle, so that movement is consistent. And it's pretty easy to just disable the gravity when the player is on the ground, and then turn it back on when the player is jumping.

  • @sarakajira
    @sarakajira 2 месяца назад +10

    You're gonna hate hearing this but the "weee!" factor does make gameplay a lot more fun. It adds a kind of "flow" to movement that feels far more natural and intuitive than simple up or down movement can achieve. I was recently replaying Pitfall The Mayan Adventure for Sega CD which has slopes, and it adds a kind of dynamism to the gameplay which is a lot of fun. For one thing you can make slippery slopes which cause the player to slide down them which adds a fun platforming element. For another, it emphasizes terrain and makes it feel more lifelike. For example in the first level of Pitfall there is a small slope on the ground that allows you to double back to a slightly higher level behind you. One of the ways Pitfall often handles slopes is by putting grass or plants in front of the slope to hide the legs. This makes it seem like you're in a cave and adds a cool paralax effect. Yeah slopes are a big pain but they can also really level up a game in terms of quality.
    I think that's also one of the differences of why a lot of modern indie games "feel" different than their 2D ancestors from old consoles: Indie devs often have to take shortcuts meanwhile the older games had entire dev teams and sizable production budgets. Sea of Stars for example is very colorful, but lacks the writing quality that a big budget JRPG with a full editorial staff like FF7 had. There's a level of depth and polish in many older games that lots of indie games still don't achieve, even with modern tools.

  • @mackthisarrowhearth295
    @mackthisarrowhearth295 2 месяца назад +21

    I love slopes, if you can build momentum of it as a player or as an enemy/obstacle. It also means that it always serves a purpose, the physics are temporary, enemies only use them if designed for them, and the rest is worth it if it is a real game essential mechanic.

  • @Ferodra
    @Ferodra 2 месяца назад +27

    If i remember correctly, Metroid Fusion and Zero Mission handled slopes by just not allowing most enemy types to enter them. Slopes were strategically placed, so it never felt odd

    • @ninomojo
      @ninomojo 2 месяца назад +3

      Yes but you forgot one crucial fact: most indie developers don't wanna have to do any proper, in depth level design :)

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

      Metroid Fusion and more so Zero Mission also just placed stuff on the Front Layer to obfuscate any Art disparancies.
      They are also MANDATORY for Metroid. (At least any Metroid with a Speed Booster Mechanic. Think about it.) Similarly, they are quite Mandatory in Games where you have a Dash, like Megaman X or ZERO. Otherwise the flow of these games are completely ruined. (Or the Rooms will appear very flat, almost amateurish)

  • @Swinkly_
    @Swinkly_ 2 месяца назад +48

    I think the importance of slopes depends heavily on the movement of your player character. In Isadora's Edge, it looks like the movement abilities are more on the rigid and precise side end of the spectrum, rather than being flowy and momentum-based. A game like Sonic, for example, couldn't (and shouldn't) exist without slopes as they're fundamental to how the character moves - whereas Hollow Knight loses practically nothing from excluding them. In my case, I've decided to use them - albeit sparingly - and just compensate for any strange interactions as they come, since the game has no combat and is focused on speed and fluidity.
    Great video! Isadora's Edge went straight on my wishlist when the Steam page went live.

    • @InboundShovel
      @InboundShovel  2 месяца назад +4

      Thank you so much - and I completely agree with your analysis!
      I'd rather spend time focusing on the combat and other precise movement mechanics, in the same vein as Hollow Knight, rather than momentum maintenance gameplay a la Sonic! :D

  • @jankkhvej434
    @jankkhvej434 2 месяца назад +8

    0:36 Now let's see Paul Allen's slope

  • @Anerisian
    @Anerisian 2 месяца назад +44

    You are spot on. Slopes are definitely a “feature” with extra costs that may not be worth it.
    You haven’t mentioned one possible art solution, provided you aren’t going for pixel art purism: tilting. The character can be angled so their up is perpendicular to the floor normal, so the wide ememy is simply rotated a bit. As you say, there are always more issues, e.g. smooth rotation on jumps and at slope beginnings and ends.

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

      That's how I did it in games I made with GODOT. Simply rotate the sprite image around the surface normal. It actually works pretty well, but GODOT has many physics problems that make using slopes an absolute inconsistent nightmare. The bad normal reads was an absolute deal breaker for me. You can't create consistentency from an inconsistent foundation!

  • @SouthpawHare
    @SouthpawHare 2 месяца назад +9

    2:55 It doesn't seem like it's necessarily an issue that the characters go uphill slower and downhill faster, right? This is totally a reasonable physics model that could be more a feature than a bug.

  • @domoyoro
    @domoyoro 2 месяца назад +36

    lol, slopes
    slopes basically turned my little prototype into a game actually worth developing.
    i definitely have spent a lot of time getting it all tuned right, including an entire rewrite to swap from raycasts to boxcasts. i didn't have any enemies walking around for a good while (since they didn't really mesh with the game concept well), but when i did finally have to implement ground detection for non-player objects, i basically took all of my player ground detection code and put it into a new class. now all of the non-player objects easily snap to ground, account for checking walls vs slopes, etc.
    also- one thing i found useful for determining if there's a slope below the player is to actually raycast under the front of the player, horizontally inward. that way you can check if there's a slope of any steepness below the player, without using a really long raycast.
    as for art, i'm a pixel perfect kinda person so i decided to opt for rotating sprites into that crunchy pixel weirdness that you'd get on the GBA. the pixel art emphasizes shapes over outlines most of the time anyways, so it's not too bad. for the most part, we try to reserve rotation for either pure shapes or for sprites that are constantly in motion. it helps mask that weirdness a bit.
    having a penguin sliding on a slope (~32x16px; a short / wide collider) did look weird even after rotating the sprite, so the sprite is offset towards the ground when the penguin is grounded.
    the 16x32px (tall / skinny) grounded idle animation is also rotated and offset, but not as much- it turned out to be important for conveying the penguin's jump direction, since the jump force is always pointed perpendicularly from the ground.
    with the level design side, slopes always became a way to go fast, preserve momentum, take cool shortcuts, and accentuate cool jumps. slopes aren't always useful when designing levels, but they help accentuate what makes my game unique.
    if i were in your level designing situation, i'd probably ask myself if there were any unique interactions you could have with slopes. since slopes are difficult and thus less common in indie games, it'd probably be worth it to spend some time jusifying them mechanically. maybe there could be a mole that pops out of the ground, but always perpendicular to the surface- so the spot that the mole is buried in is important. especially if it were inside a wall!
    of course, i'd also avoid using any enemies / mechanics that don't play well with slopes in a slopey area. ronktonk would be a no-go for example, but there'd be plenty of other areas where it could shine.
    but aside from aesthetic / uniqueness, i'm not sure if, i were in your shoes, if i'd continue work on slopes. it takes a lot of discipline to say no to something you really want, after all. this is a good vid and you present your reasoning very well.
    slopes aren't easy, and they're not beneficial for every game, but the different development needs and solutions for a genre as narrow as 2d pixel art platformers is interesting!

    • @ferenchorvath8752
      @ferenchorvath8752 2 месяца назад +3

      I hate working with slopes, but in the end it's all about the game. When you as a dev want to include them you have to check if you just want them because they are cool, or does the game benefit enough from slopes to justify all the crap you as a dev have to endure :D
      Thanks to your comment I just checked out your channel and with that, your game :) I looks cute and fun, it reminds me kinda Sonic (but not completely), and slopes there seems like they are actually a core mechanic - but that seems more like an exception than the rule :D

  • @HerraHissi
    @HerraHissi 2 месяца назад +14

    Slopes, I think are mostly an artistic tool. You mentioned Megaman as an example, but I also bring up: Rayman - the first one. The game has slopes everywhere and it's considered one of the hardest PS1 games. One thing they do with the slopes in the game is add rolling balls and falling enemies but also make them slippery sometimes which makes physics work against you. But like said: almost every floor in the game meanders like 10-15 degree slopes. Level floors are reserved in the game.

  • @TheExFatal
    @TheExFatal 2 месяца назад +84

    Sonic fangame developers sweating profusely

    • @InboundShovel
      @InboundShovel  2 месяца назад +32

      My heart goes out to all the Sonic developers

    • @LoggyDev
      @LoggyDev 2 месяца назад +3

      It's not that bad 😭

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

      To be frank most of sonic fangames are either using modded engines specifically made for sonic games or just are straight romhacks. So slope physics is a problem already being dealt with.

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

      @@LockMatch Alternatively, there is a guide out there so all of classic Sonic's physics, so slopes aren't particularly troubling unless you aren't attempting to get an exact replica of the original physics, which can be easier for somethings but harder for others (e.g slopes).

  • @ianweckhorst3200
    @ianweckhorst3200 2 месяца назад +19

    I know exactly why he likes slopes, he played super Metroid and shinesparking after running down that one slope near the start of crateria was probably a core memory

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

      Any Metroid game with a Speed-Booster in it (Shinesparking or not) NEEDS SLOPES.
      Similarly, any game which has a Ground Dash (Like Megaman X or ZERO) NEEDS SLOPES. Play them, every time you encounter a slope, think about "what would it have been like if this game didn't have slopes now" and you quickly come to the conclusion that they are not just visual... They are inherently necessary for the gameplay to flow anywhere near as well as it does. Sonic is another good example. Smooth horizontal gameplay that is fun to traverse will always include slopes.
      Or super flat and boring level design.

  • @GarrettPetersen
    @GarrettPetersen 2 месяца назад +11

    Chrono Trigger uses multiple different perspectives. Most of the time it's a 3/4 perspective that has wide slopes for characters to walk up and down. But there are some areas with side-on perspective and a slope, and they just have a small foreground wall that covers the characters' feet to deal with the issue of feet not touching the ground on a slope.

  • @therealquade
    @therealquade 2 месяца назад +4

    I have so many things to say about this, so I'm going to make a list. I noticed these because of games i've played, but mostly, I can SEE THE HITBOX OF THE GRASS IN YOUR GAME.... okay... okay... breathe...
    Positive solutions
    1: Don't use pre-built functions. Ever. They're a black box and difficult to tweak. If you don't use Godot's built in snap-to-floors, and you code your own, you can tweak it as needed, rather than having to turn it on and off. This is where the stress is coming from.
    2: The reason slopes look wrong isn't JUST because your terrain has zero perspective, but your character designs ALL have a tremendous amount of perspective. That's why your character's gait and stance is so wide. They are facing the player, rather than their direction of travel, which means their feet are spaced left and right, rather than front to back. In order to make a slope look correct, the thickness of the ground that goes above where the ground's hitbox is, needs to be as thick or thicker, than the character's gait is wide.
    3: another way to fix the visual problem of the feet sticking off the ground on slopes, is to offset the grounds collision hitbox from it's sprite for slopes. this means the underside of the ground will need to be thicker, or the opposite foot will be hanging down into the void under the ramp, and it will look weird that way.
    Criticisms
    1: The thing that makes great videogames great, and bad videogames bad, is down to 1 word. "Gamefeel". Gamefeel is 70% code, 5% graphics, and 25% sound. When you said "spending that extra time on the [any feature that is more complicated than a premade function] doesn't seem like the best use of your time"... That is how shovelware gets made. don't do that.
    2: You said you removed slopes because they are purely aesthetic, and don't contribute to gameplay. in video games, a medium based around visual aesthetics... Do you know what else is purely aesthetic and don't contribute to gameplay? good graphics. you could technically replace every sprite with differently colored squares that are the hitbox and, hey, it's the same game. that sure is a lot of extra work you saved by not bothering with the purely aesthetic. Do you see the problem with that? Now look back at megaman X. Imagine if they had said something like that, and never used slopes.
    3: slopes don't have a use-case? Go find a lets-play of sonic & knuckles on the sega genesis, and skip to sandopolis zone act 2 as sonic (not as knuckles, different level), and watch just that level. i'm talkin' 5 minutes of your time. Watch that, and tell me that slopes don't have a use-case. In fact, don't even do that, i'll just tell you. The level contains 2 vertical stacks of big platforms with obstacles, and there isn't a top or bottom of the map, it loops vertically. The 2 columns of separated by a very wide gulf, and the platforms are connected across the gap by slopes that are slick and you uncontrollably slide down. these slopes cross eachother creating big X's of slopes through the middle of the level. if you're sliding down one side, you go behind, or in front, of the opposite one, but if you jump before you reach it, you can land on the opposite side, to go down to lower on the same stack you came from, instead of crossing. and since it loops vertically, you can actually end up above where you started.
    4: you know what... SLIPPERY TERRAIN, Have an ICE LEVEL with slopes. BOOM, Instant use-case for slopes. Oh, right, almost every megaman game does that so.....
    5: Enemies that roll down ramps to attack you.. both sonic and megaman have done this....
    6: enemies or traps that only activate when you jump, but you have to ascend or descend. Hey look, Slopes, and also ladders, but mostly slopes. Especially if it's like, I dunno, the water, or lava or something is slowly going up and you have to out-run it, but there's enemies that attack when you jump.
    7: moving terrain. a slope that stays connected to one level, but then, uh-oh, something happened and now the slope is dropping down and now it connects someplace else. you could use it for puzzles, or traps, or hiding hidden rooms...
    8: The biggest problem with slopes, is giving up, because it's hard and a lot of work. your anti-work attitude has made me quite angry, but I shouldn't be angry, because you finished your game, and I haven't finished mine. but let me tell you man. early games where one man development teams. to give you a sense of scale, the original roller coaster tycoon, was made entirely by 1 guy. and that's not a platformer, that's a sim game. sims are way more to code than platformers, orders of magnitude more. and that one guy did all the code, all the graphics, all the sound... and his code was done in assembly. ASSEMBLY. and do you know what Roller coaster tycoon has? SLOPES! ISOMETRIC SLOPES! CODED IN ASSEMBLY! AND GRAVITY. AND ONE GUY!

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

      My attitude is literally the opposite of anti-work man, I'm trying to help people evaluate whether or not slopes are necessary for their game, and for my game they're absolutely not necessary.
      You can put slopes in your game, bro - I literally don't even want to stop you from doing that, I just want to help people make games.

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

      @@InboundShovel sorry man, I just got angry. some of the things you said just really sounded very much like wanting to do as little as possible, I couldn't really have much other take-away, because you spent so much time talking about the negatives, without any advocation for the positives at all. it just felt insulting, and I got an

  • @neonswift
    @neonswift 2 месяца назад +45

    So a few thoughts on this:
    1. A player/sprite doesn't need to stay at the same speed when moving up/down a slope becuase thats not how they work in real life.
    2. Seems odd that you designed it so you character is locked to the slope at all time, wouldn't you be better just doing that when you actively no they are a) in the air and b) moving down?
    3. Sonic Physics Guide has really good logic for how to handle small steps, slopes, curved floors etc. Sure its more work BUT its really valuable knowing how this stuff used to have been done.
    4. You can account for the floating feet issue but having the visual slope and the collision slope not being the same thing. Or offset the player on slopes so they're partly in the ground. I personally think worrying about the visual realism of pixel art is maybe a step too far in this regard.
    5. You're trying to find a level design use case, but why does it seemingly always involve you having an enemy at the top of a slope? Sometimes navigation alone IS the use case. Blocky tunnels for example, aren't as natural as sloped tunnels so its one of the use cases in my game is so environments look more organic. Level design isn't all about mechanics it can also be about aesthetics.
    Interesting video though. Haven't seen too many people debating why you should/shouldn't use slopes. Most just explain how.

    • @charlot6590
      @charlot6590 2 месяца назад +8

      1. This is a video game, not real life. If he wants the ground control to feel a certain way, there is probably a reason why.
      2. This can be exceedingly complicated depending on how collisions are handled. "When you're moving down" varies a lot between engines and methods of checking collisions. Think about when you're traversing up a slope; your vertical speed is technically moving you upwards. There are also just circumstances where you could collide with a slope while not moving down if your horizontal speed is high enough.
      3. Sonic physics are well-known for being unique to Sonic games. The way they calculate movement is designed around maintaining momentum even at 90 degree angles, and it's completely different from how this game seems to play.
      4. Both of these solutions are still just compromises that he didn't want to make on top of everything else. It would look especially odd in this game since the character has such a wide stance.

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

      Yeah I didn't really understand why specifically that giant tree dudes gotta be walking up and down slopes
      I also felt like I missed something with the calculations but I figure that's the actual fun part of game dev tbh
      Further down someone shared the very interesting use case of allowing grounded enemies to threaten the player while approaching from lower ground

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

      @@m0ng00se4 Slopes physics are complicated I'd never argue that thats not true. Understanding them can help a lot and I'd recommend working with them to come to the conclusion he did. Once you know you know. In my eyes all practise does contribute to the whole.
      As he said, slopes can be quite good if the gameplay is designed around it, e.g. Wario Land 4 allowing you to roll under blocks is a great mechanic for example. Adds a level of puzzle platforming of sorts.
      Rolling enemies that are specifically designed to roll up and down slopes can also be a fun enemy to tackle. Though I agree that if he's striving for more realistic pixel art design walking enemies require additional work.
      I personally would strive for slopes because it makes levels feel more naturally organic than blocky terrain. There's a fine line though, especially if you're using tiles rather than objects because it requires a bit more work to make extremely organic terrain. But adding a slope here and there into an otherwise blocky world can be good. But again it depends on the dev and the scope of the project. Hollow Knight avoided slopes but they compensated for that with a LOT of naturally shaped art assets for walls and do in fact have ceiling slopes in the game.

    • @ДюсековИльяс
      @ДюсековИльяс 2 месяца назад

      ​@@neonswift I mean hollow knight has no slopes amd it's worls still feels organic? I don't see how just not having slopes becomes such a deal breaker

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

      ​@@ДюсековИльясYou don't? I have been making a Metroidvania for 2 years now, and before I even made a single asset, I had decided slopes were essential during the planning phase. Slopes are fun, look good, and good games actually utilize them for various movement mechanics. You couldn't think of that? I thought Hollow Knight wasn't good.

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

    A lot of the physics concerns seem to come from having a system designed around flat floors and walls and trying to shoe-horn slopes into that system, rather than building the system with slopes in mind from the start. The collision logic should either be based around detecting floors, walls, ceilings, and slopes all as first-class categories of environment collision with their own logic for each of them, or based around a pure physics simulation of interacting appropriately with the normal vector of a generic surface.
    The easiest solution to the art problem is probably to tweak the collision. The Mario Maker 2 approach works well. When placing an object on a slope, you don't use the corners of its hitbox, because then it conspicuously juts out into the air. Instead use the center of the bottom edge of the hitbox. The object will still jut out slightly into the air, and also overlap slightly into the slope, but the severity of both effects is cut in half. And, up to a point, the overlap with the slope will read to the eye very similarly to the perspective style tileset, even without actually using such a tileset.
    That will surely introduce some headaches with getting collision to still work well with ledges and with transitions between slopes and flat floors, but that's definitely a solvable problem. For example, check for flat floors below the corners of the hitbox and check for a slope below the center of the hitbox, and make the slope the higher priority unless it's too far below a floor you detected. Something like that will allow you to stand on a ledge all the way to the corner of the hitbox, and still have smooth transitions when running along floors and slopes.
    The level design question is interesting. Certainly not every game needs slopes, but there are a number of ways they can be useful. Consider an enemy that fires simple horizontal projectiles. On a floor, there's no vertical distance to worry about, and you can easily jump over the projectiles as you close the horizontal distance. If the enemy is on a ledge, you can safely close the horizontal distance while the projectiles pass overhead, then jump and attack the enemy in between shots. But if the enemy is on a slope, you get an extra challenge. The shots are higher than usual, so it's difficult or impossible to jump over them, but at the same time you can't close the horizontal distance to the enemy without crossing through the line of fire. A situation like that forces the player to more aggressively take advantage of the gaps between shots. You might get a similar effect by putting the enemy on a staircase, but then the player's interaction with that terrain is very different.
    Slopes are also useful for controlling elevation of any objects or enemies that are based on moving along floors but not walls. Consider again the case of the horizontal-firing enemy above the player on a slope. You can add more pressure to that situation if there are ground-patrolling enemies coming from behind. Those enemies can climb the slope to put pressure on the player, but they wouldn't be able to climb a staircase. Or if the player has projectiles that roll or slide along the ground, like Mario throwing a koopa shell, then slopes create situations where those options are still useful against elevated enemies.
    Slopes can also just be another variety of terrain with different physics that the player has to account for. Just like slippery floors or sticky floors force the player to adapt to the physics being different, slopes can force the player to adapt to moving more easily in one direction than the other. The 'bug' you fixed with the player moving faster downhill and slower uphill doesn't strike me as a bug at all. That's a perfectly natural representation of the fact that running uphill is hard and running downhill is easy, and gives the player one more thing to think about when fighting on a slope.

  • @CryoGX
    @CryoGX 2 месяца назад +8

    As someone making my own 2d action platformer, can confirm all of that's true. In my case I had to make a convoluted system to make tile-based collisions possible to begin with, then slope physics for just the player. Enemies get left out of this bc the system doesn't transfer to their varied sizes well. The result of this so far is that enemies can show up NEAR sloped areas, but they'll likely be enemies who either move only on nearby flat ground, don't move at all, or are enemies who float in the air.
    So why slopes in my game? They actually trigger a high speed state for the player that lets them one-shot enemies. In some places, this is used to increase the stakes for a level section because if you get hit, you lose out on that momentum and now have to play out that section at default speed (invoking a kind of "perfect player syndrome" motivating you to do better). They also make levels look more varied. Also, my player character is so comprehensively ridiculous in terms of movement mechanics that the high speed mode ironically can add difficulty instead of removing it. But "fun and jank" is exactly the kind of thing I'm going for so I don't at all mind the challenges that the slopes brought for me personally.
    Can also confirm I'm a solo dev.

  • @pigdev
    @pigdev 2 месяца назад +4

    I think that most of the issues related to physics are more related to how you are currently dealing with the movement. For instance, I'd recommend using test_motion() instead of raycasting to find cliffs and use is_on_wall() instead of raycasts to check for walls.
    As for art, yeah these are actual issues. Most of them we can just say that it's kinda standard issues and players are usually OK with them, but they are really annoying.
    And for level design, I think you will find out as a fellow Mega-Man X fan, that slopes do make a lot of difference and open up for tons of possibilities.
    For instance, you showed this tree-like enemy, the wide one, in a 'pit-like" design, where the player would be bellow it, player would be able to just do air attacks and hit it without taking any damage, I can imagine the attack patterns of this enemy and I can't think of one that hits below its feet. Every time you have a cliff or pit where this monster is used as a challenge for the player to move through, players can hit them from below. And the other way around is also true. I don't know if Isadora has an attack that angles top-buttom(like Zero's Crescent Sword or Quake Blazer in MMX5) but if this is not the case, Isadora will always be in disadvange when coming from a cliff to a lower segment of the level.
    With slopes you even this out. Not to account for vehicles or rides. For instance, if you want to add a "platform enemy", let's say a mushroom that Isadora can use its head as platform and be carried through spikes or other terrains or hazards, you will have a bad time implementing jump for this enemy, where with slopes you can just keep it moving.
    Vahicles as a good use case for slopes as well, think about Mega-Man X's Ride Chasers, I hate the fact that you can jump with them, this makes no sense to me. But if you think about them TAKING ADVANTAGE of slopes main issues(when you are not snapped your vertical and horizontal velocity sum up making you hop when coming from a slope to a flat ground) you can make very fun stuff like the pit jump we make in Mega-Man X2 Overdrive Ostrich stage which is epic. There are some of these jumps in Mega-Man X5 Squid Adler stage as well.
    Not to account for push-pull physics puzzles where you can push/pull objects like crates or rocks. With slopes you can have changes in terrain height, without them you will either push them through a cliff with no option to move it back or you can't move it pass a wall.
    So I can think about many good use cases for slopes regarding level design.

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

      It is CRAZY to me that you still don't have a Checkmark. You are a staple within the Godot Community and your comment is BRUTALLY buried here, even though one of the most informal ones I've encountered!

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

      @@hiiambarney4489 I'm clearly doing something wrong 😂

  • @TinTeaKettle
    @TinTeaKettle 2 месяца назад +94

    I love seeing slopes, I hate using slopes

    • @InboundShovel
      @InboundShovel  2 месяца назад +25

      You nailed it perfectly, I can't think of a better summary of how I feel about slopes lmao

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

    I personally really love games that make full use of the terrain with unique abilities. Case in point: The Speed Booster and Shinespark in Metroid games. Where you can either use them to rocket yourself at high speeds or to save a Shinespark charge for crazy puzzles/shortcuts.

  • @carlosiagnecz
    @carlosiagnecz 2 месяца назад +8

    Game Engines hate slopes, but you don't. Most people use game engines because they just don't know how the math works. Making the math yourself is crutial, Sonic the Hedgehog for example has 6 hitboxes fixed in a axis with a maximum distance from the pivot. The genesis games had the slope data integrated in the tiles, but in a modern enviroment there are ways to calculate the angle of the floor using atan2. Also for the art problem: just rotate the whole damn thang. The genesis games did actually have the rotated sprites baked, there are some issues with wider characters such as one feet having to be in a different angle.

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

      Another genius spotted. Can you teach us how to "make" the math?

    • @sploofmcsterra4786
      @sploofmcsterra4786 Месяц назад +4

      ​@@lyraisnappingI hope you're not being sarcastic, because they know what they're talking about. If you're a game dev, you should really have a more open mind to other ways of doing things than relying on a default physics engine.

  • @ArtisanAspirationWorks
    @ArtisanAspirationWorks 2 месяца назад +28

    Wario Land 2 uses slopes. Smash Bros uses slopes. So the moral of the story is, have a use case, which is mostly platformer or puzzle related

    • @gooeydude574
      @gooeydude574 2 месяца назад +4

      Yay, Wario Land 2 mention!

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

      Doesn’t pizza tower have slopes too?

    • @ArtisanAspirationWorks
      @ArtisanAspirationWorks 2 месяца назад +6

      @@NimArchivesYT Refer to Wario Land 2+. Basically they are used for rolling, and even in Super Mario World for running up walls. Specifically, Wario Land is known for hiding secrets, and unlocking or just using rolling down slopes can allow you to break small blocks in succession and find treasure in places nothing else can.

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

      @@ArtisanAspirationWorks Thank you

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

      The art issues with slopes are way easier to handle in 3d

  • @JoeyCannoli
    @JoeyCannoli 2 месяца назад +23

    Good thing I stumbled across this video when I did. I’m working on a platformer game myself but it’s *extremely* early in development so I don’t have to worry about taking slopes out of the game because I haven’t added any yet. You saved me a great deal of annoyance!

    • @MichaelFlatt-g3i
      @MichaelFlatt-g3i 2 месяца назад +3

      Same (not a platformer exactly but still 2D), thanks @InboundShovel

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

      Haha, glad I could help!

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

      I stay away from any long Metroidvanias/platformers without slopes. They feel cheap.

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

      ​​@@CrAzYpotpieWhat a weird thing to do

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

      @@internetguy7319 How is me staying away from games I don't find enjoyable a "weird thing to do?"

  • @yeeterdeleter0117
    @yeeterdeleter0117 Месяц назад +3

    They're even buggy in geometry dash, where your horizontal movement is fixed. I still use them in my levels though, every time. Such fun gameplay if you can get it right.

  • @Mtaalas
    @Mtaalas Месяц назад +5

    This is issue only if you have very little to no experience in programming and solving platformer physics problems.
    You can have the slopes if you WANT to have the slopes. But there's no turn key solution to it, you must study more programming and basic platforming physics from SNES and SEGA mega-drive days to figure out what you can do with very little processing power...

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

      I like your point about there being no turn key solution. It is very hard to tell what problems are simple and have a generic solution, and which problems' solutions depend sensitively on what you are trying to achieve. You really need experience to recognise that it's okay to develop solutions from scratch for things that seem like they should have an easy solution for how trivial it is.
      I imagine with more beginner-friendly game engines like Godot, people are less likely to recognise where they need to put in that effort? Like in this video, there seems to be an underlying assumption that the physics should never be turned off.

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

      @@sploofmcsterra4786 Exactly.

  • @TomatOgorodow
    @TomatOgorodow 2 месяца назад +73

    0:08 No, I'm leaving

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

      Please leave and never come back

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

      Ok, farewell.

  • @apollolux
    @apollolux 2 месяца назад +39

    Slopes are "shockingly difficult for indie game devs" because most indie game devs rely on default game engine implementations of collision physics, however barebones or thorough those individual engines may have them, instead of making genuine efforts to spec the necessary math of what they want then implement it themselves. Platformers like Super Mario Bros 3 and Super Contra/Super C on the NES had slopes with 8x8 pixel tiles and 6502 assembly; Super Mario World, Contra 3, the Mega Man X trilogy, etc on the SNES had slopes with 65c816 assembly; the Sonic the Hedgehog trilogy/quadrilogy, Capcom's Strider (ported by Sega), Konami's Rocket Knight Adventures and Sparkster, among others, had slopes on the Sega Genesis with Motorola 68000 assembly and/or Zilog Z80 assembly. This isn't even taking into account arcade games of the time or Neo-Geo! These games often had programming teams of less than ten people, usually less than _five_ people, sometimes even just one or two, but they planned their calculations and knew what they wanted to get before putting in the work to do it.
    There are articles detailing reverse engineering of slopes in games like Mega Man X, Sonic, etc. I know they exist because I myself read them almost two decades ago when I was more hardcore into learning game dev with engines like RPG Maker and eventually branching out into other stuff long before Godot was a thing. On or before 2004, using the free open-source engine Sphere (which uses JavaScript for its scripting language and is still around, BTW) I had found a tech demo "Die Seesternkönigstochter" (basically "The Starfish Princess") by user SDHawk, a Sonic knockoff where you roll around on hilly terrain as a starfish). Sometime on or before 2009, Sphere user Kamatsu (IRL an Aussie computer science professor who also briefly worked at Google for a time) made a tech demo that recreated the basic slopes _and_ destruction physics of the Worms games. I myself was even making tech demos of things like 3D block-based map makers with basic rotation (before I even learned the proper matrix math for software-based 3D projection and rotation) as early as 2005 before Minecraft was even a thing. All of it using JavaScript, because that's what Sphere offered/still offers us as the scripting language and what drew us/still draws us to the engine.
    In short, slopes are "shockingly difficult for indie game devs" literally because "skill issue."

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

      Tools allow devs to muddle through without knowing math, ergo you see more devs who don't know/like math
      Kinda straightforward development if you think about it, there's a lot of fairly short answers (that make intuitive sense and I've seen some work in unity2d personally) from people who understand vector math intuitively while OP is clearly not prepared for that kind of answer so, I dunno let him make his stairs

    • @RedMattis
      @RedMattis 2 месяца назад +11

      Personally I wouldn't want to use a regular '2d rigid body' for a character in a 2D game like in the video anyway except temporarily (say they are being affected by knockback).
      I'd want full control over their movement, because otherwise you run into a lot of issues with stuff like ladders as well. Same with enemies with special movement types, e.g. spiders that climb on walls/ceilings, or enemies that can sometimes dig through the level.

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

      wow aren't you lovely. Show us your game bud let us see how you solve problems with your massive skill set.

    • @RedMattis
      @RedMattis 2 месяца назад +9

      @@lyraisnapping Apollolux seems to know their stuff and even goes out of their way to source it. I don't see a reason for your scepticism.
      Their attitude is perhaps a bit aggressive with calling it a skill-issue, but honestly, that barely qualifies an banter at the studios I've worked at. ^_^;;

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

      In other words the price of _reducing_ the barrier of entry is having a *reduced* barrier of entry.

  • @numbers0580
    @numbers0580 Месяц назад +2

    Just wanted to make an edit to the editor. At 9:06, he puts up a note about z-index and z-axis.
    Both are valid terms. As a matter of fact, when programming layers for webpages, I would often use CSS's z-index property.

  • @khaledcostasampaio2842
    @khaledcostasampaio2842 2 месяца назад +12

    i love when a developer or musician just dumps information about their projects. I barely understand it but I love their excitement.

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

    Another common option for solving the slope problem is by adding some kind of foreground noise to hide part of the character's feet, which makes it easier. Like foliage, fencing, railing, trees. etc
    This can also be combined by animations that sink the character into the ground slightly. which extends how much room you have to work with before it reaches into the ground. Which makes senes for some character anyway because they're really heavy, and standing on mud...

  • @kiwilordu5004
    @kiwilordu5004 2 месяца назад +3

    5:13 is game developing in one sentence

  • @flameofthephoenix8395
    @flameofthephoenix8395 2 месяца назад +4

    16:33 Interesting, I've never felt any need to put a slope in my game, but now I want to add slopes to something just for the sake of it, one easy answer for the art problem is to make the character a blob which will look about the same no matter what they walk on. In the current game I'm working on it will actually be an interesting challenge just to render the slope itself because of the constraints of my 3d engine I made.

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

    I think a good example of a game which needs slope are the Sonic games, because it's the only way to gain height without losing your buildup speed, or even helping to get that speed when it's a downward slope. Aside from that exemple, yeah, you're right, slope don't deserve that much work, espacially when you are indie

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

      Oh yeah, you're totally right! A super momentum-based movement platformer would absolutely /need/ slopes, lmao

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

      You're right, and also you made me think of something else, I'm a huge metroid fan and in super metroid you get the speed booster ability, and yeah now that I think about it, this ability is the main reason slopes are in the game, so samus can run through walls and across many screens without stopping, and if we add the shine spark ability, it makes more sense.

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

    Slopes are good for a few things from a gameplay perspective. 1) Momentum based movement. When you need the world to have physics that affect your player character, slopes add nuance to maintaining speed, overcoming challenges at forced variations of speed, etc. 2) they're good for slope specific challenges, such as the gun challenge you showed, but also things like charging enemies, since the change in elevation can make the challenge easier or harder for the player, since you have more or less space to get over the enemy depending on the slope. 3) slopes can be good for limited combat options. With wide, sweeping attacks, they're mostly just free kills. Your enemies may actually have more advantage from below you. Contrary to popular belief, having the low ground is often better for melee combat irl due to most people striking at chest level, so someone uphill is forced to strike downward at the enemies head, whereas the down slope enemy can strike your legs, which are already an open target due to footing, and your midsection, which is one of the widest spots on people that isn't usually fully guarded by a normal stance. This can be translated into gameplay with your default attacks not hitting low. This can be used to force the player into purposefully awkward or unfavorable combat situations. You can also have the enemies launch attacks perfectly down the hill that could throw off the player, or bouncing attacks down the hill could be threatening.
    These are just a few ideas. They aren't necessary, but hope they're some interesting ideas for you for next time you want to approach slopes with a game. Sometimes you just need a different perspective

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

      Neat that you mention the irl combat example.
      This is exactly why we learned in Karate (or the specific subset of Karate that I was trained in) to have a very stable, very, very low stance.

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

      @@hiiambarney4489 Yeah, I watched a shadiversity video where they practiced sword fighting on hills, it was fun and I always remember it whenever I hear people mentioning the high ground. High ground only really helps with projectile weapons

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

    Art solution idea: Split the player sprite into columns, put the player in all the different types of slopes, then lower the columns until they touch the flour. Save all the combinations as new sprites so you don't have to draw them yourself. I think it will work with the flatter slopes.

  • @jeffknox6014
    @jeffknox6014 2 месяца назад +21

    If you use slopes, then you need to create specific use cases for them to justify them. Some ideas include projectiles or lasers that use the slope angle to determine bounce angle; hazards that use rolling objects to increase or decrease velocity and damage based on slope angle; special actions for characters when they are on slopes.

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

    one solution to cut down on art time for some sprites is to have a top and bottom parts of the sprite that can be swapped out, leg poses can be on a separate object that can be specifically programmed to handle any leg pose, while leaving the upper body for the more adventurous animations

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

      It's in another video, but he already has this exact system implemented to handle attack animations when moving vs idle. I'm assuming he didn't mention it here since it doesn't really help with the major problem that he still has to *make* all of those unique sloped leg sprites which adds to the workload

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

      Bro I'm just procedurally animating everything cos I suck at art 😂

  • @felixp535
    @felixp535 2 месяца назад +3

    There's a nice series of videos on RUclips where someone recreates Super Mario World in Godot. They talk about ground collision and slopes, how it's handled in SMW and what the best solution usually is for modern engines. Definitely worth a look!

  • @kody.wiremane
    @kody.wiremane 2 месяца назад +2

    3:10 No good?.. This is how slopes are _expected_ to work :D

  • @Runegrem
    @Runegrem 2 месяца назад +20

    In the Mario Maker troll-level community, slopes are well known for being one of the jankiest elements in the game, right under clown cars. And if you see both of them close together, you know there's gonna be some "unexpected fun" happening.
    The speedrunning community in general seems to agree that slopes never really work quite as expected in almost all games that have them. They quite often have some specific glitches associated with them. This goes for indie games just as much as big budget games like the Mario series.

    • @shaoronmd
      @shaoronmd 2 месяца назад +4

      Slopes, clown cars, and broken tracks. tons of contraptions use these a lot

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

      There was also a broken mechanic where sideways Thwomps would slide up slopes they approached.
      This was later patched, so now they just stop if they reach a slope.
      Certain course elements, like pipes and bill blasters, also just can’t be placed on slopes without looking janky, because the game doesn’t know to connect them.

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

    When I started watching this video, I didn't like the apparent message which I interpreted as "don't use slopes because they're hard", however this turned out to be a very solid argument:
    - slopes add extra work
    - slopes impact the artstyle
    - slopes have limited use cases
    I'm still going to try to tear it apart anyway.
    I would argue that all the physics problems are because physics engines in 2D games limit flexibility. They don't have to, but many of them do (oversights, architecture complexity, probably other reasons). If you were writing a 2D game from scratch with no engine, the code that makes you fall would likely say "oh, this is ground, stop falling" and not care at all that the thing being fallen upon is shaped like a slope. That alone eliminates most of the physics problems you've outlined.
    As for art maybe making every possible sprite animation is a good thing. A lot of talented people can help and it's a great use for crowdfunding, especially in a time where a lot of work is being taken away from human artists.
    Slopes are fun, and that's a pretty solid use case. While a game should have sensible challenges and be playable, it should also be fun just to move around - that's not "no reason", that's a pretty good reason.
    All this to say that I think the message still holds strong for Isadora's Edge and games built with similar engines and artstyle, but there are a lot of cases where it won't hold up so it's definitely not a catch-all.

  • @NoamStein-h6j
    @NoamStein-h6j 2 месяца назад +3

    I agree that you should only add slopes if they enhance the design of the game, and that in your game they don't really. but they do enhance a lot of games where the movement has more momentum and acceleration unlike Hollow Knight and more like Sonic and Mario. there slopes can make it hard to get momentum when going up a slope and allow you to gain a lot of momentum when going down a slope so that you'll be able to make larger jumps.

  • @HE360
    @HE360 2 месяца назад +3

    Gosh, slopes are some of the hardest things to work with when doing game development; even with built in help like with the Kinematicbody node in Godot or the "Platform" behavior in G-Develop. Because, once you change your platform at even ONE angle different from its original point, it could change how EVERYTHING in that scene block works when the character interacts with it and either it works correctly, or it becomes a mess. It's worse when slopes and other things in the scene depend on each other. And if you're using Godot, the Godot engine doesn't have an "undo" button and "Control Z" does always work!

  • @jamiek8123
    @jamiek8123 2 месяца назад +17

    huh, one thing to do is just turn off gravity when grounded, after all you don't need gravity if you're on the ground, so only when airborne do you need gravity.
    oh yeah the rest of those issues are a pain.

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

      I don't get what this is supposed to fix?

    • @jamiek8123
      @jamiek8123 2 месяца назад +3

      @@poleve5409 the issue where gravity was effecting the speed up and down slopes. tho you do need to add a system where 'forward' is changed to be perpendicular to the normal of the ground, which means getting said normal, so that you don't come off the ground every time you go down a slope.
      ok maybe this method is a bit complicated, but to get the speed consistent on slopes you'd need some kind of ground normal system anyways.

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

      ​@@jamiek8123I mean you just modify the player's direction by the angle of the slope. It's a lot simpler than calculating the force needed to boost the player up the slope (I'm guessing for some reason you can only apply the force AFTER the physics engine in godot? Otherwise not sure why you wouldn't just apply it before...)

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

      Also, way less computationally costly to turn off the physics rather than perform more calculations to counter it.

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

    I think even if it doesnt add to the challenge, it adds to the appeal of the level, not only aesthetically but bc it makes the level feel more natural

  • @metgaming9545
    @metgaming9545 2 месяца назад +3

    In my opinion, it completely depends on what type of platformer you’re making, if it’s a combat based, skill based platformer (which is what I’m assuming Isadora is) then yeah, slopes aren’t needed. They just add unnecessary complications.
    If it’s a fast spaced platformer where the goal is to move fast, it it’s a puzzle platformer where the difficulty isn’t really in the platforming, then slopes can really help.

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

      It really depends on the rest of the design. If the player or enemies have attacks that interact with slopes in fun/intersting ways then they're worthwhile. It seems in his case they were kind of an afterthought, so there was no real damage in removing them.

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

      Meele-Combat Based Platformers would warrant Slopes imo.
      Because you have to design around high elevation Changes with attacks for that purpose or the player will be ill-equipped to handle the situation.
      Balancing this can be an issue though. Because a move that is reserved for combatting foes on a high ground could potentially lead to way to easy engagements with other foes.

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

    1. Physics: Part of game programming is making your code more robust to deal with new elements you introduce like "slopes", breaking things is part of development.
    2. Art: That is the cost of adding new elements to your games, more work is inevitable if you want more features, but it becomes a more robust base game because of it, which if you're looking to make sequels or continue development on releasing feature patches for a long period of time its totally worth it.
    3. Level Design: It sounds like you weren't using slopes for what they're strong at, you're forcing them into situations you didn't need them. For example look at "Ori and the blind forest" it uses slopes incredibly well, boulders roll down towards you, certain enemies can roll after you and will speed up because of the slope downwards and even ramp up and over hills, all these new situations add to the gameplay because of it. You just didn't bother adding or lacked the vision to add the additional programming needed in your game to support and make use of the ramps to add to your base gameplay.
    And don't get me wrong you're right that features need to be cut as a solo dev, as you don't have the manpower or time to add everything you possibly want into the game, that's what sequels or feature updates are great for, but I think you're painting intricate features as something not to bother with as a solo dev and I think that limits the imagination and determination of a game design and developer

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

      100% this.

    • @ДюсековИльяс
      @ДюсековИльяс 2 месяца назад +2

      I mean.... His game is not Ori. It seems like it's more of a megaman game. And in mega man you simply NEVER need slopes. It's a precision based fight platformer. Slopes are useless for his project. He's not making a Sonic game where alopes are essential, so why bother with slopes. That basically invalidates all your points

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

      @@ДюсековИльяс re-read the comment

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

      @@ДюсековИльяс I understand his game is not ori, I was using it as an example of how slopes CAN be integrated into the gameplay and actually have use,
      rather than trying to convince the audience they objectively have no use, it all comes down to writing the code to support its use, prototyping and figuring out the fun in the interaction.
      And to use your own point against you, his game is not megaman either, its whatever game he decides to create,
      the systems and elements of a game makes a game whatever it wants to be.

    • @ДюсековИльяс
      @ДюсековИльяс 2 месяца назад

      @@Krahfty he himself said he wanted to create a hollow knight, megaman-esque game. Slopes only have a reason to be in a 2d game if your game is about fast movement and platforming. Like Sonic

  • @littleboyred1
    @littleboyred1 2 месяца назад +3

    I actually hate navigating through most of Hollow Knight's world because *everything is a staircase.* creating challenges aren't the only use case for slopes, for sure. Just making the world less tedious to navigate is nice.
    (Hope this doesn't come off as me telling you you're somehow wrong for taking out slopes or something, just wanted to throw my two cents onto that specific part since HK was brought up.)

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

      That's actually a super insightful point, and it makes me think that there is potentially a stronger use case for slopes in Metroidvanias - or any game where exploration and backtracking is present, just to make the world nicer to navigate!
      I'm planning on having linear, level-based gameplay in Isadora's Edge, so hopefully that mitigates the issue, but it's actually a great point to bring up! :D

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

    Solutions from old that might help
    Slope: make it very tiny blocks that are one pixel big
    Interacting and movement: use an auto-jump like mechanic like minecraft has but purely for those tiny pixels
    Or just have it so that your character doesn’t move sideways unless you explicitly make the action to do so
    Legs: cut the sprite in half and have it be two (or more) sprites in reality so you only have to edit the legs
    Perspective: maybe tilt the sprite to accommodate for the slope
    Fake perspective: just don’t
    12:00 It’s over, he has the high ground
    Level design: they look nice
    and maybe for the traps have it be a rolling Boulder (or something similar) that speeds up when going down

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

    the editor whoever he is had fun with the physics part

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

    Totally a valid decision to simplify your features.
    Just wanted to throw this here for any devs looking to have rudimentary slopes. In Godot you can use SeperationRayShape2D instead of a box collider. These can be used as a simple way to handle slopes. Use vertical SeperationRays to define the height at which the character stands, and then add a horizontal SeperationRay above the base of the character. This way the horizontal ray misses low or sloped objects and the vertical ray places your character to the top. This will allow the character to step onto low objects or up gentle slopes.

  • @Gbbb239
    @Gbbb239 2 месяца назад +10

    The laugh just disconnects him temporarily from a human to an awkward 90s NPC, than his soul zaps back to his body when he gets his composure back.

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

    You make a compelling argument, but I would counter with -- "Wheeee!!!"

  • @Strudlll
    @Strudlll 2 месяца назад +11

    Icy slopes are one of the only use cases that actually change the gameplay experience. I LOVE icy slopes.

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

    I'm doing a game jam right now and this video probably saved the entire project. Thank you!

  • @doughboywhine
    @doughboywhine 2 месяца назад +3

    Steep slopes could be a way to block off parts of the map until the player unlocks a way to traverse them, like how pokemon gen 3 had muddy slopes that required a really fast bike to climb up

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

      Great comment - that's a really good use case! :D

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

    I don’t do any game design but I love your videos, especially the shorts.
    That said I took it as a challenge to think of a use case for slopes and I came up with this:
    A single massive ice slope where you are forced to slide down and enemies and obstacles are in the way.
    Ps you’ve blown my mind about how slopes work. No seriously it’s really interesting learning the problems and solutions to game designs even without being a designer

  • @Mewzuw
    @Mewzuw 2 месяца назад +13

    I wish I knew what Rayman legends Devs did to make their slopes work so well

    • @NXTangl
      @NXTangl 2 месяца назад +11

      Well, Rayman has no legs, so they could just procedurally animate his feet.

    • @Mewzuw
      @Mewzuw 2 месяца назад +3

      @@NXTangl other playable characters in the game have legs tho

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

      ​@@Mewzuw The characters that have legs have VERY TINY legs.

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

      @@Zenzuke Yeah you're right, I think Barbara is the only one that has "long" legs

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

      @@Mewzuw - for a character with longer legs, you animate the feet the same way you'd do Rayman's, and then use some form of IK to place and bend the legs between the feet and body.

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

    I agree with you...slopes introduces some issues but they are also something new in sidescroller type games. I think you had a good idea! I'm also a gamedev i understand your sense of satisfaction about it!

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

      They aren't new at all. NES games from the 80s have slopes. Do you just say things?

  • @alxdrksoul
    @alxdrksoul 2 месяца назад +13

    Slopes made run away from unity and its tutorials with hundreds of lines calculating vectors and normals and what not to make your character just stand on a slope 😅 thankfully UE warmly welcomed me to its engine where your character has zero issues walking and jumping on slopes using 0 lines of code 🥰 btw, remember heading into the final battle in ocarina of time, those stairs before fighting ganon, how about castlevania and those stairs before the dracula fight... oh yeah, I want that in my game haha.

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

    I love game dev content like this that dig into the meaty details of overlooked aspects of how a game is put together.

  • @tayl1r
    @tayl1r 2 месяца назад +3

    slopes in classic platformers like smw and megaman x center the character on the slope as it looks much nicer than just having your collider skim along the surface. but this causes the collider to basically spend half its time inside a wall! when people say slopes are complicated *this* is what they are talking about.
    i feel like your slope problems are just you treating a grid of tiles like they are an abritary physics mesh. but why? you don't need raycasts interact with a grid. you don't need to use normals and dot products to work out inclines when you can just store that information in the tile.

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

    bruh iv not seen so much deep diving into actual mechanics and their pros and cons and solutions and bugs and stuff in such smol packages before finding ur channel. the fast talking speed definitely helps lol😅 nice quick (but also visual 💖tysm) display of alotttt of different types of information is honestly like finding the value pack of gamedev youtube

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

    3:30, I just don't use gravity on ground. 7:10, what contra does for the snes, it makes a different sprite for the on slope idles, most games do not change every sprites. alternatively you can lower the sprite down to its center point (it helps visually, some games just do this) save slopes for part 2 XD

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

    Dude, I LOVE your content. I feel like it can be hard to find well-presented, digestible game-dev content -and you are checking that box phenomenally.

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

    Okay, I'm not really a seasoned game developer, so this is probably a dumb idea, but.....
    What if you just turn off gravity until you actually need gravity. Draw a ray cast to detect if there is ground, if there is no ground turn gravity on. Then, use the collision mask to detect if the ray cast is colliding with a slope and change the velocity angle of your inputs.
    The field of platforming games is almost always pretty saturated with titles. So I feel like if you make a platforming game, you need as much as you can muster in order to stand out from the pack. As much of a pain as slopes may be the potential for additional features could help a game stand out. My personal favorite platformers I have ever played use a lot of context-sensitive inputs, such as having a special sliding attack when you are sliding down a slope.
    Anyway, I was still thinking about this video when I went to sleep last night, so I hope the crazy idea my brain dreamt up can help.
    P.S. I have heard of most of the game dev secrets you share in your shorts before, but I just wanted to say that I really appreciate the simplicity and straightforwardness in how you present those videos. Thank you.

    • @sploofmcsterra4786
      @sploofmcsterra4786 Месяц назад +2

      Please become a seasoned game dev. You got that intuition.

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

    1) Instead if detecting isCollision for raycasts you can label the tile Ground, Slope, Wall and have the raycasts detect each one differently.
    2) Enemies can have entering and exiting slope animations and you can just rotate the enemy art to match the slope degrees. It wont look perfect but it will prevent you from creating several new animations. As for the player you can use the same trick but I would create separate walking and running animations myself since the gamer is always looking at the main player.

  • @trayhl
    @trayhl 2 месяца назад +4

    Here's a probably silly question:
    Why not limit your slopes to pre-defined angles, or angle singular.
    If the slopes are always a known quantity, wouldn't it significantly simplify the amount of physics work needed, as well as necessary art?
    Like, if you know your slopes are always 30º, you can easily check if something is a wall or a slope with two extra raycast half unit above and bellow the original one.
    Also, consistent slope angle looks better IMO than having any angle slopes; and SIGNIFICANTLY cuts the tile art needed for them as well...

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

      Yeah - having a super consistent set of possible angles for the slopes /really/ lightens the workload! It's a great trade-off to make, if you really want slopes but also don't want the full extra cost of adding those slopes!

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

    The programmers of every Sonic The Hedgehog are lolin'n'roflin'
    Btw: like your gamedev secrets shorts, keep'em coming!!

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

    This man refuses to do slopes sloppily.

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

    Dude, thanks for your video. I'm actually doing research on slopes right now (for a game in which they would be an essential component). While watching I remembered the game Iconoclasts having slopes and went to look at it. It actually has a ton of sloped and curved terrain throughout. Im going to take some time and do a more thorough look at how they solved the problems you layed out here. They had some really neat traversal mechanics as well.

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

    I think you're doing slopes a little dirty here. I'm just a player, but I would think that since so many games do use slopes, there have to be at least a few important reasons why they use them. Maybe you're just not aware of those reasons for now?
    Here's just a few I, as a layman, can think of: 1) Slopes make the game world feel more believable. Aesthetics matters. 2) A "rolling boulder" type challenge is a lot harder on a slope (because you have to jump over from further down). 3) Ledge challenges become harder, if the low ground also slopes away. 4) Keeping slower upwards and faster downwards movement for slopes can actually create some interesting challenges and it's less work.
    Which brings me to my 2 potential solutions: a) Just keep the slower upwards/faster downwards speed - that's how it is irl and it's fun. b) Make it so the actual ground of the slopes is a bit behind the visual line of the slope. That would make characters "sink" their feet a little into the slope and it looks better.

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

    Never wrote physics for a 2d game, but what stops you from trying this?
    1. Calculate new position after moving and check character collision.
    2. If the position collides with terrain, snap character to first empty point above the terrain, only if the height difference between last position and current position is below a reasonable treshhold.
    3. If that's not the case (you've likely collided with a wall), keep the last position of the character.

  • @TheSensei88
    @TheSensei88 2 месяца назад +4

    I was watching the slopes rant and I though: "What about Sonic?" the Sega Genesis original Sonic Games, didn't they use the same perspective as Hollow Knight? And boy they had slopes. How did they handle them? I do not remember now the game in detail, but that could be an answer.

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

      there's entire writeups online about sonic's collision detection that are fascinating. The TLDR is that they used sensors to get tile data around sprites, instead of physics-based collision. This method is used in a number of retro games and comes with the benefit of free corner correction.

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

    Extremely entertaining and informative, but my like and subscribe were due to your personality. I just couldn't stop smiling through the whole thing!

  • @shApYT
    @shApYT 2 месяца назад +3

    What about adding friction instead of bodging it? Slopes only make sense when movement is physics based like speedrunners or sonic.

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

    I am really interested in isadora's edge because of the video and the shorts (also because you remind me of Jonas Tyroller when he was making WYS)
    Will the game ever get a discord server for the news and stuff?

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

      I'm working on getting a discord server set up, so it's coming soon!

  • @monkeyme
    @monkeyme Месяц назад +4

    the playable character in Hollow Knight is called "The Knight" and The Knight is referded to as "it" by all NPC's in the game
    The Hollow Knight is One of the Final bosses

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

      Damnnn.
      But also, you are the knight in the Hollow. So I think both are correct.

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

    Good video overall, but I did want to give my opinion on a few points. The mechanics side of things seemed more like an issue with you using Godot and relying on their default physics rather than coding your own. Then for the purposes of slopes, they're not meant to be used everywhere. Slopes are just another tool in your toolkit. As shown in the video, it can be good for parts of a level where you may only want slight changes of elevation. But slopes also show when something may be coming at you from above (rolling/sliding down), or a way for the player to slide down on the other side (which is especially useful if your game has a momentum mechanic). As far as visuals go, I agree that it'll take some extra work. There are easier solutions such as bringing legs closer together or simply rotating the character to match the slope (although that doesn't always look right). If your character isn't purely a single sprite and has rigging potential, you can easily code leg bending for slopes or stairs for dynamic animations, but I don't suspect many 2D games will be doing that. It's probably best to make unique animations for slopes if you want to use them as a mechanic, especially for sliding.