The Ninja Squad 5 || A Mobile Friendly Platformer #games #all
@Stage\n\nwhen I receive [start v]\nset volume to (100) %\nforever\n    play sound [Ninja Music v] until done\nend\n\nwhen I receive [boss appears!!!!! v]\nrepeat (10)\n    change volume by (-10)\nend\nstop all sounds\nstop [other scripts in sprite v]\nset volume to (100) %\nwait (1) seconds\nforever\n    play sound [RoboBrood Battle Extended \(mp3cut v] until done\n    wait (1) seconds\nend\n\nwhen I receive [boss killed v]\nrepeat (10)\n    change volume by (-10)\nend\nstop all sounds\nstop [other scripts in sprite v]\n\n@Red Ninja\n\nwhen I receive [boss fight hit taken v]\nif <(which ninja?) = [1]> then\n    change [player health v] by (-1)\n    repeat (3)\n        repeat (10)\n            change [brightness v] effect by (7)\n        end\n        repeat (10)\n            change [brightness v] effect by (-7)\n        end\n    end\n    clear graphic effects\nend\n\ndefine Reset Level\ngo to x: (-180) y: (0)\nset [x v] to [0]\nset [y v] to [0]\nset [turn v] to [0]\npoint in direction (90)\nshow\n\nwhen I receive [play game v]\nforever\n    if <<touching (lava v)?> or <touching (light v)?>> then\n        change [y v] by (-0.3)\n        if <<<key (up arrow v) pressed?> or <key (w v) pressed?>> or <<mouse down?> and <(mouse y) > ((y position) + (10))>>> then\n            change [y v] by (2)\n        end\n        set [y v] to ((y) * (.9))\n    end\nend\n\nwhen flag clicked\nset [level v] to [1]\nset [which ninja? v] to [1]\nset [level deaths v] to [0]\nset [equipped? v] to [0]\nhide\n\nwhen I receive [play game v]\nbroadcast (Next v)\nReset Level\nforever\n    if <(in cutscene?) = [0]> then\n        if <(equipped?) > [1]> then\n            set [equipped? v] to [0]\n        end\n        if <(jump boost on/off) > [1]> then\n            set [jump boost on/off v] to [0]\n        end\n        if <(which ninja?) = [1]> then\n            show\n            if <key (r v) pressed?> then\n                Reset Level\n                broadcast (Next v)\n            end\n            if <<<key (right arrow v) pressed?> or <key (d v) pressed?>> or <<mouse down?> and <(mouse x) > (x position)>>> then\n                change [x v] by (.9)\n                change [turn v] by (.9)\n            end\n            if <<<key (left arrow v) pressed?> or <key (a v) pressed?>> or <<mouse down?> and <(mouse x) < (x position)>>> then\n                change [x v] by (-.9)\n                change [turn v] by (-.9)\n            end\n            set [x v] to ((x) * (.9))\n            change x by (x)\n            set [turn v] to ((turn) * (.9))\n            turn right (turn) degrees\n            if <touching (level v)?> then\n                change y by (1)\n                if <touching (level v)?> then\n                    change y by (1)\n                    if <touching (level v)?> then\n                        change y by (1)\n                        if <touching (level v)?> then\n                            change y by (1)\n                            if <touching (level v)?> then\n                                change y by (1)\n                                if <touching (level v)?> then\n                                    change [x v] by (((x) * (-1)) - (turn))\n                                    change x by ((turn) * (-1))\n                                    change y by (-5)\n                                end\n                            end\n                        end\n                    end\n                end\n            end\n            change [y v] by (-0.8)\n            change y by (y)\n            if <touching (level v)?> then\n                change y by ((y) * (-1))\n                set [y v] to [0]\n            end\n            change y by (-1)\n            if <touching (level v)?> then\n                if <<<key (up arrow v) pressed?> or <key (w v) pressed?>> or <<mouse down?> and <(mouse y) > ((y position) + (10))>>> then\n                    if <(equipped?) = [1]> then\n                        set [y v] to [15]\n                    else\n                        set [y v] to [12]\n                    end\n                end\n            end\n            change y by (1)\n            if <<<touching (spikes v)?> or <<<touching (long grass v)?> or <touching (water v)?>> or <touching (darkness v)?>>> or <(y position) < [-188]>> then\n                change [level deaths v] by (1)\n                broadcast (Die v)\n            end\n        else\n            hide\n            point in direction (90)\n            set [x v] to [0]\n            set [y v] to [0]\n            set [turn v] to [0]\n            set [equipped? v] to [0]\n            set [jump boost on/off v] to [0]\n            if <(which ninja?) = [2]> then\n                go to x: ([x position v] of [green ninja v]) y: ([y position v] of [green ninja v])\n            else\n                if <(which ninja?) = [3]> then\n                    if <(shrink boost on/off) = [0]> then\n                        go to x: ([x position v] of [blue ninja v]) y: ([y position v] of [blue ninja v])\n                    else\n                        go to x: ([x position v] of [blue ninja v]) y: (([y position v] of [blue ninja v]) + (20))\n                    end\n                else\n                    if <(which ninja?) = [4]> then\n                        go to x: ([x position v] of [black ninja v]) y: ([y position v] of [black ninja v])\n                    else\n                        go to x: ([x position v] of [light ninja v]) y: ([y position v] of [light ninja v])\n                    end\n                end\n            end\n        end\n    end\nend\n\nwhen I receive [play game v]\nforever\n    if <(boss fight?) = [0]> then\n        if <(x position) > [253]> then\n            go to x: (-255) y: (y position)\n            change [level v] by (1)\n            set [level deaths v] to [0]\n            broadcast (Next v)\n        end\n    end\nend\n\nwhen I receive [play game v]\nforever\n    if <(boss fight?) = [0]> then\n        if <key (space v) pressed?> then\n            broadcast (Jump Boost v)\n            wait until <not <key (space v) pressed?>>\n        end\n    else\n        set [jump boost on/off v] to [0]\n        set [equipped? v] to [0]\n    end\nend\n\nwhen I receive [jump boost v]\nchange [equipped? v] by (1)\nchange [jump boost on/off v] by (1)\n\nwhen I receive [play game v]\nforever\n    if <key (s v) pressed?> then\n        broadcast (Skip v)\n    end\nend\n\nwhen I receive [die v]\nif <(which ninja?) = [1]> then\n    set [death x v] to (x position)\n    set [death y v] to (y position)\n    Reset Level\n    stop [this script v]\nend\n\nwhen I receive [skip v]\nif <(allowed to skip) = [1]> then\n    change [level v] by (1)\n    set [level deaths v] to [0]\n    Reset Level\n    broadcast (Next v)\n    wait until <not <key (s v) pressed?>>\nend\n\nwhen I receive [boss appears!!!!! v]\nwait (0.5) seconds\ngo to x: (-180) y: (-68)\npoint in direction (90)\n\nwhen I receive [boss fight red v]\nshow\nclear graphic effects\ngo to x: (-180) y: (-68)\nforever\n    if <(which ninja?) = [1]> then\n        if <touching (boss v)?> then\n            broadcast (Boss Fight Hit Taken v)\n            wait (2.5) seconds\n        end\n    end\nend\n\nwhen I receive [boss fight die v]\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\n\nwhen I receive [stop end v]\nstop [other scripts in sprite v]\nhide\n\n@Green Ninja\n\ndefine Reset Level\ngo to x: (-180) y: (0)\nset [x v] to [0]\nset [y v] to [0]\nset [turn v] to [0]\npoint in direction (90)\nshow\n\nwhen I receive [play game v]\nset [equipped? v] to [0]\nReset Level\nforever\n    if <(in cutscene?) = [0]> then\n        if <(equipped?) > [1]> then\n            set [equipped? v] to [0]\n        end\n        if <(speed boost on/off) > [1]> then\n            set [speed boost on/off v] to [0]\n        end\n        if <(which ninja?) = [2]> then\n            show\n            if <<<key (right arrow v) pressed?> or <key (d v) pressed?>> or <<mouse down?> and <(mouse x) > (x position)>>> then\n                if <(equipped?) = [1]> then\n                    change [x v] by (1.3)\n                    change [turn v] by (1.3)\n                else\n                    change [x v] by (.9)\n                    change [turn v] by (.9)\n                end\n            end\n            if <<<key (left arrow v) pressed?> or <key (a v) pressed?>> or <<mouse down?> and <(mouse x) < (x position)>>> then\n                if <(equipped?) = [1]> then\n                    change [x v] by (-1.3)\n                    change [turn v] by (-1.3)\n                else\n                    change [x v] by (-.9)\n                    change [turn v] by (-.9)\n                end\n            end\n            set [x v] to ((x) * (.9))\n            change x by (x)\n            set [turn v] to ((turn) * (.9))\n            turn right (turn) degrees\n            if <touching (level v)?> then\n                change y by (1)\n                if <touching (level v)?> then\n                    change y by (1)\n                    if <touching (level v)?> then\n                        change y by (1)\n                        if <touching (level v)?> then\n                            change y by (1)\n                            if <touching (level v)?> then\n                                change y by (1)\n                                if <touching (level v)?> then\n                                    change [x v] by (((x) * (-1)) - (turn))\n                                    change x by ((turn) * (-1))\n                                    change y by (-5)\n                                end\n                            end\n                        end\n                    end\n                end\n            end\n            change [y v] by (-0.8)\n            change y by (y)\n            if <touching (level v)?> then\n                change y by ((y) * (-1))\n                set [y v] to [0]\n            end\n            change y by (-1)\n            if <touching (level v)?> then\n                if <<<key (up arrow v) pressed?> or <key (w v) pressed?>> or <<mouse down?> and <(mouse y) > ((y position) + (10))>>> then\n                    set [y v] to [12]\n                end\n            end\n            change y by (1)\n            if <(boss fight?) = [0]> then\n                if <<<touching (spikes v)?> or <<<touching (lava v)?> or <touching (water v)?>> or <touching (darkness v)?>>> or <(y position) < [-188]>> then\n                    change [level deaths v] by (1)\n                    broadcast (Die v)\n                end\n            end\n        else\n            hide\n            point in direction (90)\n            set [x v] to [0]\n            set [y v] to [0]\n            set [turn v] to [0]\n            set [equipped? v] to [0]\n            set [speed boost on/off v] to [0]\n            if <(which ninja?) = [1]> then\n                go to x: ([x position v] of [red ninja v]) y: ([y position v] of [red ninja v])\n            else\n                if <(which ninja?) = [3]> then\n                    if <(shrink boost on/off) = [0]> then\n                        go to x: ([x position v] of [blue ninja v]) y: ([y position v] of [blue ninja v])\n                    else\n                        go to x: ([x position v] of [blue ninja v]) y: (([y position v] of [blue ninja v]) + (20))\n                    end\n                else\n                    if <(which ninja?) = [4]> then\n                        go to x: ([x position v] of [black ninja v]) y: ([y position v] of [black ninja v])\n                    else\n                        go to x: ([x position v] of [light ninja v]) y: ([y position v] of [light ninja v])\n                    end\n                end\n            end\n        end\n    end\nend\n\nwhen I receive [play game v]\nforever\n    if <(boss fight?) = [0]> then\n        if <(x position) > [253]> then\n            go to x: (-255) y: (y position)\n            change [level v] by (1)\n            set [level deaths v] to [0]\n            broadcast (Next v)\n        end\n    end\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [play game v]\nforever\n    if <(which ninja?) = [2]> then\n        if <(boss fight?) = [0]> then\n            if <key (space v) pressed?> then\n                broadcast (Speed Boost v)\n                wait until <not <key (space v) pressed?>>\n            end\n        else\n            set [speed boost on/off v] to [0]\n            set [equipped? v] to [0]\n        end\n    end\nend\n\nwhen I receive [play game v]\nforever\n    if <<touching (long grass v)?> or <touching (light v)?>> then\n        change [y v] by (-0.3)\n        if <<<key (up arrow v) pressed?> or <key (w v) pressed?>> or <<mouse down?> and <(mouse y) > ((y position) + (10))>>> then\n            change [y v] by (2)\n        end\n        set [y v] to ((y) * (.9))\n    end\nend\n\nwhen I receive [speed boost v]\nchange [equipped? v] by (1)\nchange [speed boost on/off v] by (1)\n\nwhen I receive [die v]\nif <(which ninja?) = [2]> then\n    set [death x v] to (x position)\n    set [death y v] to (y position)\n    Reset Level\n    stop [this script v]\nend\n\nwhen I receive [skip v]\nif <(allowed to skip) = [1]> then\n    Reset Level\nend\n\nwhen I receive [transition v]\nwait (0.5) seconds\ngo to x: (-180) y: (-68)\npoint in direction (90)\n\nwhen I receive [boss fight green v]\nshow\nclear graphic effects\ngo to x: (-180) y: (-68)\nforever\n    if <(which ninja?) = [2]> then\n        if <touching (boss v)?> then\n            broadcast (Boss Fight Hit Taken v)\n            wait (2.5) seconds\n        end\n        if <(y position) < [-188]> then\n            Reset Level\n            broadcast (Boss Fight Hit Taken v)\n        end\n    end\nend\n\nwhen I receive [boss fight hit taken v]\nif <(which ninja?) = [2]> then\n    change [player health v] by (-1)\n    repeat (3)\n        repeat (10)\n            change [brightness v] effect by (7)\n        end\n        repeat (10)\n            change [brightness v] effect by (-7)\n        end\n    end\n    clear graphic effects\nend\n\nwhen I receive [boss fight die v]\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\n\nwhen I receive [stop end v]\nstop [other scripts in sprite v]\nhide\n\n@Blue Ninja\n\ndefine Reset Level\ngo to x: (-180) y: (0)\nset [x v] to [0]\nset [y v] to [0]\nset [turn v] to [0]\npoint in direction (90)\nshow\n\nwhen flag clicked\nhide\n\nwhen I receive [play game v]\nset size to (80) %\nset [equipped? v] to [0]\nReset Level\nforever\n    if <(in cutscene?) = [0]> then\n        if <(equipped?) > [1]> then\n            change y by (10)\n            set size to (80) %\n            set [equipped? v] to [0]\n        end\n        if <(shrink boost on/off) > [1]> then\n            set [shrink boost on/off v] to [0]\n        end\n        if <(which ninja?) = [3]> then\n            show\n            if <<<key (right arrow v) pressed?> or <key (d v) pressed?>> or <<mouse down?> and <(mouse x) > (x position)>>> then\n                if <(shrink boost on/off) = [0]> then\n                    change [x v] by (.9)\n                    change [turn v] by (.9)\n                else\n                    change [x v] by (.7)\n                    change [turn v] by (.7)\n                end\n            end\n            if <<<key (left arrow v) pressed?> or <key (a v) pressed?>> or <<mouse down?> and <(mouse x) < (x position)>>> then\n                if <(shrink boost on/off) = [0]> then\n                    change [x v] by (-.9)\n                    change [turn v] by (-.9)\n                else\n                    change [x v] by (-.7)\n                    change [turn v] by (-.7)\n                end\n            end\n            set [x v] to ((x) * (.9))\n            change x by (x)\n            set [turn v] to ((turn) * (.9))\n            turn right (turn) degrees\n            if <touching (level v)?> then\n                change y by (1)\n                if <touching (level v)?> then\n                    change y by (1)\n                    if <touching (level v)?> then\n                        change y by (1)\n                        if <touching (level v)?> then\n                            change y by (1)\n                            if <touching (level v)?> then\n                                change y by (1)\n                                if <touching (level v)?> then\n                                    change [x v] by (((x) * (-1)) - (turn))\n                                    change x by ((turn) * (-1))\n                                    change y by (-5)\n                                end\n                            end\n                        end\n                    end\n                end\n            end\n            change [y v] by (-0.8)\n            change y by (y)\n            if <touching (level v)?> then\n                change y by ((y) * (-1))\n                set [y v] to [0]\n            end\n            change y by (-1)\n            if <touching (level v)?> then\n                if <<<key (up arrow v) pressed?> or <key (w v) pressed?>> or <<mouse down?> and <(mouse y) > ((y position) + (10))>>> then\n                    set [y v] to [12]\n                end\n            end\n            change y by (1)\n            if <(boss fight?) = [0]> then\n                if <(shrink boost on/off) = [0]> then\n                    if <<<touching (spikes v)?> or <<<touching (lava v)?> or <touching (long grass v)?>> or <touching (darkness v)?>>> or <(y position) < [-188]>> then\n                        change [level deaths v] by (1)\n                        broadcast (Die v)\n                    end\n                else\n                    if <<<touching (spikes v)?> or <<<touching (lava v)?> or <touching (long grass v)?>> or <touching (darkness v)?>>> or <(y position) < [-177]>> then\n                        change [level deaths v] by (1)\n                        broadcast (Die v)\n                    end\n                end\n            end\n        else\n            hide\n            set size to (80) %\n            point in direction (90)\n            set [x v] to [0]\n            set [y v] to [0]\n            set [turn v] to [0]\n            set [equipped? v] to [0]\n            set [shrink boost on/off v] to [0]\n            if <(which ninja?) = [1]> then\n                go to x: ([x position v] of [red ninja v]) y: ([y position v] of [red ninja v])\n            else\n                if <(which ninja?) = [2]> then\n                    go to x: ([x position v] of [green ninja v]) y: ([y position v] of [green ninja v])\n                else\n                    if <(which ninja?) = [4]> then\n                        go to x: ([x position v] of [black ninja v]) y: ([y position v] of [black ninja v])\n                    else\n                        go to x: ([x position v] of [light ninja v]) y: ([y position v] of [light ninja v])\n                    end\n                end\n            end\n        end\n    end\nend\n\nwhen I receive [play game v]\nforever\n    if <(boss fight?) = [0]> then\n        if <(which ninja?) = [3]> then\n            if <key (space v) pressed?> then\n                broadcast (Shrink v)\n                wait until <not <key (space v) pressed?>>\n            end\n        end\n    else\n        set [shrink boost on/off v] to [0]\n        set [equipped? v] to [0]\n    end\nend\n\nwhen I receive [play game v]\nforever\n    if <(boss fight?) = [0]> then\n        if <(shrink boost on/off) = [0]> then\n            if <(x position) > [253]> then\n                go to x: (-255) y: (y position)\n                change [level v] by (1)\n                set [level deaths v] to [0]\n                broadcast (Next v)\n            end\n        else\n            if <(x position) > [236]> then\n                go to x: (-238) y: (y position)\n                change [level v] by (1)\n                set [level deaths v] to [0]\n                broadcast (Next v)\n            end\n        end\n    end\nend\n\nwhen I receive [play game v]\nforever\n    if <<touching (water v)?> or <touching (light v)?>> then\n        change [y v] by (-0.3)\n        if <<<key (up arrow v) pressed?> or <key (w v) pressed?>> or <<mouse down?> and <(mouse y) > ((y position) + (10))>>> then\n            change [y v] by (2)\n        end\n        set [y v] to ((y) * (.9))\n    end\nend\n\nwhen I receive [die v]\nif <(which ninja?) = [3]> then\n    set [death x v] to (x position)\n    set [death y v] to (y position)\n    Reset Level\n    stop [this script v]\nend\n\nwhen I receive [play game v]\nforever\n    if <(shrink boost on/off) = [0]> then\n        set size to (80) %\n    else\n        set size to (35) %\n    end\nend\n\nwhen I receive [shrink v]\nchange [equipped? v] by (1)\nchange [shrink boost on/off v] by (1)\n\nwhen I receive [skip v]\nif <(allowed to skip) = [1]> then\n    Reset Level\nend\n\nwhen I receive [transition v]\ngo to x: (-180) y: (-68)\npoint in direction (90)\n\nwhen I receive [boss fight die v]\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\n\nwhen I receive [boss fight blue v]\nshow\nclear graphic effects\ngo to x: (-180) y: (0)\nforever\n    if <(which ninja?) = [3]> then\n        if <<touching (boss v)?> and <not <([costume name v] of [boss v]) = [Warning]>>> then\n            broadcast (Boss Fight Hit Taken v)\n            wait (2.5) seconds\n        end\n        if <(y position) < [-188]> then\n            Reset Level\n            broadcast (Boss Fight Hit Taken v)\n        end\n    end\nend\n\nwhen I receive [boss fight hit taken v]\nif <(which ninja?) = [3]> then\n    change [player health v] by (-1)\n    repeat (3)\n        repeat (10)\n            change [brightness v] effect by (7)\n        end\n        repeat (10)\n            change [brightness v] effect by (-7)\n        end\n    end\n    clear graphic effects\nend\n\nwhen I receive [transition v]\nwait (0.5) seconds\ngo to x: (-180) y: (0)\npoint in direction (90)\n\nwhen I receive [stop end v]\nstop [other scripts in sprite v]\nhide\n\n@Black Ninja\n\nwhen I receive [play game v]\nforever\n    if <<<touching (lava v)?> or <touching (long grass v)?>> or <<touching (water v)?> or <touching (darkness v)?>>> then\n        change [y v] by (-0.3)\n        if <<<key (up arrow v) pressed?> or <key (w v) pressed?>> or <<mouse down?> and <(mouse y) > ((y position) + (10))>>> then\n            change [y v] by (2)\n        end\n        set [y v] to ((y) * (.9))\n    end\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [play game v]\nReset Level\nhide\nforever\n    if <(in cutscene?) = [0]> then\n        if <(which ninja?) = [4]> then\n            show\n            if <key (r v) pressed?> then\n                Reset Level\n                broadcast (Next v)\n            end\n            if <<<key (right arrow v) pressed?> or <key (d v) pressed?>> or <<mouse down?> and <(mouse x) > (x position)>>> then\n                change [x v] by (.9)\n                change [turn v] by (.9)\n            end\n            if <<<key (left arrow v) pressed?> or <key (a v) pressed?>> or <<mouse down?> and <(mouse x) < (x position)>>> then\n                change [x v] by (-.9)\n                change [turn v] by (-.9)\n            end\n            set [x v] to ((x) * (.9))\n            change x by (x)\n            set [turn v] to ((turn) * (.9))\n            turn right (turn) degrees\n            if <touching (level v)?> then\n                change y by (1)\n                if <touching (level v)?> then\n                    change y by (1)\n                    if <touching (level v)?> then\n                        change y by (1)\n                        if <touching (level v)?> then\n                            change y by (1)\n                            if <touching (level v)?> then\n                                change y by (1)\n                                if <touching (level v)?> then\n                                    change [x v] by (((x) * (-1)) - (turn))\n                                    change x by ((turn) * (-1))\n                                    change y by (-5)\n                                end\n                            end\n                        end\n                    end\n                end\n            end\n            change [y v] by (-0.8)\n            change y by (y)\n            if <touching (level v)?> then\n                change y by ((y) * (-1))\n                set [y v] to [0]\n            end\n            change y by (-1)\n            if <touching (level v)?> then\n                if <<<key (up arrow v) pressed?> or <key (w v) pressed?>> or <<mouse down?> and <(mouse y) > ((y position) + (10))>>> then\n                    set [y v] to [12]\n                end\n            end\n            change y by (1)\n            if <(boss fight?) = [0]> then\n                if <<<touching (spikes v)?> or <(y position) < [-188]>> or <touching (light v)?>> then\n                    change [level deaths v] by (1)\n                    broadcast (Die v)\n                end\n            end\n        else\n            hide\n            point in direction (90)\n            set [x v] to [0]\n            set [y v] to [0]\n            set [turn v] to [0]\n            set [equipped? v] to [0]\n            set [black weapon v] to [sword]\n            if <(which ninja?) = [1]> then\n                go to x: ([x position v] of [red ninja v]) y: ([y position v] of [red ninja v])\n            else\n                if <(which ninja?) = [2]> then\n                    go to x: ([x position v] of [green ninja v]) y: ([y position v] of [green ninja v])\n                else\n                    if <(which ninja?) = [3]> then\n                        if <(shrink boost on/off) = [0]> then\n                            go to x: ([x position v] of [blue ninja v]) y: ([y position v] of [blue ninja v])\n                        else\n                            go to x: ([x position v] of [blue ninja v]) y: (([y position v] of [blue ninja v]) + (20))\n                        end\n                    else\n                        go to x: ([x position v] of [light ninja v]) y: ([y position v] of [light ninja v])\n                    end\n                end\n            end\n        end\n    end\nend\n\nwhen I receive [play game v]\nforever\n    if <(boss fight?) = [0]> then\n        if <(x position) > [253]> then\n            go to x: (-255) y: (y position)\n            change [level v] by (1)\n            set [level deaths v] to [0]\n            broadcast (Next v)\n        end\n    end\nend\n\ndefine Reset Level\nif <(boss fight?) = [0]> then\n    go to x: (-180) y: (0)\nelse\n    go to x: (0) y: (100)\nend\nset [x v] to [0]\nset [y v] to [0]\nset [turn v] to [0]\npoint in direction (90)\nshow\n\nwhen I receive [die v]\nset [death x v] to (x position)\nset [death y v] to (y position)\nReset Level\nstop [this script v]\n\nwhen I receive [play game v]\nforever\n    if <(which ninja?) = [4]> then\n        if <(boss fight?) = [0]> then\n            if <key (space v) pressed?> then\n                broadcast (Change Black Weapon v)\n                wait until <not <key (space v) pressed?>>\n            end\n        else\n            set [black weapon v] to [star]\n        end\n    end\nend\n\nwhen I receive [skip v]\nif <(allowed to skip) = [1]> then\n    Reset Level\nend\n\nwhen I receive [boss fight die v]\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\n\nwhen I receive [boss fight hit taken v]\nif <(which ninja?) = [4]> then\n    change [player health v] by (-1)\n    repeat (3)\n        repeat (10)\n            change [brightness v] effect by (7)\n        end\n        repeat (10)\n            change [brightness v] effect by (-7)\n        end\n    end\n    clear graphic effects\nend\n\nwhen I receive [boss fight black v]\nshow\nclear graphic effects\ngo to x: (0) y: (120)\nforever\n    if <(which ninja?) = [4]> then\n        if <<touching (boss v)?> or <touching (light v)?>> then\n            broadcast (Boss Fight Hit Taken v)\n            wait (2.5) seconds\n        end\n        if <(y position) < [-188]> then\n            Reset Level\n            broadcast (Boss Fight Hit Taken v)\n        end\n    end\nend\n\nwhen I receive [transition v]\nwait (0.5) seconds\ngo to x: (0) y: (120)\npoint in direction (90)\n\nwhen I receive [stop end v]\nstop [other scripts in sprite v]\nhide\n\n@Light Ninja\n\nwhen flag clicked\ngo to x: (122) y: (7)\npoint in direction (90)\nhide\n\nwhen I receive [play game v]\nReset Level\nhide\nforever\n    if <(in cutscene?) = [0]> then\n        if <(equipped?) > [1]> then\n            set [equipped? v] to [0]\n        end\n        if <(light boost on/off) > [1]> then\n            set [light boost on/off v] to [0]\n        end\n        if <(which ninja?) = [5]> then\n            show\n            if <key (r v) pressed?> then\n                Reset Level\n                broadcast (Next v)\n            end\n            if <<<key (right arrow v) pressed?> or <key (d v) pressed?>> or <<mouse down?> and <(mouse x) > (x position)>>> then\n                change [x v] by (.9)\n                change [turn v] by (.9)\n            end\n            if <<<key (left arrow v) pressed?> or <key (a v) pressed?>> or <<mouse down?> and <(mouse x) < (x position)>>> then\n                change [x v] by (-.9)\n                change [turn v] by (-.9)\n            end\n            set [x v] to ((x) * (.9))\n            change x by (x)\n            set [turn v] to ((turn) * (.9))\n            turn right (turn) degrees\n            if <touching (level v)?> then\n                change y by (1)\n                if <touching (level v)?> then\n                    change y by (1)\n                    if <touching (level v)?> then\n                        change y by (1)\n                        if <touching (level v)?> then\n                            change y by (1)\n                            if <touching (level v)?> then\n                                change y by (1)\n                                if <touching (level v)?> then\n                                    change [x v] by (((x) * (-1)) - (turn))\n                                    change x by ((turn) * (-1))\n                                    change y by (-5)\n                                end\n                            end\n                        end\n                    end\n                end\n            end\n            change [y v] by (-0.8)\n            change y by (y)\n            if <touching (level v)?> then\n                change y by ((y) * (-1))\n                set [y v] to [0]\n            end\n            change y by (-1)\n            if <touching (level v)?> then\n                if <<<key (up arrow v) pressed?> or <key (w v) pressed?>> or <<mouse down?> and <(mouse y) > ((y position) + (10))>>> then\n                    set [y v] to [12]\n                end\n            end\n            change y by (1)\n            if <(boss fight?) = [0]> then\n                if <<<touching (spikes v)?> or <(y position) < [-188]>> or <<<touching (lava v)?> or <touching (long grass v)?>> or <<touching (water v)?> or <touching (darkness v)?>>>> then\n                    change [level deaths v] by (1)\n                    broadcast (Die v)\n                end\n            end\n        else\n            hide\n            point in direction (90)\n            set [x v] to [0]\n            set [y v] to [0]\n            set [turn v] to [0]\n            set [equipped? v] to [0]\n            set [light boost on/off v] to [0]\n            if <(which ninja?) = [1]> then\n                go to x: ([x position v] of [red ninja v]) y: ([y position v] of [red ninja v])\n            else\n                if <(which ninja?) = [2]> then\n                    go to x: ([x position v] of [green ninja v]) y: ([y position v] of [green ninja v])\n                else\n                    if <(which ninja?) = [3]> then\n                        if <(shrink boost on/off) = [0]> then\n                            go to x: ([x position v] of [blue ninja v]) y: ([y position v] of [blue ninja v])\n                        else\n                            go to x: ([x position v] of [blue ninja v]) y: (([y position v] of [blue ninja v]) + (20))\n                        end\n                    else\n                        go to x: ([x position v] of [black ninja v]) y: ([y position v] of [black ninja v])\n                    end\n                end\n            end\n        end\n    end\nend\n\nwhen I receive [play game v]\nforever\n    if <(boss fight?) = [0]> then\n        if <(x position) > [253]> then\n            go to x: (-255) y: (y position)\n            change [level v] by (1)\n            set [level deaths v] to [0]\n            broadcast (Next v)\n        end\n    end\nend\n\ndefine Reset Level\ngo to x: (-180) y: (0)\nset [x v] to [0]\nset [y v] to [0]\nset [turn v] to [0]\npoint in direction (90)\nshow\n\nwhen I receive [die v]\nset [death x v] to (x position)\nset [death y v] to (y position)\nReset Level\nstop [this script v]\n\nwhen I receive [play game v]\nforever\n    if <touching (light v)?> then\n        change [y v] by (-0.3)\n        if <<<key (up arrow v) pressed?> or <key (w v) pressed?>> or <<mouse down?> and <(mouse y) > ((y position) + (10))>>> then\n            change [y v] by (2)\n        end\n        set [y v] to ((y) * (.9))\n    end\nend\n\nwhen I receive [skip v]\nif <(allowed to skip) = [1]> then\n    Reset Level\nend\n\nwhen I receive [play game v]\nforever\n    if <(which ninja?) = [5]> then\n        if <(boss fight?) = [0]> then\n            if <key (space v) pressed?> then\n                broadcast (Light Boost v)\n                wait until <not <key (space v) pressed?>>\n            end\n        else\n            set [light boost on/off v] to [0]\n            set [equipped? v] to [0]\n        end\n    end\nend\n\nwhen I receive [light boost v]\nchange [equipped? v] by (1)\nchange [light boost on/off v] by (1)\n\nwhen I receive [transition v]\ngo to x: (-180) y: (-68)\npoint in direction (90)\n\nwhen I receive [boss fight die v]\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\n\nwhen I receive [boss fight light v]\nshow\nclear graphic effects\ngo to x: (-180) y: (-68)\nforever\n    if <(which ninja?) = [5]> then\n        if <<touching (boss v)?> or <touching (darkness v)?>> then\n            broadcast (Boss Fight Hit Taken v)\n            wait (2.5) seconds\n        end\n    end\nend\n\nwhen I receive [boss fight hit taken v]\nif <(which ninja?) = [5]> then\n    change [player health v] by (-1)\n    repeat (3)\n        repeat (10)\n            change [brightness v] effect by (7)\n        end\n        repeat (10)\n            change [brightness v] effect by (-7)\n        end\n    end\n    clear graphic effects\nend\n\nwhen I receive [transition v]\nwait (0.5) seconds\ngo to x: (-180) y: (-68)\npoint in direction (90)\n\nwhen I receive [transition v]\nif <(TRANSITION) = [killed]> then\n    Reset Level\nend\n\nwhen I receive [stop end v]\nstop [other scripts in sprite v]\nhide\n\n@Light Boost\n\nwhen flag clicked\nshow\ncreate clone of (_myself_ v)\nforever\n    set [ghost v] effect to (50)\n    set size to ((200) + ((10) * ([sin v] of (((timer) - (50)) * (200)) ))) %\n    broadcast (Go to Light Ninja v)\n    go to [back v] layer\n    if <<(which ninja?) = [5]> and <(light boost on/off) = [1]>> then\n        show\n    else\n        hide\n    end\nend\n\nwhen I start as a clone\nforever\n    set [ghost v] effect to (50)\n    set size to ((230) + ((10) * ([sin v] of (((timer) - (50)) * (200)) ))) %\n    go to [back v] layer\n    if <<(which ninja?) = [5]> and <(light boost on/off) = [1]>> then\n        show\n    else\n        hide\n    end\nend\n\nwhen I receive [go to light ninja v]\ngo to (light ninja v)\n\nwhen I receive [cutscene v]\nhide\nstop [other scripts in sprite v]\ndelete this clone\n\nwhen I receive [stop end v]\nstop [other scripts in sprite v]\nhide\n\n@Level\n\nwhen flag clicked\nhide\n\nwhen I receive [play game v]\nshow\ngo to [front v] layer\ngo [backward v] (1) layers\ngo [backward v] (7) layers\nforever\n    switch costume to (level)\nend\n\nwhen I receive [stop v]\nstop [other scripts in sprite v]\n\nwhen I receive [transition v]\nrepeat (5)\n    change [ghost v] effect by (20)\nend\nif <(TRANSITION) = [red]> then\n    switch costume to (boss fight level1 v)\nelse\n    if <(TRANSITION) = [green]> then\n        switch costume to (boss fight level2 v)\n    else\n        if <(TRANSITION) = [blue]> then\n            switch costume to (boss fight level3 v)\n        else\n            if <(TRANSITION) = [black]> then\n                switch costume to (boss fight level4 v)\n            else\n                if <(TRANSITION) = [light]> then\n                    switch costume to (boss fight level5 v)\n                else\n                    switch costume to (after boss v)\n                end\n            end\n        end\n    end\nend\nrepeat (5)\n    change [ghost v] effect by (-20)\nend\n\nwhen I receive [stop end v]\nstop [other scripts in sprite v]\nhide\n\n@Spikes\n\nwhen flag clicked\nhide\n\nwhen I receive [play game v]\nshow\ngo to [back v] layer\nforever\n    switch costume to (level)\nend\n\nwhen I receive [stop v]\nstop [other scripts in sprite v]\nhide\n\nwhen I receive [stop end v]\nstop [other scripts in sprite v]\nhide\n\n@Invisible Spikes\n\nwhen flag clicked\nhide\n\nwhen I receive [play game v]\nshow\ngo to [back v] layer\nforever\n    show\n    switch costume to (level)\n    if <<<touching (red ninja v)?> or <touching (green ninja v)?>> or <<touching (blue ninja v)?> or <<touching (black ninja v)?> or <touching (light ninja v)?>>>> then\n        broadcast (Die v)\n    end\n    if <(light boost on/off) = [1]> then\n        set [ghost v] effect to (70)\n    else\n        set [ghost v] effect to (100)\n    end\nend\n\nwhen I receive [stop v]\nstop [other scripts in sprite v]\nhide\n\nwhen I receive [stop end v]\nstop [other scripts in sprite v]\nhide\n\n@Words\n\nwhen flag clicked\nhide\n\nwhen I receive [play game v]\nshow\ngo to [front v] layer\ngo [backward v] (1) layers\nforever\n    switch costume to (level)\nend\n\nwhen I receive [stop end v]\nstop [other scripts in sprite v]\nhide\n\nwhen I receive [stop v]\nstop [other scripts in sprite v]\nhide\n\n@Skip\n\nwhen I receive [next v]\nhide\ngo to [front v] layer\nset [level deaths v] to [0]\nset [allowed to skip v] to [0]\nforever\n    if <(level) < [1111111111]> then\n        if <(level deaths) > [4]> then\n            show\n            set [allowed to skip v] to [1]\n        end\n    end\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [stop v]\nstop [other scripts in sprite v]\nhide\n\n@Particles\n\nwhen flag clicked\nhide\nset [is clone? v] to []\n\nwhen I receive [die v]\nstart sound [Punch Sound Effect v]\nif <not <(is clone?) = [1]>> then\n    repeat (2)\n        Particles\n    end\nend\n\nwhen I start as a clone\nif <(which ninja?) = [1]> then\n    switch costume to (pick random (1) to (3))\nelse\n    if <(which ninja?) = [2]> then\n        switch costume to (pick random (4) to (6))\n    else\n        if <(which ninja?) = [3]> then\n            switch costume to (pick random (7) to (9))\n        else\n            if <(which ninja?) = [4]> then\n                switch costume to (pick random (10) to (12))\n            else\n                switch costume to (pick random (13) to (15))\n            end\n        end\n    end\nend\nset [ghost v] effect to (0)\nset [color v] effect to (pick random (-5) to (5))\nset [brightness v] effect to (pick random (-20) to (0))\nset [is clone? v] to [1]\ngo to x: (death x) y: (death y)\nshow\nset [x v] to (pick random (-10) to (10))\nset [y v] to (pick random (5) to (30))\nrepeat until <<touching (_edge_ v)?> or <touching (level v)?>>\n    change [y v] by (-2)\n    set [x v] to ((x) * (0.9))\n    set [y v] to ((y) * (0.9))\n    change x by (x)\n    change y by (y)\n    set x to ((x position) + (pick random (shake) to ((shake) - ((shake) * (2)))))\n    set y to ((y position) + (pick random (shake) to ((shake) - ((shake) * (2)))))\n    if <touching (level v)?> then\n        change y by (1)\n        if <touching (level v)?> then\n            change y by (1)\n            if <touching (level v)?> then\n                change y by (1)\n                if <touching (level v)?> then\n                    change y by (1)\n                    if <touching (level v)?> then\n                        change y by (1)\n                        if <touching (level v)?> then\n                            change y by (1)\n                            if <touching (level v)?> then\n                                change y by (1)\n                                if <touching (level v)?> then\n                                    change y by (1)\n                                    if <touching (level v)?> then\n                                        change y by (1)\n                                        if <touching (level v)?> then\n                                            change y by (1)\n                                            if <touching (level v)?> then\n                                                change y by (1)\n                                                if <touching (level v)?> then\n                                                    change y by (1)\n                                                else\n                                                    change y by (-1)\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\nrepeat (20)\n    change [ghost v] effect by (5)\nend\ndelete this clone\n\ndefine Particles\nrepeat (5)\n    create clone of (_myself_ v)\nend\n\n@Slime Particles\n\nwhen flag clicked\nhide\nset [is clone? v] to []\n\nwhen I receive [slime die v]\nstart sound [Punch Sound Effect v]\nif <not <(is clone?) = [1]>> then\n    repeat (2)\n        Particles\n    end\nend\n\nwhen I start as a clone\nswitch costume to (pick random (((monster cost) * (2)) - (1)) to ((monster cost) * (2)))\nset [ghost v] effect to (0)\nset [color v] effect to (pick random (-5) to (5))\nset [brightness v] effect to (pick random (-20) to (0))\nset [is clone? v] to [1]\ngo to x: (slime death x) y: (slime death y)\nshow\nset [x v] to (pick random (-10) to (10))\nset [y v] to (pick random (5) to (30))\nrepeat until <<touching (_edge_ v)?> or <touching (level v)?>>\n    change [y v] by (-2)\n    set [x v] to ((x) * (0.9))\n    set [y v] to ((y) * (0.9))\n    change x by (x)\n    change y by (y)\n    set x to ((x position) + (pick random (shake) to ((shake) - ((shake) * (2)))))\n    set y to ((y position) + (pick random (shake) to ((shake) - ((shake) * (2)))))\n    if <touching (level v)?> then\n        change y by (1)\n        if <touching (level v)?> then\n            change y by (1)\n            if <touching (level v)?> then\n                change y by (1)\n                if <touching (level v)?> then\n                    change y by (1)\n                    if <touching (level v)?> then\n                        change y by (1)\n                        if <touching (level v)?> then\n                            change y by (1)\n                            if <touching (level v)?> then\n                                change y by (1)\n                                if <touching (level v)?> then\n                                    change y by (1)\n                                    if <touching (level v)?> then\n                                        change y by (1)\n                                        if <touching (level v)?> then\n                                            change y by (1)\n                                            if <touching (level v)?> then\n                                                change y by (1)\n                                                if <touching (level v)?> then\n                                                    change y by (1)\n                                                else\n                                                    change y by (-1)\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\nrepeat (20)\n    change [ghost v] effect by (5)\nend\ndelete this clone\n\ndefine Particles\nrepeat (5)\n    create clone of (_myself_ v)\nend\n\n@Change Explosion\n\nwhen flag clicked\nhide\n\nwhen I receive [switch v]\nstart sound [BOOM!!!!! v]\nswitch costume to (exploding a v)\nshow\ngo to [front v] layer\nset size to (500) %\ngo to x: ([x position v] of [red ninja v]) y: ([y position v] of [red ninja v])\nrepeat (13)\n    next costume\n    wait (0.00000001) seconds\nend\nhide\nstop [this script v]\n\n@Switch Ninja\n\nwhen flag clicked\nhide\n\nwhen I receive [play game v]\nforever\n    if <(which ninja?) > [5]> then\n        set [which ninja? v] to [1]\n    end\nend\n\nwhen I receive [play game v]\nset [switch in progress v] to [0]\nshow\ngo to [front v] layer\ngo to x: (195) y: (-145)\nforever\n    if <touching (mouse-pointer v)?> then\n        set [brightness v] effect to (10)\n        if <mouse down?> then\n            if <(switch in progress) = [0]> then\n                set [switch in progress v] to [1]\n                broadcast (Switch v)\n                change [which ninja? v] by (1)\n                wait until <not <mouse down?>>\n                set [switch in progress v] to [0]\n            end\n        end\n    else\n        set [brightness v] effect to (0)\n    end\nend\n\nwhen I receive [play game v]\nforever\n    if <key (z v) pressed?> then\n        if <(switch in progress) = [0]> then\n            set [switch in progress v] to [1]\n            broadcast (Switch v)\n            change [which ninja? v] by (1)\n            wait until <not <key (z v) pressed?>>\n            set [switch in progress v] to [0]\n        end\n    end\nend\n\nwhen I receive [stop v]\nstop [other scripts in sprite v]\nhide\n\n@Jump Boost On/Off\n\nwhen flag clicked\nhide\n\nwhen I receive [play game v]\ngo to [front v] layer\ngo [backward v] (3) layers\ngo to x: (-170) y: (-155)\nset [jump boost on/off v] to [0]\nforever\n    if <(which ninja?) = [1]> then\n        show\n        switch costume to (jump boost on/off)\n    else\n        hide\n    end\nend\n\nwhen I receive [play game v]\nforever\n    if <(which ninja?) = [1]> then\n        if <touching (mouse-pointer v)?> then\n            set [brightness v] effect to (10)\n            if <mouse down?> then\n                broadcast (Jump Boost v)\n                wait until <not <mouse down?>>\n            end\n        else\n            set [brightness v] effect to (0)\n        end\n    end\nend\n\nwhen I receive [stop v]\nstop [other scripts in sprite v]\nhide\n\n@Speed Boost On/Off\n\nwhen flag clicked\nhide\n\nwhen I receive [play game v]\ngo to [front v] layer\ngo [backward v] (2) layers\ngo to x: (-170) y: (-155)\nset [speed boost on/off v] to [0]\nforever\n    if <(which ninja?) = [2]> then\n        show\n        switch costume to (speed boost on/off)\n    else\n        hide\n    end\nend\n\nwhen I receive [play game v]\nforever\n    if <(which ninja?) = [2]> then\n        if <touching (mouse-pointer v)?> then\n            set [brightness v] effect to (10)\n            if <mouse down?> then\n                broadcast (Speed Boost v)\n                wait until <not <mouse down?>>\n            end\n        else\n            set [brightness v] effect to (0)\n        end\n    end\nend\n\nwhen I receive [stop v]\nstop [other scripts in sprite v]\nhide\n\n@Shrink Boost On/Off\n\nwhen flag clicked\nhide\n\nwhen I receive [play game v]\ngo to [front v] layer\ngo to x: (-170) y: (-155)\nset [shrink boost on/off v] to [0]\nforever\n    if <(which ninja?) = [3]> then\n        show\n        switch costume to (shrink boost on/off)\n    else\n        hide\n    end\nend\n\nwhen I receive [play game v]\nforever\n    if <(which ninja?) = [3]> then\n        if <touching (mouse-pointer v)?> then\n            set [brightness v] effect to (10)\n            if <mouse down?> then\n                broadcast (Shrink v)\n                wait until <not <mouse down?>>\n            end\n        else\n            set [brightness v] effect to (0)\n        end\n    end\nend\n\nwhen I receive [stop v]\nstop [other scripts in sprite v]\nhide\n\n@Weapon button\n\nwhen flag clicked\nhide\n\nwhen I receive [play game v]\ngo to [front v] layer\ngo to x: (-170) y: (-155)\nset [black weapon v] to [sword]\nforever\n    if <(which ninja?) = [4]> then\n        show\n        switch costume to (black weapon)\n    else\n        hide\n    end\nend\n\nwhen I receive [play game v]\nforever\n    if <(which ninja?) = [4]> then\n        if <touching (mouse-pointer v)?> then\n            set [brightness v] effect to (10)\n            if <mouse down?> then\n                broadcast (Change Black Weapon v)\n                wait until <not <mouse down?>>\n            end\n        else\n            set [brightness v] effect to (0)\n        end\n    end\nend\n\nwhen I receive [change black weapon v]\nif <(black weapon) = [sword]> then\n    set [black weapon v] to [star]\nelse\n    set [black weapon v] to [sword]\nend\n\nwhen I receive [stop v]\nstop [other scripts in sprite v]\nhide\n\n@Light Boost On/Off\n\nwhen flag clicked\nhide\n\nwhen I receive [play game v]\ngo to [front v] layer\ngo to x: (-170) y: (-155)\nset [black weapon v] to [sword]\nforever\n    if <(which ninja?) = [5]> then\n        show\n        switch costume to (light boost on/off)\n    else\n        hide\n    end\nend\n\nwhen I receive [play game v]\nforever\n    if <(which ninja?) = [5]> then\n        if <touching (mouse-pointer v)?> then\n            set [brightness v] effect to (10)\n            if <mouse down?> then\n                broadcast (Light Boost v)\n                wait until <not <mouse down?>>\n            end\n        else\n            set [brightness v] effect to (0)\n        end\n    end\nend\n\nwhen I receive [stop v]\nstop [other scripts in sprite v]\nhide\n\n@Sword\n\nwhen flag clicked\nset [direction of sword v] to [right]\npoint in direction (90)\nset size to (80) %\nhide\n\nwhen I receive [play game v]\nshow\nswitch costume to (1 v)\nforever\n    broadcast (Sword v)\nend\n\nwhen I receive [sword v]\nforever\n    if <(which ninja?) = [1]> then\n        go to (red ninja v)\n    else\n        if <(which ninja?) = [2]> then\n            go to (green ninja v)\n        else\n            if <(which ninja?) = [3]> then\n                go to (blue ninja v)\n            else\n                if <(which ninja?) = [4]> then\n                    go to (black ninja v)\n                else\n                    go to (light ninja v)\n                end\n            end\n        end\n    end\n    if <not <(black weapon) = [star]>> then\n        show\n        if <<<key (right arrow v) pressed?> or <key (d v) pressed?>> or <<<mouse down?> and <(mouse x) > (x position)>> and <(brightness on?) = [0]>>> then\n            if <(attack in progress) = [0]> then\n                switch costume to (1 v)\n                set [direction of sword v] to [right]\n            else\n                set [direction of sword v] to [right]\n            end\n        end\n        if <<<key (left arrow v) pressed?> or <key (a v) pressed?>> or <<<mouse down?> and <(mouse x) < (x position)>> and <(brightness on?) = [0]>>> then\n            if <(attack in progress) = [0]> then\n                switch costume to (9 v)\n                set [direction of sword v] to [left]\n            else\n                set [direction of sword v] to [left]\n            end\n        end\n        if <(shrink boost on/off) = [1]> then\n            set size to (40) %\n        else\n            set size to (80) %\n        end\n    else\n        hide\n    end\nend\n\nwhen [t v] key pressed\nif <not <(black weapon) = [star]>> then\n    if <(cutscene?) = [0]> then\n        if <(attack in progress) = [0]> then\n            broadcast (Attack v) and wait\n        end\n    end\nend\n\nwhen I receive [attack v]\nset [attack in progress v] to [1]\nif <(attack in progress) = [1]> then\n    repeat (7)\n        next costume\n    end\n    repeat (10)\n        change [ghost v] effect by (10)\n    end\nend\nif <(direction of sword) = [right]> then\n    switch costume to (1 v)\nelse\n    switch costume to (9 v)\nend\nset [attack in progress v] to [0]\nset [ghost v] effect to (0)\nwait until <not <key (t v) pressed?>>\n\nwhen I receive [boss fight die v]\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\n\nwhen I receive [transition v]\nclear graphic effects\n\nwhen I receive [stop end v]\nstop [other scripts in sprite v]\nhide\n\n@Ninja Star\n\nwhen I receive [play game v]\nshow\nset [black? v] to [1]\nforever\n    broadcast (Star v)\nend\n\nwhen flag clicked\nset [black? v] to [0]\nset [throw in progress v] to [0]\nhide\n\nwhen I receive [star v]\nif <(black weapon) = [star]> then\n    show\n    forever\n        if <(throw in progress) = [0]> then\n            go to x: (([x position v] of [black ninja v]) + (5)) y: (([y position v] of [black ninja v]) - (5))\n        end\n    end\nelse\n    hide\nend\n\nwhen [f v] key pressed\nif <(black weapon) = [star]> then\n    if <(throw in progress) = [0]> then\n        if <(black?) = [1]> then\n            broadcast (Throw v)\n        end\n    end\nend\n\nwhen I receive [throw v]\nset [throw in progress v] to [1]\nrepeat until <<<touching (_edge_ v)?> or <touching (level v)?>> or <touching (boss v)?>>\n    change x by (10)\n    turn right (15) degrees\nend\nset [throw in progress v] to [0]\n\nwhen I receive [transition v]\nclear graphic effects\n\nwhen I receive [boss fight die v]\nrepeat (10)\n    change [ghost v] effect by (10)\nend\n\nwhen I receive [stop end v]\nstop [other scripts in sprite v]\nhide\n\n@Enemy\n\nwhen flag clicked\nhide\n\nwhen I receive [next v]\nbroadcast (Delete Clones v) and wait\nif <(level) = [7]> then\n    Clone [40] [-40] [1]\nelse\n    if <(level) = [9]> then\n        Clone [140] [-40] [3]\n        Clone [200] [-40] [4]\n    else\n        if <(level) = [10]> then\n            Clone [200] [70] [2]\n        else\n            if <(level) = [15]> then\n                Clone [40] [-40] [1]\n            else\n                if <(level) = [19]> then\n                    Clone [140] [45] [3]\n                else\n                    if <(level) = [21]> then\n                        Clone [60] [-40] [1]\n                        Clone [150] [-40] [2]\n                    else\n                        if <(level) = [22]> then\n                            Clone [130] [130] [3]\n                            Clone [240] [130] [4]\n                        end\n                    end\n                end\n            end\n        end\n    end\nend\n\nwhen I receive [die v]\nbroadcast (Delete Clones v) and wait\nif <(level) = [7]> then\n    Clone [40] [-40] [1]\nelse\n    if <(level) = [9]> then\n        Clone [140] [-40] [3]\n        Clone [200] [-40] [4]\n    else\n        if <(level) = [10]> then\n            Clone [200] [70] [2]\n        else\n            if <(level) = [15]> then\n                Clone [40] [-40] [1]\n            else\n                if <(level) = [19]> then\n                    Clone [140] [45] [3]\n                else\n                    if <(level) = [21]> then\n                        Clone [60] [-40] [1]\n                        Clone [150] [-40] [2]\n                    else\n                        if <(level) = [22]> then\n                            Clone [130] [130] [3]\n                            Clone [240] [130] [4]\n                        end\n                    end\n                end\n            end\n        end\n    end\nend\n\nwhen I start as a clone\nshow\nset [x v] to [0]\nset [y v] to [0]\nset rotation style [left-right v]\nrepeat until <<<touching (sword v)?> or <touching (ninja star v)?>> or <(y position) < [-184]>>\n    change [y v] by (-1)\n    if <([x position v] of [black ninja v]) < (x position)> then\n        change [x v] by ((monster speed) * (-1))\n        point in direction (90)\n    else\n        change [x v] by (monster speed)\n        point in direction (-90)\n    end\n    set [x v] to ((x) * (.9))\n    change x by (x)\n    if <touching (level v)?> then\n        change y by (1)\n        if <touching (level v)?> then\n            change y by (1)\n            if <touching (level v)?> then\n                change y by (1)\n                if <touching (level v)?> then\n                    change y by (1)\n                    if <touching (level v)?> then\n                        change y by (-4)\n                        change x by ((x) * (-1))\n                        if <([y position v] of [black ninja v]) > ((y position) + (15))> then\n                            set [y v] to (monster WJ height)\n                            if <([abs v] of (x) ) = (x)> then\n                                set [x v] to ((monster WJ speed) * (-1))\n                            else\n                                set [x v] to (monster WJ speed)\n                            end\n                        else\n                            set [x v] to [0]\n                        end\n                    end\n                end\n            end\n        end\n    end\n    change y by (y)\n    if <touching (level v)?> then\n        change y by ((y) * (-1))\n        set [y v] to [0]\n    end\n    change y by (-1)\n    if <<([y position v] of [black ninja v]) > ((y position) + (15))> and <touching (level v)?>> then\n        set [y v] to (monster jump height)\n    end\n    change y by (1)\n    if <<<touching (red ninja v)?> or <touching (green ninja v)?>> or <<touching (blue ninja v)?> or <<touching (black ninja v)?> or <touching (light ninja v)?>>>> then\n        if <(boss fight?) = [0]> then\n            change [level deaths v] by (1)\n            broadcast (Die v)\n        else\n            broadcast (Boss Fight Hit Taken v)\n            set [enemy hit? v] to [1]\n            delete this clone\n        end\n    end\nend\nset [slime death x v] to (x position)\nset [slime death y v] to (y position)\nset [monster cost v] to (costume [number v])\nset [enemy hit? v] to [1]\nbroadcast (Slime Die v)\ndelete this clone\n\nwhen I receive [delete clones v]\ndelete this clone\n\ndefine Clone (x) (y) (monster)\ngo to x: (x) y: (y)\nif <(monster) = [1]> then\n    switch costume to (1 v)\n    monster stats [.6] [12] [5] [8]\nelse\n    if <(monster) = [2]> then\n        switch costume to (2 v)\n        monster stats [.9] [12] [5] [8]\n    else\n        if <(monster) = [3]> then\n            switch costume to (3 v)\n            monster stats [.6] [15] [5] [10]\n        else\n            switch costume to (4 v)\n            monster stats [.6] [12] [8] [15]\n        end\n    end\nend\ncreate clone of (_myself_ v)\n\ndefine monster stats (speed) (jump height) (wj speed) (wj height)\nset [monster speed v] to (speed)\nset [monster jump height v] to (jump height)\nset [monster wj speed v] to (wj speed)\nset [monster wj height v] to (wj height)\n\nwhen I receive [spawn monster boss fight v]\nClone (BOSS FIGHT MONSTER SPAWN X) (BOSS FIGHT MONSTER SPAWN Y) (BOSS FIGHT MONSTER SPAWN TYPE)\n\nwhen I receive [stop end v]\nstop [other scripts in sprite v]\nhide\n\nwhen I receive [boss fight die v]\ndelete this clone\n\n@Attack\n\nwhen flag clicked\nhide\n\nwhen I receive [play game v]\nshow\ngo to [front v] layer\ngo to x: (110) y: (-140)\nforever\n    go to [front v] layer\n    go [backward v] (3) layers\n    if <(black weapon) = [sword]> then\n        show\n        if <touching (mouse-pointer v)?> then\n            set [brightness v] effect to (10)\n            if <mouse down?> then\n                if <(attack in progress) = [0]> then\n                    broadcast (Attack v)\n                    wait until <not <mouse down?>>\n                end\n            end\n        else\n            set [brightness v] effect to (0)\n        end\n    else\n        hide\n    end\nend\n\nwhen I receive [stop end v]\nstop [other scripts in sprite v]\nhide\n\n@Throw\n\nwhen flag clicked\nhide\n\nwhen I receive [play game v]\nshow\ngo to [front v] layer\ngo to x: (110) y: (-140)\nforever\n    go to [front v] layer\n    if <(black weapon) = [star]> then\n        show\n        if <touching (mouse-pointer v)?> then\n            set [brightness v] effect to (10)\n            if <mouse down?> then\n                if <(throw in progress) = [0]> then\n                    broadcast (Throw v)\n                    wait until <not <mouse down?>>\n                end\n            end\n        else\n            set [brightness v] effect to (0)\n        end\n    else\n        hide\n    end\nend\n\nwhen I receive [stop v]\nstop [other scripts in sprite v]\nhide\n\n@Lava\n\nwhen flag clicked\nhide\n\nwhen I receive [play game v]\nshow\nforever\n    go to [back v] layer\n    switch costume to (level)\nend\n\nwhen I receive [stop v]\nstop [other scripts in sprite v]\nhide\n\nwhen I receive [transition v]\nif <(TRANSITION) = [red]> then\n    show\n    repeat (5)\n        change [ghost v] effect by (20)\n    end\n    switch costume to (boss fight v)\n    repeat (5)\n        change [ghost v] effect by (-20)\n    end\nelse\n    repeat (5)\n        change [ghost v] effect by (20)\n    end\n    hide\nend\n\n@Long Grass\n\nwhen flag clicked\nhide\n\nwhen I receive [play game v]\nshow\nforever\n    go to [back v] layer\n    switch costume to (level)\nend\n\nwhen I receive [stop v]\nstop [other scripts in sprite v]\nhide\n\nwhen I receive [transition v]\nif <(TRANSITION) = [green]> then\n    show\n    repeat (5)\n        change [ghost v] effect by (20)\n    end\n    switch costume to (boss fight v)\n    repeat (5)\n        change [ghost v] effect by (-20)\n    end\nelse\n    repeat (5)\n        change [ghost v] effect by (20)\n    end\n    hide\nend\n\n@Water\n\nwhen flag clicked\nhide\n\nwhen I receive [play game v]\nshow\nforever\n    go to [back v] layer\n    switch costume to (level)\nend\n\nwhen I receive [stop v]\nstop [other scripts in sprite v]\nhide\n\nwhen I receive [transition v]\nif <(TRANSITION) = [blue]> then\n    show\n    repeat (5)\n        change [ghost v] effect by (20)\n    end\n    switch costume to (boss fight v)\n    repeat (5)\n        change [ghost v] effect by (-20)\n    end\nelse\n    repeat (5)\n        change [ghost v] effect by (20)\n    end\n    hide\nend\n\n@Darkness\n\nwhen flag clicked\nhide\n\nwhen I receive [play game v]\nshow\nforever\n    go to [back v] layer\n    switch costume to (level)\nend\n\nwhen I receive [stop v]\nstop [other scripts in sprite v]\nhide\n\nwhen I receive [transition v]\nif <(TRANSITION) = [black]> then\n    show\n    repeat (5)\n        change [ghost v] effect by (20)\n    end\n    switch costume to (boss fight black v)\n    repeat (5)\n        change [ghost v] effect by (-20)\n    end\nelse\n    if <(TRANSITION) = [light]> then\n        show\n        repeat (5)\n            change [ghost v] effect by (20)\n        end\n        switch costume to (boss fight light v)\n        repeat (5)\n            change [ghost v] effect by (-20)\n        end\n    else\n        repeat (5)\n            change [ghost v] effect by (20)\n        end\n        hide\n    end\nend\n\n@Light\n\nwhen flag clicked\nhide\n\nwhen I receive [play game v]\nshow\nforever\n    go to [back v] layer\n    switch costume to (level)\nend\n\nwhen I receive [stop v]\nstop [other scripts in sprite v]\nhide\n\nwhen I receive [transition v]\nif <(TRANSITION) = [black]> then\n    go to [back v] layer\n    show\n    repeat (5)\n        change [ghost v] effect by (20)\n    end\n    switch costume to (boss fight black v)\n    repeat (5)\n        change [ghost v] effect by (-20)\n    end\nelse\n    if <(TRANSITION) = [light]> then\n        show\n        repeat (5)\n            change [ghost v] effect by (20)\n        end\n        switch costume to (boss fight light v)\n        repeat (5)\n            change [ghost v] effect by (-20)\n        end\n    else\n        repeat (5)\n            change [ghost v] effect by (20)\n        end\n        hide\n    end\nend\n\n@Boss\n\nwhen flag clicked\nset [boss fight? v] to [0]\nset [boss vulnerable? v] to [0]\ngo to x: (135) y: (80)\nhide\n\nwhen I receive [play game v]\nswitch costume to (boss v)\npoint in direction (90)\nwait (0.1) seconds\nwait until <(level) > [24]>\nshow\nbroadcast (Boss Appears!!!!! v)\nwait (4) seconds\nbroadcast (Boss Talks v)\n\ndefine Clone (id)\nset [clone v] to (id)\ncreate clone of (_myself_ v)\n\nwhen I receive [boss fight red v]\ngo to [front v] layer\nwait (1) seconds\nset [in cutscene? v] to [1]\nbroadcast (Red Ninja v) and wait\nset [in cutscene? v] to [0]\nwait (1) seconds\nshow\nswitch costume to (boss angry v)\npoint in direction (0)\ngo to x: (266) y: (120)\nrepeat until <(x position) < [-265]>\n    change x by (-10)\nend\nhide\nwait (1) seconds\nshow\npoint in direction (180)\ngo to x: (-266) y: (-40)\nrepeat until <(x position) > [265]>\n    change x by (10)\nend\nhide\nwait (1) seconds\nshow\npoint in direction (-90)\ngo to x: (-130) y: (206)\nrepeat until <(y position) < [-205]>\n    change y by (-10)\nend\nhide\nwait (1) seconds\nshow\npoint in direction (90)\ngo to x: (150) y: (-206)\nrepeat until <(y position) > [205]>\n    change y by (10)\nend\nhide\nwait (1) seconds\nswitch costume to (boss v)\nshow\ngo to x: (50) y: (206)\nrepeat until <(y position) < [94]>\n    change y by (-3)\nend\ngo to x: (50) y: (91)\nwait (0.5) seconds\nSay One Line [Haha, not bad...]\nwait (0.5) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\nclear graphic effects\nwait (1) seconds\nshow\ngo to x: (170) y: (206)\nrepeat until <(y position) < [106]>\n    change y by (-5)\nend\nwait (0.7) seconds\nrepeat (10)\n    set [enemy hit? v] to [0]\n    Spawn Enemy [150] [150] [1]\n    wait until <(enemy hit?) = [1]>\n    wait (1) seconds\nend\nwait (0.7) seconds\nrepeat until <(x position) < [151]>\n    change x by (-2)\nend\nwait (1) seconds\nshow\ngo to x: (150) y: (105)\nSay One Line [HOW!?]\nswitch costume to (boss vulnerable v)\nTake Hits [5]\nset [boss vulnerable? v] to [0]\nwait (0.5) seconds\nSay One Line [OW!!!!!]\nset [in cutscene? v] to [1]\nbroadcast (Time for you... GREEN v) and wait\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\n\ndefine Say One Line (speech)\nset [say v] to (speech)\nset [in cutscene? v] to [1]\nbroadcast (Talk v) and wait\nset [in cutscene? v] to [0]\n\ndefine Spawn Enemy (x) (y) (type)\nset [boss fight monster spawn x v] to (x)\nset [boss fight monster spawn y v] to (y)\nset [boss fight monster spawn type v] to (type)\nbroadcast (Spawn Monster Boss Fight v)\n\ndefine Take Hits (hits)\nset [boss vulnerable? v] to [1]\nrepeat (hits)\n    wait until <<touching (sword v)?> or <touching (ninja star v)?>>\n    repeat (2)\n        change [brightness v] effect by (25)\n    end\n    repeat (2)\n        change [brightness v] effect by (-25)\n    end\n    wait (0.3) seconds\nend\n\nwhen I receive [boss fight green v]\nset [in cutscene? v] to [0]\ngo to [front v] layer\nwait (1) seconds\nclear graphic effects\nswitch costume to (boss v)\nshow\ngo to x: (200) y: (206)\nrepeat until <touching (level v)?>\n    change y by (-3)\nend\nshow\ngo to x: (200) y: (-46)\nwait (0.5) seconds\nSay One Line [Green Ninja,~ let's hope I can defeat you-instead!!]\nwait (0.5) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\nclear graphic effects\nwait (1) seconds\nswitch costume to (runexmite v)\nshow\npoint in direction (90)\ngo to x: (246) y: (80)\nrepeat (15)\n    change x by (-4.66)\nend\nwait (0.5) seconds\nSay One Line [This is a Runexmite,~ and it will follow you-until it dies.]\nSay One Line [Hopefully you can't outrun it!!]\nwait (0.5) seconds\nswitch costume to (runexmite running v)\npoint towards (green ninja v)\nreset timer\nrepeat until <(timer) > [15]>\n    move (4) steps\n    point towards (green ninja v)\nend\nwait (0.5) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nwait (1) seconds\nswitch costume to (boss v)\nshow\npoint in direction (90)\ngo to x: (100) y: (100)\nrepeat (10)\n    change [ghost v] effect by (-10)\nend\nwait (0.5) seconds\nSay One Line [Huh, better than I thought.]\nSay One Line [Well take this!]\nwait (0.5) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\nclear graphic effects\nwait (1) seconds\nClone [Saw1]\nClone [Saw2]\nwait (16.5) seconds\nshow\nset [ghost v] effect to (100)\nset size to (100) %\nswitch costume to (boss v)\ngo to x: (100) y: (100)\nrepeat (10)\n    change [ghost v] effect by (-10)\nend\nwait (0.5) seconds\nSay One Line [You are too good!!]\nswitch costume to (boss vulnerable v)\nTake Hits [7]\nset [boss vulnerable? v] to [0]\nwait (0.5) seconds\nSay One Line [DAMN IT!!!!!]\nset [in cutscene? v] to [1]\nbroadcast (Well, hopefully blue v) and wait\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\n\nwhen I receive [boss appears!!!!! v]\nbroadcast (Stop v)\nset [boss fight? v] to [1]\n\nwhen I receive [transition v]\nhide\n\nwhen I receive [boss fight die v]\nstop [other scripts in sprite v]\nset [boss vulnerable? v] to [0]\nbroadcast (Delete Boss Clones v)\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\nclear graphic effects\nwait (1) seconds\nbroadcast (Transition v)\n\nwhen I start as a clone\nif <(Clone) = [Saw1]> then\n    show\n    set size to (90) %\n    switch costume to (saw v)\n    go to x: (274) y: (-30)\n    point in direction (90)\n    repeat until <(x position) < [-273]>\n        change x by (-5)\n        turn left (10) degrees\n    end\n    hide\n    wait (0.7) seconds\n    show\n    go to x: (0) y: (-204)\n    point in direction (90)\n    repeat until <(y position) > [203]>\n        change y by (5)\n        turn right (10) degrees\n    end\n    hide\n    wait (1.5) seconds\n    show\n    go to x: (-150) y: (204)\n    point in direction (90)\n    repeat until <(y position) < [-203]>\n        change y by (-5)\n        turn left (10) degrees\n    end\n    hide\n    wait (1) seconds\n    show\n    go to x: (150) y: (204)\n    point in direction (90)\n    repeat until <(y position) < [-203]>\n        change y by (-5)\n        turn left (10) degrees\n    end\n    hide\n    delete this clone\nend\n\nwhen I start as a clone\nif <(Clone) = [Saw2]> then\n    show\n    set size to (90) %\n    switch costume to (saw v)\n    go to x: (-150) y: (204)\n    point in direction (90)\n    repeat until <(y position) < [-203]>\n        change y by (-5)\n        turn left (10) degrees\n    end\n    hide\n    wait (1.5) seconds\n    show\n    go to x: (-274) y: (30)\n    point in direction (90)\n    repeat until <(x position) > [273]>\n        change x by (5)\n        turn right (10) degrees\n    end\n    hide\n    wait (0.7) seconds\n    show\n    go to x: (-20) y: (204)\n    point in direction (90)\n    repeat until <(y position) < [-203]>\n        change y by (-5)\n        turn left (10) degrees\n    end\n    hide\n    wait (1) seconds\n    show\n    go to x: (20) y: (204)\n    point in direction (90)\n    repeat until <(y position) < [-203]>\n        change y by (-5)\n        turn left (10) degrees\n    end\n    hide\n    delete this clone\nend\n\nwhen I receive [boss fight blue v]\nset [in cutscene? v] to [0]\ngo to [front v] layer\nwait (1) seconds\nset [ghost v] effect to (100)\nswitch costume to (boss v)\ngo to x: (140) y: (140)\npoint in direction (90)\nshow\nrepeat (10)\n    change [ghost v] effect by (-10)\nend\nwait (0.5) seconds\nSay One Line [Hello blue ninja,~ today you shall be ended!!]\nwait (0.5) seconds\nrepeat (12)\n    turn left (15) degrees\nend\nwait (0.5) seconds\nset [y v] to [0]\nrepeat until <(y position) < [-205]>\n    change [y v] by (-0.8)\n    change y by (y)\nend\nhide\npoint in direction (90)\nwait (1) seconds\nShow Warning [200] [-60]\nShow Warning [200] [-130]\nwait (2) seconds\nLaunch Rocket [284] [-60] [x]\nLaunch Rocket [284] [-130] [x]\nwait (2) seconds\nShow Warning [-200] [145]\nShow Warning [-130] [145]\nShow Warning [-60] [145]\nwait (2) seconds\nLaunch Rocket [-200] [224] [y]\nLaunch Rocket [-130] [224] [y]\nLaunch Rocket [-60] [224] [y]\nwait (2) seconds\nShow Warning [200] [145]\nShow Warning [130] [145]\nShow Warning [60] [145]\nwait (2) seconds\nLaunch Rocket [200] [224] [y]\nLaunch Rocket [130] [224] [y]\nLaunch Rocket [60] [224] [y]\nwait (2) seconds\nShow Warning [-200] [40]\nShow Warning [-200] [-20]\nShow Warning [200] [-80]\nShow Warning [200] [-140]\nwait (2) seconds\nLaunch Rocket [-284] [40] [x]\nLaunch Rocket [-284] [-20] [x]\nLaunch Rocket [284] [-80] [x]\nLaunch Rocket [284] [-140] [x]\nwait (3) seconds\nset [ghost v] effect to (100)\nswitch costume to (boss v)\ngo to x: (140) y: (-100)\npoint in direction (90)\nshow\nrepeat (10)\n    change [ghost v] effect by (-10)\nend\nwait (0.5) seconds\nSay One Line [Wow,~ you are good!]\nSay One Line [But not GOOD ENOUGH!!!!!]\nwait (0.5) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\nclear graphic effects\nwait (1) seconds\nswitch costume to (boss angry v)\npoint in direction (-90)\ngo to x: (-165) y: (206)\nshow\nrepeat until <(y position) < [-205]>\n    change y by (-10)\nend\nhide\npoint in direction (90)\nwait (1) seconds\nShow Warning [200] [145]\nShow Warning [130] [145]\nShow Warning [60] [145]\nwait (2) seconds\nLaunch Rocket [200] [224] [y]\nLaunch Rocket [130] [224] [y]\nLaunch Rocket [60] [224] [y]\nswitch costume to (boss angry v)\npoint in direction (0)\ngo to x: (266) y: (-70)\nshow\nrepeat until <(x position) < [-265]>\n    change x by (-10)\nend\nhide\nwait (2) seconds\nset [ghost v] effect to (100)\nswitch costume to (boss v)\ngo to x: (140) y: (-100)\npoint in direction (90)\nshow\nrepeat (10)\n    change [ghost v] effect by (-10)\nend\nwait (0.5) seconds\nreset timer\nswitch costume to (boss chasing v)\nrepeat until <(timer) > [20]>\n    move (5) steps\n    point towards (blue ninja v)\nend\nwait (0.5) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\nwait (0.5) seconds\nshow\nswitch costume to (boss v)\npoint in direction (90)\ngo to x: (140) y: (-100)\nrepeat (10)\n    change [ghost v] effect by (-10)\nend\nwait (0.5) seconds\nSay One Line [You are too strong...]\nswitch costume to (boss vulnerable v)\nTake Hits [10]\nset [boss vulnerable? v] to [0]\nwait (0.5) seconds\nSay One Line [Dang...]\nset [in cutscene? v] to [1]\nbroadcast (Time for an old foe... v) and wait\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\n\nwhen I start as a clone\nif <(Clone) = [Warning]> then\n    show\n    switch costume to (warning v)\n    repeat (3)\n        show\n        wait (0.3) seconds\n        hide\n        wait (0.3) seconds\n    end\n    delete this clone\nend\n\nwhen I start as a clone\nif <(Clone) = [RocketX]> then\n    show\n    switch costume to (rocket v)\n    if <(x position) > [0]> then\n        point in direction (180)\n        repeat until <(x position) < [-283]>\n            change x by (-15)\n        end\n    else\n        point in direction (0)\n        repeat until <(x position) > [283]>\n            change x by (15)\n        end\n    end\n    delete this clone\nend\n\ndefine Show Warning (x) (y)\nswitch costume to (warning v)\ngo to x: (x) y: (y)\nClone [Warning]\n\ndefine Launch Rocket (x) (y) (type)\nswitch costume to (rocket v)\ngo to x: (x) y: (y)\nif <(type) = [x]> then\n    Clone [RocketX]\nelse\n    Clone [RocketY]\nend\n\nwhen I start as a clone\nif <(Clone) = [RocketY]> then\n    show\n    switch costume to (rocket v)\n    if <(y position) > [0]> then\n        point in direction (90)\n        repeat until <(y position) < [-223]>\n            change y by (-15)\n        end\n    else\n        point in direction (-90)\n        repeat until <(y position) > [223]>\n            change y by (15)\n        end\n    end\n    delete this clone\nend\n\nwhen I receive [delete boss clones v]\ndelete this clone\n\nwhen I receive [boss fight black v]\nset [in cutscene? v] to [0]\ngo to [front v] layer\nwait (1) seconds\nclear graphic effects\nswitch costume to (boss v)\ngo to x: (255) y: (120)\npoint in direction (90)\nshow\nrepeat until <(x position) < [181]>\n    change x by (-5)\nend\nwait (0.5) seconds\nSay One Line [We meet again!!!~~ Only this time,~ I will KILL-YOU!!!!!]\nwait (0.5) seconds\nrepeat until <(y position) > [205]>\n    change y by (10)\nend\nhide\nwait (0.5) seconds\nrepeat (5)\n    set [enemy hit? v] to [0]\n    Spawn Enemy [110] [130] [1]\n    wait until <(enemy hit?) = [1]>\n    wait (1) seconds\nend\nrepeat (5)\n    set [enemy hit? v] to [0]\n    Spawn Enemy [110] [130] [2]\n    wait until <(enemy hit?) = [1]>\n    wait (1) seconds\nend\nrepeat (5)\n    set [enemy hit? v] to [0]\n    Spawn Enemy [130] [130] [3]\n    wait until <(enemy hit?) = [1]>\n    wait (1) seconds\nend\nrepeat (5)\n    set [enemy hit? v] to [0]\n    Spawn Enemy [130] [130] [4]\n    wait until <(enemy hit?) = [1]>\n    wait (1) seconds\nend\nwait (1) seconds\nSay One Line [Not bad!!!!!]\nSay One Line [Hopefully this attack can kill you!!!!!]\nwait (1) seconds\npoint in direction (90)\nswitch costume to (boss light right v)\ngo to x: (-280) y: (120)\nshow\nrepeat until <(x position) > [279]>\n    Clone [Light Trail]\n    change x by (10)\nend\nhide\nwait (1.5) seconds\nswitch costume to (boss light left v)\ngo to x: (280) y: (-120)\nshow\nrepeat until <(x position) < [-279]>\n    Clone [Light Trail]\n    change x by (-10)\nend\nhide\nwait (1.5) seconds\nswitch costume to (boss light right v)\npoint in direction (180)\ngo to x: (130) y: (220)\nshow\nrepeat until <(y position) < [-219]>\n    Clone [Light Trail]\n    change y by (-10)\nend\nhide\nwait (1.5) seconds\npoint in direction (90)\ngo to x: (-280) y: (0)\nshow\nrepeat until <(x position) > [279]>\n    Clone [Light Trail]\n    change x by (10)\nend\nhide\nwait (0.5) seconds\npoint in direction (90)\ngo to x: (-280) y: (130)\nshow\nrepeat until <(x position) > [279]>\n    Clone [Light Trail]\n    change x by (10)\nend\nhide\nwait (1) seconds\nswitch costume to (boss light left v)\ngo to x: (280) y: (-120)\nshow\nrepeat until <(x position) < [-279]>\n    Clone [Light Trail]\n    change x by (-10)\nend\nhide\nwait (0.5) seconds\npoint in direction (180)\ngo to x: (-130) y: (-220)\nshow\nrepeat until <(y position) > [219]>\n    Clone [Light Trail]\n    change y by (10)\nend\nhide\nwait (1) seconds\nswitch costume to (boss light right v)\npoint in direction (90)\ngo to x: (-280) y: (130)\nshow\nrepeat until <(x position) > [279]>\n    Clone [Light Trail]\n    change x by (10)\nend\nhide\nwait (0.5) seconds\nswitch costume to (boss light left v)\ngo to x: (280) y: (-120)\nshow\nrepeat until <(x position) < [-279]>\n    Clone [Light Trail]\n    change x by (-10)\nend\nhide\nwait (2.5) seconds\nswitch costume to (boss light right v)\npoint in direction (180)\ngo to x: (130) y: (220)\nshow\nrepeat until <(y position) < [-219]>\n    Clone [Light Trail]\n    change y by (-10)\nend\nhide\nwait (0.5) seconds\nswitch costume to (boss light left v)\npoint in direction (180)\ngo to x: (0) y: (-220)\nshow\nrepeat until <(y position) > [219]>\n    Clone [Light Trail]\n    change y by (10)\nend\nhide\nwait (3.5) seconds\nswitch costume to (boss v)\ngo to x: (255) y: (120)\npoint in direction (90)\nshow\nrepeat until <(x position) < [181]>\n    change x by (-5)\nend\nwait (0.5) seconds\nSay One Line [I...~~ may not be strong enough...]\nswitch costume to (boss vulnerable v)\nTake Hits [12]\nset [boss vulnerable? v] to [0]\nwait (0.5) seconds\nSay One Line [NO!!!!!]\nset [in cutscene? v] to [1]\nbroadcast (This is my last and only hope... v) and wait\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\n\nwhen I start as a clone\nif <(Clone) = [Light Trail]> then\n    switch costume to (light trail v)\n    show\n    wait (3.5) seconds\n    repeat (10)\n        change [ghost v] effect by (10)\n    end\n    delete this clone\nend\n\nwhen I receive [boss fight light v]\nset [in cutscene? v] to [0]\ngo to [front v] layer\nwait (1) seconds\nswitch costume to (boss v)\nset [ghost v] effect to (100)\ngo to x: (160) y: (120)\npoint in direction (90)\nshow\nrepeat (10)\n    change [ghost v] effect by (-10)\nend\nwait (0.5) seconds\nSay One Line [Well,~~ my only chance of success is if I-KILL YOU!!!!!]\nwait (0.5) seconds\nrepeat until <(x position) > [257]>\n    change x by (10)\nend\nhide\nwait (1) seconds\nshow\nswitch costume to (boss dark talking v)\npoint in direction (90)\ngo to x: (140) y: (200)\nrepeat until <(y position) < [101]>\n    change y by (-10)\nend\nwait (0.5) seconds\nSay One Line [Try deal with the DARKNESS!!!!!]\nwait (0.5) seconds\nreset timer\nswitch costume to (boss dark chasing v)\nrepeat until <(timer) > [25]>\n    Clone [Dark Trail Chase]\n    move (4) steps\n    point towards (light ninja v)\nend\nwait (0.5) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\nclear graphic effects\nwait (0.5) seconds\nswitch costume to (boss dark chasing v)\nshow\npoint in direction (180)\ngo to x: (-120) y: (220)\nrepeat until <(y position) < [-219]>\n    Clone [Dark Trail Attack]\n    change y by (-10)\nend\nhide\nwait (0.5) seconds\nshow\npoint in direction (90)\ngo to x: (-280) y: (-50)\nrepeat until <(x position) > [279]>\n    Clone [Dark Trail Attack]\n    change x by (10)\nend\nhide\nwait (0.5) seconds\nshow\npoint in direction (90)\ngo to x: (-280) y: (120)\nrepeat until <(x position) > [279]>\n    Clone [Dark Trail Attack]\n    change x by (10)\nend\nhide\nwait (3) seconds\nswitch costume to (boss v)\nset [ghost v] effect to (100)\ngo to x: (160) y: (120)\npoint in direction (90)\nshow\nrepeat (10)\n    change [ghost v] effect by (-10)\nend\nwait (0.5) seconds\nSay One Line [DAMN!!!!!~~~ You are GOOD!!!!!]\nwait (0.5) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\nclear graphic effects\nwait (1) seconds\nshow\nswitch costume to (boss angry v)\ngo to x: (258) y: (-50)\nrepeat until <(x position) < [191]>\n    change x by (-10)\nend\nwait (0.5) seconds\nClone [Bullet]\nglide (0.3) secs to x: (188) y: (0)\nClone [Bullet]\nglide (0.3) secs to x: (188) y: (50)\nClone [Bullet]\nwait (1) seconds\nrepeat (15)\n    glide (0.3) secs to x: (188) y: (pick random (-50) to (150))\n    Clone [Bullet]\n    wait (0.5) seconds\nend\nSay One Line [Hmm,~ not bad...~~ NOW I'LL GO FASTER!!!!!]\nwait (0.5) seconds\nrepeat (25)\n    glide (0.3) secs to x: (188) y: (pick random (-50) to (150))\n    Clone [Bullet]\n    wait (0.3) seconds\nend\nwait (0.2) seconds\nSay One Line [Even FASTER!!!!!]\nwait (0.5) seconds\nrepeat (30)\n    glide (0.3) secs to x: (188) y: (pick random (-50) to (150))\n    Clone [Bullet]\n    wait (0.1) seconds\nend\nwait (0.4) seconds\nrepeat until <(round (y position)) = [-54]>\n    change y by (((-54) - (y position)) / (5))\nend\nshow\ngo to x: (188) y: (-54)\nwait (0.3) seconds\nSay One Line [H...~H...~HOW!!!!!]\nswitch costume to (boss vulnerable v)\nTake Hits [15]\nset [boss vulnerable? v] to [0]\nwait (0.5) seconds\nSay One Line [This...~~ is the end for me...]\nset [in cutscene? v] to [1]\nbroadcast (NO!!!!! v) and wait\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\n\nwhen I start as a clone\nif <(Clone) = [Dark Trail Chase]> then\n    switch costume to (dark trail v)\n    show\n    wait (2.5) seconds\n    repeat (10)\n        change [ghost v] effect by (10)\n    end\n    delete this clone\nend\n\nwhen I start as a clone\nif <(Clone) = [Dark Trail Attack]> then\n    switch costume to (dark trail v)\n    show\n    wait (3.5) seconds\n    repeat (10)\n        change [ghost v] effect by (10)\n    end\n    delete this clone\nend\n\nwhen I start as a clone\nif <(Clone) = [Bullet]> then\n    switch costume to (bullet v)\n    set size to (150) %\n    repeat until <<touching (_edge_ v)?> or <touching (light ninja v)?>>\n        change x by (-10)\n    end\n    delete this clone\nend\n\nwhen I receive [boss killed v]\nset [transition v] to [killed]\nbroadcast (Transition v)\n\nwhen I receive [stop end v]\nstop [other scripts in sprite v]\nhide\n\n@Attack Signal Boss\n\nwhen I receive [play game v]\nforever\n    set [ghost v] effect to (100)\n    wait (0.5) seconds\n    set [ghost v] effect to (0)\n    wait (0.5) seconds\nend\n\nwhen I receive [play game v]\nforever\n    if <(boss vulnerable?) = [1]> then\n        show\n    else\n        hide\n    end\n    go to [front v] layer\n    go [backward v] (1) layers\nend\n\n@Screen\n\nwhen flag clicked\nset [in cutscene? v] to [0]\nset [ghost v] effect to (100)\nshow\n\nwhen I receive [boss appears!!!!! v]\ngo to [front v] layer\nrepeat (10)\n    change [ghost v] effect by (-10)\nend\nbroadcast (Stop v)\nset [which ninja? v] to [1]\nwait (0.5) seconds\nset [in cutscene? v] to [1]\nwait (1.5) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\nend\n\nset [in cutscene? v] to [1]\n\n@Text\n\nwhen I start as a clone\ngo to [front v] layer\nshow\nif <(costume [name v]) = [costume1]> then\n    repeat until <(dialog done?) = [1]>\n        if <(dialog done?) = [2]> then\n            delete this clone\n        end\n    end\n    switch costume to (costume2 v)\n    wait until <(dialog done?) = [2]>\n    wait (0.05) seconds\nend\nwait until <(dialog done?) = [2]>\ndelete this clone\n\ndefine print (text) brightness (brightness) colour (colour) pitch (pitch) and wait (wait)\ngo to x: (0) y: (0)\nswitch costume to (costume1 v)\ncreate clone of (_myself_ v)\nset [brightness v] effect to (brightness)\nset [color v] effect to (colour)\nswitch costume to (a v)\ngo to x: (-215) y: (150)\nset [letter v] to [1]\nset [dialog done? v] to [0]\nset [pitch v] effect to (pitch)\nrepeat (length of (text))\n    switch costume to (letter (letter) of (text))\n    if <(letter (letter) of (text)) = [~]> then\n        wait (0.2) seconds\n    else\n        if <(letter (letter) of (text)) = [-]> then\n            set x to (-215)\n            change y by (-15)\n        else\n            if <not <(letter (letter) of (text)) = [ ]>> then\n                create clone of (_myself_ v)\n            end\n            change x by (10)\n            if <<(letter (letter) of (text)) = [i]> or <(letter (letter) of (text)) = [t]>> then\n                change x by (-1)\n            end\n        end\n    end\n    change [letter v] by (1)\n    start sound [Speak v]\n    if <<(letter (letter) of (text)) = [i]> or <(letter (letter) of (text)) = [t]>> then\n        change x by (-2)\n    end\nend\nif <(wait) = []> then\n    set [dialog done? v] to [1]\n    wait until <<key (space v) pressed?> or <mouse down?>>\nelse\n    wait (wait) seconds\nend\nwait (0) seconds\nclear graphic effects\nset [dialog done? v] to [2]\nwait (0.05) seconds\n\nwhen I receive [boss talks v]\nprint [Hello there...] brightness [-100] colour [] pitch [-20] and wait []\nprint [You may know who I am...] brightness [-100] colour [] pitch [-20] and wait []\nprint [I am Runexio.~~ I am the one who turned this-world into darkness.] brightness [-100] colour [] pitch [-20] and wait []\nprint [And today...~~~ You shall DIE!!!!!] brightness [-100] colour [] pitch [-20] and wait []\nset [transition v] to [red]\nbroadcast (Transition v)\n\nwhen I receive [red ninja v]\nprint [Red Ninja...~ Let's see how well you do!!] brightness [-100] colour [] pitch [-20] and wait []\n\nwhen I receive [talk v]\nprint (SAY) brightness [-100] colour [] pitch [-20] and wait []\n\nwhen I receive [time for you... green v]\nprint [Time to fight you...~~ GREEN NINJA!!] brightness [-100] colour [] pitch [-20] and wait []\nset [transition v] to [green]\nbroadcast (Transition v)\n\nwhen I receive [well, hopefully blue v]\nprint [Well, hopefully blue will be much of an-easier fight!!] brightness [-100] colour [] pitch [-20] and wait []\nset [transition v] to [blue]\nbroadcast (Transition v)\n\nwhen I receive [time for an old foe... v]\nprint [It's time for me to fight an OLD FOE!!!!!] brightness [-100] colour [] pitch [-20] and wait []\nset [transition v] to [black]\nbroadcast (Transition v)\n\nwhen I receive [this is my last and only hope... v]\nprint [This will be...~~ my last and ONLY hope...] brightness [-100] colour [] pitch [-20] and wait []\nset [transition v] to [light]\nbroadcast (Transition v)\n\nwhen I receive [no!!!!! v]\nprint [NO!!!!!] brightness [-100] colour [] pitch [-20] and wait []\nbroadcast (Boss Killed v)\n\n@Transition\n\nwhen I start as a clone\ngo to [front v] layer\nif <(costume [number v]) = [2]> then\n    show\n    set [ghost v] effect to (0)\n    repeat (18)\n        switch costume to (blank v)\n        change size by ((size) / (4))\n        switch costume to (circle v)\n    end\n    change [done? v] by (1)\n    repeat (10)\n        change [ghost v] effect by (10)\n    end\n    delete this clone\nend\n\nwhen flag clicked\nhide\ngo to x: (0) y: (0)\n\nwhen I receive [transition v]\nset [done? v] to [0]\nset [clone id v] to [0]\nwait (0) seconds\nset [brightness v] effect to (20)\nhide\nrepeat (3)\n    go to [front v] layer\n    create clone of (_myself_ v)\n    change [brightness v] effect by (-10)\n    wait (0.05) seconds\nend\nswitch costume to (circle v)\nset [brightness v] effect to (20)\nrepeat (3)\n    go to [front v] layer\n    create clone of (_myself_ v)\n    change [brightness v] effect by (-10)\n    wait (0.05) seconds\nend\nwait until <(Done?) = [6]>\nif <(TRANSITION) = [red]> then\n    broadcast (Boss Fight RED v)\nelse\n    if <(TRANSITION) = [green]> then\n        broadcast (Boss Fight GREEN v)\n    else\n        if <(TRANSITION) = [blue]> then\n            broadcast (Boss Fight BLUE v)\n        else\n            if <(TRANSITION) = [black]> then\n                broadcast (Boss Fight Black v)\n            else\n                if <(TRANSITION) = [light]> then\n                    broadcast (Boss Fight LIGHT v)\n                else\n                end\n            end\n        end\n    end\nend\n\nwhen flag clicked\nswitch costume to (circle v)\n\nwhen I receive [transition v]\nif <(TRANSITION) = [red]> then\n    wait (0.3) seconds\n    set [in cutscene? v] to [0]\nelse\n    if <(TRANSITION) = [green]> then\n        wait (0.3) seconds\n        set [in cutscene? v] to [0]\n        set [which ninja? v] to [2]\n    else\n        if <(TRANSITION) = [blue]> then\n            wait (0.3) seconds\n            set [in cutscene? v] to [0]\n            set [which ninja? v] to [3]\n        else\n            if <(TRANSITION) = [black]> then\n                wait (0.3) seconds\n                set [in cutscene? v] to [0]\n                set [which ninja? v] to [4]\n            else\n                if <(TRANSITION) = [light]> then\n                    wait (0.3) seconds\n                    set [in cutscene? v] to [0]\n                    set [which ninja? v] to [5]\n                else\n                    if <(TRANSITION) = [killed]> then\n                        wait (0.3) seconds\n                        set [in cutscene? v] to [0]\n                        set [boss fight? v] to [0]\n                    end\n                end\n            end\n        end\n    end\nend\n\nwhen I receive [stop end v]\nstop [other scripts in sprite v]\nhide\n\n@Boss Fight Haze\n\nwhen flag clicked\nhide\n\nwhen I receive [transition v]\nwait (0.3) seconds\nshow\nswitch costume to (dot v)\nset size to (200) %\ngo to [front v] layer\nif <(TRANSITION) = [red]> then\n    switch costume to (red ninja v)\nelse\n    if <(TRANSITION) = [green]> then\n        switch costume to (green ninja v)\n    else\n        if <(TRANSITION) = [blue]> then\n            switch costume to (blue ninja v)\n        else\n            if <(TRANSITION) = [black]> then\n                switch costume to (black ninja v)\n            else\n                if <(TRANSITION) = [light]> then\n                    switch costume to (light ninja v)\n                else\n                    hide\n                end\n            end\n        end\n    end\nend\n\nwhen I receive [transition to green v]\nwait (0.3) seconds\n\n@Player Health Boss Fight\n\nwhen I receive [transition v]\nshow\nset [player health v] to [5]\nforever\n    switch costume to (PLAYER HEALTH)\n    if <(PLAYER HEALTH) = [0]> then\n        broadcast (Boss Fight Die v)\n        hide\n        wait (5) seconds\n        show\n        set [player health v] to [5]\n    end\nend\n\nwhen flag clicked\nset [player health v] to [5]\ngo to x: (-219) y: (157)\nhide\n\nwhen I receive [boss killed v]\nstop [other scripts in sprite v]\nhide\n\n@End Cutscene\n\nwhen flag clicked\nhide\nswitch costume to (black v)\n\nwhen I receive [cutscene v]\nset [ghost v] effect to (100)\nshow\ngo to [front v] layer\nstop all sounds\nrepeat (20)\n    change [ghost v] effect by (-5)\nend\nbroadcast (Stop End v)\nwait (0.3) seconds\nset [brightness v] effect to (-100)\nnext costume\nrepeat (20)\n    change [brightness v] effect by (5)\nend\nwait until <mouse down?>\nrepeat (20)\n    change [brightness v] effect by (-5)\nend\nwait (1) seconds\nhide\nbroadcast (Outro v)\nstop [this script v]\n\nwhen I receive [boss killed v]\nwait until <(level) = [26]>\nbroadcast (Cutscene v)\n\n@Button\n\nwhen flag clicked\nhide\n\nwhen I receive [start v]\nshow\ngo to [front v] layer\ngo to x: (0) y: (-100)\nforever\n    if <touching (mouse-pointer v)?> then\n        set [brightness v] effect to (10)\n        if <mouse down?> then\n            hide\n            broadcast (Play Game v)\n            stop [this script v]\n        end\n    else\n        set [brightness v] effect to (0)\n    end\nend\n\n@Title\n\nwhen I receive [start v]\nshow\ngo to x: (0) y: (85)\ngo to [front v] layer\nforever\n    point in direction ((([sin v] of ((timer) * (300)) ) * (7)) + (90))\nend\n\nwhen I receive [play game v]\nstop [other scripts in sprite v]\nhide\n\nwhen flag clicked\nhide\n\n@Image\n\nwhen flag clicked\nhide\n\nwhen I receive [start v]\nshow\ngo to x: (0) y: (0)\n\nwhen I receive [play game v]\nstop [other scripts in sprite v]\nhide\n\n@Intro\n\ndefine Particle Physics\nmove ((yv) + (3)) steps\nset [yv v] to ((yv) * (0.95))\nchange x by (xv)\nset [xv v] to ((xv) * (0.8))\nif <([abs v] of (direction) ) < [90]> then\n    turn right (((0) - (direction)) / (30)) degrees\nelse\n    if <(direction) < [0]> then\n        turn right (((-180) - (direction)) / (30)) degrees\n    else\n        turn right (((180) - (direction)) / (30)) degrees\n    end\nend\n\ndefine Particles (amount)\nrepeat (amount)\n    Clone [Particle]\nend\n\nwhen I start as a clone\nif <(Clone) = [Particle]> then\n    go to [front v] layer\n    set size to (50) %\n    switch costume to (join [Particle] (pick random (1) to (4)))\n    show\n    set [brightness v] effect to (b)\n    set [color v] effect to (90)\n    set [ghost v] effect to (25)\n    go to x: (0) y: (0)\n    point in direction (pick random (-179) to (179))\n    set [xv v] to (pick random (10) to (-10))\n    set [yv v] to (pick random (5) to (15))\n    repeat (50)\n        go to [front v] layer\n        Particle Physics\n        if <touching (_edge_ v)?> then\n            change [ghost v] effect by (10)\n            go to [front v] layer\n        end\n    end\n    if <not <touching (_edge_ v)?>> then\n        repeat (10)\n            go to [front v] layer\n            Particle Physics\n            change [ghost v] effect by (10)\n        end\n    end\n    delete this clone\nend\n\ndefine Smooth (x) (y) (s) (d) (g)\nrepeat until <<(round (x position)) = (x)> and <<(round (y position)) = (y)> and <<(round (size)) = (s)> and <(round (direction)) = (d)>>>>\n    change x by (((x) - (x position)) / (5))\n    change y by (((y) - (y position)) / (5))\n    change size by (((s) - (size)) / (5))\n    turn right (((d) - (direction)) / (5)) degrees\n    change [ghost v] effect by (g)\nend\n\nwhen flag clicked\nshow\nset [stop lffr? v] to [0]\ngo to x: (0) y: (0)\npoint in direction (90)\nstart sound [Yoshi Star Galaxy Remix v]\nset volume to (100) %\ngo to x: (0) y: (0)\nswitch costume to (jc v)\nset [intro start? v] to [0]\nClone [Back]\nwait (1) seconds\nrepeat (9)\n    next costume\nend\nwait (1.1) seconds\nrepeat (9)\n    next costume\nend\nwait (1.5) seconds\nswitch costume to (logo v)\nClone [Developed by]\nrepeat (15)\n    change x by (8)\n    turn right (24) degrees\nend\nwait (1) seconds\nClone [Square]\nwait (0.5) seconds\nClone [Movement]\nset [b v] to [40]\nrepeat (4)\n    Particles [30]\n    wait (1.5) seconds\nend\nwait (1) seconds\nset [stop lffr? v] to [1]\nClone [End Square]\nstop [other scripts in sprite v]\nhide\nwait until <(intro start?) = [1]>\nbroadcast (Start v)\nstop [this script v]\n\nwhen I start as a clone\nif <(Clone) = [Developed by]> then\n    switch costume to (developed by v)\n    set size to (225) %\n    go to x: (-350) y: (0)\n    set size to (150) %\n    repeat (60)\n        change x by (((-100) - (x position)) / (5))\n    end\nend\n\ndefine Clone (id)\nset [clone v] to (id)\ncreate clone of (_myself_ v)\n\nwhen I start as a clone\nif <(Clone) = [Square]> then\n    show\n    go to [front v] layer\n    go to x: (0) y: (1000)\n    switch costume to (square v)\n    Smooth [0] [-370] [100] [90] [0]\n    repeat until <(stop lffr?) = [1]>\n        set [brightness v] effect to (pick random (0) to (30))\n        Clone [LFFR]\n    end\nend\n\nwhen I start as a clone\nif <(Clone) = [Movement]> then\n    go to [front v] layer\n    forever\n        show\n        switch costume to (logo v)\n        go to x: (0) y: (0)\n        set [data v] to [70]\n        set [doat v] to (pick random (70) to (110))\n        set [daro v] to (pick random (-1) to (1))\n        repeat (17)\n            set [brightness v] effect to (data)\n            set [data v] to ((data) * (0.7))\n            set size to ((200) + (data)) %\n            point in direction ((doat) + (((data) / (4)) * (daro)))\n        end\n    end\nend\n\nwhen I start as a clone\nif <(Clone) = [End Square]> then\n    stop all sounds\n    start sound [Low Whoosh v]\n    switch costume to (end square v)\n    go to [front v] layer\n    set size to (150) %\n    go to x: (-585) y: (0)\n    set size to (100) %\n    repeat (60)\n        change x by (((0) - (x position)) / (5))\n    end\n    set [intro start? v] to [1]\n    broadcast (Delete Intro Clones v)\nend\n\nwhen I receive [delete intro clones v]\ndelete this clone\n\nwhen I start as a clone\nif <(Clone) = [Back]> then\n    show\n    go to [back v] layer\n    switch costume to (dot v)\n    set size to (100) %\n    switch costume to (back v)\n    forever\n        point in direction ((([cos v] of ((timer) * (100)) ) * (15)) + (90))\n    end\nend\n\nwhen flag clicked\nforever\n    if <<key (space v) pressed?> or <mouse down?>> then\n        stop all sounds\n        broadcast (Start v)\n        stop [other scripts in sprite v]\n        broadcast (Delete Intro Clones v)\n        hide\n        stop [this script v]\n    end\nend\n\nwhen I start as a clone\nif <(Clone) = [LFFR]> then\n    go to x: (pick random (-240) to (240)) y: (-300)\n    switch costume to (pick random (29) to (32))\n    if <(costume [number v]) = [32]> then\n        point in direction (pick random (1) to (360))\n    end\n    set size to (25) %\n    show\n    go to [front v] layer\n    set [y v] to (pick random (12) to (17))\n    repeat (100)\n        set size to (150) %\n        change [y v] by (-1)\n        change y by (y)\n        set size to (25) %\n    end\n    delete this clone\nend\n\n@Outro\n\nwhen flag clicked\nhide\nswitch costume to (text v)\nset [ghost v] effect to (100)\n\nwhen I start as a clone\nif <(Clone) = [OC]> then\n    show\n    set [ghost v] effect to (100)\n    go to x: (0) y: (-30)\n    go to [front v] layer\n    go [backward v] (1) layers\n    switch costume to (oc v)\n    repeat (10)\n        change [ghost v] effect by (-10)\n    end\n    set [tan v] to [0]\n    forever\n        if <touching (mouse-pointer v)?> then\n            change size by (((150) - (size)) / (2))\n            point in direction (((90) + (([sin v] of ((timer) * (200)) ) * (10))) + ([tan v] of (TAN) ))\n            change [tan v] by (1)\n        else\n            change size by (((100) - (size)) / (2))\n            point in direction (((90) + (([sin v] of ((timer) * (200)) ) * (10))) + ([tan v] of (TAN) ))\n            change [tan v] by (1)\n        end\n    end\nend\n\ndefine Clone Sprite ID (id) (#)\nset [clone v] to (id)\nrepeat (#)\n    create clone of (_myself_ v)\nend\n\nwhen I start as a clone\nif <(Clone) = [Projects]> then\n    show\n    set [ghost v] effect to (100)\n    go to x: (0) y: (0)\n    go to [front v] layer\n    go [backward v] (1) layers\n    switch costume to (games v)\n    repeat (10)\n        change [ghost v] effect by (-10)\n    end\n    forever\n        set y to (([sin v] of ((timer) * (300)) ) * (7))\n    end\nend\n\nwhen I start as a clone\nif <(Clone) = [Name]> then\n    show\n    set [ghost v] effect to (100)\n    go to x: (0) y: (130)\n    go to [front v] layer\n    go [backward v] (1) layers\n    switch costume to (name v)\n    repeat (10)\n        change [ghost v] effect by (-10)\n    end\n    forever\n        point in direction ((([sin v] of ((timer) * (500)) ) * (7)) + (90))\n    end\nend\n\nwhen I start as a clone\nif <(Clone) = [Back]> then\n    show\n    set [ghost v] effect to (100)\n    go to x: (0) y: (0)\n    go to [front v] layer\n    go [backward v] (1) layers\n    switch costume to (back v)\n    repeat (10)\n        change [ghost v] effect by (-10)\n    end\n    forever\n        point in direction ((([cos v] of ((timer) * (100)) ) * (15)) + (90))\n    end\nend\n\nwhen I receive [show v]\nshow\nrepeat (10)\n    change [ghost v] effect by (-10)\nend\n\nwhen I receive [outro v]\nforever\n    play sound [Outro v] until done\nend\n\nwhen I receive [outro v]\ngo to [front v] layer\nClone Sprite ID [Back] [1]\nClone Sprite ID [OC] [1]\nClone Sprite ID [Name] [1]\nClone Sprite ID [Projects] [1]\nbroadcast (Show v)\n\n@TN\n\nwhen flag clicked\ngo to x: (0) y: (0)\nforever\n    show\n    go to [front v] layer\n    set [ghost v] effect to (100)\nend\n\n
ㅤㅤ★★★★★ The Ninja Squad 5 ★★★★★\nㅤㅤㅤㅤㅤㅤㅤby @JC_ProGold\n\nSkip the intro by clicking on the mouse or tapping the space bar.\n\nHere is the project you have all been waiting MONTHS for!!!!! It has been almost 6 months since the release of part 4, and now here is part 5 :D\n\n★★★ STORY ★★★\nThe 5 ninjas entered the Castle of Werwell... It was dangerous but at the very end, they came across the baddie they once met before... RUNEXIO!!!!! Can you defeat him? Or will you die because of his immense power?\n\n★★★ CONTROLS ★★★\n➜Reset Level - Press 'r'\n➜Skip Level if it is allowed - Press 's'\n\n➜Move and jump - Arrow keys, WASD or use the mouse pointer\n➜Switch ninja - Click the 'switch button' or press 'z'\n\n# These abilities are not always on, you have to turn them on\n➜Turn on or off special ability - Space bar or click the icon on the bottom left \n➜Switch between weapons (only black) - Space bar or click the icon on the bottom left\n\n➜Use sword - Press 't' or click the 'attack button' \n➜Use star (only black) - Press 'f' or click the 'throw button'\n\n★★★ POWERS AND WEAKNESSESS ★★★\nRed - Resistant to lava and light, dies to grass, water and darkness. Can get a JUMP BOOST.\nGreen - Resistant to grass and light, dies to lava, water and darkness. Can get a SPEED BOOST.\nBlue - Resistant to water and light, dies to lava, grass and darkness. Can get a SHRINK BOOST.\nBlack - Resistant to lava, grass, water and darkness, dies to light. Can use TWO WEAPONS.\nLight - Resistant to light, dies to lava, grass, water and darkness. Can get a LIGHT BOOST.\n\nMake sure to ❤️ and ⭐ is you enjoy!!!!!