Scratch (A Platformer) 2.0

Instructions: AD or Arrow Keys To Move\nUp Or W To Jump\n\n\n\n\nSTORY\n_______________________________________________________\nScratch Cat Has Been Used For Scratch As a Sprite Ever Sense Scratch Was Made. But Something Went Wrong And The Scratch Cat Was Sucked Into The Code. And He Is Trying To Escape.\n_______________________________________________________    \n

@Stage\n\nwhen flag clicked\nswitch backdrop to (backdrop1 v)\n\nwhen I receive [thumbnail v]\nswitch backdrop to (backdrop2 v)\n\nwhen I receive [end v]\nswitch backdrop to (backdrop3 v)\nstop all sounds\nstop [all v]\n\nwhen flag clicked\nforever\n    play sound (pick random (1) to (2)) until done\nend\n\n@Scratch Cat\n\nwhen flag clicked\nshow\ngo to x: (-162) y: (180)\nset [x v] to [0]\nset [y v] to [0]\nswitch costume to (stand_1 v)\nforever\n    platform physics (11.5) (-1) (0.7) (2)\nend\n\ndefine None\nswitch costume to (hitbox v)\nchange y by (y)\nif <touching (ground v)?> then\n    repeat ([abs v] of (y) )\n        if <touching (ground v)?> then\n            change y by ((-1) * (([abs v] of (y) ) / (y)))\n        end\n    end\n    if <<<key (up arrow v) pressed?> or <key (w v) pressed?>> and <not <(y) > [0]>>> then\n        set [y v] to (jump height)\n    else\n        set [y v] to [0]\n    end\nelse\n    change [y v] by (gravity)\nend\nif <<key (right arrow v) pressed?> or <key (d v) pressed?>> then\n    change [x v] by (movement speed)\n    point in direction (90)\nend\nif <<key (left arrow v) pressed?> or <key (a v) pressed?>> then\n    change [x v] by ((-1) * (movement speed))\n    point in direction (-90)\nend\nchange x by (x)\nif <touching (ground v)?> then\n    set [old  y v] to (y position)\n    repeat ([abs v] of (x) )\n        if <touching (ground v)?> then\n            change y by (1)\n        end\n    end\n    if <touching (ground v)?> then\n        set y to (Old  Y)\n        repeat ([ceiling v] of ([abs v] of (x) ) )\n            if <touching (ground v)?> then\n                change x by ((-1) * (([abs v] of (x) ) / (x)))\n            end\n        end\n        set [x v] to [0]\n    end\nend\nswitch costume to (stand_1 v)\nset [x v] to ((x) * (friction))\nif <(y) > [2]> then\n    switch costume to (jump_1 v)\nend\nif <(y) < [-3]> then\n    switch costume to (fall_1 v)\nend\nif <<<key (right arrow v) pressed?> or <key (d v) pressed?>> or <<key (left arrow v) pressed?> or <key (a v) pressed?>>> then\n    switch costume to (Walk)\nend\nif <<(y position) < [-179]> or <touching (lava v)?>> then\n    go to x: (-162) y: (180)\nend\n\nwhen flag clicked\nset [walk v] to [4]\nforever\n    change [walk v] by (1)\n    if <(Walk) > [19]> then\n        set [walk v] to [4]\n    end\n    wait (0.01) seconds\nend\n\nwhen flag clicked\nforever\n    if <(x position) > [235]> then\n        go to x: (-162) y: (180)\n        broadcast (Next Room  v)\n    end\nend\n\nwhen I receive [thumbnail v]\nhide\nstop [other scripts in sprite v]\n\nwhen flag clicked\nforever\n    if <touching color (#009933)?> then\n        broadcast (End v)\n        hide\n    end\nend\n\n@Ground\n\nwhen flag clicked\nshow\nswitch costume to (00 v)\ngo to x: (0) y: (0)\n\nwhen I receive [thumbnail v]\nhide\nstop [other scripts in sprite v]\n\nwhen I receive [end v]\nhide\n\nwhen I receive [next room  v]\nnext costume\n\nwhen flag clicked\nforever\n    if <(costume [number v]) = [11]> then\n        broadcast (Lava v)\n    end\nend\n\n@ThumbNail\n\nwhen flag clicked\nhide\nforever\n    if <(username) = [Popfiz910]> then\n        if <key (t v) pressed?> then\n            show\n            broadcast (ThumbNail v)\n        end\n    end\nend\n\nwhen I receive [end v]\nhide\n\n@Lava\n\nwhen flag clicked\ngo to x: (164) y: (0)\nhide\n\nwhen I receive [lava v]\nshow\n\nwhen I receive [next room  v]\nhide\n\n