Underground Platformer

Instructions: Use arrow keys or AWDS get through the course 

@Stage\n\n@minon\n\nwhen I receive [y vel  v]\nset [yv v] to [20]\n\nwhen flag clicked\ngo to x: (-200) y: (-1)\nset size to (80) %\nswitch costume to (alive v)\nshow\nset [level v] to [1]\nset [xv v] to [0]\nset [yv v] to [0]\nforever\n    if <<<key (right arrow v) pressed?> or <key (d v) pressed?>> or <<mouse down?> and <(mouse x) > [10]>>> then\n        change [xv v] by (1)\n    end\n    if <<<key (left arrow v) pressed?> or <key (a v) pressed?>> or <<mouse down?> and <(mouse x) < [-10]>>> then\n        change [xv v] by (-1)\n    end\n    set [xv v] to ((Xv) * (0.9))\n    change x by (Xv)\n    if <touching (platform v)?> then\n        change y by (1)\n        if <touching (platform v)?> then\n            change y by (1)\n            if <touching (platform v)?> then\n                change y by (1)\n                if <touching (platform v)?> then\n                    change y by (1)\n                    if <touching (platform v)?> then\n                        change y by (1)\n                        if <touching (platform v)?> then\n                            change x by ((Xv) * (-1))\n                            if <<<key (up arrow v) pressed?> or <key (w v) pressed?>> or <<mouse down?> and <(mouse y) > (y position)>>> then\n                                if <(Xv) > [0]> then\n                                    set [xv v] to [5]\n                                else\n                                    set [xv v] to [-5]\n                                end\n                                set [yv v] to [12]\n                            else\n                                set [xv v] to [0]\n                            end\n                        end\n                    end\n                end\n            end\n        end\n    end\n    change [yv v] by (-1)\n    change y by (Yv)\n    if <touching (platform v)?> then\n        change y by ((Yv) * (-1))\n        set [yv v] to [0]\n    end\n    change y by (-1)\n    if <touching (platform v)?> then\n        if <<<key (up arrow v) pressed?> or <key (w v) pressed?>> or <<mouse down?> and <(mouse y) > (y position)>>> then\n            set [yv v] to [15]\n        end\n    end\n    if <touching (water v)?> then\n        if <<<key (right arrow v) pressed?> or <key (d v) pressed?>> or <<mouse down?> and <(mouse x) > (x position)>>> then\n            change [xv v] by (-00.9)\n        end\n        if <<<key (left arrow v) pressed?> or <key (a v) pressed?>> or <<mouse down?> and <(mouse x) > (x position)>>> then\n            change [xv v] by (0.9)\n        end\n        if <<<key (up arrow v) pressed?> or <key (w v) pressed?>> or <<mouse down?> and <(mouse y) > (y position)>>> then\n            set [yv v] to [2]\n        end\n    end\n    if <touching (marshmello v)?> then\n        set [yv v] to [20]\n    end\n    change y by (1)\n    if <key (r v) pressed?> then\n        reset\n    end\n    if < or <touching (lava variable v)?>> then\n        start sound [Death v]\n        reset\n    end\n    if <(x position) > [230]> then\n        change [level v] by (1)\n        broadcast (Next level! v)\n        reset\n    end\nend\n\nwhen flag clicked\nforever\n    if <touching (danger v)?> then\n        broadcast (Reset! v)\n    end\nend\n\nwhen I receive [reset! v]\ngo to x: (-200) y: (-169)\n\nwhen flag clicked\nforever\n    if <<(x position) = [274]> and <(y position) = [-167]>> then\n        broadcast (Next level! v)\n    end\nend\n\nwhen I receive [next level! v]\ngo to x: (-200) y: (-169)\n\nwhen flag clicked\nforever\n    if <(level) = [11]> then\n        stop [other scripts in sprite v]\n        go to x: (-4) y: (-43)\n    end\nend\n\n@backround\n\nwhen flag clicked\nswitch costume to (costume1 v)\nforever\n    go to [back v] layer\nend\n\nwhen I receive [next level! v]\nnext costume\n\n@Platform\n\nwhen I receive [next level! v]\nnext costume\n\nwhen flag clicked\nshow\ngo to [front v] layer\nswitch costume to (costume1 v)\n\n@Danger\n\nwhen flag clicked\nshow\ngo to [back v] layer\nswitch costume to (costume1 v)\n\nwhen I receive [next level! v]\nnext costume\n\n@Sprite1\n\nwhen flag clicked\nhide\ngo to [back v] layer\n\n