Sorry for the lack of updates! I've still been running in circles due to confusion, and the main problem: collision with the bg layer. Floors and platforms dont work, rpg wall collision doesnt work... so i've been mentally takin a break!
Well, I think the main problem is that you're using sprites for bg collision, but I will give you points for stretching it out though. You've had the background load before so do that for this. Then make a variable, BG for example, and give it a value with BGGET so it looks like this;
BG=BGGET(layer,(PX+ofsx)/16,(PY+ofsy)/16)
ofsx/ofsy or X/Y offset help make collision more precise.
Thanks! To be honest, I'm not a fan of how collision works in this. Sprite collision isn't that bad but bgcollision seems a little iffy. Just remember that for sprite collision, set up a hitbox for each direction so they don't overlap with each other. And give a separate hitbox for taking damage.
Ok, even though sprite movement has no real restrictions BGGET works off of the 16x16 bg tiles. That's why BGGET(L,X,Y) looks more like BGGET(L,PX/16,PY/16). This is where order is important, if you add 1 to PX before dividing by 16 (by parentheses) you're change the "hitbox". If you add 1 after you're changing the tile