My best Platformer Yet!!!

Instructions: Use W.A.S.D. or arrow keys to move, and have a great time!\n-----------------------------------------------------------------------\nThe trick to wall climbing is to hold the up arrow or W.\n-----------------------------------------------------------------------\nClick Z. to skip the first (easier) levels.\nClick R. to reset your game\nClick K. at any time to skip a level that's to hard!\n------------------------------------------------------------------------\nDon't forget to Heart & Star! :)\nNew platformer, click link \nhttps://scratch.mit.edu/projects/381728623/

@Stage\n\n@mee sa\n\ndefine Platform (jump height) (gravity) (friction) (running speed)\nif <<key (right arrow v) pressed?> or <key (d v) pressed?>> then\n    point in direction (90)\n    change [x velocity2 v] by (running speed)\nend\nif <<key (left arrow v) pressed?> or <key (a v) pressed?>> then\n    point in direction (-90)\n    change [x velocity2 v] by ((running speed) * (-1))\nend\nset [x velocity2 v] to ((X Velocity2) * (friction))\nchange x by (X Velocity2)\nif <touching (level v)?> then\n    set [slope2 v] to [0]\n    repeat until <<(Slope2) = [8]> or <not <touching (level v)?>>>\n        change [slope2 v] by (1)\n        change y by (1)\n    end\n    if <touching (level v)?> then\n        change y by ((Slope2) * (-1))\n        repeat ([ceiling v] of ([abs v] of (X Velocity2) ) )\n            if <touching (level v)?> then\n                change x by ((([abs v] of (X Velocity2) ) / (X Velocity2)) * (-1))\n            end\n        end\n        set [x velocity2 v] to [0]\n    end\nend\nchange y by (Y Velocity2)\nif <touching (level v)?> then\n    repeat ([ceiling v] of ([abs v] of (Y Velocity2) ) )\n        if <touching (level v)?> then\n            change y by ((([abs v] of (Y Velocity2) ) / (Y Velocity2)) * (-1))\n        end\n    end\n    if <<(([abs v] of (Y Velocity2) ) / (Y Velocity2)) = [-1]> and <<key (up arrow v) pressed?> or <key (w v) pressed?>>> then\n        set [y velocity2 v] to (jump height)\n    else\n        set [y velocity2 v] to [0]\n    end\nelse\n    change [y velocity2 v] by (-1)\nend\nswitch costume to (guy v)\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 Velocity2) > [2]> then\n    switch costume to (jump v)\nend\nif <(Y Velocity2) < [-3]> then\n    switch costume to (fal v)\nend\n\nwhen flag clicked\nset [level v] to [1]\n\nwhen flag clicked\nset [walk v] to [5]\nforever\n    change [walk v] by (1)\n    if <(Walk) > [8]> then\n        set [walk v] to [5]\n    end\n    wait (0.1) seconds\nend\n\nwhen flag clicked\nswitch backdrop to (backdrop1 v)\ngo to x: (-145) y: (-100)\nset [x velocity2 v] to [0]\nset [y velocity2 v] to [0]\nforever\n    Platform [11.5] [-1] [0.7] [3]\nend\n\nwhen flag clicked\nforever\n    if <touching (portal v)?> then\n        set [brightness v] effect to (60)\n        wait (0.05) seconds\n        change [brightness v] effect by (80)\n        go to x: (-145) y: (-100)\n        set [brightness v] effect to (0)\n        change [level v] by (1)\n    end\nend\n\nwhen flag clicked\nhide variable [slope2 v]\nhide variable [walk v]\nhide variable [y velocity2 v]\nhide variable [x velocity2 v]\n\nwhen flag clicked\nforever\n    if <<<<touching (spike 1 v)?> or <touching (spike 6 v)?>> or <touching (spike 2 v)?>> or <<touching (spike 4 v)?> or <<touching (spike 5 v)?> or <touching (spike 3 v)?>>>> then\n        go to x: (-145) y: (-100)\n    end\nend\n\nwhen flag clicked\nforever\n    if <touching color (#ff0000)?> then\n        go to x: (-145) y: (-100)\n    end\nend\n\nwhen flag clicked\nforever\n    if <key (z v) pressed?> then\n        set [level v] to [5]\n        go to x: (-145) y: (-100)\n    end\nend\n\nwhen flag clicked\nforever\n    if <key (r v) pressed?> then\n        go to x: (-145) y: (-100)\n        set [level v] to [1]\n    end\nend\n\nwhen flag clicked\nforever\n    if <key (k v) pressed?> then\n        wait (.5) seconds\n        change [level v] by (1)\n    end\nend\n\nwhen flag clicked\nforever\n    create clone of (_myself_ v)\nend\n\nwhen I start as a clone\nrepeat (5)\n    change [ghost v] effect by (20)\nend\ndelete this clone\n\n@level\n\nchange [level v] by (1)\n\nwhen flag clicked\nforever\n    go to x: (0) y: (-25)\n    switch costume to (level)\nend\n\nwhen flag clicked\nforever\n    play sound [Mission Impossible Theme\(full theme\)2 v] until done\nend\n\n@portal\n\nwhen flag clicked\nforever\n    turn right (5) degrees\nend\n\nwhen flag clicked\nshow\nforever\n    if <<(level) = [1]> or <(level) = [2]>> then\n        go to x: (172) y: (-100)\n    end\n    if <(level) = [4]> then\n        go to x: (214) y: (135)\n    end\n    if <(level) = [5]> then\n        go to x: (210) y: (60)\n    end\n    if <(level) = [6]> then\n        go to x: (-204) y: (107)\n    end\n    if <(level) = [7]> then\n        go to x: (214) y: (72)\n    end\n    if <(level) = [8]> then\n        go to x: (-200) y: (100)\n    end\n    if <(level) = [9]> then\n        go to x: (214) y: (108)\n    end\n    if <(level) = [10]> then\n        hide\n    end\nend\n\n@spike 1\n\nwhen flag clicked\nhide\nforever\n    if <(level) = [2]> then\n        show\n        go to x: (29) y: (-111)\n    end\n    if <(level) = [3]> then\n        hide\n    end\n    if <(level) = [6]> then\n        show\n        go to x: (-20) y: (50)\n    end\n    if <(level) = [7]> then\n        hide\n    end\n    if <(level) = [8]> then\n        show\n        go to x: (-14) y: (121)\n    end\n    if <(level) = [9]> then\n        go to x: (-120) y: (100)\n    end\n    if <(level) = [10]> then\n        hide\n    end\nend\n\n@spike 2\n\nshow\n\nwhen flag clicked\nhide\nforever\n    if <(level) = [2]> then\n        show\n        go to x: (-4) y: (-111)\n    end\n    if <(level) = [3]> then\n        hide\n    end\n    if <(level) = [5]> then\n        show\n        go to x: (29) y: (-23)\n    end\n    if <(level) = [6]> then\n        go to x: (-107) y: (-111)\n    end\n    if <(level) = [7]> then\n        hide\n    end\n    if <(level) = [8]> then\n        show\n        go to x: (-5) y: (-15)\n    end\n    if <(level) = [9]> then\n        hide\n        go to x: (-93) y: (-112)\n    end\nend\n\n@spike 4\n\nwhen flag clicked\nhide\nforever\n    if <(level) = [5]> then\n        show\n        go to x: (160) y: (-72)\n    end\n    if <(level) = [6]> then\n        go to x: (-72) y: (-111)\n    end\n    if <(level) = [7]> then\n        hide\n    end\n    if <(level) = [8]> then\n        show\n        go to x: (215) y: (41)\n    end\n    if <(level) = [10]> then\n        hide\n    end\nend\n\n@spike 5\n\nshow\n\nwhen flag clicked\nhide\nforever\n    if <(level) = [5]> then\n        show\n        go to x: (-9) y: (-112)\n    end\n    if <(level) = [6]> then\n        go to x: (0) y: (-111)\n    end\n    if <(level) = [7]> then\n        hide\n    end\nend\n\n@spike 3\n\nwhen flag clicked\nhide\nforever\n    if <(level) = [2]> then\n        show\n        go to x: (-37) y: (-111)\n    end\n    if <(level) = [3]> then\n        hide\n    end\n    if <(level) = [5]> then\n        show\n        go to x: (-40) y: (-112)\n    end\n    if <(level) = [6]> then\n        go to x: (36) y: (-111)\n    end\n    if <(level) = [7]> then\n        hide\n    end\nend\n\nshow\n\n@text\n\nwhen flag clicked\nforever\n    switch costume to (level)\n    go to x: (36) y: (28)\nend\n\n@spike 6\n\nwhen flag clicked\nhide\nforever\n    if <(level) = [6]> then\n        show\n        go to x: (-57) y: (50)\n    end\n    if <(level) = [7]> then\n        hide\n    end\nend\n\nshow\n\n@lava\n\nwhen flag clicked\nforever\n    go to x: (0) y: (-25)\n    switch costume to (level)\n    go to [front v] layer\nend\n\n@Heart\n\nwhen flag clicked\nhide\nforever\n    if <(level) = [10]> then\n        show\n        switch backdrop to (party v)\n    end\nend\n\nwhen flag clicked\nforever\n    switch costume to (heart red v)\n    wait (0.1) seconds\n    switch costume to (heart red3 v)\n    wait (0.1) seconds\n    switch costume to (heart red v)\n    wait (0.1) seconds\n    switch costume to (heart red2 v)\n    wait (0.1) seconds\nend\n\n@Star\n\nwhen flag clicked\nforever\n    switch costume to (star v)\n    wait (0.1) seconds\n    switch costume to (star2 v)\n    wait (0.1) seconds\n    switch costume to (star v)\n    wait (0.1) seconds\n    switch costume to (star3 v)\n    wait (0.1) seconds\nend\n\nwhen flag clicked\nhide\nforever\n    if <(level) = [10]> then\n        show\n    end\nend\n\n