The Ninja Warrior || A Platformer #games

Instructions: Hi And Welcome To My Newest Platformer\nThe Ninja Warrior || A Platformer\nOver 25+ Hours Of Work\n▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬\nCan We Get Featured Or On Trending?\n▶ Arrow Keys ◈ WASD To Move\n▶ Watch Out For Spikes, Holes And Lava Enemy Ninjas And Enemy Ninja Stars\n▶ Boosters Make You Jump Higher\n▶ "R" To Reset A Level\n★ ALL LEVELS ARE POSSIBLE\n★★★★★★★★★★Credits★★★★★★★★★★\nPlayer Art By @epikcoding (I Made Some Modifications)\nPlatformer Physics By @Funut\nGround, Flower And Mushroom Art By @IcedSnow And Kenney.nl\nShuriken Art By @Will_Wam\nBooster And Spike Art By @TimMcCool\nCloud Effect By @Squad_Legend\nMusic From Naruto\nOther Code And Art By Me\n\n❤️ By @MarioRocks11\n❤️ And ⭐️ By @KrishTheKing123\n❤️ By @Kodiak77-77\n\nRemember To ❤️ And ⭐️\n\nSuggest It To Get Featured Here:\nhttps://scratch.mit.edu/studios/4228481/comments\n\nreport bugs and faults in the comments\n\nOver 500 Code Blocks\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n★★★★★★★★★★★Tags★★★★★★★★★★★\n#Ninja #Platformer #Colors #Simple #Art #Slope #Wall #Star #Advanced #Hello #Line #Flower #Grass #Monster1234Funny #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Games #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials #Tutorials\n\n\n\n\n

@Stage\n\nwhen flag clicked\nforever\n    play sound [song v] until done\nend\n\n@Blank\n\n@Game Manager\n\nwhen flag clicked\nhide\nset [end v] to [0]\nset [deaths v] to [0]\nhide variable [deaths v]\nhide variable [☁ wr deaths v]\nrepeat until <(End) = [1]>\n    wait (0.1) seconds\nend\n\nwhen flag clicked\nwait until <(Level) = [14]>\nbroadcast (End v)\n\nwhen I receive [end v]\nif <(Deaths) > (☁ WR Deaths)> then\n    set [☁ wr deaths v] to (Deaths)\nend\nset [end v] to [1]\n\nwhen I receive [restart v]\nchange [deaths v] by (1)\n\nwhen I receive [end v]\nshow\nshow variable [☁ wr deaths v]\nshow variable [deaths v]\ngo to [front v] layer\nstop [all v]\n\nset [☁ wr deaths v] to [20]\n\n@Player\n\ndefine platform physics (jump height) (gravity) (friction) (movement speed)\nswitch costume to (hitbox v)\nchange y by (Y Velocity)\nif <touching (ground v)?> then\n    repeat ([abs v] of (Y Velocity) )\n        if <touching (ground v)?> then\n            change y by ((-1) * (([abs v] of (Y Velocity) ) / (Y Velocity)))\n        end\n    end\n    if <<<key (up arrow v) pressed?> or <key (w v) pressed?>> and <not <(Y Velocity) > [0]>>> then\n        set [y velocity v] to (jump height)\n    else\n        set [y velocity v] to [0]\n    end\nelse\n    change [y velocity v] by (gravity)\nend\nif <<key (right arrow v) pressed?> or <key (d v) pressed?>> then\n    change [x velocity v] by (movement speed)\n    point in direction (90)\nend\nif <<key (left arrow v) pressed?> or <key (a v) pressed?>> then\n    change [x velocity v] by ((-1) * (movement speed))\n    point in direction (-90)\nend\nchange x by (X Velocity)\nif <touching (ground v)?> then\n    set [old y v] to (y position)\n    repeat ([abs v] of (X Velocity) )\n        if <touching (ground v)?> then\n            change y by (1)\n        end\n    end\n    if <touching (ground v)?> then\n        set y to (Old Y)\n        repeat ([ceiling v] of ([abs v] of (X Velocity) ) )\n            if <touching (ground v)?> then\n                change x by ((-1) * (([abs v] of (X Velocity) ) / (X Velocity)))\n            end\n        end\n        set [x velocity v] to [0]\n    end\nend\nset [x velocity v] to ((X Velocity) * (friction))\nswitch costume to (ninja v)\n\nwhen flag clicked\nset [level v] to [1]\nset rotation style [left-right v]\nbroadcast (Reset v)\nforever\n    platform physics (13.5) (-1) (0.7) (2.1)\n    if <(x position) > [235]> then\n        change [level v] by (1)\n        broadcast (Reset v)\n    end\n    if <touching (spikes v)?> then\n        broadcast (Reset v)\n        broadcast (Restart v)\n    end\n    if <touching (boosters v)?> then\n        set [y velocity v] to [20]\n    end\nend\n\ndefine Respawn\nif <(Level) = [8]> then\n    go to x: (182) y: (80)\nelse\n    go to x: (-207) y: (-72)\nend\n\nwhen I receive [reset v]\nRespawn\n\nwhen [r v] key pressed\nRespawn\n\n@Enemies\n\nwhen flag clicked\nhide\n\ndefine Create Clone At (x) (y) With Clone Speed If Type = 1 (speed) With Type: (type) With Projectile Speed If Type = 2 (projectile speed)\nset [clone speed v] to (speed)\nset [projectile speed v] to (projectile speed)\nset [enemy v] to (type)\ngo to x: (x) y: (y)\ncreate clone of (_myself_ v)\n\nwhen I start as a clone\nset rotation style [left-right v]\nset [enemy y velocity v] to [0]\nshow\nforever\n    if <(Enemy) = [1]> then\n        Gravity\n        if <not <touching (player v)?>> then\n            if <not <([x position v] of [player v]) = (x position)>> then\n                point towards (player v)\n            end\n        end\n        if <touching (player v)?> then\n            broadcast (Reset v)\n        end\n        if <(Wall Detection) = [0]> then\n            if <not <touching (player v)?>> then\n                if <not <([x position v] of [player v]) = (x position)>> then\n                    if <(direction) > [0]> then\n                        change x by (Clone Speed)\n                    end\n                    if <(direction) < [0]> then\n                        change x by (join [-] (Clone Speed))\n                    end\n                end\n            end\n        end\n        switch costume to (wall detection v)\n        if <touching (ground v)?> then\n            set [wall detection v] to [1]\n        else\n            set [wall detection v] to [0]\n        end\n        switch costume to (enemy v)\n    else\n        if <(Enemy) = [2]> then\n            switch costume to (enemy2 v)\n            if <not <touching (player v)?>> then\n                if <not <([x position v] of [player v]) = (x position)>> then\n                    point towards (player v)\n                end\n            end\n            if <touching (player v)?> then\n                broadcast (Reset v)\n                broadcast (Restart v)\n            end\n        else\n            delete this clone\n        end\n    end\nend\n\ndefine Gravity\nif <not <touching (ground v)?>> then\n    change [enemy y velocity v] by (-1)\n    change y by (Enemy Y Velocity)\nend\nif <touching (ground v)?> then\n    set [enemy y velocity v] to [0]\n    repeat until <not <touching (ground v)?>>\n        change y by (1)\n    end\nend\n\nwhen I receive [reset v]\nwait (0.01) seconds\nif <(Level) = [2]> then\n    Create Clone At [178] [-50] With Clone Speed If Type = 1 [3] With Type: [1] With Projectile Speed If Type = 2 [1]\nend\nif <(Level) = [3]> then\n    Create Clone At [178] [-119] With Clone Speed If Type = 1 [3] With Type: [2] With Projectile Speed If Type = 2 [1]\nend\nif <(Level) = [7]> then\n    Create Clone At [178] [-50] With Clone Speed If Type = 1 [3] With Type: [1] With Projectile Speed If Type = 2 [1]\n    Create Clone At [178] [-119] With Clone Speed If Type = 1 [3] With Type: [2] With Projectile Speed If Type = 2 [1]\nend\nif <(Level) = [8]> then\n    Create Clone At [-75] [130] With Clone Speed If Type = 1 [3] With Type: [1] With Projectile Speed If Type = 2 [1]\n    Create Clone At [-98] [-120] With Clone Speed If Type = 1 [3] With Type: [2] With Projectile Speed If Type = 2 [0.9]\n    wait (0.03) seconds\n    Create Clone At [-12] [-120] With Clone Speed If Type = 1 [3] With Type: [2] With Projectile Speed If Type = 2 [0.9]\n    wait (0.03) seconds\n    Create Clone At [148] [-120] With Clone Speed If Type = 1 [3] With Type: [2] With Projectile Speed If Type = 2 [0.9]\nend\nif <(Level) = [11]> then\n    Create Clone At [-20] [51] With Clone Speed If Type = 1 [3] With Type: [2] With Projectile Speed If Type = 2 [1]\n    Create Clone At [220] [-52] With Clone Speed If Type = 1 [3] With Type: [1] With Projectile Speed If Type = 2 [1]\nend\nif <(Level) = [12]> then\n    Create Clone At [222] [-122] With Clone Speed If Type = 1 [3] With Type: [2] With Projectile Speed If Type = 2 [0.6]\n    Create Clone At [171] [44] With Clone Speed If Type = 1 [3.5] With Type: [1] With Projectile Speed If Type = 2 [0.6]\n    Create Clone At [80] [110] With Clone Speed If Type = 1 [3.5] With Type: [1] With Projectile Speed If Type = 2 [0.6]\n    Create Clone At [-22] [166] With Clone Speed If Type = 1 [3.5] With Type: [1] With Projectile Speed If Type = 2 [0.6]\nend\nif <(Level) = [13]> then\n    Create Clone At [0] [-143] With Clone Speed If Type = 1 [3] With Type: [3] With Projectile Speed If Type = 2 [0.6]\nend\n\nwhen I receive [reset v]\ndelete this clone\n\ndefine Enemy Type 2 Create Projectiles\nchange [enemy ninja star # v] by (1)\nadd (x position) to [enemy x v]\nadd (y position) to [enemy y v]\ncreate clone of (enemy shurikens v)\n\nwhen I start as a clone\nwait (([abs v] of (Projectile Speed) ) / (3)) seconds\nforever\n    if <(Enemy) = [2]> then\n        Enemy Type 2 Create Projectiles\n        wait ([abs v] of (Projectile Speed) ) seconds\n    end\nend\n\nwhen I receive [reset v]\nset [enemy ninja star # v] to [0]\ndelete all of [enemy x v]\ndelete all of [enemy y v]\n\nwhen flag clicked\nset [level v] to [1]\n\nwhen I start as a clone\nforever\n    if <not <(Enemy) = [3]>> then\n        if <touching (player shurikens v)?> then\n            delete this clone\n        end\n    end\nend\n\n@Ground\n\nwhen flag clicked\nforever\n    switch costume to (Level)\nend\n\n@Art\n\nwhen flag clicked\nforever\n    go to [back v] layer\n    switch costume to (Level)\n    set [ghost v] effect to (15)\nend\n\n@Enemy Shurikens\n\nwhen flag clicked\nhide\n\nwhen I start as a clone\ngo to [back v] layer\ngo to x: (item (Enemy Ninja star #) of [enemy x v]) y: (item (Enemy Ninja star #) of [enemy y v])\nshow\npoint towards (player v)\nrepeat until <<<touching (_edge_ v)?> or <touching (player v)?>> or <<touching (ground v)?> or <<touching (player shurikens v)?> or <<touching (spikes v)?> or <touching (lava v)?>>>>>\n    move (10) steps\n    if <touching (player v)?> then\n        broadcast (Reset v)\n        broadcast (Restart v)\n        hide\n        delete this clone\n    end\nend\nif <touching (player v)?> then\n    broadcast (Reset v)\n    broadcast (Restart v)\nend\nhide\ndelete this clone\n\nwhen I start as a clone\nforever\n    switch costume to ((costume [number v]) - (1))\nend\n\nwait (0.03) seconds\n\nwhen I receive [reset v]\ndelete this clone\n\n@Player Shurikens\n\nwhen flag clicked\nhide\nforever\n    if <key (space v) pressed?> then\n        create clone of (_myself_ v)\n        wait (1) seconds\n    end\nend\n\nwhen I start as a clone\nif <([direction v] of [player v]) = [90]> then\n    set [look v] to [0]\nend\nif <([direction v] of [player v]) = [-90]> then\n    set [look v] to [1]\nend\ngo to [back v] layer\nshow\ngo to (player v)\npoint in direction ([direction v] of [player v])\nrepeat until <<touching (_edge_ v)?> or <<touching (ground v)?> or <<touching (spikes v)?> or <touching (lava v)?>>>>\n    if <(Look) = [1]> then\n        change x by (-11)\n        turn right (15) degrees\n    end\n    if <(Look) = [0]> then\n        change x by (11)\n        turn right (15) degrees\n    end\nend\nhide\ndelete this clone\n\nwhen I receive [reset v]\ndelete this clone\n\nmove (10) steps\n\n@lava\n\nwhen I start as a clone\nforever\n    show\n    set [ghost v] effect to (70)\n    go to [back v] layer\n    switch costume to (Level)\n    set y to ((([sin v] of (((Time) + (me)) * (300)) ) * (8)) - ((me) * (5)))\nend\n\nwhen I start as a clone\nshow\nforever\n    if <touching (player v)?> then\n        broadcast (Reset v)\n        broadcast (Restart v)\n    end\nend\n\nwhen flag clicked\nclear graphic effects\ngo to x: (0) y: (0)\nset [me v] to [1]\nrepeat (3)\n    create clone of (_myself_ v)\n    change y by (-5)\n    change [brightness v] effect by (-10)\n    change [me v] by (1)\nend\n\n@spikes\n\nwhen flag clicked\nforever\n    switch costume to (Level)\nend\n\n@shadows\n\nwhen flag clicked\nforever\n    switch costume to (Level)\n    set [ghost v] effect to (65)\nend\n\n@Boosters\n\nwhen flag clicked\nforever\n    switch costume to (Level)\nend\n\n@Assets\n\n@Clouds\n\nwhen flag clicked\ngo to x: (240) y: (240)\nhide\nset [cos. v] to [1]\nswitch costume to (costume2 v)\nwait (0.25) seconds\nforever\n    create clone of (_myself_ v)\n    wait (pick random (1.3) to (2.3)) seconds\nend\n\nwhen I start as a clone\ngo to [front v] layer\nshow\nset size to (pick random (82) to (102)) %\nset [ghost v] effect to (pick random (30) to (50))\ngo to x: (230) y: (pick random (155) to (20))\nset [cos. v] to (pick random (1) to (3))\nif <(cos.) = [1]> then\n    switch costume to (costume1 v)\nend\nif <(cos.) = [2]> then\n    switch costume to (costume2 v)\nend\nif <(cos.) = [3]> then\n    switch costume to (costume3 v)\nend\nrepeat until <(x position) < [-230]>\n    move (pick random (-4) to (-8)) steps\nend\ndelete this clone\n\n@TB\n\nwhen flag clicked\ngo to x: (0) y: (0)\nset [ghost v] effect to (100)\nset rotation style [left-right v]\n\nwhen [r v] key pressed\nbroadcast (Reset v)\n\n@shadows2\n\nwhen flag clicked\nset [direction v] to [10]\nforever\n    go to x: (0) y: (-148)\n    switch costume to (Level)\n    if <touching (player v)?> then\n        broadcast (Reset v)\n        broadcast (Restart v)\n    end\nend\n\nwhen flag clicked\nforever\n    point in direction (([sin v] of ((timer) * (100)) ) * (200))\nend\n\n