huge thanks to @Gangstermango for the help and ideas very out of date now go check out sonic skyfall daily progress instead https://scratch.mit.edu/projects/1315212928/
THIS IS IN HEAVY DEVELOPMENT this has been shared directly as i created it, so you can see as i develop it and add features - NOT A GAME this code is fairly well commented, so feel free to look inside. it might be turned into a tutorial series later, or it wont, im not sure CHANGELOG 0.1 - got tile scrolling working, can grab tile types from xy positions 0.2 - basic ground collision working, made a filler level, changed some physics to be a bit more responsive, also tiles loop along the y axis now 0.3 - improved some collision, added a debug mode (press k to toggle) 0.4 - added accurate jump physics (changes both the x and y value for accuracy on slopes) 0.45 - fixed a small bug where the player would sink slightly into sloped tiles at their apex 0.45 bugged - trying to fix a bug with the collision detection but i seem to have introduced many more... working on fixing it 0.5 - at long last, the bug with collision has been fixed! i've also gone through and organized most of the code and added some comments, and im working on wall collision next 0.6 - wall collision has been added! next up: working on whether or not the player should stick to the floor and ceiling collision 0.7 - edge detection is in! the player will no longer snap to the ground if the angle is too steep. 0.8 - ceiling collision is added but has major flaws... also something about it broke wall collision in some cases so that needs to be reworked now... but we're getting there 0.9 - wall and ceiling collision have both been fixed! all that's left now is to add walking on walls/ceilings