Icey (#3) - A Platformer #Games #All #Platformer #Trending

Instructions: ✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪\nMinecraft Platformer 4\nhttps://scratch.mit.edu/projects/554690423/\n✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪✪\n=========================================\nEpisode 2 https://scratch.mit.edu/projects/337665977\nEpisode 3 https://scratch.mit.edu/projects/348650899/\n\nMinecraft Platformer - Episode 1 \n\n➊ Use ARROW keys, ASDW, touchscreen or mouse.\n➋ Press SPACEBAR to chop, hit or craft.\n\nLevel 1 has a tutorial to get you started...\n\nFirst 100 to love and comment win chance to be added  to the credit crew!\n\n---------- IPad, tablet, and mobile friendly ---------\n\n-----------------------Search Tags-----------------------\n#games #minecraft  #platformer #platform #music #1  #animation #atomicmagicnumber  #episode #mobile\n---------------------------------------------------------------\nPro tip - to thank you for reading this stuff:\n\nHUGE BONUS CHESTS for completing levels FAST!\nMAX of 5 CHEST per level for ULTRA FAST players!\nYes, it is possible to get all the chests... but it is hard - getting even one chest a level is a huge achievement.

@Stage\n\nwhen flag clicked\nset [power v] to [none]\nset [kill v] to [0]\n\nwhen I receive [reset v]\nwait until <(ready) = [1]>\nforever\n    repeat until <([dead v] of [player v]) = [1]>\n        switch backdrop to (LEVEL)\n        if <(Camera X) > (item (LEVEL) of [pizzax v])> then\n            stop all sounds\n            play sound [Goal v] until done\n            broadcast (win v)\n            wait until <(Camera X) < (item (LEVEL) of [pizzax v])>\n        end\n    end\n    stop all sounds\n    play sound [Death v] until done\n    wait until <([dead v] of [player v]) = [0]>\nend\n\nwhen I receive [reset v]\nforever\n    if <([dead v] of [player v]) = [0]> then\n        if <(Camera X) < (item (LEVEL) of [pizzax v])> then\n            play sound (join [Level ] (LEVEL)) until done\n        end\n    end\nend\n\nwhen I receive [reset v]\nforever\n    wait until <(Camera X) > (((((item (LEVEL) of [pizzax v]) - (item (LEVEL) of [spawnx v])) / (2)) * ((checkpoint) + (1))) + (item (LEVEL) of [spawnx v]))>\n    change [checkpoint v] by (1)\nend\n\n@Player\n\nset [camera y v] to (Y)\nchange [camera x v] by (((X) - (Camera X)) / (5))\nchange [camera y v] by (((Y) - (Camera Y)) / (5))\n\ndefine Position\nset x to ((X) - (Camera X))\nset y to ((Y) - (Camera Y))\n\ndefine Loop\nPosition\nchange [x v] by (Xvel)\nchange [y v] by (Yvel)\nset [xvel v] to ((Xvel) * (0.96))\nset [yvel v] to ((Yvel) * (0.96))\nset [moving v] to [0]\nhit-test\nset [dead v] to [0]\nif <(Y) < [-180]> then\n    set [dead v] to [1]\nend\nif <touching (virus v)?> then\n    set [dead v] to [1]\nend\nif <(ground pound) = [0]> then\n    set [moving v] to [1]\n    set [push v] to [0]\n    if <(bite) = [1]> then\n        set [moving v] to [0]\n    else\n        if <<key (d v) pressed?> or <key (right arrow v) pressed?>> then\n            if <(ice) = [1]> then\n                change [xvel v] by ((3) - ([abs v] of (Xvel) ))\n            else\n                change [xvel v] by ((5) - ([abs v] of (Xvel) ))\n            end\n            point in direction (90)\n        else\n            if <<key (a v) pressed?> or <key (left arrow v) pressed?>> then\n                if <(ice) = [1]> then\n                    change [xvel v] by ((-3) - ((0) - ([abs v] of (Xvel) )))\n                else\n                    change [xvel v] by ((-5) - ((0) - ([abs v] of (Xvel) )))\n                end\n                point in direction (-90)\n            else\n                set [moving v] to [0]\n            end\n        end\n    end\n    if <(xcollision) = [1]> then\n        Collision\n        set [xvel v] to [0]\n        set [moving v] to [0]\n        if <<key (d v) pressed?> or <key (right arrow v) pressed?>> then\n            set [push v] to [1]\n        else\n            if <<key (a v) pressed?> or <key (left arrow v) pressed?>> then\n                set [push v] to [1]\n            else\n                set [moving v] to [0]\n            end\n        end\n    end\nend\nif <key (space v) pressed?> then\n    set [bite v] to [1]\nend\nif <(ycollision) = [1]> then\n    Collision\n    if <(Yvel) < [0]> then\n        start sound (join [Footstep] (LEVEL))\n    end\n    set [yvel v] to [0]\n    set [jump v] to [0]\n    if <(ground pound) > [0]> then\n        change [ground pound v] by (-0.25)\n    end\n    if <<key (w v) pressed?> or <key (up arrow v) pressed?>> then\n        start sound [Jump v]\n        set [jump v] to [1]\n        set [yvel v] to ((7) + ((Xvel) * (0.25)))\n    end\n    if <(bite) = [1]> then\nelse\n    change [yvel v] by (-0.5)\nend\nif <(ice) = [1]> then\n    set [xvel v] to ((Xvel) * (0.96))\nelse\n    set [xvel v] to ((Xvel) * (0.8))\nend\nCollision\n\ndefine Collision\nset [ice v] to [0]\nswitch costume to (up v)\nif <<touching (level v)?> or <touching (frozen v)?>> then\n    change [yvel v] by ((0) - ([abs v] of (Yvel) ))\n    repeat until <not <<touching (level v)?> or <touching (frozen v)?>>>\n        change [y v] by (-1)\n        Position\n    end\nend\nswitch costume to (side v)\nif <(xcollision) = [1]> then\n    if <(direction) > [0]> then\n        repeat until <not <<touching (level v)?> or <touching (frozen v)?>>>\n            change [x v] by (-1)\n            Position\n        end\n        change [x v] by (1)\n        Position\n    else\n        repeat until <not <<touching (level v)?> or <touching (frozen v)?>>>\n            change [x v] by (1)\n            Position\n        end\n        change [x v] by (-1)\n        Position\n    end\nend\nswitch costume to (down v)\nif <(ycollision) = [1]> then\n    if <touching (frozen v)?> then\n        set [ice v] to [1]\n    end\n    repeat until <not <<touching (level v)?> or <touching (frozen v)?>>>\n        change [y v] by (1)\n        Position\n    end\n    change [y v] by (-1)\n    Position\nend\n\ndefine hit-test\nswitch costume to (side v)\nset [xcollision v] to [0]\nif <<touching (level v)?> or <touching (frozen v)?>> then\n    set [xcollision v] to [1]\nend\nswitch costume to (down v)\nset [ycollision v] to [0]\nif <<touching (level v)?> or <touching (frozen v)?>> then\n    set [ycollision v] to [1]\nend\n\ndefine Animation\nif <(bite) = [1]> then\n    change [biteanim v] by (0.25)\n    if <(biteanim) > [2]> then\n        if <key (space v) pressed?> then\n            set [biteanim v] to [2]\n        else\n            set [bite v] to [0]\n            set [biteanim v] to [1]\n        end\n    end\n    if <(ycollision) = [0]> then\n        set [animation v] to [1]\n        if <([abs v] of (Yvel) ) > [5]> then\n            switch costume to (join [Jump1Bite] (round (biteanim)))\n        else\n            if <([abs v] of (Yvel) ) > [3.5]> then\n                switch costume to (join [Jump2Bite] (round (biteanim)))\n            else\n                if <([abs v] of (Yvel) ) > [2.5]> then\n                    switch costume to (join [Jump3Bite] (round (biteanim)))\n                else\n                    switch costume to (join [Jump4Bite] (round (biteanim)))\n                end\n            end\n        end\n    else\n        switch costume to (join [Bite] (round (biteanim)))\n    end\nelse\n    set [biteanim v] to [1]\n    if <(ycollision) = [0]> then\n        set [animation v] to [1]\n        if <([abs v] of (Yvel) ) > [5]> then\n            switch costume to (jump1 v)\n        else\n            if <([abs v] of (Yvel) ) > [3.5]> then\n                switch costume to (jump2 v)\n            else\n                if <([abs v] of (Yvel) ) > [2.5]> then\n                    switch costume to (jump3 v)\n                else\n                    switch costume to (jump4 v)\n                end\n            end\n        end\n    else\n        if <(push) = [1]> then\n            switch costume to (pushh v)\n        else\n            if <(moving) = [1]> then\n                change [animation v] by (([abs v] of (Xvel) ) / (5))\n                if <(animation) > [9]> then\n                    start sound (join [Footstep] (LEVEL))\n                    set [animation v] to [1]\n                end\n                switch costume to (join [Walk] (round (animation)))\n            else\n                set [animation v] to [1]\n                switch costume to (stance v)\n            end\n        end\n    end\nend\n\nwhen I receive [reset v]\nstop [other scripts in sprite v]\nshow\npoint in direction (90)\nset [dead v] to [0]\nset [camera x v] to (((item (LEVEL) of [spawnx v]) + (150)) + ((((item (LEVEL) of [pizzax v]) - (item (LEVEL) of [spawnx v])) / (2)) * (checkpoint)))\nset [camera y v] to [0]\nset [x v] to ((item (LEVEL) of [spawnx v]) + ((((item (LEVEL) of [pizzax v]) - (item (LEVEL) of [spawnx v])) / (2)) * (checkpoint)))\nset [xvel v] to [0]\nset [yvel v] to [0]\nset [y v] to [100]\nPosition\nswitch costume to (stance v)\nwait until <(ready) = [1]>\nwait (0.1) seconds\nforever\n    Loop\n    Animation\n    if <(X) > (Camera X)> then\n        set [camera x v] to (X)\n        Position\n    end\n    if <(dead) = [1]> then\n        switch costume to (dead v)\n        set [bite v] to [0]\n        set [yvel v] to [10]\n        wait (0.25) seconds\n        repeat until <(Y) < [-240]>\n            change [y v] by (Yvel)\n            Position\n            change [yvel v] by (-0.5)\n        end\n        change [life v] by (-1)\n        set [power v] to [none]\n        broadcast (fade v) and wait\n        set [ready v] to [0]\n        set [y v] to [-50]\n        Position\n        if <(LIFE) < [1]> then\n            broadcast (game over v)\n            broadcast (fadeo v)\n        else\n            broadcast (reset v)\n            broadcast (fadeo v)\n        end\n        stop [this script v]\n    end\n    if <(X) > (item (LEVEL) of [pizzax v])> then\n        set [x v] to (item (LEVEL) of [pizzax v])\n        repeat until <touching (level v)?>\n            change [y v] by (Yvel)\n            Position\n            change [yvel v] by (-0.5)\n        end\n        Collision\n        Animation\n        switch costume to (goal v)\n        wait (6) seconds\n        broadcast (pizza v)\n        stop [this script v]\n    end\nend\n\nwhen flag clicked\nset [ready v] to [0]\nif <(played?) = [0]> then\n    broadcast (legend v)\n    hide\nelse\n    broadcast (reset v)\n    broadcast (fadeo v)\nend\n\nif <<key (s v) pressed?> or <key (down arrow v) pressed?>> then\n    set [xvel v] to [0]\n    set [ground pound v] to [1]\n    change [yvel v] by (-5)\nend\n\n@Level\n\ndefine Position\nset x to ((X) - (Camera X))\nset y to ((Y) - (Camera Y))\nif <((X) - (Camera X)) < [-480]> then\n    next costume\n    next costume\n    change [x v] by (960)\nelse\n    set [ready v] to [1]\nend\n\nwhen I start as a clone\nshow\nforever\n    Loop\nend\n\nwhen I receive [reset v]\ngo to x: (-2) y: (0)\nif <[0] = [0]> then\n    delete this clone\nend\nwait (0.01) seconds\nset [x v] to [0]\nset [y v] to [1]\nswitch costume to (1 v)\nLevel\nswitch costume to (costume1 v)\nset [ghost v] effect to (100)\n\ndefine Level\nrepeat (2)\n    create clone of (_myself_ v)\n    next costume\n    change [x v] by (480)\nend\n\ndefine Loop\nset [ghost v] effect to (100)\nPosition\n\n@Heart\n\ndefine Hearts\nrepeat ((LIFE) - (1))\n    create clone of (_myself_ v)\n    change x by (15)\n    if <(x position) > [-85]> then\n        set x to (-220)\n        change y by (-15)\n    end\nend\n\nwhen I receive [reset v]\ngo to x: (-220) y: (90)\nrepeat (1)\n    delete this clone\nend\nshow\nswitch costume to (heart v)\nset size to (20) %\nHearts\nforever\n    repeat (10)\n        change size by (0.5)\n    end\n    repeat (10)\n        change size by (-0.5)\n    end\nend\n\nwhen I receive [reset v]\nforever\n    wait until <(kill) > [4]>\n    play sound [life v] until done\n    go to x: (-220) y: (90)\n    repeat (1)\n        delete this clone\n    end\n    set [kill v] to [0]\n    change [life v] by (1)\n    show\n    switch costume to (heart v)\n    Hearts\nend\n\nwhen I start as a clone\nswitch costume to (heart v)\nset size to (20) %\n\nwhen flag clicked\nhide\n\n@Kills\n\nwhen I receive [reset v]\ngo to x: (-180) y: (110)\nshow\nswitch costume to (0 v)\nset size to (20) %\nforever\n    set [ghost v] effect to (10)\n    switch costume to ((kill) + (1))\nend\n\nwhen flag clicked\nhide\n\n@Power\n\nwhen I receive [reset v]\ngo to x: (205) y: (100)\nshow\nset size to (20) %\nforever\n    switch costume to (POWER)\nend\n\nwhen flag clicked\nhide\n\n@Pizza\n\nwhen I receive [reset v]\ngo to x: (205) y: (55)\nshow\nset size to (20) %\nforever\n    switch costume to (PIZZA)\nend\n\nwhen I receive [legend v]\nhide\n\nwhen I receive [pizza v]\nrepeat (10)\n    change x by ((205) / (-10))\n    change y by ((55) / (-10))\n    change size by (((100) - (20)) / (10))\nend\nwait (1) seconds\nstart sound [Get v]\nchange [pizza v] by (1)\nwait (2) seconds\nbroadcast (Fade v) and wait\nset [ready v] to [0]\nchange [level v] by (1)\nif <(LEVEL) = [2]> then\n    broadcast (enjoy v)\nelse\n    broadcast (reset v)\nend\nset [checkpoint v] to [0]\nbroadcast (FadeO v)\n\n@Border\n\nwhen flag clicked\nset [checkpoint? v] to [0]\nswitch costume to (border v)\nshow\nforever\n    go to [front v] layer\nend\n\nif <(cheated?) = [1]> then\n    hide\nend\n\nswitch costume to (newthumb v)\ngo to [front v] layer\nshow\nset [played? v] to [0]\nset [gameovers v] to [0]\nset [level v] to [1]\nset [pizza v] to [1]\nset [life v] to [3]\nset [cheated? v] to [0]\nset [shadow v] to [0]\n\n@Fade\n\nwhen I receive [fade v]\nshow\nset [ghost v] effect to (100)\nrepeat (10)\n    change [ghost v] effect by (-10)\n    go to [front v] layer\nend\n\nwhen I receive [fadeo v]\nshow\nset [ghost v] effect to (0)\nwait until <(ready) = [1]>\nwait (0.1) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    go to [front v] layer\nend\nhide\n\n@Levelfg\n\ndefine Position\nset x to ((X) - (Camera X))\nset y to ((Y) - (Camera Y))\nif <((X) - (Camera X)) < [-480]> then\n    next costume\n    next costume\n    change [x v] by (960)\nend\n\nwhen I start as a clone\nshow\nforever\n    Loop\nend\n\nwhen I receive [reset v]\ngo to x: (0) y: (0)\nwait (0.01) seconds\nif <[0] = [0]> then\n    delete this clone\nend\nset [x v] to [0]\nset [y v] to [0]\nswitch costume to (1fg v)\nLevel\nswitch costume to (costume1 v)\nset [ghost v] effect to (100)\n\ndefine Level\nrepeat (2)\n    create clone of (_myself_ v)\n    next costume\n    change [x v] by (480)\nend\n\ndefine Loop\nset [ghost v] effect to (0)\nPosition\n\n@Levelmg\n\nwhen I receive [reset v]\ngo to x: (0) y: (0)\nwait (0.01) seconds\nif <[0] = [0]> then\n    delete this clone\nend\nset [x v] to [0]\nset [y v] to [0]\nswitch costume to (mg v)\nif <<(LEVEL) = [1]> or <(LEVEL) = [3]>> then\n    Level\nend\nswitch costume to (costume1 v)\nset [ghost v] effect to (100)\n\ndefine Level\nrepeat (2)\n    set size to (pick random (75) to (100)) %\n    change [y v] by (pick random (-10) to (10))\n    create clone of (_myself_ v)\n    change [x v] by (960)\nend\n\ndefine Position\nset x to (((X) - (Camera X)) / (2))\nset y to (((Y) - (Camera Y)) / (2))\nchange [x v] by ((size) * (-0.01))\nif <(((X) - (Camera X)) / (2)) < [-480]> then\n    set size to (pick random (75) to (100)) %\n    change [y v] by (pick random (-10) to (10))\n    change [x v] by (1920)\nend\n\nwhen I start as a clone\nshow\nforever\n    Loop\nend\n\ndefine Loop\nset [ghost v] effect to (25)\nPosition\n\n@Not Suspicious\n\nwhen flag clicked\ndelete (all) of [prompt v]\nshow list [prompt v]\nforever\n    if <key (c v) pressed?> then\n        set [cheated? v] to [1]\n        hide list [prompt v]\n        c\n    end\nend\n\ndefine c\nforever\n    ask [] and wait\n    add (join [>] (answer)) to [prompt v]\n    if <(answer) = [level skip]> then\n        broadcast (Fade v) and wait\n        change [level v] by (1)\n        broadcast (reset v)\n        broadcast (FadeO v)\n    else\n        if <(answer) = [set level]> then\n            add (join [     ] [input level:]) to [prompt v]\n            ask [] and wait\n            add (join [>] (answer)) to [prompt v]\n            if <<(answer) > [0]> and <(answer) < ((length of [pizzax v]) + (1))>> then\n                broadcast (Fade v) and wait\n                set [level v] to (answer)\n                add (join [     ] (join [level ] (join (LEVEL) [ selected]))) to [prompt v]\n                broadcast (reset v)\n                broadcast (FadeO v)\n            else\n                add (join [     ] (join [invalid request "] (join (answer) ["]))) to [prompt v]\n            end\n        else\n            if <(answer) = [set lives]> then\n                add (join [     ] [input lives:]) to [prompt v]\n                ask [] and wait\n                add (join [>] (answer)) to [prompt v]\n                set [numeral v] to (answer)\n                if <<(answer) > [0]> and <(answer) < [51]>> then\n                    add (join [     ] [request will reset level, continue?]) to [prompt v]\n                    ask [] and wait\n                    add (join [>] (answer)) to [prompt v]\n                    if <(answer) = [yes]> then\n                        broadcast (Fade v) and wait\n                        set [life v] to (numeral)\n                        add (join [     ] (join [lives set to ] (numeral))) to [prompt v]\n                        broadcast (reset v)\n                        broadcast (FadeO v)\n                    else\n                        add (join [     ] [request cancelled]) to [prompt v]\n                    end\n                else\n                    add (join [     ] (join [invalid request "] (join (answer) ["]))) to [prompt v]\n                end\n            else\n                if <(answer) = [set power]> then\n                    add (join [     ] [input power:]) to [prompt v]\n                    ask [] and wait\n                    add (join [>] (answer)) to [prompt v]\n                    if <(answer) = [ice]> then\n                        set [power v] to (answer)\n                        add (join [     ] (join [power set to ] (answer))) to [prompt v]\n                    else\n                        if <(answer) = [lightning]> then\n                            set [power v] to (answer)\n                            add (join [     ] (join [power set to ] (answer))) to [prompt v]\n                        else\n                            if <(answer) = [fire]> then\n                                set [power v] to (answer)\n                                add (join [     ] (join [power set to ] (answer))) to [prompt v]\n                            else\n                                if <(answer) = [none]> then\n                                    set [power v] to (answer)\n                                    add (join [     ] (join [power set to ] (answer))) to [prompt v]\n                                else\n                                    add (join [     ] (join [invalid request "] (join (answer) ["]))) to [prompt v]\n                                end\n                            end\n                        end\n                    end\n                else\n                    if <(answer) = [shadow on = true]> then\n                        add (join [     ] [request will reset level, continue?]) to [prompt v]\n                        ask [] and wait\n                        add (join [>] (answer)) to [prompt v]\n                        if <(answer) = [yes]> then\n                            broadcast (Fade v) and wait\n                            set [shadow v] to [1]\n                            add (join [     ] (join [shadow on set to ] [true])) to [prompt v]\n                            broadcast (reset v)\n                            broadcast (FadeO v)\n                        else\n                            add (join [     ] [request cancelled]) to [prompt v]\n                        end\n                    else\n                        if <(answer) = [shadow on = false]> then\n                            add (join [     ] [request will reset level, continue?]) to [prompt v]\n                            ask [] and wait\n                            add (join [>] (answer)) to [prompt v]\n                            if <(answer) = [yes]> then\n                                broadcast (Fade v) and wait\n                                set [shadow v] to [0]\n                                add (join [     ] (join [shadow on set to ] [false])) to [prompt v]\n                                broadcast (reset v)\n                                broadcast (FadeO v)\n                            else\n                                add (join [     ] [request cancelled]) to [prompt v]\n                            end\n                        else\n                            if <(answer) = [exit]> then\n                                show list [prompt v]\n                                stop [this script v]\n                            else\n                                add (join [     ] (join [invalid request "] (join (answer) ["]))) to [prompt v]\n                            end\n                        end\n                    end\n                end\n            end\n        end\n    end\nend\n\n@Virus\n\nwhen I receive [reset v]\nhide\ngo to x: (0) y: (0)\npoint in direction (150)\nset [direction v] to [150]\nif <[0] = [0]> then\n    delete this clone\nend\nwait until <(ready) = [1]>\nset [clone v] to [1]\nrepeat (length of [level1virus v])\n    set [test v] to [0]\n    set [x v] to (item (clone) of [level1virus v])\n    set [y v] to [-100]\n    switch costume to (join [Virus] (item (clone) of [level1virustype v]))\n    set [type v] to (costume [number v])\n    wait until <((X) - (Camera X)) < [240]>\n    create clone of (_myself_ v)\n    change [clone v] by (1)\nend\n\nwhen I start as a clone\nshow\nrepeat until <((X) - (Camera X)) < [-240]>\n    repeat (20)\n        Loop\n        point in direction (direction)\n        if <([dead v] of [player v]) = [0]> then\n            if <(test) = [0]> then\n                turn left (3) degrees\n                change [x v] by (-1.2)\n            else\n                turn left (-3) degrees\n                change [x v] by (1.2)\n            end\n        end\n        set [direction v] to (direction)\n        thing\n    end\n    repeat (5)\n        Loop\n        if <((X) - (Camera X)) > [-210]> then\n            test\n        end\n        thing\n    end\nend\ndelete this clone\n\ndefine Position\nset x to ((X) - (Camera X))\nset y to ((Y) - (Camera Y))\n\ndefine Loop\nPosition\nset rotation style [all around v]\nswitch costume to (join [Virus] (item (clone) of [level1virustype v]))\npoint in direction (direction)\nrepeat until <not <touching (level v)?>>\n    change [y v] by (1)\n    Position\nend\nchange [y v] by (-3)\nif <((X) - (Camera X)) < [-240]> then\n    delete this clone\nend\n\ndefine test\nset rotation style [left-right v]\nif <(test) = [0]> then\n    point in direction (90)\nelse\n    point in direction (-90)\nend\nswitch costume to (test v)\nif <<touching (level v)?> or <touching (frozen v)?>> then\n    set [test v] to (test)\nelse\n    set [test v] to ((1) - (test))\nend\nswitch costume to (test2 v)\nif <<touching (level v)?> or <touching (frozen v)?>> then\n    set [test v] to ((1) - (test))\nelse\n    set [test v] to (test)\nend\nset rotation style [all around v]\nswitch costume to (join [Virus] (item (clone) of [level1virustype v]))\npoint in direction (direction)\nif <((X) - (Camera X)) > [-210]> then\n    repeat until <not <touching (level v)?>>\n        change [y v] by (1)\n        Position\n    end\n    change [y v] by (-3)\nend\n\ndefine thing\nif <touching (projectile v)?> then\n    if <(POWER) = [lightning]> then\n        if <<(type) = [1]> or <(type) = [2]>> then\n            start sound [SystemSE_0.aw_0000000a v]\n            repeat (10)\n                change [pixelate v] effect by (10)\n                change [ghost v] effect by (10)\n            end\n            change [kill v] by (1)\n            delete this clone\n        end\n    else\n        if <(POWER) = [fire]> then\n            if <<(type) = [1]> or <(type) = [3]>> then\n                start sound [SystemSE_0.aw_0000000a v]\n                repeat (10)\n                    change [pixelate v] effect by (10)\n                    change [ghost v] effect by (10)\n                end\n                change [kill v] by (1)\n                delete this clone\n            end\n        else\n            if <<(type) = [2]> or <(type) = [3]>> then\n                set [fx v] to (X)\n                set [fy v] to (Y)\n                set [ft v] to (type)\n                create clone of (frozen v)\n                change [kill v] by (1)\n                delete this clone\n            end\n        end\n    end\nend\n\nif <((X) - (Camera X)) > [-210]> then\nend\nif <not <(type) = [1]>> then\nend\n\n@Powerups\n\ndefine Position\nset x to ((X) - (Camera X))\nset y to ((Y) - (Camera Y))\n\ndefine Loop\nPosition\nset size to (15) %\nrepeat until <not <touching (level v)?>>\n    change [y v] by (1)\n    Position\nend\nchange [y v] by (-3)\nif <touching (player v)?> then\n    start sound [Powerup v]\n    set [power v] to (item (clone) of [level1powertype v])\n    delete this clone\nend\n\nwhen I receive [reset v]\nhide\ngo to x: (0) y: (0)\npoint in direction (90)\nif <[1] > [0]> then\n    delete this clone\nend\nwait until <(ready) = [1]>\nset [clone v] to [1]\nrepeat (length of [level1powertype v])\n    set [x v] to (item (clone) of [level1powerx v])\n    set [y v] to [-100]\n    switch costume to (item (clone) of [level1powertype v])\n    wait until <((X) - (Camera X)) < [240]>\n    create clone of (_myself_ v)\n    change [clone v] by (1)\nend\n\nwhen I start as a clone\nrepeat until <((X) - (Camera X)) < [-240]>\n    show\n    Loop\nend\ndelete this clone\n\nwhen I start as a clone\nforever\n    repeat (25)\n        change [brightness v] effect by (0.5)\n    end\n    repeat (25)\n        change [brightness v] effect by (-0.5)\n    end\nend\n\n@Projectile\n\nwhen I start as a clone\nset [type v] to (POWER)\nif <(POWER) = [lightning]> then\n    set [x v] to ([x v] of [player v])\n    set [y v] to (([y v] of [player v]) + (-10))\n    set [xvel v] to (([direction v] of [player v]) / (5))\n    set [yvel v] to [0]\n    start sound [lightning v]\n    repeat until <touching (_edge_ v)?>\n        if <([dead v] of [player v]) = [0]> then\n            show\n            lightning loop\n        end\n    end\n    delete this clone\nelse\n    set [x v] to ([x v] of [player v])\n    set [y v] to (([y v] of [player v]) + (10))\n    set [xvel v] to (([direction v] of [player v]) / (12))\n    point in direction ([direction v] of [player v])\n    set [yvel v] to [0]\n    start sound (join (POWER) [ball])\n    repeat until <<<touching (_edge_ v)?> or <touching (virus v)?>> or <touching (frozen v)?>>\n        if <([dead v] of [player v]) = [0]> then\n            show\n            ball loop\n        end\n    end\n    if <not <touching (_edge_ v)?>> then\n        start sound [Wall v]\n    end\n    delete this clone\nend\n\ndefine Position\nset x to ((X) - (Camera X))\nset y to ((Y) - (Camera Y))\n\ndefine ball loop\nPosition\npoint in direction (90)\nset [test v] to [0]\nswitch costume to (test v)\nif <not <touching (level v)?>> then\n    set [test v] to [1]\nend\nswitch costume to (type)\nchange [x v] by (Xvel)\nchange [y v] by (Yvel)\nchange [yvel v] by (-0.5)\nif <touching (level v)?> then\n    if <(test) = [1]> then\n        start sound [Wall v]\n        delete this clone\n    end\n    set [yvel v] to [6]\n    repeat until <not <touching (level v)?>>\n        change [y v] by (1)\n        Position\n    end\nend\n\nwhen I receive [reset v]\nhide\nif <[0] = [0]> then\n    delete this clone\nend\nforever\n    wait until <([bite v] of [player v]) = [1]>\n    if <(POWER) = [fire]> then\n        switch costume to (POWER)\n        create clone of (_myself_ v)\n    else\n        if <(POWER) = [ice]> then\n            switch costume to (POWER)\n            create clone of (_myself_ v)\n        else\n            if <(POWER) = [lightning]> then\n                switch costume to (POWER)\n                create clone of (_myself_ v)\n            else\n            end\n        end\n    end\n    repeat (15)\n    end\nend\n\ndefine lightning loop\nPosition\nchange [x v] by (Xvel)\nchange [y v] by (Yvel)\n\nwait until <([bite v] of [player v]) = [0]>\n\n@Shadow\n\ndefine Position\nset x to ((X) - (Camera X))\nset y to ((Y) - (Camera Y))\n\ndefine Loop\nswitch costume to (down v)\nset [x v] to ([x v] of [player v])\nset [y v] to ([y v] of [player v])\nPosition\nrepeat until <<<touching (level v)?> or <touching (_edge_ v)?>> or <touching (frozen v)?>>\n    change [y v] by (-1)\n    Position\nend\nchange [y v] by (-3)\nset [x v] to ([x v] of [player v])\nPosition\nswitch costume to (shadow v)\n\nwhen flag clicked\nhide\n\nwhen I receive [reset v]\nif <(shadow) = [1]> then\n    show\n    set [y v] to [0]\n    forever\n        if <([dead v] of [player v]) = [0]> then\n            Loop\n            set [ghost v] effect to (((distance to [player v]) * (0.4)) + (50))\n            show\n            set size to (((distance to [player v]) * (-0.1)) + (20)) %\n        else\n            set size to (0) %\n            hide\n        end\n    end\nend\n\n@Pizza Collect\n\nwhen I receive [reset v]\nhide\ngo to x: (0) y: (0)\npoint in direction (90)\nif <[1] > [0]> then\n    delete this clone\nend\nset [clone v] to [1]\nwait until <(ready) = [1]>\nset [x v] to (item (LEVEL) of [pizzax v])\nset [y v] to [0]\nwait until <((X) - (Camera X)) < [240]>\ncreate clone of (_myself_ v)\n\nwhen I start as a clone\nrepeat until <((X) - (Camera X)) < [-240]>\n    show\n    Loop\nend\ndelete this clone\n\ndefine Position\nset x to ((X) - (Camera X))\nset y to ((Y) - (Camera Y))\n\ndefine Loop\nPosition\nset size to (50) %\n\n@Prologue\n\nwhen I receive [reset v]\nhide\n\nwhen I receive [legend v]\nstart sound [Prologue v]\nshow\nswitch costume to (text1 v)\nset [ready v] to [1]\nbroadcast (fadeo v)\nwait (0.4) seconds\nswitch costume to (text2 v)\nrepeat (5)\n    wait until <key (space v) pressed?>\n    wait until <not <key (space v) pressed?>>\n    broadcast (fade v) and wait\n    broadcast (pnext v)\n    broadcast (fadeo v)\nend\nwait (0.5) seconds\nstart sound [nsmbwiiPressStart v]\nset [played? v] to [1]\n\nwhen I receive [pnext v]\nnext costume\n\n@Frozen\n\nwhen I receive [reset v]\nhide\ngo to x: (0) y: (0)\npoint in direction (150)\nwait (0.01) seconds\nif <[0] = [0]> then\n    delete this clone\nend\nset [clone v] to [1]\n\nwhen I start as a clone\nshow\nset [clone v] to (FT)\nset [x v] to (FX)\nset [y v] to (FY)\nstart sound [Freeze v]\nrepeat until <((X) - (Camera X)) < [-240]>\n    Loop\nend\ndelete this clone\n\ndefine Position\nset x to ((X) - (Camera X))\nset y to ((Y) - (Camera Y))\n\ndefine Loop\nPosition\nswitch costume to (clone)\npoint in direction (90)\nrepeat until <not <touching (level v)?>>\n    change [y v] by (1)\n    Position\nend\nchange [y v] by (-3)\n\n@GameOver\n\nwhen flag clicked\nhide\nset size to (0) %\n\nwhen I receive [game over v]\nswitch costume to (costume1 v)\nstop all sounds\nchange [gameovers v] by (1)\nwait (0.04) seconds\nswitch costume to (gameover v)\ngo to [front v] layer\nshow\nset size to (100) %\nset [life v] to [3]\nstart sound [Game Over v]\n\n@Level Completed!\n\nwhen flag clicked\nhide\n\nwhen I receive [reset v]\ngo to x: (0) y: (0)\npoint in direction (90)\nhide\nset size to (50) %\n\nwhen I receive [win v]\nshow\nstart sound [Win v]\nrepeat (5)\n    change size by (4)\n    change y by (7)\nend\n\n@Enjoy\n\nwhen flag clicked\nhide\nset size to (0) %\n\nwhen I receive [enjoy v]\nswitch costume to (costume1 v)\nwait (0.04) seconds\nstop all sounds\nswitch costume to (enjoy v)\ngo to [front v] layer\nshow\nset size to (100) %\nwait until <key (space v) pressed?>\nwait until <not <key (space v) pressed?>>\nbroadcast (Fade v) and wait\nhide\nset size to (0) %\nbroadcast (reset v)\nbroadcast (FadeO v)\n\n