Cheese Platformer

Instructions: Normal Keys, 'S' 'K' 'I' 'P' to go to the next level. 'R' to restart. 17 levels. 'C' to change character. ‘Q’ to dash.\nTHE 10 ACHIEVEMENTS TO UNLOCK:\n-Left\n-Right\n-Up\n-Dash\n-Reset\n-Skip Level\n-Complete the game\n-Die\n-Love and Fav (You might need to wait a few seconds to get this)\n-Bounce

@Stage\n\n@Cheese\n\nwhen flag clicked\nset [achievements v] to [0]\nshow\nReset\nforever\n    if <<key (right arrow v) pressed?> or <key (d v) pressed?>> then\n        change [xv v] by (1)\n    end\n    if <<key (left arrow v) pressed?> or <key (a v) pressed?>> 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 color (#7eff42)?> or <color (#38761d) is touching (#7eff42)?>> then\n        change y by (1)\n        if <<touching color (#7eff42)?> or <color (#38761d) is touching (#7eff42)?>> then\n            change y by (1)\n            if <<touching color (#7eff42)?> or <color (#38761d) is touching (#7eff42)?>> then\n                change y by (1)\n                if <<touching color (#7eff42)?> or <color (#38761d) is touching (#7eff42)?>> then\n                    change y by (1)\n                    if <<touching color (#7eff42)?> or <color (#38761d) is touching (#7eff42)?>> then\n                        change y by (1)\n                        if <<touching color (#7eff42)?> or <color (#38761d) is touching (#7eff42)?>> then\n                            change y by (1)\n                            if <<touching color (#7eff42)?> or <color (#38761d) is touching (#7eff42)?>> then\n                                change y by (1)\n                                if <<touching color (#7eff42)?> or <color (#38761d) is touching (#7eff42)?>> then\n                                    change y by (1)\n                                    if <<touching color (#7eff42)?> or <color (#38761d) is touching (#7eff42)?>> then\n                                        change x by ((xv) * (-1))\n                                        change y by (-8)\n                                    end\n                                end\n                            end\n                        end\n                    end\n                end\n            end\n        end\n    end\n    change y by (-1)\n    if <<touching color (#7eff42)?> or <color (#38761d) is touching (#7eff42)?>> then\n        if <<key (up arrow v) pressed?> or <key (w v) pressed?>> then\n            set [yv v] to [16]\n        end\n    end\n    if <<touching color (#83ecff)?> or <color (#38761d) is touching (#83ecff)?>> then\n        if <<key (up arrow v) pressed?> or <key (w v) pressed?>> then\n            set [yv v] to [4]\n        end\n    end\n    if <<touching color (#83ecff)?> or <color (#38761d) is touching (#83ecff)?>> then\n        if <<key (down arrow v) pressed?> or <key (s v) pressed?>> then\n            set [yv v] to [-4]\n        end\n    end\n    change y by (1)\n    set [yv v] to ((yv) * (0.99))\n    change [yv v] by (-1)\n    change y by (yv)\n    if <<touching color (#7eff42)?> or <color (#38761d) is touching (#7eff42)?>> then\n        change y by ((yv) * (-1))\n        set [yv v] to [0]\n    end\n    if <(x position) > [220]> then\n        broadcast (NEXT LEVEL v)\n        Reset\n    end\n    if <touching (spikes v)?> then\n        wait (0.01) seconds\n        Reset\n    end\n    if <(y position) < [-165]> then\n        Reset\n    end\n    if <touching color (#ffe800)?> then\n        change [yv v] by (20)\n    end\n    if <<([costume # v] of [level v]) > [12]> and <key (q v) pressed?>> then\n        set [xv v] to [30]\n    end\n    if <touching (water v)?> then\n        set [yv v] to [-2]\n        wait (0) seconds\n    end\nend\n\ndefine Reset\nif level = [1] go to : x [-221] y: [-31]\nif level = [2] go to : x [-221] y: [-31]\nif level = [3] go to : x [-221] y: [-31]\nif level = [4] go to : x [-221] y: [-31]\nif level = [5] go to : x [-221] y: [-31]\nif level = [6] go to : x [-221] y: [-31]\nif level = [7] go to : x [-221] y: [-31]\nif level = [8] go to : x [-221] y: [-31]\nif level = [9] go to : x [-221] y: [-31]\nif level = [10] go to : x [-221] y: [-31]\nif level = [11] go to : x [-159] y: [-125]\nif level = [12] go to : x [-221] y: [-31]\nif level = [13] go to : x [-221] y: [-31]\nif level = [14] go to : x [-221] y: [-31]\nif level = [15] go to : x [-221] y: [-31]\nif level = [16] go to : x [-221] y: [-31]\nif level = [17] go to : x [-221] y: [-31]\nif level = [18] go to : x [-221] y: [-31]\nif level = [19] go to : x [-221] y: [-31]\nif level = [20] go to : x [-221] y: [-31]\n\ndefine if level = (level#) go to : x (x) y: (y)\nif <(level#) = ([costume # v] of [level v])> then\n    go to x: (x) y: (y)\nend\n\nwhen I receive [next level v]\nReset\n\nwhen flag clicked\nwait until <(y position) < [-165]>\nbroadcast (Falling v)\nReset\n\nwhen [r v] key pressed\nReset\n\nwhen [c v] key pressed\nnext costume\n\nwhen flag clicked\nforever\n    wait until <([costume # v] of [level v]) = [2]>\n    switch costume to (blue cheese v)\n    wait until <([costume # v] of [level v]) = [3]>\n    switch costume to (cheese v)\nend\n\nwhen flag clicked\nwait until <<touching (spikes v)?> or <(y position) < [-165]>>\nchange [achievements v] by (1)\nset [achievement now v] to [DIE ACHIEVEMENT]\nwait (3) seconds\nset [achievement now v] to []\n\nwhen flag clicked\nwait until <touching (trampoline v)?>\nchange [achievements v] by (1)\nset [achievement now v] to [BOUNCE ACHIEVEMENT]\nwait (3) seconds\nset [achievement now v] to []\n\n@Level\n\nwhen I receive [next level v]\nnext costume\n\nwhen flag clicked\ngo to [back v] layer\nswitch costume to (costume1 v)\n\nwhen I receive [green flag v]\ngo to [front v] layer\n\n@Spikes\n\nwhen flag clicked\nswitch costume to (costume2 v)\n\nwhen I receive [next level v]\nnext costume\n\n@Trampoline\n\nwhen flag clicked\nswitch costume to (costume1 v)\n\nwhen I receive [next level v]\nnext costume\n\n@Thumbnail\n\nwhen flag clicked\nshow\nset [ghost v] effect to (0)\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nset [ghost v] effect to (0)\nhide\nbroadcast (Green Flag v)\n\n@Cloud\n\nwhen I start as a clone\nif <<([costume # v] of [level v]) = [5]> or <<([costume # v] of [level v]) = [6]> or <([costume # v] of [level v]) = [7]>>> then\n    delete this clone\nend\nshow\nswitch costume to (pick random (1) to (5))\nset [x cloud v] to (pick random (-1) to (-3))\nset [ghost v] effect to (pick random (50) to (75))\nset size to (pick random (20) to (100)) %\nset y to (pick random (140) to (160))\nset x to (220)\nrepeat until <(x position) < [-200]>\n    change x by (x cloud)\nend\ndelete this clone\n\nwhen flag clicked\nhide\nforever\n    if <not <<([costume # v] of [level v]) = [5]> or <<([costume # v] of [level v]) = [6]> or <([costume # v] of [level v]) = [7]>>>> then\n        create clone of (_myself_ v)\n        wait (pick random (1) to (2)) seconds\n    end\nend\n\n@Achievements\n\nwhen flag clicked\nset [achievements v] to [0]\nset [achievement now v] to []\nwait until <key (left arrow v) pressed?>\nchange [achievements v] by (1)\nshow\nset [achievement now v] to [LEFT KEY ACHIEVEMENT]\nwait (3) seconds\nset [achievement now v] to []\nhide\n\nwhen flag clicked\nshow\nforever\n    set [achievements v] to (join [Achievements: ] (ACHIEVEMENTS))\nend\n\nwhen flag clicked\nwait until <key (right arrow v) pressed?>\nchange [achievements v] by (1)\nshow\nset [achievement now v] to [RIGHT KEY ACHIEVEMENT]\nwait (3) seconds\nset [achievement now v] to []\nhide\n\nwhen flag clicked\nwait until <key (up arrow v) pressed?>\nchange [achievements v] by (1)\nshow\nset [achievement now v] to [UP KEY ACHIEVEMENT]\nwait (3) seconds\nset [achievement now v] to []\nhide\n\nwhen flag clicked\nwait until <key (s v) pressed?>\nwait until <key (k v) pressed?>\nwait until <key (i v) pressed?>\nwait until <key (p v) pressed?>\nchange [achievements v] by (1)\nshow\nset [achievement now v] to [SKIP ACHIEVEMENT]\nwait (3) seconds\nset [achievement now v] to []\nhide\n\nwhen flag clicked\nwait until <<key (q v) pressed?> and <([costume # v] of [level v]) > [12]>>\nchange [achievements v] by (1)\nshow\nset [achievement now v] to [DASH ACHIEVEMENT]\nwait (3) seconds\nset [achievement now v] to []\nhide\n\nwhen flag clicked\nwait until <key (r v) pressed?>\nchange [achievements v] by (1)\nshow\nset [achievement now v] to [RESET ACHIEVEMENT]\nwait (3) seconds\nset [achievement now v] to []\nhide\n\nwhen flag clicked\nwait until <([costume # v] of [level v]) = [2]>\nwait until <([costume # v] of [level v]) = [1]>\nchange [achievements v] by (1)\nshow\nset [achievement now v] to [COMPLETE THE GAME ACHIEVEMENT]\nwait (3) seconds\nset [achievement now v] to []\nhide\n\n@Love + Fav\n\nwhen flag clicked\nhide\nset [faved___ v] to [0]\nset [loved__ v] to [0]\nset [clone id v] to [0]\ncreate clone of (_myself_ v)\nwait (0.2) seconds\nset [clone id v] to [1]\ncreate clone of (_myself_ v)\nwait until <<(LOVED__) = [1]> and <(FAVED___) = [1]>>\nwait (1) seconds\nhide\nshow\ngo to x: (0) y: (50)\nreset timer\ngo to [front v] layer\nswitch costume to (pick random (1) to (4))\nset [ghost v] effect to (100)\nrepeat until <(timer) > [3.5]>\n    change y by ((y position) / (-15))\n    change [ghost v] effect by (-3)\nend\nchange [achievements v] by (1)\nset [achievement now v] to [LOVE AND FAV ACHIEVEMENT]\nwait (3) seconds\nset [achievement now v] to []\nreset timer\nrepeat until <(timer) > [3.5]>\n    change y by (((y position) - (-100)) / (-15))\n    change [ghost v] effect by (10)\nend\n\nwhen I start as a clone\nif <(clone id) = [0]> then\n    go to x: (-15) y: (0)\n    set [loved__ v] to [0]\n    switch costume to (love v)\n    forever\n        set [love? v] to <touching (mouse-pointer v)?>\n        if <touching (mouse-pointer v)?> then\n            set [loved__ v] to [1]\n        end\n    end\nend\nif <(clone id) = [1]> then\n    go to x: (0) y: (0)\n    switch costume to (fave v)\n    set [faved___ v] to [0]\n    forever\n        set [fav v] to <touching (mouse-pointer v)?>\n        if <touching (mouse-pointer v)?> then\n            set [faved___ v] to [1]\n        end\n    end\nend\n\n@NiceGuy5\n\nwhen flag clicked\nshow\nset [ghost v] effect to (0)\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nset [ghost v] effect to (0)\nhide\nbroadcast (Green Flag v)\n\n