[Example] 2D Topdown Jumping


#1

2D TopDown Jumping

2d%20topdown%20jump%20small

Its been a while, since i started this little experiment.
I thought i´ll finish it up and publish here for everyone interested.
a custom camera shake is included.

The highlight here is the Shadow, that indicates your position. With this necessary feature , actual gameplay with 2d jumps is possible. I made it with a tiled Sprite to dynamically change the height/width. It works pretty well, but doesn’t update fast enough to be perfect.

Disclaimer:
For everyone who wants to use it: The Tilebased shadow was made, before sprite masking existed. The Masking extension does this much better.

enjoy :slight_smile:

Edit:
I did an isometric (dimetric) example too, to show, how to use the masking extension for the shadow.
2d%20topdown%20sio%20jump%20small

Isometric Jumping


#2

Nice one, good job :+1:


#3

Wow… I remembered a videogame “Sonic Battle”, because there’s platforms, like in your example. Very good job


#4

i added a isometric example too.


#5

This is rad as all heck. Both examples are really good uses of the basics and concepts.


#6

I took my isometric concept and expanded upon it, by adding grabable ledges and other fancy states.
Getting the Sorting/ZOrders right is a pretty difficult task, but i got it 95% working now.
I have not done any serious polishing for now (especially the Origin points of the getup animations need some finetuning & the movement of the character), but the proof of concept stands.

one curious problem i faced was, that i needed the player to split in 2 objects, to have the upper half of the getup animation a layer higher, but only the first time i played the animation of the second bodypart, the animations stayed in sync. every following animation iterations had a slight delay and the only way to solve it was to delete the 2nd part and recreate it.

2.5D Platformer
Can anyone who test it give feedback about the framerate?
sometimes it runs smooth, sometimes its laggy for me, idk why and how to fix it. Hopefully its just hardware limitations.


#7

Really good work! very good combination of resources!


#8

How was your frame rate? Laggy?
It’s supposed to be 30fps


#9

I can’t see the exact value but I don’t think it reaches 30fps. What I could see is that the movement is smoother when you start the walk in any direction. At about 0.2-0.3 seconds it gets slower. The movement is smoother only when you start the walk.
I don’t know if it’s because my computer is slow.


#10

Awesome :clap:
It runs smooth for me, even with the sprint, but I didn’t see a FPS counter.
The only issue I noticed is with the arrows. If I do: press right, press down, release down, then right isn’t detected anymore, I need to release and press it again.
Not sure if that’s your game or my keyboard or something else.
Also, it’s a bit weird that she jumps high to eventually grab the edge when falling. Again, not sure if that’s your game or GD.


#11

Thanks for the feedback

Well, the acellaration of the character is not instant

It’s the game. To avoid moonwalking and for better performance it only reads the last input.

Not sure what’s weird for You?
There are 4 different jumpheights, depending on speed. Lowest speed = standjump =highest jump
If you grab a ledge or not is depending on the height


#12

I mean, regarding fps. Surely the problem is my computer


#13

I meant that it would feel more natural if she grabbed the edge on the way up, not during her fall.

Oh, I just noticed she can move sideways during the grab, awesome!


#14

Hmm. It’s intentional to grab the ledge during fall.
Otherwise grabbing far away ledges in platfplatformer sections would not be possible.
But I get your point of overshooting jumps to grab ledges right in front feels a little off.
I could make an initial check at the start of the jump and automatically adjust jumpheight to ledgeheight, if speed is 0 and ledge is right in front.

The initial idea of this project was a 2D monsterhunter. But a stealth / thief game or a simple collect “insert Mario stars substitute here” kind of game would work well too.
As of now, it’s just testing height mechanics