Puzzle Platformer

Instructions: -arrow keys to move\n-I feel like I should have to say this but advertising will be removed\n- part 2 is out!!! https://scratch.mit.edu/projects/649559376/\n-you guys can either vote on what choice I should make the next off or I can make it so that in the next one you can choose\n-this took me 5 hours o.o\n-all levels are possible\n- hope you like this it took me so long!!\n-1500+ VEIWS?!? WOAH

@Stage\n\nwhen I receive [clean up flop v]\nswitch backdrop to (backdrop2 v)\n\nwhen flag clicked\nswitch backdrop to (backdrop1 v)\n\nwhen I receive [into the code v]\nswitch backdrop to (backdrop3 v)\n\nwhen I receive [glitcchhh v]\nswitch backdrop to (backdrop2 v)\n\n@Player\n\nwhen I receive [death v]\nset rotation style [all around v]\nset [gravity v] to [10]\nrepeat until <(y position) < [-179]>\n    switch costume to (bye-bye v)\n    go to [front v] layer\n    turn right (10) degrees\n    change y by (Gravity)\n    change [gravity v] by (-1)\nend\nset rotation style [left-right v]\n\nwhen I receive [start v]\npoint in direction (90)\nset rotation style [left-right v]\nshow\nhide variable [y v]\nhide variable [x v]\nset [y v] to [0]\nset [x v] to [0]\nforever\n    change [y v] by (-1)\n    if <<key (left arrow v) pressed?> or <<key (a v) pressed?> or <<mouse down?> and <(x position) > (mouse x)>>>> then\n        point in direction (-90)\n        change [x v] by (-1)\n    end\n    if <<key (right arrow v) pressed?> or <<key (d v) pressed?> or <<mouse down?> and <(mouse x) > (x position)>>>> then\n        point in direction (90)\n        change [x v] by (1)\n    end\n    set [x v] to ((X) * (0.9))\n    change x by (X)\n    if <<touching (platformer v)?> or <touching (helper v)?>> then\n        change y by (1)\n    end\n    if <<touching (platformer v)?> or <touching (helper v)?>> then\n        change y by (1)\n    end\n    if <<touching (platformer v)?> or <touching (helper v)?>> then\n        change y by (1)\n    end\n    if <<touching (platformer v)?> or <touching (helper v)?>> then\n        change y by (1)\n    end\n    if <<touching (platformer v)?> or <touching (helper v)?>> then\n        change y by (-4)\n        change x by ((X) * (-1))\n        if <<key (up arrow v) pressed?> or <<key (w v) pressed?> or <<mouse down?> and <(mouse y) > (y position)>>>> then\n            set [y v] to [17]\n            if <(X) > [0]> then\n                set [x v] to [-10]\n            else\n                set [x v] to [10]\n            end\n        else\n            set [x v] to [0]\n        end\n    end\n    change y by (Y)\n    if <<touching (platformer v)?> or <touching (helper v)?>> then\n        change y by ((Y) - ((Y) * (2)))\n        set [y v] to [0]\n    end\n    change y by (-1)\n    if <<<key (up arrow v) pressed?> or <<key (w v) pressed?> or <<mouse down?> and <(mouse y) > (y position)>>>> and <touching (platformer v)?>> then\n        set [y v] to [15]\n    end\n    change y by (1)\n    if <touching (spikes v)?> then\n        broadcast (Death v) and wait\n        go to x: (-217) y: (70)\n        point in direction (90)\n        set rotation style [left-right v]\n        broadcast (Reset the moving variables v)\n        clear graphic effects\n    end\n    if <(x position) > [222]> then\n        hide\n        broadcast (Next Level v) and wait\n        go to x: (-214) y: (70)\n        broadcast (Reset the moving variables v)\n        show\n        clear graphic effects\n    end\nend\n\nwhen I receive [reset the moving variables v]\nset [x v] to [0]\nset [y v] to [0]\n\nwhen flag clicked\ngo to x: (-214) y: (-85)\npoint in direction (90)\n\nwhen I receive [skip v]\nhide\ngo to x: (-214) y: (70)\nbroadcast (Next Level v)\nbroadcast (Reset the moving variables v)\nshow\n\nwhen flag clicked\nforever\n    if <<touching (bounce v)?> or <touching (bounce2 v)?>> then\n        set [y v] to [20]\n    end\nend\n\nwhen flag clicked\nforever\n    if <touching (speed2 v)?> then\n        change [x v] by (10)\n    end\n    if <<<touching (speed3 v)?> or <touching (speed4 v)?>> or <<touching (speed5 v)?> or <<touching (speed6 v)?> or <<touching (speed v)?> or <<<touching (speed8 v)?> or <<touching (speed9 v)?> or <touching (speed10 v)?>>> or <touching (speed11 v)?>>>>>> then\n        change [x v] by (-10)\n    end\n    if <touching (speed7 v)?> then\n        change [y v] by (-10)\n    end\nend\n\nwhen flag clicked\nbroadcast (Start v)\n\nwhen flag clicked\nforever\n    if <<<key (right arrow v) pressed?> or <<mouse down?> and <(mouse x) > (x position)>>> or <<key (left arrow v) pressed?> or <<mouse down?> and <(x position) > (mouse x)>>>> then\n        if <not <<key (up arrow v) pressed?> or <<mouse down?> and <(mouse y) > (y position)>>>> then\n            switch costume to (side v)\n        else\n            switch costume to (up-side v)\n        end\n    else\n        if <<key (up arrow v) pressed?> or <<mouse down?> and <(mouse y) > (y position)>>> then\n            if <<<key (right arrow v) pressed?> or <<mouse down?> and <(mouse x) > (x position)>>> or <<key (left arrow v) pressed?> or <<mouse down?> and <(x position) > (mouse x)>>>> then\n                switch costume to (up-side v)\n            else\n                switch costume to (up v)\n            end\n        else\n            if <<key (down arrow v) pressed?> or <<mouse down?> and <(y position) > (mouse y)>>> then\n                switch costume to (squueze v)\n            else\n                switch costume to (middle v)\n            end\n        end\n    end\nend\n\nwhen flag clicked\nshow\ngo to x: (-205) y: (-54)\nforever\n    if <<<key (up arrow v) pressed?> or <<mouse down?> and <(mouse y) > (y position)>>> and <touching (water v)?>> then\n        change [y v] by (1)\n        if <<<key (up arrow v) pressed?> or <<mouse down?> and <(mouse y) > (y position)>>> and <not <touching (water v)?>>> then\n            set [y v] to [-1]\n        end\n    end\nend\n\nwhen I receive [next level v]\ngo to x: (-205) y: (-55)\n\nwhen flag clicked\nswitch costume to (middle v)\nforever\n    wait (0.1) seconds\n    create clone of (_myself_ v)\nend\n\nwhen I start as a clone\nswitch costume to (trail v)\nrepeat (20)\n    change size by (-5)\n    change [ghost v] effect by (5)\nend\ndelete this clone\n\nwhen flag clicked\nforever\n    if <touching (sprite2 v)?> then\n        broadcast (walls v)\n    end\nend\n\n@Spikes\n\nwhen flag clicked\npoint in direction (90)\nshow\nforever\n    go to x: (0) y: (0)\n    if <<(level) = [3]> or <<(level) = [7]> or <<(level) = [9]> or <(level) = [12]>>>> then\n        set y to ((([sin v] of (((timer) + (Lava)) * (300)) ) * (2)) - ((Lava) * (4)))\n    end\n    if <(level) = [8]> then\n        turn right (5) degrees\n        go to x: (0) y: (-50)\n    else\n        point in direction (90)\n    end\nend\n\nwhen flag clicked\nswitch costume to (costume1 v)\nset [level v] to [1]\n\nwhen flag clicked\nforever\n    go to [back v] layer\n    go [forward v] (1) layers\nend\n\nwhen I receive [next level v]\nnext costume\n\nwhen I receive [next level v]\nchange [level v] by (1)\n\n@Platformer\n\nwhen I receive [levelübergang v]\nnext costume\nchange [level v] by (1)\n\nwhen flag clicked\nshow\nswitch costume to (costume1 v)\nset [level v] to [1]\nforever\n    go to x: (0) y: (0)\nend\n\nwhen I receive [intro finish v]\ngo to [front v] layer\ngo [backward v] (5) layers\n\nwhen I receive [next level v]\nnext costume\nchange [level v] by (1)\n\nwhen I receive [walls v]\nswitch costume to (walls free v)\n\nwhen I receive [walls 2 v]\nif <<(level) = [3]> or <(level) = [4]>> then\n    stop [this script v]\nend\nif <<(level) = [5]> or <(level) = [6]>> then\n    stop [this script v]\nend\nif <<(level) = [7]> or <(level) = [8]>> then\n    stop [this script v]\nend\nif <<(level) = [9]> or <(level) = [10]>> then\n    stop [this script v]\nend\nif <<(level) = [11]> or <(level) = [12]>> then\n    stop [this script v]\nend\nif <<(level) = [13]> or <(level) = [14]>> then\n    stop [this script v]\nend\nif <<(level) = [15]> or <(level) = [16]>> then\n    stop [this script v]\nend\nswitch costume to (walls free2 v)\n\nwhen flag clicked\nforever\n    if <(level) = [2]> then\n        broadcast (button 2 v)\n    end\n    if <(level) = [3]> then\n        stop [this script v]\n    end\nend\n\nwhen I receive [walls 3 v]\nif <<(level) = [3]> or <(level) = [4]>> then\n    stop [this script v]\nend\nif <<(level) = [5]> or <(level) = [6]>> then\n    stop [this script v]\nend\nif <<(level) = [7]> or <(level) = [8]>> then\n    stop [this script v]\nend\nif <<(level) = [9]> or <(level) = [10]>> then\n    stop [this script v]\nend\nif <<(level) = [11]> or <(level) = [12]>> then\n    stop [this script v]\nend\nif <<(level) = [13]> or <(level) = [14]>> then\n    stop [this script v]\nend\nif <<(level) = [15]> or <(level) = [16]>> then\n    stop [this script v]\nend\nswitch costume to (walls free4 v)\n\nwhen flag clicked\nwait until <(level) = [3]>\nif <(level) = [3]> then\n    switch costume to (costume 3 v)\n    broadcast (clean up crew v)\nend\nif <(level) = [4]> then\n    stop [this script v]\nend\n\nwhen I receive [process failed v]\nswitch costume to (costume 4 v)\n\nwhen flag clicked\nwait until <(level) = [4]>\nbroadcast (glitch effect v)\nbroadcast (clean up flop v)\n\nwhen flag clicked\nwait until <(level) = [14]>\nbroadcast (Into the code v)\n\nwhen flag clicked\nwait until <(level) = [11]>\nwait (0) seconds\nbroadcast (glitcchhh v)\n\nwhen flag clicked\nwait until <(level) = [12]>\nbroadcast (stop glitching v)\n\n@Sprite1\n\nwhen flag clicked\nswitch costume to (costume1 v)\nhide\n\nwhen this sprite clicked\nforever\n    switch costume to (costume2 v)\n    wait (.1) seconds\n    broadcast (walls 2 v)\n    wait (3) seconds\n    hide\nend\n\nwhen I receive [button 2 v]\nshow\n\n@Sprite2\n\nwhen flag clicked\nshow\nswitch costume to (costume1 v)\nforever\n    if <(level) = [1]> then\n        switch costume to (costume1 v)\n        go to x: (50) y: (-59)\n    end\n    if <(level) = [2]> then\n        hide\n    end\nend\n\nwhen I receive [walls v]\nswitch costume to (costume2 v)\nwait (1) seconds\nswitch costume to (costume1 v)\nhide\n\n@Sprite3\n\nwhen flag clicked\nswitch costume to (costume1 v)\nhide\n\nwhen this sprite clicked\nforever\n    switch costume to (costume2 v)\n    broadcast (walls 3 v)\n    wait (3) seconds\n    hide\nend\n\nwhen I receive [button 2 v]\nshow\n\n@Sprite4\n\nwhen flag clicked\nhide\n\nwhen I receive [clean up crew v]\nswitch costume to (costume1 v)\nshow\nwait (2) seconds\nrepeat (11)\n    next costume\n    wait (.7) seconds\nend\nwait (2) seconds\nbroadcast (process failed v)\n\nwhen I receive [clean up flop v]\nhide\n\n@Sprite5\n\nwhen flag clicked\nhide\n\nwhen I receive [glitch effect v]\nshow\n\n@Sprite6\n\nwhen flag clicked\nforever\n    show\n    go to [front v] layer\n    set [ghost v] effect to (100)\n    go to x: (0) y: (0)\nend\n\n@Sprite7\n\nwhen flag clicked\nforever\n    play sound [No Money v] until done\nend\n\n@Sprite8\n\nwhen I receive [glitcchhh v]\ngo to [front v] layer\nshow\nset [ghost v] effect to (20)\nrepeat (10)\n    next costume\n    wait (.07) seconds\nend\n\nwhen flag clicked\nswitch costume to (costume1 v)\nhide\n\nwhen I receive [stop glitching v]\nhide\n\n