 Colorful ~ A Scrolling Platformer
@Stage\n\n@Player\n\nwhen flag clicked\nbroadcast (Green Flag v)\nbroadcast (Play Game v)\n\nwhen I receive [green flag v]\nhide\ngo to [front v] layer\n\nwhen I receive [play game v]\nset [level v] to [1]\nforever\n    broadcast (Reset v) and wait\n    broadcast (Setup v) and wait\n    Game On\n    repeat until <(EXIT) > []>\n        Tick\n        broadcast (Tick v) and wait\n    end\n    Game - Die\nend\n\ndefine Game On\nset [x v] to [0]\nset [y v] to [0]\nset [sy v] to [0]\nset [in air v] to [0]\nset [exit v] to []\nshow\n\ndefine Tick\nif <key (left arrow v) pressed?> then\n    Change Player X By [-8]\nend\nif <key (right arrow v) pressed?> then\n    Change Player X By [8]\nend\nif <key (up arrow v) pressed?> then\n    if <(in air) < [4]> then\n        set [sy v] to [16]\n    end\nend\nchange [sy v] by (-2)\nChange Player Y By (sy)\nset [scroll x v] to (x)\nPosition\nif <(y) < [-180]> then\n    set [exit v] to [die]\nend\n\ndefine Change Player Y By (sy)\nchange [y v] by (sy)\nchange [in air v] by (1)\nPosition\nTest - Die\nrepeat until <not <touching (platforms v)?>>\n    if <(sy) > [0]> then\n        change [y v] by (-1)\n    else\n        change [y v] by (1)\n        set [in air v] to [0]\n    end\n    Position\n    set [sy v] to [0]\nend\n\ndefine Position\ngo to x: ((x) - (SCROLL X)) y: ((y) - (SCROLL Y))\n\ndefine Change Player X By (sx)\nchange [x v] by (sx)\nPosition\nTest - Die\nif <touching (platforms v)?> then\n    repeat (12)\n        change [y v] by (1)\n        Position\n        if <not <touching (platforms v)?>> then\n            stop [this script v]\n        end\n    end\n    change [y v] by (-12)\n    repeat until <not <touching (platforms v)?>>\n        if <(sx) > [0]> then\n            change [x v] by (-1)\n        else\n            change [x v] by (1)\n        end\n        Position\n    end\nend\n\nchange [x v] by (-8)\nchange [x v] by (8)\n\ndefine Game - Die\nset [exit v] to []\nrepeat (5)\n    hide\n    wait (0.1) seconds\n    show\n    wait (0.1) seconds\nend\nhide\nwait (0.5) seconds\n\nchange [color v] effect by (25)\nchange [color v] effect by (25)\n\ndefine Test - Die\nif <touching color (#ff0000)?> then\n    set [exit v] to [die]\nend\n\nwhen [space v] key pressed\nnext costume\n\n@Platforms\n\nwhen I receive [green flag v]\nshow\n\nwhen I receive [tick v]\nposition ((x) - (SCROLL X)) ((y) - (SCROLL Y))\n\nwhen I receive [setup v]\nset [x v] to [0]\nset [y v] to [0]\nswitch costume to (level 1 1 v)\nrepeat (17)\n    create clone of (_myself_ v)\n    change [x v] by (360)\n    next costume\nend\n\ncreate clone of (_myself_ v)\nchange [x v] by (360)\nnext costume\ncreate clone of (_myself_ v)\nchange [x v] by (360)\nnext costume\ncreate clone of (_myself_ v)\nchange [x v] by (360)\nnext costume\ncreate clone of (_myself_ v)\nchange [x v] by (360)\nnext costume\ncreate clone of (_myself_ v)\nchange [x v] by (360)\nnext costume\ncreate clone of (_myself_ v)\nchange [x v] by (360)\nnext costume\ncreate clone of (_myself_ v)\nchange [x v] by (360)\nnext costume\ncreate clone of (_myself_ v)\nchange [x v] by (360)\nnext costume\ncreate clone of (_myself_ v)\nchange [x v] by (360)\nnext costume\ncreate clone of (_myself_ v)\nchange [x v] by (360)\nnext costume\n\ndefine position (x) (y)\ngo to x: (x) y: (y)\nif <<(x) = (x position)> and <(y) = (y position)>> then\n    show\nelse\n    hide\nend\n\nwhen I receive [reset v]\ndelete this clone\n\n@Sprite4\n\nwhen flag clicked\ngo to [back v] layer\ngo [backward v] (2) layers\nset [ghost v] effect to (50)\nset y to (-131)\nforever\n    create clone of (_myself_ v)\n    change [color v] effect by (25)\n    wait (0.5) seconds\nend\n\nwhen I start as a clone\nset x to (pick random (-204) to (262))\nglide (5) secs to x: (x position) y: (223)\ndelete this clone\n\ngo to x: (0) y: (0)\n\n@Sprite1\n\nwhen I receive [green flag v]\nset [timer v] to [0]\nforever\n    wait (0.1) seconds\n    change [timer v] by (0.1)\nend\n\n@Sprite2Sprite1Sprite1\n\nwhen I receive [green flag v]\nshow\nwait (3) seconds\nforever\n    wait (0.1) seconds\n    change [ghost v] effect by (25)\nend\n\n
Press the green flag.\nUse arrow keys to move. Press space to change character color. \nGet past all the obstacles without touching the lava or falling into the pit. \nThere are 18 levels and all are possible!\nLove, favorite, comment, remix, and follow!\nPlease no hate comments!