Adventure || A Scrolling Platformer
@Stage\n\nwhen [m v] key pressed\n\nforever\n    hide variable [mouse v]\n    if <<(username) = [Antz4Ever]> and <key (m v) pressed?>> then\n        show variable [mouse v]\n        set [mouse v] to (join ((mouse x) + (ScrollX)) (join [, ] ((mouse y) + (ScrollY))))\n    else\n        hide variable [mouse v]\n    end\nend\n\nwhen I receive [green flag v]\nhide variable [mouse v]\n\nwhen I receive [intro over v]\nrepeat (50)\n    change [ghost v] effect by (2)\nend\nswitch backdrop to (normal v)\nbroadcast (Green Flag v) and wait\nbroadcast (Play Game v) and wait\n\nwhen flag clicked\nset [ghost v] effect to (0)\n\nwhen flag clicked\nif <(pick random (1) to (2)) = [2]> then\n    forever\n        play sound [the piano music v] until done\n        play sound [TheFatRat - Windfall v] until done\n        play sound [Jim Yosef - Reverse \[End of Time EP\] v] until done\n        play sound [Modulation - on the move v] until done\n        play sound [vexento-masked-heroes-1-AHM56EBq6 \(1\) v] until done\n    end\nelse\n    forever\n        play sound [Glorious_morning v] until done\n        play sound [Vicetone - United We Dance v] until done\n        play sound [Modulation - on the move v] until done\n        play sound [the piano music v] until done\n        play sound [vexento-masked-heroes-1-AHM56EBq6 \(1\) v] until done\n    end\nend\n\n@player\n\nwhen flag clicked\nbroadcast (Green Flag v) and wait\nbroadcast (Play Game v) and wait\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    Test-Background\n    repeat until <(EXIT) > []>\n        Tick\n        broadcast (Tick v)\n    end\n    if <(EXIT) = [win]> then\n        Game - Win\n    else\n        Game - Die\n    end\nend\n\nbroadcast (Tick v) and wait\n\ndefine Game On\nset [x v] to [0]\nset [y v] to [0]\nset [scrollx v] to [0]\nset [scrolly v] to [120]\nset [sy v] to [0]\nset [in air v] to [0]\nset size to (100) %\nshow\nset [ghost v] effect to (0)\nwait (1) seconds\nset [exit v] to []\n\ndefine Tick\nif <<<key (left arrow v) pressed?> or <key (a v) pressed?>> or <<mouse down?> and <(mouse x) < (x position)>>> then\n    Change player x by [-8]\nend\nif <<<key (right arrow v) pressed?> or <key (d v) pressed?>> or <<mouse down?> and <(mouse x) > (x position)>>> then\n    Change player x by [8]\nend\nif <<key (up arrow v) pressed?> or <<key (w v) pressed?> or <<mouse down?> and <(mouse y) > ((y position) + (20))>>>> 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)\nTest - Die\nchange [scrollx v] by (round (((x) - (ScrollX)) / (10)))\nif <(ScrollX) < [0]> then\n    set [scrollx v] to [0]\nend\nchange [scrolly v] by (round (((y) - (ScrollY)) / (10)))\nif <(ScrollY) < [0]> then\n    set [scrolly v] to [0]\nend\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\nrepeat until <not <touching (platforms v)?>>\n    if <(sy) > [1]> 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) - (ScrollX)) y: ((y) - (ScrollY))\n\ndefine Change player x by (sx)\nchange [x v] by (sx)\nPosition\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) > [1]> then\n            change [x v] by (-1)\n        else\n            change [x v] by (1)\n        end\n        Position\n    end\nend\n\ndefine Game - Die\nset [exit v] to []\nstart sound [Crunch v]\nrepeat (5)\n    hide\n    wait (0.1) seconds\n    show\n    wait (0.1) seconds\nend\nhide\nwait (0.5) seconds\nbroadcast (Reset v)\n\ndefine Test - Die\nif <touching (danger zones v)?> then\n    set [exit v] to [die]\nend\n\ndefine Game - Win\nstart sound [Teleport v]\nrepeat (50)\n    point towards (exit v)\n    turn right (65) degrees\n    move ((distance to [exit v]) / (2)) steps\n    change size by (-1)\n    change [ghost v] effect by (2)\nend\nhide\nchange [level v] by (1)\nbroadcast (Change v)\nwait (1) seconds\nTest-Background\n\ndefine Test-Background\nif <(LEVEL) = [1]> then\n    switch backdrop to (normal v)\nelse\n    if <(LEVEL) = [2]> then\n        switch backdrop to (desert v)\n    else\n        if <(LEVEL) = [3]> then\n            switch backdrop to (giphy v)\n        else\n            if <(LEVEL) = [4]> then\n                switch backdrop to (normal2 v)\n            else\n                if <(LEVEL) = [5]> then\n                    switch backdrop to (desert2 v)\n                else\n                    if <(LEVEL) = [6]> then\n                        switch backdrop to (normal v)\n                    end\n                end\n            end\n        end\n    end\nend\n\ndefine Move On\nhide\nchange [level v] by (1)\nbroadcast (Change v)\nbroadcast (Reset v)\nwait (1) seconds\nTest-Background\nGame On\n\nwhen I receive [next level v]\nMove On\n\n@platforms\n\nwhen I receive [green flag v]\nhide\n\nwhen I receive [tick v]\nposition ((x) - (ScrollX)) ((y) - (ScrollY))\n\nwhen I receive [setup v]\nset [x v] to [0]\nset [y v] to [0]\nif <(LEVEL) = [1]> then\n    switch costume to (level 1 1 v)\n    Clone at x: [475] y: [0] Layers: []\n    Clone at x: [550] y: [0] Layers: []\n    Clone at x: [590] y: [0] Layers: []\n    Clone at x: [700] y: [0] Layers: []\nelse\n    if <(LEVEL) = [2]> then\n        switch costume to (level 2 1 v)\n        Clone at x: [615] y: [0] Layers: [0]\n        Clone at x: [640] y: [60] Layers: [1]\n        Clone at x: [450] y: [-70] Layers: [0]\n        Clone at x: [500] y: [-40] Layers: [0]\n        Clone at x: [650] y: [20] Layers: [0]\n        Clone at x: [400] y: [-5] Layers: [0]\n    else\n        if <(LEVEL) = [3]> then\n            switch costume to (level 3 1 v)\n            Clone at x: [495] y: [0] Layers: [1]\n            Clone at x: [475] y: [0] Layers: [1]\n            Clone at x: [640] y: [0] Layers: [1]\n            Clone at x: [640] y: [0] Layers: [1]\n            Clone at x: [700] y: [0] Layers: [1]\n        else\n            if <(LEVEL) = [4]> then\n                switch costume to (level 4 1 v)\n                Clone at x: [500] y: [0] Layers: [1]\n                Clone at x: [350] y: [200] Layers: [1]\n                Clone at x: [550] y: [-250] Layers: [1]\n                Clone at x: [500] y: [8] Layers: [1]\n                Clone at x: [429] y: [148] Layers: [1]\n            else\n                if <(LEVEL) = [5]> then\n                    switch costume to (level 5 1 v)\n                    Clone at x: [485] y: [0] Layers: [0]\n                    Clone at x: [550] y: [0] Layers: [0]\n                    Clone at x: [500] y: [0] Layers: [0]\n                    Clone at x: [820] y: [0] Layers: [0]\n                    Clone at x: [500] y: [100] Layers: [1]\n                    Clone at x: [450] y: [-100] Layers: [0]\n                else\n                    if <(LEVEL) = [6]> then\n                        switch costume to (level end v)\n                    end\n                end\n            end\n        end\n    end\nend\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\ndefine Clone at x: (x) y: (y) Layers: (#)\ncreate clone of (_myself_ v)\nchange [x v] by (x)\nchange [y v] by (y)\ngo [backward v] (#) layers\nnext costume\n\n@collectables\n\nwhen I start as a clone\nforever\n    repeat (10)\n        change size by (2)\n    end\n    repeat (10)\n        change size by (-2)\n    end\nend\n\nwhen flag clicked\n\nwhen I receive [green flag v]\nhide\n\nwhen I receive [tick v]\nposition ((x) - (ScrollX)) ((y) - (ScrollY))\nif <touching (player v)?> then\n    change [collected v] by (1)\n    start sound [nsmb_coin v]\n    if <(COLLECTED) = (COLLECTED MAX)> then\n        broadcast (Portal Open v)\n    end\n    delete this clone\nend\n\nwhen I receive [setup v]\nset size to (100) %\nhide\nset [collected v] to [0]\nset [collected max v] to [0]\nset [x v] to [0]\nset [y v] to [0]\nif <(LEVEL) = [1]> then\n    switch costume to (collectable v)\n    Clone at x: [75] y: [-54]\n    Clone at x: [104] y: [-5]\n    Clone at x: [146] y: [30]\n    Clone at x: [191] y: [27]\n    Clone at x: [191] y: [27]\n    Clone at x: [237] y: [12]\n    Clone at x: [368] y: [96]\n    Clone at x: [418] y: [111]\n    Clone at x: [468] y: [105]\n    Clone at x: [864] y: [8]\n    Clone at x: [864] y: [168]\n    Clone at x: [904] y: [168]\n    Clone at x: [940] y: [168]\n    Clone at x: [1307] y: [14]\n    Clone at x: [1267] y: [14]\n    Clone at x: [1225] y: [13]\n    Clone at x: [1695] y: [33]\n    Clone at x: [2554] y: [193]\n    Clone at x: [2516] y: [193]\n    Clone at x: [2478] y: [193]\nelse\n    if <(LEVEL) = [2]> then\n        switch costume to (collectable v)\n        Clone at x: [60] y: [-49]\n        Clone at x: [89] y: [-56]\n        Clone at x: [120] y: [-65]\n        Clone at x: [710] y: [75]\n        Clone at x: [1735] y: [54]\n        Clone at x: [1854] y: [20]\n        Clone at x: [2407] y: [18]\n        Clone at x: [2827] y: [-20]\n        Clone at x: [2940] y: [-87]\n        Clone at x: [3479] y: [-23]\n    else\n        if <(LEVEL) = [3]> then\n            switch costume to (collectable v)\n            Clone at x: [115] y: [-19]\n            Clone at x: [160] y: [-19]\n            Clone at x: [200] y: [-19]\n            Clone at x: [449] y: [32]\n            Clone at x: [836] y: [-20]\n            Clone at x: [1467] y: [-72]\n            Clone at x: [1504] y: [-63]\n            Clone at x: [1540] y: [-67]\n            Clone at x: [1862] y: [37]\n            Clone at x: [2383] y: [-46]\n        else\n            if <(LEVEL) = [4]> then\n                switch costume to (collectable v)\n                Clone at x: [188] y: [-66]\n                Clone at x: [228] y: [-63]\n                Clone at x: [270] y: [-52]\n                Clone at x: [843] y: [77]\n                Clone at x: [955] y: [152]\n                Clone at x: [677] y: [294]\n                Clone at x: [634] y: [409]\n                Clone at x: [674] y: [409]\n                Clone at x: [714] y: [409]\n                Clone at x: [1545] y: [-66]\n                Clone at x: [1977] y: [18]\n                Clone at x: [2143] y: [39]\n                Clone at x: [2156] y: [77]\n                Clone at x: [2173] y: [110]\n                Clone at x: [2144] y: [236]\n                Clone at x: [2022] y: [297]\n            else\n                if <(LEVEL) = [5]> then\n                    switch costume to (collectable v)\n                    Clone at x: [70] y: [89]\n                    Clone at x: [186] y: [150]\n                    Clone at x: [477] y: [101]\n                    Clone at x: [762] y: [6]\n                    Clone at x: [865] y: [118]\n                    Clone at x: [1258] y: [-127]\n                    Clone at x: [1399] y: [-22]\n                    Clone at x: [1401] y: [79]\n                    Clone at x: [1638] y: [358]\n                    Clone at x: [2870] y: [202]\n                end\n            end\n        end\n    end\n    set [x v] to [-999999]\nend\nset [x v] to [-999999]\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\ndefine Clone at x: (x) y: (y)\nset [x v] to (x)\nset [y v] to (y)\nchange [collected max v] by (1)\ncreate clone of (_myself_ v)\n\ngo to [front v] layer\nset [ghost v] effect to (0)\n\nClone at x: [] y: []\n\n@Danger Zones\n\nwhen I receive [green flag v]\nhide\n\nwhen I receive [tick v]\nposition ((x) - (ScrollX)) ((y) - (ScrollY))\n\nwhen I receive [setup v]\nset [x v] to [0]\nset [y v] to [0]\nif <(LEVEL) = [1]> then\n    switch costume to (level 1 1 v)\n    Clone at x: [475] y: [0]\n    Clone at x: [550] y: [0]\n    Clone at x: [590] y: [0]\n    Clone at x: [700] y: [0]\nelse\n    if <(LEVEL) = [2]> then\n        wait until <(BackgroundReady) = [yes]>\n        switch costume to (level 2 1 v)\n        Clone at x: [600] y: [-5]\n        Clone at x: [600] y: [0]\n        Clone at x: [500] y: [-8]\n        Clone at x: [508] y: [-40]\n        Clone at x: [1050] y: [20]\n    else\n        if <(LEVEL) = [3]> then\n            wait until <(BackgroundReady) = [yes]>\n            switch costume to (level 3 1 v)\n            Clone at x: [495] y: [0]\n            Clone at x: [475] y: [0]\n            Clone at x: [640] y: [0]\n            Clone at x: [640] y: [0]\n            Clone at x: [700] y: [0]\n        else\n            if <(LEVEL) = [4]> then\n                switch costume to (level 4 1 v)\n                Clone at x: [500] y: [0]\n                Clone at x: [350] y: [200]\n                Clone at x: [550] y: [-250]\n                Clone at x: [500] y: [8]\n                Clone at x: [429] y: [148]\n            else\n                if <(LEVEL) = [5]> then\n                    switch costume to (level 5 1 v)\n                    Clone at x: [485] y: [0]\n                    Clone at x: [550] y: [0]\n                    Clone at x: [500] y: [0]\n                    Clone at x: [820] y: [0]\n                    Clone at x: [500] y: [100]\n                    Clone at x: [450] y: [-100]\n                else\n                    if <(LEVEL) = [6]> then\n                        switch costume to (level 1 5 v)\n                    end\n                end\n            end\n        end\n    end\nend\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\ndefine Clone at x: (x) y: (y)\ncreate clone of (_myself_ v)\nchange [x v] by (x)\nchange [y v] by (y)\nnext costume\n\nClone at x: [485] y: [0] Layers: [0]\nClone at x: [550] y: [0] Layers: [0]\nClone at x: [500] y: [0] Layers: [0]\nClone at x: [820] y: [0] Layers: [0]\nClone at x: [500] y: [100] Layers: [1]\nClone at x: [450] y: [-100] Layers: [0]\n\nrepeat (10)\n    change size by (5)\nend\nrepeat (10)\n    change size by (-5)\nend\n\n@Exit\n\nwhen I receive [green flag v]\nhide\n\nwhen I receive [tick v]\nposition ((x) - (ScrollX)) ((y) - (ScrollY))\nif <<(costume [number v]) = [2]> and <touching (player v)?>> then\n    set [exit v] to [win]\nend\n\nwhen I receive [setup v]\nhide\nset [collected v] to [0]\nset [x v] to [0]\nset [y v] to [0]\nif <(LEVEL) = [1]> then\n    switch costume to (exit closed v)\n    Clone at x: [2679] y: [216]\nelse\n    if <(LEVEL) = [2]> then\n        switch costume to (exit closed v)\n        Clone at x: [3639] y: [4]\n    else\n        if <(LEVEL) = [3]> then\n            switch costume to (exit closed v)\n            Clone at x: [3037] y: [150]\n        else\n            if <(LEVEL) = [4]> then\n                switch costume to (exit closed v)\n                Clone at x: [1903] y: [343]\n            else\n                if <(LEVEL) = [5]> then\n                    switch costume to (exit closed v)\n                    Clone at x: [3479] y: [396]\n                else\n                    if <(LEVEL) = [6]> then\n                        switch costume to (exit closed v)\n                        Clone at x: [99999] y: [396]\n                    end\n                end\n            end\n        end\n    end\nend\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\ndefine Clone at x: (x) y: (y)\nset [x v] to (x)\nset [y v] to (y)\n\nwhen I receive [portal open v]\nswitch costume to (exit open v)\n\n@Trees and stuff\n\nwhen flag clicked\n\nwhen I receive [green flag v]\nhide\n\nwhen I receive [tick v]\nposition ((x) - (ScrollX)) ((y) - (ScrollY))\n\nwhen I receive [setup v]\nset [backgroundready v] to [no]\nset size to (100) %\nTest - BackLayer\nhide\nset [x v] to [0]\nset [y v] to [0]\nif <(LEVEL) = [1]> then\n    Test - BackLayer\n    Clone at x: [-210] y: [25] Size: [150] Costume [Mossy Boulders]\n    Clone at x: [63] y: [30] Size: [100] Costume [tree]\n    Clone at x: [560] y: [80] Size: [85] Costume [tree2]\n    Clone at x: [610] y: [60] Size: [70] Costume [tree2]\n    Clone at x: [300] y: [0] Size: [100] Costume [bush]\n    Clone at x: [2130] y: [-77] Size: [100] Costume [stones]\n    Clone at x: [1833] y: [20] Size: [100] Costume [tree3]\n    Clone at x: [1385] y: [10] Size: [80] Costume [plants]\n    Clone at x: [1475] y: [-18] Size: [100] Costume [Mossy Boulders]\nelse\n    if <(LEVEL) = [2]> then\n        Test - BackLayer\n        Clone at x: [-32] y: [-50] Size: [80] Costume [dunes]\n        Clone at x: [411] y: [-50] Size: [80] Costume [dunes]\n        Clone at x: [854] y: [-50] Size: [80] Costume [dunes]\n        Clone at x: [1297] y: [-50] Size: [80] Costume [dunes]\n        Clone at x: [1740] y: [-50] Size: [80] Costume [dunes]\n        Clone at x: [2183] y: [-50] Size: [80] Costume [dunes]\n        Clone at x: [2626] y: [-50] Size: [80] Costume [dunes]\n        Clone at x: [3069] y: [-50] Size: [80] Costume [dunes]\n        Clone at x: [3512] y: [-50] Size: [80] Costume [dunes]\n        Clone at x: [3955] y: [-50] Size: [80] Costume [dunes]\n        Clone at x: [1250] y: [54] Size: [100] Costume [bridge frame]\n        Clone at x: [-206] y: [22] Size: [90] Costume [Rock]\n        Clone at x: [-73] y: [-30] Size: [40] Costume [Deadbush]\n        Clone at x: [-137] y: [40] Size: [80] Costume [Cactus]\n        Clone at x: [217] y: [-50] Size: [100] Costume [Palm Tree]\n        Clone at x: [624] y: [70] Size: [100] Costume [Cactus2]\n        Clone at x: [680] y: [50] Size: [60] Costume [Cactus3]\n        Clone at x: [1640] y: [20] Size: [80] Costume [Deadbush]\n        Clone at x: [2146] y: [-54] Size: [80] Costume [Cactus3]\n        wait (0.5) seconds\n        set [backgroundready v] to [yes]\n    else\n        if <(LEVEL) = [3]> then\n            Test - BackLayer\n            Clone at x: [-200] y: [20] Size: [150] Costume [Moon boulders]\n            Clone at x: [-56] y: [-10] Size: [100] Costume [THE MOON LANDING IS REAL]\n            Clone at x: [737] y: [-14] Size: [100] Costume [Moon Dune]\n            wait (1) seconds\n            set [backgroundready v] to [yes]\n        else\n            if <(LEVEL) = [4]> then\n                Test - BackLayer\n                Clone at x: [-197] y: [16] Size: [100] Costume [pine tree]\n                Clone at x: [-31] y: [-60] Size: [80] Costume [Deadbush]\n                Clone at x: [-126] y: [-50] Size: [80] Costume [Snowman]\n                Clone at x: [642] y: [125] Size: [100] Costume [winter tree]\n                Clone at x: [786] y: [213] Size: [100] Costume [frozen grass]\n                Clone at x: [804] y: [338] Size: [60] Costume [frozen grass]\n                Clone at x: [1320] y: [11] Size: [80] Costume [frozen grass]\n                Clone at x: [1826] y: [82] Size: [90] Costume [WATCH OUT]\n                wait (1) seconds\n                set [backgroundready v] to [yes]\n            else\n                if <(LEVEL) = [5]> then\n                    Test - BackLayer\n                    Clone at x: [-118] y: [110] Size: [100] Costume [fallTree]\n                    Clone at x: [310] y: [121] Size: [100] Costume [canyons]\n                    Clone at x: [-161] y: [23] Size: [85] Costume [DeadbushSmall]\n                    Clone at x: [1031] y: [208] Size: [85] Costume [DeadbushSmall]\n                    Clone at x: [1288] y: [0] Size: [85] Costume [canyons]\n                    Clone at x: [1606] y: [400] Size: [80] Costume [fallTree3]\n                    Clone at x: [1633] y: [370] Size: [80] Costume [fallTree4]\n                    Clone at x: [2138] y: [160] Size: [100] Costume [fallTree2]\n                    Clone at x: [1816] y: [250] Size: [85] Costume [Cactus]\n                    Clone at x: [3325] y: [280] Size: [85] Costume [DeadbushSmall]\n                    Clone at x: [2861] y: [0] Size: [85] Costume [SUN]\n                    wait (1) seconds\n                    set [backgroundready v] to [yes]\n                else\n                    if <(LEVEL) = [6]> then\n                        Test - BackLayer\n                        Clone at x: [125] y: [-45] Size: [80] Costume [DeadbushSmall]\n                        Clone at x: [40] y: [30] Size: [100] Costume [tree]\n                        Clone at x: [-210] y: [25] Size: [150] Costume [Mossy Boulders]\n                        Clone at x: [-80] y: [100] Size: [100] Costume [thanks for playing]\n                        wait (1) seconds\n                        set [backgroundready v] to [yes]\n                    end\n                end\n            end\n        end\n    end\n    set [x v] to [-999999]\nend\nset [x v] to [-999999]\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\ngo to [front v] layer\nset [ghost v] effect to (0)\n\ndefine Clone at x: (x) y: (y) Size: (size) Costume (costume #)\nset [x v] to (x)\nset [y v] to (y)\nset size to (size) %\nswitch costume to (costume #)\ncreate clone of (_myself_ v)\n\ndefine Test - BackLayer\ngo to [back v] layer\n\nClone at x: [-56] y: [-10] Size: [100] Costume [THE MOON LANDING IS REAL]\n\n@Clouds\n\nwhen flag clicked\n\nwhen I receive [green flag v]\nhide\n\nwhen I receive [tick v]\nposition ((x) - (ScrollX)) ((y) - (ScrollY))\n\nwhen I receive [setup v]\nset size to (100) %\nset [ghost v] effect to (50)\nTest - FrontLayer\nhide\nset [x v] to [0]\nset [y v] to [0]\nif <(LEVEL) = [1]> then\n    Test - FrontLayer\n    Clone at x: [-197] y: [123] Size: [100] Costume [Cloud]\n    Clone at x: [118] y: [72] Size: [100] Costume [Cloud2]\n    Clone at x: [343] y: [225] Size: [100] Costume [Cloud3]\n    Clone at x: [758] y: [48] Size: [100] Costume [Cloud4]\n    Clone at x: [1004] y: [205] Size: [100] Costume [Cloud]\n    Clone at x: [1196] y: [87] Size: [80] Costume [Cloud2]\n    Clone at x: [1569] y: [97] Size: [100] Costume [Cloud3]\n    Clone at x: [1700] y: [63] Size: [80] Costume [Cloud4]\n    Clone at x: [2034] y: [40] Size: [100] Costume [Cloud]\n    Clone at x: [2283] y: [200] Size: [100] Costume [Cloud2]\nelse\n    if <(LEVEL) = [2]> then\n    set [x v] to [-999999]\nend\nset [x v] to [-999999]\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\ngo to [front v] layer\nset [ghost v] effect to (0)\n\ndefine Clone at x: (x) y: (y) Size: (size) Costume (costume #)\nset [x v] to (x)\nset [y v] to (y)\nset size to (size) %\nswitch costume to (costume #)\ncreate clone of (_myself_ v)\n\ndefine Test - FrontLayer\ngo to [front v] layer\n\nwhen I start as a clone\n\n@transition\n\nwhen I receive [green flag v]\nhide\n\nwhen I receive [change v]\ngo to x: (500) y: (0)\nshow\ngo to [front v] layer\nglide (1) secs to x: (0) y: (0)\nwait (1) seconds\nglide (1) secs to x: (-500) y: (0)\nhide\n\n@Reset\n\nwhen flag clicked\nset size to (100) %\nforever\n    if <touching (mouse-pointer v)?> then\n        change size by (20)\n        change [ghost v] effect by (25)\n        wait until <not <touching (mouse-pointer v)?>>\n        change size by (-20)\n        change [ghost v] effect by (-25)\n    end\nend\n\nwhen I receive [green flag v]\ngo to x: (-214) y: (153)\nswitch costume to (costume1 v)\nset size to (60) %\ngo to [front v] layer\nshow\n\nwhen this sprite clicked\nbroadcast (Reset v)\n\n@Skip\n\nwhen flag clicked\nset size to (100) %\nforever\n    if <touching (mouse-pointer v)?> then\n        change size by (20)\n        change [ghost v] effect by (25)\n        wait until <not <touching (mouse-pointer v)?>>\n        change size by (-20)\n        change [ghost v] effect by (-25)\n    end\nend\n\nwhen I receive [green flag v]\ngo to x: (-172) y: (153)\nswitch costume to (costume1 v)\nset size to (60) %\ngo to [front v] layer\nshow\n\nwhen this sprite clicked\nbroadcast (Next level v)\n\n@detector\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\nshow\ngo to x: (0) y: (50)\nreset timer\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\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@Thumbnail\n\nwhen flag clicked\nshow\nset [ghost v] effect to (100)\nwait (1) seconds\ngo to [front v] layer\n\n
HOW TO PLAY\nFullscreen highly recommended for better graphics (and maybe less lag?)\nArrow keys or wasd to move\nCollect all the coins before going through the portal\nNOTE: skip or reset buttons do not work in level 1 unless you move forward a bit ¯\_(ツ)_/¯\nMOBILE FRIENDLY\nEnjoy :)\n-------------------------------------------------------------------------\nThis took me about a month and a half \nFirst scrolling platformer