see inside for instructions
you could implement the code into a platformer but i have a separate engine with more complex code for that https://scratch.mit.edu/projects/1101249245/ check it out!