Hello everyone,
I’ve been trying to find a solution to this problem for a while. What I’m going to talk about might not bother or shock many people but I find that it prevents the possibility to make really “precise” platformers
Basically when you jump on a upwards platform, the momentum is broken and it looks like I’m jumping straight up without running, then I keep moving forward in the air. I’ve uploaded a few clips of tests I did to show you a little more.
(since my account is new I can’t upload more than 1 embedded video and streamable doesn’t seem to work here so I’ve posted the links on a privatebin PrivateBin)
Note that the first 2 clips are made from the platformer template, I just changed the sprite of the character to make it more visible and I changed the gravity to 9000 to make the problem look more obvious right away.
On the 2nd, the gravity isn’t changed from the platformer template. It’s still there but I guess it’s more subtle. You can see the moment I jump there’s no momentum, only happens when I’m trying to jump on the right on this ascending slope (and it doesn’t matter how high it is, I’ve tried to have the slope just a little tiny bit higher, the issue is still there)
The 3rd one comes from my personal project where it’s also visible. I’ve just did a new map with testing platforms and it happens on both side, as long as you jump on the ascending side.
For now the solution I found is to put the platform in jumpthrough. In jumpthrough everything works as it should. The problem is that I want to have the ability to jump down from a platform, but I don’t want the player to be able to jump down wherever he wants. So I thought of a variable that I could enable or disable depending on the platform he is on. This is the most reliable workaround I’ve found so far. It requires more work but for the moment I have to make do with it.
I thought it was still worth posting here in case anyone wants to take a look at it? For me it’s clearly a bug and I was tearing my hair out a bit because I felt like it was a basic thing and I had to skip something, but the tutorials I’ve seen only use flat platforms. Anyway, since I didn’t see anyone talking about it, I thought it was a good idea to at least post here to see what people who know more about it than me think.
Sorry if it’s too long, thanks a lot if you read it all