☁ Sunrise Multiplayer Scrolling Platformer COLLAB ||#games #all

Instructions: It's finally out after an intense two weeks of school and making this game! Collab with @matcha_noah ! Go follow him! IF CHECKPOINTS DISAPPEAR, IT IS A BUG!! JUST CLICK THE GREEN FLAG TO START AGAIN!!! Also no advertising!! >:(    Graphics may be blurry in small screen. OTHERS MAY LAG!!!   Reshared because of a bug with someone stuck in the game, they still didn't get out.\n-------------------------------------------------------------------------\nMobile friendly, use arrow keys or w, a, and d to move. Press "T" for chat, and "Y" for shop, press space to close both of those. Press "N" to hide or show names. Don't touch spikes, saws, cacti or fall. There are 4 checkpoints, 3 glows, and 8 achievements in all. Enjoy! Top loved!  \n------------------------------!!!----------------------------------------\n@ItsdaAlexGamer (loved and faved)\n@talexat  (loved and faved and commented)\n@AUMSUMTHEGREATHULK (loved and faved)\n@-5K- (commented)\n@cesa23 (loved and commented)\n@-superwooper- (loved)\n@5wonders (commented, loved and faved)\n-------------------------------Credits--------------------------------\n@griffpatch (multiplayer and scrolling)\n@JTHEJET (engine, coin design and chat button)\n@StratfordJames (trend, and love&fav detector.)\n@mathca_noah (Collab)\n@-Xaf- for the song Nebula\nWhoever made saw design.\n(This is @matcha_noah 's version: https://scratch.mit.edu/projects/449929947/ )\n----------------------------------Tags--------------------------------\n#sunrise #multiplayer #scrolling #platformer #collab #idk #random #why #fun #a #games #all #jimmycube #cube #jimmythecube #lol         #I #dont #need #this #many #tags

@Stage\n\nwhen [m v] key pressed\nshow variable [mouse x,y v]\nset [mouse x,y v] to (join ((mouse x) + (SCROLL X)) (join [,] ((mouse y) + (SCROLL Y))))\n\nwhen flag clicked\nforever\n    play sound [Xaf - Nebula v] until done\nend\n\nwhen flag clicked\nswitch backdrop to (back2 v)\nrepeat until <(backdrop [number v]) = [6]>\n    wait (15) seconds\n    next backdrop\nend\n\nwhen flag clicked\nhide variable [mouse x,y v]\n\nwhen [n v] key pressed\nhide variable [mouse x,y v]\n\nwhen flag clicked\nset [personal chat v] to [0]\nforever\n    if <<<<key (o v) pressed?> or <<key (u v) pressed?> or <key (i v) pressed?>>> and <(username) = [akiosan]>> and <(Personal Chat) = [0]>> then\n        set [personal chat v] to [1]\n        set [chat words v] to [20]\n        ask [Chat:] and wait\n        broadcast (personal chat v) and wait\n    end\n    set [personal chat v] to [0]\nend\n\n@Blank\n\n@Player\n\nwhen I receive [begin v]\nset [chat v] to [0]\nshow list [chat v]\nforever\n    Chat\nend\n\nif <(Chat) = [1]> then\n    show list [chat v]\n    set [chat v] to [0]\n    wait until <<not <<touching (mouse-pointer v)?> and <mouse down?>>> and <not <key (t v) pressed?>>>\n    if <(Chat) = [0]> then\n        set [chat v] to [1]\n        wait until <<not <<touching (mouse-pointer v)?> and <mouse down?>>> and <not <key (t v) pressed?>>>\n    end\nend\n\nwhen I receive [play game v]\nset [connected? v] to [0]\n\ndefine Position\ngo to x: ((x) - (SCROLL X)) y: ((y) - (SCROLL Y))\n\nwhen I receive [green flag v]\nhide\ngo to [front v] layer\n\ndefine Change Player x by (sx)\npoint in direction (90)\nchange [x v] by (sx)\nPosition\nif <<touching (platforms v)?> or <touching (moving platforms v)?>> then\n    repeat (12)\n        change [y v] by (1)\n        Position\n        if <not <<touching (platforms v)?> or <touching (moving platforms v)?>>> then\n            stop [this script v]\n        end\n    end\n    change [y v] by (-12)\n    if <<<(y position) < (mouse y)> and <mouse down?>> or <<key (up arrow v) pressed?> or <key (w v) pressed?>>> then\n        if <(sx) > [0]> then\n            set [sx v] to [-16]\n        else\n            set [sx v] to [16]\n        end\n        set [in air v] to [0]\n    else\n        set [sx v] to [0]\n    end\n    repeat until <not <<touching (platforms v)?> or <touching (moving 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\nwhen flag clicked\npoint in direction (90)\nbroadcast (Green Flag v) and wait\nbroadcast (Play Game v) and wait\n\ndefine Change Player y by (sy)\nchange [y v] by (sy)\nchange [in air v] by (.9)\nPosition\nrepeat until <not <<touching (platforms v)?> or <touching (moving 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 Game On\nset [y v] to [0]\nset [x v] to [0]\nset [sx v] to [0]\nset [sy v] to [0]\nset [in air v] to [0]\nset [exit v] to []\nset [ghost v] effect to (0)\nset size to (100) %\nif <(Checkpoint) = [1]> then\n    set [x v] to [1470]\n    set [y v] to [65]\nend\nif <(Checkpoint) = [2]> then\n    set [x v] to [3300]\n    set [y v] to [330]\n    set [scroll y v] to [350]\nend\nif <(Checkpoint) = [3]> then\n    set [x v] to [6340]\n    set [y v] to [65]\nend\nif <(Checkpoint) = [4]> then\n    set [x v] to [9188]\n    set [y v] to [730]\n    set [scroll y v] to [700]\nend\n\ndefine Test - Die\nif <<<touching (danger v)?> or <touching (saws v)?>> or <touching (water v)?>> then\n    set [exit v] to [die]\n    broadcast (DEATH CHECK v)\nend\n\ndefine Game - Die\nset [exit v] to []\nstart sound [Hurt v]\n\ndefine Game - Win\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)\nwait (1) seconds\nstop [other scripts in sprite v]\n\ndefine Tick\nif <not <key (any v) pressed?>> then\n    switch costume to (normal v)\nend\nif <<<(mouse x) < (x position)> and <mouse down?>> or <<key (left arrow v) pressed?> or <key (a v) pressed?>>> then\n    switch costume to (left v)\n    change [sx v] by (-2)\nend\nif <<<(x position) < (mouse x)> and <mouse down?>> or <<key (right arrow v) pressed?> or <key (d v) pressed?>>> then\n    switch costume to (right v)\n    change [sx v] by (2)\nend\nif <<<<(y position) < (mouse y)> and <mouse down?>> or <<key (up arrow v) pressed?> or <key (w v) pressed?>>> and <<<(mouse x) < (x position)> and <mouse down?>> or <<key (left arrow v) pressed?> or <key (a v) pressed?>>>> then\n    switch costume to (left up v)\nend\nif <<<<(y position) < (mouse y)> and <mouse down?>> or <<key (up arrow v) pressed?> or <key (w v) pressed?>>> and <<<(x position) < (mouse x)> and <mouse down?>> or <<key (right arrow v) pressed?> or <key (d v) pressed?>>>> then\n    switch costume to (right up v)\nend\nset [sx v] to ((sx) * (0.8))\nif <([abs v] of (sx) ) > [0.9]> then\n    Change Player x by (round (sx))\nend\nif <<<(y position) < (mouse y)> and <mouse down?>> or <<key (up arrow v) pressed?> or <key (w v) pressed?>>> then\n    if <(in air) < [4]> then\n        set [sy v] to [16]\n    end\nend\nif <(sy) > [-20]> then\n    change [sy v] by (-2)\nend\nChange Player y by (sy)\nTest - Die\nset [scroll x v] to (x)\nif <(SCROLL X) < [0]> then\n    set [scroll x v] to [0]\nend\nchange [scroll y v] by (round (((y) - (SCROLL Y)) / (10)))\nif <(SCROLL Y) < [0]> then\n    set [scroll y v] to [0]\nend\nPosition\nif <(y) < [-180]> then\n    set [exit v] to [die]\nend\nif <(x) < [-220]> then\n    set [x v] to [-220]\nend\n\nwhen flag clicked\nhide\nset [max players v] to [10]\nset [my player # v] to [0]\nbroadcast (Connecting v)\nbroadcast (Setup Others v) and wait\nbroadcast (Join Game v) and wait\nif <(MY PLAYER #) > [0]> then\n    broadcast (Connected v)\n    start sound [Connect v]\nelse\n    broadcast (Full v)\n    start sound [Disconnect v]\nend\nbroadcast (Begin v)\n\ndefine set cloud # (player) to (value)\nif <(player) = [1]> then\n    set [☁ p1 v] to (value)\nelse\n    if <(player) = [2]> then\n        set [☁ p2 v] to (value)\n    else\n        if <(player) = [3]> then\n            set [☁ p3 v] to (value)\n        else\n            if <(player) = [4]> then\n                set [☁ p4 v] to (value)\n            else\n                if <(player) = [5]> then\n                    set [☁ p5 v] to (value)\n                else\n                    if <(player) = [6]> then\n                        set [☁ p6 v] to (value)\n                    else\n                        if <(player) = [7]> then\n                            set [☁ p7 v] to (value)\n                        else\n                            if <(player) = [8]> then\n                                set [☁ p8 v] to (value)\n                            else\n                                if <(player) = [9]> then\n                                    set [☁ p9 v] to (value)\n                                else\n                                    if <(player) = [10]> then\n                                        set [☁ p10 v] to (value)\n                                    end\n                                end\n                            end\n                        end\n                    end\n                end\n            end\n        end\n    end\nend\n\ndefine write (val) to encoded\nset [letter # v] to [1]\nrepeat (length of (val))\n    set [encoded v] to (join (encoded) (item # of (letter (letter #) of (val)) in [code v]))\n    change [letter # v] by (1)\nend\nset [encoded v] to (join (encoded) [00])\n\nwhen I receive [begin v]\nforever\n    if <(MY PLAYER #) > [0]> then\n        send cloud data\n    end\nend\n\ndefine send cloud data\nset [encoded v] to []\nwrite (username) to encoded\nwrite (round ((timer) * (10))) to encoded\nwrite (x) to encoded\nwrite (y) to encoded\nwrite (Chat Words) to encoded\nset cloud # (MY PLAYER #) to (encoded)\n\ndefine Chat\nif <(Chat) = [1]> then\n    if <key (1 v) pressed?> then\n        set [chat words v] to [1]\n        say (item (1) of [chat v])\n        broadcast (Chat Close v)\n        wait (2) seconds\n        say []\n        set [chat words v] to [0]\n    else\n        if <key (2 v) pressed?> then\n            set [chat words v] to [2]\n            say (item (2) of [chat v])\n            broadcast (Chat Close v)\n            wait (2) seconds\n            say []\n            set [chat words v] to [0]\n        else\n            if <key (3 v) pressed?> then\n                set [chat words v] to [3]\n                say (item (3) of [chat v])\n                broadcast (Chat Close v)\n                wait (2) seconds\n                say []\n                set [chat words v] to [0]\n            else\n                if <key (4 v) pressed?> then\n                    set [chat words v] to [4]\n                    say (item (4) of [chat v])\n                    broadcast (Chat Close v)\n                    wait (2) seconds\n                    say []\n                    set [chat words v] to [0]\n                else\n                    if <key (5 v) pressed?> then\n                        set [chat words v] to [5]\n                        say (item (5) of [chat v])\n                        broadcast (Chat Close v)\n                        wait (2) seconds\n                        say []\n                        set [chat words v] to [0]\n                    else\n                        if <key (6 v) pressed?> then\n                            set [chat words v] to [6]\n                            say (item (6) of [chat v])\n                            broadcast (Chat Close v)\n                            wait (3) seconds\n                            say []\n                            set [chat words v] to [0]\n                        else\n                            if <key (7 v) pressed?> then\n                                set [chat words v] to [7]\n                                say (item (7) of [chat v])\n                                broadcast (Chat Close v)\n                                wait (2) seconds\n                                say []\n                                set [chat words v] to [0]\n                            else\n                                if <key (8 v) pressed?> then\n                                    set [chat words v] to [8]\n                                    say (item (8) of [chat v])\n                                    broadcast (Chat Close v)\n                                    wait (2) seconds\n                                    say []\n                                    set [chat words v] to [0]\n                                else\n                                    if <key (9 v) pressed?> then\n                                        set [chat words v] to [9]\n                                        say (item (9) of [chat v])\n                                        broadcast (Chat Close v)\n                                        wait (2) seconds\n                                        say []\n                                        set [chat words v] to [0]\n                                    else\n                                        if <key (0 v) pressed?> then\n                                            set [chat words v] to [10]\n                                            say (item (10) of [chat v])\n                                            broadcast (Chat Close v)\n                                            wait (2) seconds\n                                            say []\n                                            set [chat words v] to [0]\n                                        else\n                                            if <key (p v) pressed?> then\n                                                set [chat words v] to [11]\n                                                say (item (11) of [chat v])\n                                                broadcast (Chat Close v)\n                                                wait (2) seconds\n                                                say []\n                                                set [chat words v] to [0]\n                                            else\n                                                if <<key (r v) pressed?> and <(username) = [akiosan]>> then\n                                                    set [chat words v] to [12]\n                                                    say (item (12) of [chat v])\n                                                    broadcast (Chat Close v)\n                                                    wait (3) seconds\n                                                    say []\n                                                    set [chat words v] to [0]\n                                                else\n                                                    set [chat words v] to [0]\n                                                end\n                                            end\n                                        end\n                                    end\n                                end\n                            end\n                        end\n                    end\n                end\n            end\n        end\n    end\nend\n\nwhen flag clicked\ngo to [front v] layer\n\nwhen I receive [connected v]\nset [connected? v] to [1]\nshow\n\nwhen I receive [connecting v]\nhide\n\nwhen I receive [play game v]\nforever\n    if <(Connected?) = [1]> then\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)\n        end\n        if <(EXIT) = [win]> then\n            Game - Win\n        else\n            Game - Die\n        end\n    end\nend\n\nwhen I receive [connected v]\nset [level v] to [1]\n\nwhen I receive [setup v]\nset [scroll x v] to [0]\nset [scroll y v] to [0]\nset [sx v] to [0]\nset [sy v] to [0]\nif <(Checkpoint) = [1]> then\n    set [x v] to [1470]\n    set [y v] to [65]\nend\nset [exit v] to []\n\nwhen I receive [spring v]\nset [sy v] to [30]\n\nwhen I receive [personal chat v]\nadd (answer) to [chat v]\nsay (item (length of [chat v]) of [chat v])\nwait (3) seconds\nsay []\nset [chat words v] to [0]\nset [personal chat v] to [0]\n\n@Others\n\nwhen I receive [begin v]\nset [names v] to [1]\nforever\n    if <key (n v) pressed?> then\n        if <(names) = [1]> then\n            wait until <not <key (n v) pressed?>>\n            set [names v] to [0]\n        else\n            wait until <not <key (n v) pressed?>>\n            set [names v] to [1]\n        end\n    end\nend\n\nwhen I receive [setup others v]\nsetup players\n\ndefine setup players\nhide\nset [offline v] to [100]\nset [player # v] to [1]\nrepeat ((MAX PLAYERS) - (1))\n    create clone of (_myself_ v)\n    change [player # v] by (1)\nend\n\ndefine value = cloud # (player)\nif <(player) = [1]> then\n    set [value v] to (☁ P1)\nelse\n    if <(player) = [2]> then\n        set [value v] to (☁ P2)\n    else\n        if <(player) = [3]> then\n            set [value v] to (☁ P3)\n        else\n            if <(player) = [4]> then\n                set [value v] to (☁ P4)\n            else\n                if <(player) = [5]> then\n                    set [value v] to (☁ P5)\n                else\n                    if <(player) = [6]> then\n                        set [value v] to (☁ P6)\n                    else\n                        if <(player) = [7]> then\n                            set [value v] to (☁ P7)\n                        else\n                            if <(player) = [8]> then\n                                set [value v] to (☁ P8)\n                            else\n                                if <(player) = [9]> then\n                                    set [value v] to (☁ P9)\n                                else\n                                    if <(player) = [10]> then\n                                        set [value v] to (☁ P10)\n                                    end\n                                end\n                            end\n                        end\n                    end\n                end\n            end\n        end\n    end\nend\n\nset [value v] to (☁ P3)\n\nwhen I receive [begin v]\nforever\n    if <(MY PLAYER #) = (player #)> then\n        set [offline v] to [100]\n        hide\n    else\n        Tick\n    end\nend\n\ndefine Tick\nvalue = cloud # (player #)\nif <(join [A] (value)) = (last value)> then\n    change [offline v] by (1)\n    if <(offline) = [100]> then\n        hide\n    end\nelse\n    set [last value v] to (join [A] (value))\n    if <(offline) > [99]> then\n        show\n    end\n    set [offline v] to [0]\nend\nbegin decode of (value)\nvalue = read from encoded\nif <(names) = [1]> then\n    say (join (player #) (join [:] (value)))\nelse\n    say []\nend\nvalue = read from encoded\nvalue = read from encoded\nset x to ((value) - (SCROLL X))\nvalue = read from encoded\nset y to (((value) - (SCROLL Y)) + (8))\nvalue = read from encoded\nbroadcast (Decode Chat v)\n\ndefine begin decode of (encoded)\nset [encoded v] to (encoded)\nset [letter # v] to [1]\n\ndefine value = read from encoded\nset [value v] to []\nforever\n    set [idx v] to (join (letter (letter #) of (encoded)) (letter ((letter #) + (1)) of (encoded)))\n    change [letter # v] by (2)\n    if <(idx) < [1]> then\n        stop [this script v]\n    end\n    set [value v] to (join (value) (item (idx) of [code v]))\nend\n\nwhen I receive [join game v]\nvalue = cloud # (player #)\nset [last value v] to (join [A] (value))\nwait (3) seconds\nvalue = cloud # (player #)\nif <(join [A] (value)) = (last value)> then\n    set [my player # v] to (player #)\nend\n\ndefine Decode Chat (chat)\nif <(chat) = [1]> then\n    say (item (1) of [chat v]) for (2) seconds\n    broadcast (plz ban v)\nelse\n    if <(chat) = [2]> then\n        say (item (2) of [chat v]) for (2) seconds\n    else\n        if <(chat) = [3]> then\n            say (item (3) of [chat v]) for (2) seconds\n        else\n            if <(chat) = [4]> then\n                say (item (4) of [chat v]) for (2) seconds\n            else\n                if <(chat) = [5]> then\n                    say (item (5) of [chat v]) for (2) seconds\n                else\n                    if <(chat) = [6]> then\n                        say (item (6) of [chat v]) for (2) seconds\n                    else\n                        if <(chat) = [7]> then\n                            say (item (7) of [chat v]) for (2) seconds\n                        else\n                            if <(chat) = [8]> then\n                                say (item (8) of [chat v]) for (2) seconds\n                            else\n                                if <(chat) = [9]> then\n                                    say (item (9) of [chat v]) for (2) seconds\n                                else\n                                    if <(chat) = [10]> then\n                                        say (item (10) of [chat v]) for (2) seconds\n                                    else\n                                        if <(chat) = [11]> then\n                                            say (item (11) of [chat v]) for (2) seconds\n                                        else\n                                            if <(chat) = [12]> then\n                                                say (item (12) of [chat v]) for (3) seconds\n                                            else\n                                                if <(chat) = (Others Chat)> then\n                                                    say (item (Others Chat) of [chat v]) for (3) seconds\n                                                end\n                                            end\n                                        end\n                                    end\n                                end\n                            end\n                        end\n                    end\n                end\n            end\n        end\n    end\nend\n\nwhen I receive [decode chat v]\nDecode Chat (value)\n\nwhen flag clicked\nset [others chat v] to [12]\n\nwhen I receive [personal chat v]\nchange [others chat v] by (1)\n\nhide\n\n@Platforms\n\nwhen I receive [green flag v]\nhide\n\nwhen I receive [tick v]\nPosition ((Platforms: x) - (SCROLL X)) ((Platforms: y) - (SCROLL Y))\n\nwhen I receive [setup v]\nhide\nset [platforms: x v] to [0]\nset [platforms: y v] to [0]\nif <(LEVEL) = [1]> then\n    switch costume to (level 1 1 v)\n    Clone at x: [480] y: [0]\n    Clone at x: [480] y: [-1]\n    Clone at x: [480] y: [0]\n    Clone at x: [1100] y: [350]\n    Clone at x: [0] y: [-300]\n    Clone at x: [480] y: [300]\n    Clone at x: [480] y: [0]\n    Clone at x: [700] y: [-345]\n    Clone at x: [480] y: [0]\n    Clone at x: [480] y: [0]\n    Clone at x: [1000] y: [0]\n    Clone at x: [1200] y: [200]\n    Clone at x: [480] y: [0]\n    Clone at x: [480] y: [0]\n    Clone at x: [1000] y: [380]\n    Clone at x: [480] y: [0]\n    Clone at x: [480] y: [0]\n    Clone at x: [1000] y: [-10]\n    Clone at x: [480] y: [0]\n    Clone at x: [480] y: [0]\nend\n\ndefine Position (x) (y)\nset size to (100) %\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 [platforms: x v] by (x)\nchange [platforms: y v] by (y)\nnext costume\n\nnext costume\nnext costume\n\ncreate clone of (_myself_ v)\n\n@Moving Platforms\n\nwhen flag clicked\nhide\n\nwhen flag clicked\nhide\n\nwhen I receive [tick v]\nif <(Direction) = [h]> then\n    Position (((Moving Platforms2: Moving Platforms: x) - (SCROLL X)) + (([cos v] of ((timer) * (speed)) ) * (distance))) ((Moving Platforms2: Moving Platforms: y) - (SCROLL Y))\nelse\n    Position ((Moving Platforms2: Moving Platforms: x) - (SCROLL X)) (((Moving Platforms2: Moving Platforms: y) - (SCROLL Y)) + (([cos v] of ((timer) * (speed)) ) * (distance)))\nend\n\ndefine Clone at x: (x) y: (y) Distance (distance) Speed (speed) Direction (direction)\npoint in direction (90)\nset [direction v] to (direction)\nset [distance v] to (distance)\nset [speed v] to (speed)\nset [moving platforms2: moving platforms: x v] to (x)\nset [moving platforms2: moving platforms: y v] to (y)\nnext costume\ncreate clone of (_myself_ v)\n\nwhen I receive [setup v]\nswitch costume to (platform v)\nset [moving platforms2: moving platforms: x v] to [0]\nset [moving platforms2: moving platforms: y v] to [0]\nif <(LEVEL) = [1]> then\n    Clone at x: [2000] y: [10] Distance [200] Speed [70] Direction [h]\n    Clone at x: [5630] y: [20] Distance [120] Speed [100] Direction [h]\n    Clone at x: [6500] y: [20] Distance [100] Speed [100] Direction [v]\n    Clone at x: [6800] y: [120] Distance [120] Speed [100] Direction [h]\n    Clone at x: [8750] y: [510] Distance [120] Speed [100] Direction [h]\n    Clone at x: [10800] y: [630] Distance [120] Speed [100] Direction [h]\nend\nset [moving platforms2: moving platforms: x v] to [-500]\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@DANGER\n\nwhen I receive [green flag v]\nhide\n\nwhen I receive [tick v]\nPosition ((DANGER: x) - (SCROLL X)) ((DANGER: y) - (SCROLL Y))\n\nwhen I receive [setup v]\nhide\nset [danger: x v] to [0]\nset [danger: y v] to [0]\nswitch costume to (level 1 1 v)\nif <(LEVEL) = [1]> then\n    Clone at x: [360] y: [0]\n    Clone at x: [700] y: [0]\n    Clone at x: [1750] y: [250]\n    Clone at x: [600] y: [0]\n    Clone at x: [650] y: [-290]\n    Clone at x: [700] y: [0]\n    Clone at x: [300] y: [0]\n    Clone at x: [1000] y: [0]\n    Clone at x: [2300] y: [200]\n    Clone at x: [1350] y: [520]\n    Clone at x: [500] y: [0]\n    Clone at x: [1300] y: [-130]\nend\n\ndefine Position (x) (y)\ngo to [back v] layer\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 [danger: x v] by (x)\nchange [danger: y v] by (y)\nnext costume\n\n@Saws\n\nwhen I receive [green flag v]\nhide variable [mouse v]\nhide\n\nwhen I receive [tick v]\nturn right (12) degrees\nPosition ((Saws: x) - (SCROLL X)) ((Saws: y) - (SCROLL Y))\ngo to [back v] layer\n\nwhen I receive [setup v]\nhide\nset [saws: x v] to [0]\nset [saws: y v] to [0]\nif <(LEVEL) = [1]> then\n    Clone at x: [150] y: [-50]\n    Clone at x: [1250] y: [-50]\n    Clone at x: [2540] y: [260]\n    Clone at x: [4300] y: [8]\n    Clone at x: [4570] y: [70]\n    Clone at x: [5250] y: [-40]\n    Clone at x: [7300] y: [165]\n    Clone at x: [7500] y: [165]\n    Clone at x: [7700] y: [165]\n    Clone at x: [7900] y: [165]\n    Clone at x: [9370] y: [800]\n    Clone at x: [11216] y: [530]\nend\nset [saws: 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)\nshow\nset [saws: x v] to (x)\nset [saws: y v] to (y)\ncreate clone of (_myself_ v)\n\nClone at x: [340] y: [27]\nClone at x: [530] y: [27]\nClone at x: [786] y: [27]\nClone at x: [1124] y: [27]\nClone at x: [1331] y: [245]\nClone at x: [1065] y: [345]\nClone at x: [825] y: [272]\nClone at x: [392] y: [245]\nClone at x: [197] y: [335]\n\nClone at x: [631] y: [11]\n\n@Collectables\n\nwhen I receive [green flag v]\nhide\n\nwhen I receive [tick v]\nnext costume\nPosition ((Collectables: x) - (SCROLL X)) ((Collectables: y) - (SCROLL Y))\nif <touching (player v)?> then\n    change [collected v] by (1)\n    delete this clone\nend\n\nwhen I receive [setup v]\nset [coins v] to [0]\nhide\nset [collectables: x v] to [0]\nset [collectables: y v] to [0]\nif <(LEVEL) = [1]> then\n    switch costume to (coin1 v)\n    Clone at x: [-7] y: [63]\n    Clone at x: [955] y: [63]\n    Clone at x: [3150] y: [450]\n    Clone at x: [4500] y: [150]\n    Clone at x: [6100] y: [70]\n    Clone at x: [7400] y: [200]\n    Clone at x: [9450] y: [705]\n    Clone at x: [10804] y: [807]\nend\nset [collectables: x v] to [-9999999999]\n\ncreate clone of (_myself_ v)\n\nnext costume\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\ndefine Clone at x: (x) y: (y)\nset [collectables: x v] to (x)\nset [collectables: y v] to (y)\ncreate clone of (_myself_ v)\n\nwhen flag clicked\nset [collected v] to [0]\n\nwhen I receive [begin v]\nshow variable [collected v]\n\nwhen I receive [setup v]\nif <<(Checkpoint) = [1]> and <not <(OldCollected) = [1]>>> then\n    set [coinscheck1 v] to (COLLECTED)\n    set [oldcollected v] to [1]\nelse\n    if <<(Checkpoint) = [2]> and <not <(OldCollected) = [2]>>> then\n        set [coinscheck2 v] to (COLLECTED)\n        set [oldcollected v] to [2]\n    else\n        if <<(Checkpoint) = [3]> and <not <(OldCollected) = [3]>>> then\n            set [coinscheck3 v] to (COLLECTED)\n            set [oldcollected v] to [3]\n        else\n            if <<(Checkpoint) = [4]> and <not <(OldCollected) = [4]>>> then\n                set [coinscheck4 v] to (COLLECTED)\n                set [oldcollected v] to [4]\n            else\n                set [collected v] to [0]\n            end\n        end\n    end\nend\n\nwhen I receive [setup v]\nif <<(Checkpoint) = [1]> and <(OldCollected) = [1]>> then\n    set [collected v] to (CoinsCheck1)\nelse\n    if <<(Checkpoint) = [2]> and <(OldCollected) = [2]>> then\n        set [collected v] to (CoinsCheck2)\n    else\n        if <<(Checkpoint) = [3]> and <(OldCollected) = [3]>> then\n            set [collected v] to (CoinsCheck3)\n        else\n            if <<(Checkpoint) = [4]> and <(OldCollected) = [4]>> then\n                set [collected v] to (Coinscheck4)\n            else\n            end\n        end\n    end\nend\n\nwhen flag clicked\nset [oldcollected v] to [0]\n\nwhen I receive [buy glow 1 v]\nif <<(Checkpoint) = [1]> and <(OldCollected) = [1]>> then\n    set [coinscheck1 v] to (COLLECTED)\nelse\n    if <<(Checkpoint) = [2]> and <(OldCollected) = [2]>> then\n        set [coinscheck2 v] to (COLLECTED)\n    else\n        if <<(Checkpoint) = [3]> and <(OldCollected) = [3]>> then\n            set [coinscheck3 v] to (COLLECTED)\n        else\n            if <<(Checkpoint) = [4]> and <(OldCollected) = [4]>> then\n                set [coinscheck4 v] to (COLLECTED)\n            end\n        end\n    end\nend\n\nwhen I receive [buy glow 3 v]\nif <<(Checkpoint) = [1]> and <(OldCollected) = [1]>> then\n    set [coinscheck1 v] to (COLLECTED)\nelse\n    if <<(Checkpoint) = [2]> and <(OldCollected) = [2]>> then\n        set [coinscheck2 v] to (COLLECTED)\n    else\n        if <<(Checkpoint) = [3]> and <(OldCollected) = [3]>> then\n            set [coinscheck3 v] to (COLLECTED)\n        else\n            if <<(Checkpoint) = [4]> and <(OldCollected) = [4]>> then\n                set [coinscheck4 v] to (COLLECTED)\n            end\n        end\n    end\nend\n\n@Checkpoint \n\nwhen I receive [green flag v]\nhide\n\nwhen I receive [tick v]\nPosition ((Checkpoint : x) - (SCROLL X)) ((Checkpoint : y) - (SCROLL Y))\nif <(costume [number v]) = [2]> then\n    if <touching (player v)?> then\n        start sound [CHECKPOINT v]\n        switch costume to (checkpoint open v)\n        change [checkpoint v] by (1)\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\ndefine Clone at x: (x) y: (y)\nset [checkpoint : x v] to (x)\nset [checkpoint : y v] to (y)\ncreate clone of (_myself_ v)\n\nwhen flag clicked\nset [checkpoint v] to [0]\nswitch costume to (checkpoint closed v)\nset [checkpoint : x v] to [0]\nset [checkpoint : y v] to [0]\nhide\nif <(LEVEL) = [1]> then\n    go [backward v] (6) layers\n    Clone at x: [1470] y: [65]\n    Clone at x: [3300] y: [280]\n    Clone at x: [6340] y: [60]\n    Clone at x: [9188] y: [696]\nend\nset [checkpoint : x v] to [-99999]\n\nwhen I receive [reset v]\n\n@Death\n\nwhen flag clicked\nset [ghost v] effect to (100)\n\nwhen I receive [death check v]\nclear graphic effects\nrepeat (20)\n    go to [front v] layer\n    change [ghost v] effect by (5)\nend\n\n@Spring\n\nwhen I receive [green flag v]\nhide\n\nwhen I receive [tick v]\nPosition ((Checkpoint : x) - (SCROLL X)) ((Checkpoint : y) - (SCROLL Y))\nif <touching (player v)?> then\n    broadcast (SPRING v) and wait\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\ndefine Clone at x: (x) y: (y)\nset [checkpoint : x v] to (x)\nset [checkpoint : y v] to (y)\ncreate clone of (_myself_ v)\n\nwhen flag clicked\nswitch costume to (costume6 v)\n\nwhen I receive [reset v]\ndelete this clone\n\nwhen I receive [setup v]\nhide\nset [checkpoint : x v] to [0]\nset [checkpoint : y v] to [0]\nif <(LEVEL) = [1]> then\n    switch costume to (costume1 v)\n    Clone at x: [400] y: [115]\n    Clone at x: [8450] y: [335]\n    Clone at x: [9300] y: [690]\n    Clone at x: [11720] y: [560]\nend\nset [checkpoint : x v] to [-99999]\n\nwhen I receive [spring v]\nstart sound [Big Boing v]\nswitch costume to (costume6 v)\nrepeat (9)\n    next costume\n    wait (.01) seconds\nend\nswitch costume to (costume6 v)\n\n@Chat Button\n\nwhen I receive [tick v]\nif <touching (mouse-pointer v)?> then\n    repeat until <(size) > [119]>\n        change [size v] by (.9)\n        change size by (size)\n    end\n    if <mouse down?> then\n        broadcast (Chat Open v)\n        hide\n        wait until <not <mouse down?>>\n    end\nelse\n    repeat until <(size) < [101]>\n        set [size v] to [-.8]\n        change [size v] by (-.9)\n        change size by (size)\n    end\nend\n\nwhen I receive [chat close v]\nset size to (100) %\nset [ghost v] effect to (100)\nshow\nrepeat (10)\n    change [ghost v] effect by (-10)\nend\n\nwhen I receive [begin v]\nset [size v] to [.8]\nshow\nrepeat (40)\n    change [ghost v] effect by (-3)\nend\n\nwhen flag clicked\ngo to [front v] layer\nhide\ngo to x: (0) y: (0)\nchange [ghost v] effect by (100)\n\nwhen flag clicked\ngo to x: (-193) y: (-156)\nset size to (100) %\n\nwhen [t v] key pressed\n\nbroadcast (Chat Open v)\nhide\nwait until <not <mouse down?>>\n\nwhen I receive [tick v]\nif <key (t v) pressed?> then\n    broadcast (Chat Open v)\n    hide\nend\n\n@Chat\n\nwhen I receive [tick v]\nif <(Chat) = [1]> then\n    show\nelse\n    hide\nend\nif <key (space v) pressed?> then\n    broadcast (Chat Close v)\n    hide\n    wait until <not <key (space v) pressed?>>\nend\n\nwhen I receive [green flag v]\nhide\n\nwhen flag clicked\nhide\ngo to [front v] layer\n\nwhen I receive [chat open v]\nset [chat v] to [1]\n\nwhen I receive [chat close v]\nset [chat v] to [0]\n\nwhen I receive [tick v]\ngo [forward v] (2) layers\nwait (1) seconds\n\n@Shop button\n\nwhen I receive [tick v]\nif <touching (mouse-pointer v)?> then\n    repeat until <(size) > [119]>\n        change [size v] by (.9)\n        change size by (size)\n    end\n    if <mouse down?> then\n        broadcast (shop open v)\n        hide\n        wait until <not <mouse down?>>\n    end\nelse\n    repeat until <(size) < [101]>\n        set [size v] to [-.8]\n        change [size v] by (-.9)\n        change size by (size)\n    end\nend\n\nwhen I receive [shop close v]\nset size to (100) %\nset [ghost v] effect to (100)\nshow\nrepeat (10)\n    change [ghost v] effect by (-10)\nend\n\nwhen I receive [begin v]\nset [size v] to [.8]\nshow\nrepeat (40)\n    change [ghost v] effect by (-3)\nend\n\nwhen flag clicked\ngo to [front v] layer\nhide\ngo to x: (0) y: (0)\nchange [ghost v] effect by (100)\n\nwhen flag clicked\ngo to x: (-120) y: (-156)\nset size to (100) %\n\nwhen I receive [tick v]\nif <key (y v) pressed?> then\n    broadcast (shop open v)\n    hide\nend\n\nwhen I receive [shop open v]\nbroadcast (Chat Close v)\n\nwhen I receive [chat open v]\nbroadcast (shop close v)\n\n@Shop\n\nwhen I receive [tick v]\nif <(shop) = [1]> then\n    show\nelse\n    hide\nend\nif <key (space v) pressed?> then\n    broadcast (shop close v)\n    hide\n    wait until <not <key (space v) pressed?>>\nend\n\nwhen I receive [green flag v]\nhide\n\nwhen flag clicked\nhide\ngo to [front v] layer\n\nwhen I receive [shop open v]\nset [shop v] to [1]\n\nwhen I receive [shop close v]\nset [shop v] to [0]\n\nwhen I receive [tick v]\ngo [forward v] (2) layers\nwait (1) seconds\n\n@Love fave\n\nwhen flag clicked\nset [costume v] to [0]\nhide\nforever\n    if <not <<(LOVED__) = [1]> and <(FAVED___) = [1]>>> then\n        wait (pick random (180) to (240)) seconds\n        switch costume to (costume1 v)\n        go to x: (0) y: (50)\n        show\n        go to [front v] layer\n        start sound [pop v]\n        repeat (9)\n            change y by (-6)\n        end\n        repeat (5)\n            change y by (3)\n        end\n        repeat (5)\n            change y by (-1)\n        end\n        wait (2) seconds\n        repeat (15)\n            change y by (7)\n        end\n        hide\n    else\n        hide\n    end\n    if <(Costume) > [0]> then\n        hide\n        stop [this script v]\n    end\nend\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\nbroadcast (Thanks v)\n\ngo to x: (0) y: (0)\nshow\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@Thanks\n\nwhen I receive [thanks v]\nswitch costume to (costume2 v)\ngo to x: (-210) y: (50)\nshow\ngo to [front v] layer\nstart sound [pop v]\nrepeat (9)\n    change y by (-6)\nend\nrepeat (5)\n    change y by (3)\nend\nrepeat (5)\n    change y by (-3)\nend\nwait (1) seconds\nrepeat (10)\n    change y by (6)\nend\nhide\n\nwhen I start as a clone\ngo to x: (0) y: (-50)\nshow\ngo to [front v] layer\nrepeat (12)\n    change y by (-9)\nend\nrepeat (5)\n    change y by (3)\nend\nrepeat (5)\n    change y by (-1)\nend\nforever\n    if <touching (mouse-pointer v)?> then\n        set [ghost v] effect to (50)\n        if <(costume [number v]) = [2]> then\n            if <mouse down?> then\n                set [costume v] to [2]\n                repeat (25)\n                    change y by (10)\n                end\n                hide\n                delete this clone\n            end\n        else\n            if <(costume [number v]) = [3]> then\n                if <mouse down?> then\n                    set [costume v] to [1]\n                    repeat (25)\n                        change y by (15)\n                    end\n                    hide\n                    delete this clone\n                end\n            end\n        end\n    else\n        set [ghost v] effect to (0)\n    end\n    if <(Costume) > [0.99]> then\n        repeat (25)\n            change y by (15)\n        end\n        hide\n        delete this clone\n    end\n    hide\n    delete this clone\nend\n\nwhen flag clicked\nhide\nset [costume v] to [0.9]\n\nwhen I receive [begin v]\nset [costume v] to [0.9]\nwait (0.1) seconds\nset [costume v] to [0.9]\nwait (0.2) seconds\nset [costume v] to [0.9]\n\n@Joining\n\nwhen flag clicked\nhide\n\nwhen I receive [begin v]\nhide\n\nwhen I receive [connecting v]\nswitch costume to (joining v)\nshow\n\nwhen I receive [connected v]\ngo [forward v] (1322) layers\nstart sound [Connect v]\nswitch costume to (connected v)\nshow\nwait (1) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\nend\n\nwhen I receive [full v]\nswitch costume to (full  v)\nshow\n\n@Loading\n\nwhen flag clicked\ngo [forward v] (213) layers\nset size to (100) %\nhide\npoint in direction (90)\nclear graphic effects\ngo to x: (0) y: (-80)\n\nwhen I receive [connecting v]\nrepeat (11)\n    create clone of (_myself_ v)\n    turn right (40) degrees\nend\n\nwhen I receive [connected v]\nrepeat (10)\n    change [ghost v] effect by (10)\nend\ndelete this clone\n\nwhen I start as a clone\nshow\nset [ghost v] effect to (100)\nforever\n    repeat (20)\n        turn right (7.5) degrees\n        change [ghost v] effect by (-6)\n        change size by (1)\n    end\n    repeat (20)\n        turn right (7.5) degrees\n        change [ghost v] effect by (6)\n        change size by (-1)\n    end\nend\n\n@TN\n\nwhen flag clicked\ngo to x: (0) y: (0)\nset [ghost v] effect to (100)\n\ngo to [front v] layer\nset [collected v] to [0]\nhide variable [collected v]\nhide variable [achievements v]\nhide variable [mouse x,y v]\n\n@stats\n\nwhen flag clicked\ngo to [front v] layer\nhide\n\nwhen I receive [begin v]\nshow\n\nhide\n\ngo to [front v] layer\n\n@Glow 1\n\nwhen I receive [equip glow 2 v]\nhide\n\nwhen flag clicked\nhide\n\nwhen I receive [equip glow 1 v]\nshow\nforever\n    go to (player v)\nend\n\nwhen I receive [unequip glow 1 v]\nhide\n\nwhen I receive [equip glow 3 v]\nhide\n\n@Glow 2\n\nwhen I receive [equip glow 2 v]\nshow\nforever\n    go to (player v)\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [equip glow 1 v]\nhide\n\nwhen I receive [unequip glow 2 v]\nhide\n\nwhen I receive [equip glow 3 v]\nhide\n\n@Glow 3\n\nwhen I receive [equip glow 2 v]\nhide\n\nwhen flag clicked\nhide\n\nwhen I receive [equip glow 3 v]\nshow\nforever\n    go to (player v)\nend\n\nwhen I receive [unequip glow 3 v]\nhide\n\nwhen I receive [equip glow 1 v]\nhide\n\n@SHOP Glow 1\n\nwhen flag clicked\ngo to x: (-17) y: (-40)\ngo to [front v] layer\nhide\nswitch costume to (costume1 v)\n\nwhen I receive [shop open v]\nif <not <(EXIT) = [win]>> then\n    show\nend\n\nwhen this sprite clicked\nif <(costume [number v]) = [2]> then\n    broadcast (Equip Glow 1 v)\nend\nif <<<(COLLECTED) > [3]> or <(COLLECTED) = [3]>> and <(costume [number v]) = [1]>> then\n    broadcast (buy glow 1 v)\nend\nif <(costume [number v]) = [3]> then\n    switch costume to (costume2 v)\n    broadcast (unequip glow 1 v)\nend\n\nwhen I receive [buy glow 1 v]\nswitch costume to (costume2 v)\nchange [collected v] by (-3)\n\nwhen I receive [shop close v]\nhide\n\nwhen I receive [equip glow 1 v]\nswitch costume to (costume3 v)\n\nwhen I receive [equip glow 2 v]\nif <(costume [number v]) = [3]> then\n    switch costume to (costume2 v)\nend\n\nwhen I receive [equip glow 3 v]\nif <(costume [number v]) = [3]> then\n    switch costume to (costume2 v)\nend\n\nwhen I receive [tick v]\ngo to [front v] layer\n\n@SHOP Glow 2\n\nwhen I receive [shop open v]\nif <not <(EXIT) = [win]>> then\n    show\nend\n\nwhen flag clicked\ngo to x: (130) y: (-40)\ngo to [front v] layer\nhide\nswitch costume to (costume1 v)\n\nwhen I receive [shop close v]\nhide\n\nwhen this sprite clicked\nif <(costume [number v]) = [2]> then\n    broadcast (Equip Glow 2 v)\nend\nif <(costume [number v]) = [3]> then\n    switch costume to (costume2 v)\n    broadcast (unequip glow 2 v)\nend\n\nwhen I receive [thanks v]\nswitch costume to (costume2 v)\n\nwhen I receive [equip glow 2 v]\nswitch costume to (costume3 v)\n\nwhen I receive [equip glow 1 v]\nif <(costume [number v]) = [3]> then\n    switch costume to (costume2 v)\nend\n\nwhen I receive [equip glow 3 v]\nif <(costume [number v]) = [3]> then\n    switch costume to (costume2 v)\nend\n\nwhen I receive [tick v]\ngo to [front v] layer\n\n@SHOP Glow 3\n\nwhen I receive [shop open v]\nif <not <(EXIT) = [win]>> then\n    show\nend\n\nwhen flag clicked\ngo to x: (-17) y: (-100)\ngo to [front v] layer\nhide\nswitch costume to (costume1 v)\n\nwhen this sprite clicked\nif <(costume [number v]) = [2]> then\n    broadcast (equip glow 3 v)\nend\nif <<<(COLLECTED) > [6]> or <(COLLECTED) = [6]>> and <(costume [number v]) = [1]>> then\n    broadcast (buy glow 3 v)\nend\nif <(costume [number v]) = [3]> then\n    switch costume to (costume2 v)\n    broadcast (unequip glow 3 v)\nend\n\nwhen I receive [buy glow 3 v]\nswitch costume to (costume2 v)\nchange [collected v] by (-6)\n\nwhen I receive [shop close v]\nhide\n\nwhen I receive [equip glow 3 v]\nswitch costume to (costume3 v)\n\nwhen I receive [equip glow 2 v]\nif <(costume [number v]) = [3]> then\n    switch costume to (costume2 v)\nend\n\nwhen I receive [equip glow 1 v]\nif <(costume [number v]) = [3]> then\n    switch costume to (costume2 v)\nend\n\nwhen I receive [tick v]\ngo to [front v] layer\n\n@Achievements\n\nwhen flag clicked\nhide\ngo to x: (65) y: (-125)\n\nwhen I receive [begin v]\nswitch costume to (costume3 v)\nset [deaths v] to [0]\nset [jumps v] to [0]\nset [checkachieve1 v] to [0]\nset [checkachieve5 v] to [0]\nforever\n    wait (.2) seconds\n    if <<<(y position) < (mouse y)> and <mouse down?>> or <<key (up arrow v) pressed?> or <key (w v) pressed?>>> then\n        change [jumps v] by (1)\n    end\n    if <<(jumps) = [10]> and <(CHECKachieve1) = [0]>> then\n        broadcast (achievement 1  v)\n        set [checkachieve1 v] to [1]\n    end\n    if <<(jumps) = [50]> and <(CHECKachieve5) = [0]>> then\n        broadcast (achievement5 v)\n        set [checkachieve5 v] to [1]\n    end\nend\n\nwhen I receive [begin v]\nset [checkachieve2 v] to [0]\nforever\n    if <<<(LOVED__) = [1]> and <(FAVED___) = [1]>> and <(CHECKachieve2) = [0]>> then\n        broadcast (achievement 2 v)\n    end\nend\n\nwhen I receive [achievement 1  v]\nstart sound [Pop v]\nswitch costume to (costume3 v)\nshow\nchange [achievements# v] by (1)\nwait (5) seconds\nhide\n\nwhen I receive [achievement 2 v]\nset [checkachieve2 v] to [1]\nstart sound [Pop v]\nswitch costume to (costume2 v)\nshow\nchange [achievements# v] by (1)\nwait (5) seconds\nhide\n\nwhen I receive [buy glow 1 v]\nbroadcast (achievement 3 v)\n\nwhen I receive [achievement 3 v]\nstart sound [Pop v]\nswitch costume to (costume4 v)\nshow\nchange [achievements# v] by (1)\nwait (5) seconds\nhide\n\nwhen I receive [begin v]\nset [checkachieve4 v] to [0]\nforever\n    if <<(Checkpoint) = [3]> and <(CHECKachieve4) = [0]>> then\n        broadcast (achievement 4 v)\n    end\nend\n\nwhen I receive [achievement 4 v]\nset [checkachieve4 v] to [1]\nstart sound [Pop v]\nswitch costume to (costume5 v)\nshow\nchange [achievements# v] by (1)\nwait (5) seconds\nhide\n\nwhen I receive [achievement5 v]\nstart sound [Pop v]\nswitch costume to (costume6 v)\nshow\nchange [achievements# v] by (1)\nwait (5) seconds\nhide\n\nwhen I receive [buy glow 3 v]\nbroadcast (achievement 6 v)\n\nwhen I receive [achievement 6 v]\nstart sound [Pop v]\nswitch costume to (costume7 v)\nshow\nchange [achievements# v] by (1)\nwait (5) seconds\nhide\n\nwhen I receive [death check v]\nchange [deaths v] by (1)\nif <(deaths) = [10]> then\n    broadcast (achievement 7 v)\nend\n\nwhen I receive [achievement 7 v]\nstart sound [Pop v]\nswitch costume to (costume8 v)\nshow\nchange [achievements# v] by (1)\nwait (5) seconds\nhide\n\nwhen I receive [achievement 8 v]\nstart sound [Pop v]\nswitch costume to (costume9 v)\nshow\nchange [achievements# v] by (1)\nwait (5) seconds\nhide\n\nwhen flag clicked\nhide variable [achievements v]\nset [achievements# v] to [0]\nforever\n    set [achievements v] to (join (achievements#) [/8])\n    if <(achievements#) > [8]> then\n        set [achievements# v] to [8]\n    end\nend\n\nwhen I receive [begin v]\nshow variable [achievements v]\n\nwhen I receive [theend v]\nbroadcast (achievement 9 v)\n\nwhen I receive [begin v]\nset [checkachieve 9 v] to [0]\n\nwhen I receive [achievement 9 v]\ngo to [front v] layer\nstart sound [Pop v]\nswitch costume to (costume10 v)\nshow\nchange [achievements# v] by (1)\nwait (7) seconds\nhide\n\n@Ending\n\nwhen flag clicked\nhide\n\nwhen I receive [theend v]\nshow\nset [ghost v] effect to (100)\nhide variable [achievements v]\nhide variable [collected v]\nforever\n    go to [front v] layer\n    change [ghost v] effect by (-2)\nend\n\nhide\n\n@Exit\n\nset [exit v] to [win]\n\nwhen I receive [green flag v]\nhide\n\nwhen I receive [tick v]\nswitch costume to (open v)\nPosition ((Exit: x) - (SCROLL X)) ((Exit: y) - (SCROLL Y))\nif <<<touching (player v)?> and <(costume [number v]) = [1]>> and <(CHECKachieve 9) = [0]>> then\n    set [checkachieve 9 v] to [1]\n    broadcast (TheEND v)\n    set [exit v] to [win]\nend\n\nwhen I receive [setup v]\nhide\nset [exit: x v] to [0]\nset [exit: y v] to [0]\nif <(LEVEL) = [1]> then\n    switch costume to (open v)\n    Clone at x: [12157] y: [580]\nend\n\ndefine Position (x) (y)\ngo to [back v] layer\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 [exit: x v] to (x)\nset [exit: y v] to (y)\n\nshow\n\n@Inacitve\n\nwhen flag clicked\nset [inactivity v] to [0]\nhide\nforever\n    wait (1) seconds\n    change [inactivity v] by (1)\nend\n\nwhen flag clicked\nforever\n    if <<key (any v) pressed?> or <mouse down?>> then\n        set [inactivity v] to [0]\n    end\n    if <(inactivity) > [120]> then\n        broadcast (INACTIVE v)\n    end\nend\n\nwhen I receive [inactive v]\nshow\ngo to [front v] layer\ngo to [front v] layer\ngo to [front v] layer\nstop [all v]\n\nhide\n\n