Grass - A Platformer

Instructions: NOTE: PLS HEART AND STAR\nCHECK OUT MY BRAND NEW PLATFORMER:\nhttps://scratch.mit.edu/projects/561354508/\n\nDifficulty Chart Obby: https://scratch.mit.edu/projects/555265782/\nWelcome to Grass - A Platformer!\nThere are currently 103 levels.\n--------------------------------------------------------------\nREAD ME                                                          |\n--------------------------------------------------------------\nRed is killer blocks - Don't touch them\nBlue is bouncy blocks - They make you bounce

@Stage\n\n@aaaa\n\nwhen flag clicked\nset [deaths v] to [0]\ngo to [front v] layer\ngo to x: (-200) y: (-41)\nhide variable [y v]\nhide variable [x v]\nset [y v] to [0]\nset [x v] to [0]\nhide\n\nwhen flag clicked\nforever\n    create clone of (_myself_ v)\n    go to [front v] layer\nend\n\nwhen I start as a clone\nrepeat (10)\n    change size by (-10)\n    change [ghost v] effect by (10)\nend\ndelete this clone\n\nset [level v] to [47]\n\nwhen flag clicked\nforever\n    if <touching (alien v)?> then\n        go to x: (-200) y: (-41)\n    end\nend\n\nset [level v] to [50]\n\nwhen flag clicked\nwait until <(level) = [103]>\nif <(Deaths) < (☁ Highscore deaths)> then\n    set [☁ highscore deaths v] to (Deaths)\nend\n\nset [☁ highscore deaths v] to [41]\n\nwhen I receive [start v]\nswitch costume to (1346 v)\nshow\nforever\n    change [y v] by (-1)\n    if <<<key (right arrow v) pressed?> or <key (d v) pressed?>> or <<mouse down?> and <(mouse x) > (x position)>>> then\n        change [x v] by (1)\n        switch costume to (1346 v)\n    end\n    if <<<key (left arrow v) pressed?> or <key (a v) pressed?>> or <<mouse down?> and <(x position) > (mouse x)>>> then\n        change [x v] by (-1)\n        switch costume to (1347 v)\n    end\n    set [x v] to ((x) * (0.9))\n    change x by (x)\n    if <touching color (#00ff3f)?> then\n        change y by (1)\n    end\n    if <touching color (#00ff3f)?> then\n        change y by (1)\n    end\n    if <touching color (#00ff3f)?> then\n        change y by (1)\n    end\n    if <touching color (#00ff3f)?> then\n        change y by (1)\n    end\n    if <touching color (#00ff3f)?> then\n        change y by (-1)\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 [15]\n            if <([abs v] of (x) ) = (x)> 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 color (#00ff3f)?> 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 color (#00ff3f)?>> then\n        set [y v] to [15]\n    end\n    change y by (1)\n    if <touching color (#ff0000)?> then\n        go to x: (-200) y: (-41)\n        change [deaths v] by (1)\n    end\n    if <<(x position) > [236]> and <(level) < [160]>> then\n        change [level v] by (1)\n        broadcast (levelup v)\n        go to x: (-200) y: (-41)\n    end\n    if <touching color (#00ff3f)?> then\n        change y by ((y) - ((y) * (2)))\n        set [y v] to [0]\n    end\n    if <key (r v) pressed?> then\n        go to x: (-200) y: (-41)\n        change [deaths v] by (1)\n    end\n    if <touching color (#d400ff)?> then\n        go to [front v] layer\n        wait (0.01) seconds\n        change [x v] by (5)\n    end\n    if <touching color (#00ffff)?> then\n        wait (0.01) seconds\n        change [y v] by (10)\n    end\nend\n\npoint in direction (90)\n\npoint in direction (-90)\n\nbroadcast (start v)\n\nchange [level v] by (1)\n\n@Sprite1\n\nwhen flag clicked\nset [level v] to [1]\nforever\n    switch costume to (level)\nend\n\nset [level v] to [65]\n\nset [level v] to [71]\n\nset [level v] to [99]\n\nwhen flag clicked\nhide variable [☁ highscore deaths v]\nhide variable [deaths v]\n\nchange [level v] by (1)\n\n@Thumbnail\n\nwhen flag clicked\nset [ghost v] effect to (0)\ngo to [front v] layer\ngo to [front v] layer\nwait (2) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\nend\n\nwhen flag clicked\nforever\n    go to [front v] layer\nend\n\n@Alien\n\nwhen flag clicked\nforever\n    if <(level) = [51]> then\n        show\n        glide (0.4) secs to (random position v)\n    else\n        hide\n    end\nend\n\nwhen flag clicked\nforever\n    go to [front v] layer\nend\n\n@Sprite2\n\nwhen flag clicked\nforever\n    turn right (3) degrees\nend\n\nwhen flag clicked\nforever\n    go to [front v] layer\nend\n\nset [level v] to [61]\n\nif <(level) = [61]> then\nend\n\nshow\n\nwhen flag clicked\nforever\n    if <(level) = [61]> then\n        show\n    else\n        hide\n    end\nend\n\n@Sprite3\n\nwhen flag clicked\nforever\n    turn right (3) degrees\nend\n\nwhen flag clicked\nforever\n    if <(level) = [62]> then\n        show\n    else\n        hide\n    end\nend\n\nset [level v] to [62]\n\nwhen flag clicked\nforever\n    go to [front v] layer\nend\n\n@Sprite4\n\nwhen flag clicked\nforever\n    if <(level) = [69]> then\n        show\n        change [color v] effect by (2)\n    else\n        hide\n    end\nend\n\ngo to [front v] layer\n\n@Sprite5\n\nwhen flag clicked\nforever\n    turn right (3) degrees\nend\n\nwhen flag clicked\nforever\n    if <(level) = [89]> then\n        show\n    else\n        hide\n    end\nend\n\nset [level v] to [62]\n\nwhen flag clicked\nforever\n    go to [front v] layer\nend\n\n@Sprite6\n\nwhen flag clicked\nforever\n    turn right (4) degrees\nend\n\nwhen flag clicked\nforever\n    if <(level) = [90]> then\n        show\n    else\n        hide\n    end\nend\n\nset [level v] to [90]\n\nwhen flag clicked\nforever\n    go to [front v] layer\nend\n\n@Sprite7\n\nwhen flag clicked\nforever\n    turn right (6) degrees\nend\n\nwhen flag clicked\nforever\n    if <(level) = [101]> then\n        show\n    else\n        hide\n    end\nend\n\nset [level v] to [62]\n\nwhen flag clicked\nforever\n    go to [front v] layer\nend\n\n@Sprite8\n\nwhen flag clicked\nforever\n    turn right (6) degrees\nend\n\nwhen flag clicked\nforever\n    if <(level) = [101]> then\n        show\n    else\n        hide\n    end\nend\n\nset [level v] to [62]\n\nwhen flag clicked\nforever\n    go to [front v] layer\nend\n\n@Sprite9\n\nwhen flag clicked\nforever\n    turn right (5) degrees\nend\n\nwhen flag clicked\nforever\n    if <(level) = [102]> then\n        show\n    else\n        hide\n    end\nend\n\nset [level v] to [62]\n\nwhen flag clicked\nforever\n    go to [front v] layer\nend\n\n@Sprite10\n\nwhen I receive [start v]\nhide\n\nwhen flag clicked\nshow\n\n@Sprite11\n\nwhen I receive [start v]\nhide\n\nwhen flag clicked\ngo to [front v] layer\nshow\n\nwhen this sprite clicked\nbroadcast (black screen v)\n\n@Sprite12\n\nwhen flag clicked\nhide\nforever\n    go to [front v] layer\nend\n\nwhen I receive [black screen v]\nshow\nset [ghost v] effect to (100)\nrepeat (50)\n    change [ghost v] effect by (-2)\nend\nwait (2.5) seconds\nbroadcast (start v)\nhide\n\n@coin\n\nwhen flag clicked\nhide\nhide variable [coins v]\nset [coins v] to [0]\n\nwhen I receive [levelup v]\nhide\nif <(pick random (1) to (14)) > [12]> then\n    go to x: (pick random (-200) to (200)) y: (pick random (-200) to (200))\n    show\nend\n\nchange [coins v] by (1)\n\nwhen flag clicked\nforever\n    if <touching (aaaa v)?> then\n        change [coins v] by (1)\n        hide\n    end\nend\n\nwhen flag clicked\nforever\n    replace item (1) of [~player stats~ v] with (join [Coins: ] (coins))\n    replace item (2) of [~player stats~ v] with (join [Level: ] (level))\n    replace item (3) of [~player stats~ v] with (join [Deaths: ] (Deaths))\nend\n\nwhen flag clicked\nforever\n    if <key (space v) pressed?> then\n        hide list [~player stats~ v]\n    else\n        show list [~player stats~ v]\n    end\nend\n\ndelete all of [~player stats~ v]\n\nwhen flag clicked\nbroadcast (del v)\nreplace item (4) of [~player stats~ v] with [Release space to exit]\n\nwhen I receive [del v]\n\nif <(length of [~player stats~ v]) < [0]> then\n    add [Coins] to [~player stats~ v]\n    add [Level] to [~player stats~ v]\nelse\nend\n\n@Sprite13\n\nwhen flag clicked\nforever\n    if <key (s v) pressed?> then\n        show\n    else\n        hide\n    end\nend\n\nwhen this sprite clicked\nif <(level) > [24]> then\n    change [coins v] by (level)\n    broadcast (black screen v)\n    set [level v] to [1]\nend\n\n