I wrote an API yesterday that allows walljumping universally for all characters. Although it's a little tough to get it to work with Peach due to the hover, you can still get her to walljump if you get the timing right. v1.1 adds a new variable (see below). Thanks to Enjl for the suggestion. This version is still compatible with levels using the older version. Also as of v1.2 the player can no longer walljump when holding an item and also can't walljump while on a mount (boot, Yoshi, or clown car).
The following are variables that can be accessed via a lunadll.lua file, etc.:
walljumps.slideSpeed: Speed when sliding down walls. (Default: 3, Recommended Range: 2.5-3.5)
walljumps.jumpIntensityX: Absolute speed of how fast the player travels along the horizontal axis after walljumping. (Default: 3, Recommended Range: 3-5)
walljumps.jumpIntensityY: Speed of how fast the player travels along the vertical axis after walljumping. (Default: -9, Recommended Range: 8.5-10)
walljumps.delayTime: Time (in seconds) that the player has to wait to walljump after making contact with the wall. (Default: 0.25, Recommended Range: 0-0.4)
New v1.1:
walljumps.forceRelease: True or false (boolean) whether or not the player must release the jump key before performing a wall jump. (Default: false)
So it's more of a Mega Man X style wall jump... this is going to be, like, very useful for me. I was going to try to figure out how to code an MMX-style wall jump and this saves me a lot of work. Is it possible to assign a new sprite for sliding on the wall using empty spaces on the player GFX file?
Enchlore wrote:So it's more of a Mega Man X style wall jump... this is going to be, like, very useful for me. I was going to try to figure out how to code an MMX-style wall jump and this saves me a lot of work. Is it possible to assign a new sprite for sliding on the wall using empty spaces on the player GFX file?
I was considering that. The issue revolves around all of the different characters with different empty spaces, especially with 2.0 coming out, which has character costumes that have different hitboxes, etc. The other issue with using those empty spaces is setting the hitboxes for them. I would suggest using an already existing sprite on the spritesheet, for example, when I had this idea earlier, I looked at using the jump animations of Mario and Luigi, since they have one hand in the air
After playing through a level with this I have noticed some issues.
1) You can just hold a button and jump your way into space, which feels awkward and is just wrong.
2) You don't "stick" to the wall, which makes jumping to walls on the opposite side very tricky and uncomfortable to control.
Enjl wrote:After playing through a level with this I have noticed some issues.
1) You can just hold a button and jump your way into space, which feels awkward and is just wrong.
2) You don't "stick" to the wall, which makes jumping to walls on the opposite side very tricky and uncomfortable to control.
If you can explain further, I'll see what I can do. What do you mean by "jump your way into space"? And I also don't understand what you're referring to by "stick"
Enjl wrote:After playing through a level with this I have noticed some issues.
1) You can just hold a button and jump your way into space, which feels awkward and is just wrong.
2) You don't "stick" to the wall, which makes jumping to walls on the opposite side very tricky and uncomfortable to control.
If you can explain further, I'll see what I can do. What do you mean by "jump your way into space"? And I also don't understand what you're referring to by "stick"
1) You'll jump off a wall as long as the jump button is pressed after the initial delay is over, which means that as long as you're enclosed between two walls, holding the jump button is enough to propel you all the way to the top:
2) Usually when you have walljump code, you give the player a certain amount of tolerance before detaching them from the wall, to let them switch over to moving into the opposite direction without losing the ability to jump off the wall. Just play New Super Mario Bros. for the DS.
Enjl wrote:1) You'll jump off a wall as long as the jump button is pressed after the initial delay is over, which means that as long as you're enclosed between two walls, holding the jump button is enough to propel you all the way to the top:
So are you saying that the code should force the player to let go of the jump button?
Enjl wrote:2) Usually when you have walljump code, you give the player a certain amount of tolerance before detaching them from the wall, to let them switch over to moving into the opposite direction without losing the ability to jump off the wall. Just play New Super Mario Bros. for the DS.
So you mean it should consider the player wallsliding if they're within a certain distance from the wall, not necessarily pushed directly up against it?
This is amazing!! Now I'm gonna need to think of how to use wall jumping in certain levels... Man, I guess you could say people are making SMBX great again!