Discuss Scratch

danieldumpling
Scratcher
17 posts

Wall slide

I am developing a rework for a game that I have created, and I can't find a way to make people slide against a wall when they hit it. You can move forward, or turn.
MineTurte
Scratcher
1000+ posts

Wall slide

danieldumpling wrote:

I am developing a rework for a game that I have created, and I can't find a way to make people slide against a wall when they hit it. You can move forward, or turn.
I personally do not know how to do this as I haven't ever really tried but I do suggest looking for a platformer tutorial on YouTube. Pretty sure griffpatch has made one actually.

Hope this helps!
yadayadayadagoodbye
Scratcher
1000+ posts

Wall slide

I would assume you have horizontal collision. To add wallsliding, after you do horizontal collision, check if the player if currently on the ground or in the air, if in the air and the player has touched the “ground” in some other way, they're horizontally on a wall, in which case you can set their y velocity to -1
MineTurte
Scratcher
1000+ posts

Wall slide

yadayadayadagoodbye wrote:

I would assume you have horizontal collision. To add wallsliding, after you do horizontal collision, check if the player if currently on the ground or in the air, if in the air and the player has touched the “ground” in some other way, they're horizontally on a wall, in which case you can set their y velocity to -1
Oh look who came crawling back
danieldumpling
Scratcher
17 posts

Wall slide

Oh I forgot to clarify that my game is top-down, here's a link: https://scratch.mit.edu/projects/838440106/fullscreen/
MineTurte
Scratcher
1000+ posts

Wall slide

danieldumpling wrote:

Oh I forgot to clarify that my game is top-down, here's a link: https://scratch.mit.edu/projects/838440106/fullscreen/
what- how can a platformer be top-down and have wall sliding? Unless you plan on making it 3D…

Edit: or if you mean like horizontal wall sliding… Like in COD…

Last edited by MineTurte (March 20, 2024 19:59:32)

danieldumpling
Scratcher
17 posts

Wall slide

MineTurte wrote:

danieldumpling wrote:

Oh I forgot to clarify that my game is top-down, here's a link: https://scratch.mit.edu/projects/838440106/fullscreen/
what- how can a platformer be top-down and have wall sliding? Unless you plan on making it 3D…

Edit: or if you mean like horizontal wall sliding… Like in COD…

It's not a platformer
danieldumpling
Scratcher
17 posts

Wall slide

I tried bouncing the player back but it is very glitchy

Powered by DjangoBB