Astro >>> A 360 degrees Platformer
@Stage\n\n@player\n\nwhen flag clicked\nshow\nset [air left v] to [100]\nswitch costume to (astronaut right v)\ngo to x: (0) y: (-10)\n\nwhen I receive [player to left v]\nswitch costume to (astronaut left v)\n\nwhen I receive [player to right v]\nswitch costume to (astronaut right v)\n\ngo to x: (0) y: (-40)\n\nwhen I receive [dead v]\nswitch costume to (astronaut right v)\ngo to x: (0) y: (-10)\n\nwhen flag clicked\nforever\n    change y by (-5)\n    if <touching color (#ff0000)?> then\n        repeat (20)\n            change [ghost v] effect by (5)\n        end\n        broadcast (setup v)\n        repeat (20)\n            change [ghost v] effect by (-5)\n        end\n    end\n    change y by (5)\nend\n\nwhen flag clicked\nforever\n    change [air left v] by (-1)\n    wait (0.2) seconds\nend\n\nwhen flag clicked\nforever\n    if <(air left) = [0]> then\n        repeat (20)\n            change [ghost v] effect by (5)\n        end\n        stop all sounds\n        broadcast (setup v)\n        repeat (20)\n            change [ghost v] effect by (-5)\n        end\n    end\nend\n\nwhen I receive [setup v]\nset [air left v] to [100]\n\nwhen flag clicked\nforever\n    change y by (-5)\n    if <<<touching color (#00ffff)?> and <touching (moon v)?>> or <touching color (#00ffff)?>> then\n        broadcast (setup v)\n        broadcast (next level v)\n    end\n    change y by (5)\nend\n\nwhen I receive [next level v]\nset [air left v] to [100]\n\nwhen flag clicked\nforever\n    repeat until <(level) = [3]>\n        play sound [Vexento - Masked Heroes \[NCS Fanmade\] v] until done\n    end\nend\n\nwhen flag clicked\nshow variable [air left v]\nforever\n    repeat until <(level) = [3]>\n        if <(air left) = [35]> then\n            start sound [alert sound v]\n        end\n    end\nend\n\nwhen I receive [outro v]\nstop all sounds\nhide variable [air left v]\nhide\nstop [this script v]\n\nwhen flag clicked\nforever\n    if <(level) = [3]> then\n        hide\n        broadcast (end v)\n        stop [this script v]\n    end\nend\n\n@moon\n\nwhen flag clicked\nshow\nbroadcast (setup v)\nset [level v] to [1]\nforever\n    change [_y vel v] by (1)\n    if <key (right arrow v) pressed?> then\n        change [_r vel v] by (-0.2)\n        broadcast (player to right v)\n    end\n    if <key (left arrow v) pressed?> then\n        change [_r vel v] by (0.2)\n        broadcast (player to left v)\n    end\n    set [_r vel v] to ((_R vel) * (0.82))\n    turn right (_R vel) degrees\n    if <touching (player v)?> then\n        change y by (-1)\n        if <touching (player v)?> then\n            change y by (-1)\n            if <touching (player v)?> then\n                change y by (-1)\n                if <touching (player v)?> then\n                    change y by (-1)\n                    if <touching (player v)?> then\n                        change y by (4)\n                        turn right ((_R vel) * (-1)) degrees\n                        set [_r vel v] to [0]\n                    end\n                end\n            end\n        end\n    end\n    change y by (_Y vel)\n    if <touching (player v)?> then\n        change y by ((_Y vel) * (-1))\n        set [_y vel v] to [0]\n    end\n    change y by (1)\n    if <touching (player v)?> then\n        if <key (up arrow v) pressed?> then\n            set [_y vel v] to [-16]\n        end\n    end\n    change y by (-1)\nend\n\nwhen I receive [setup v]\nSet Size to [500]\nset [_r vel v] to [0]\nset [_y vel v] to [0]\ngo to x: (0) y: (-800)\npoint in direction (90)\n\ndefine Set Size to (size)\nswitch costume to (dot v)\nset size to (size) %\nswitch costume to (level 1 v)\n\nwhen I receive [dead v]\ngo to x: (0) y: (-800)\npoint in direction (90)\n\nSet Size to [500]\nset [_r vel v] to [0]\nset [_y vel v] to [0]\n\nwhen I receive [next level v]\nchange [level v] by (1)\nnext costume\n\nwhen I receive [outro v]\nhide\nstop [this script v]\n\nwhen I receive [end v]\nhide\nstop [this script v]\n\n@thumbnail\n\nwhen flag clicked\nswitch costume to (thumbnail v)\ngo to x: (9) y: (9)\nshow\ngo to [front v] layer\nset [ghost v] effect to (100)\n\n@backdrops\n\nwhen flag clicked\nshow\ngo to [back v] layer\ngo to x: (1) y: (-6)\nswitch costume to (pick random (1) to (3))\n\nwhen I receive [outro v]\nhide\n\n@ending\n\nwhen I receive [end v]\nswitch costume to (costume1 v)\nshow\nrepeat (74)\n    wait (0.03) seconds\n    next costume\nend\nwait (1) seconds\nbroadcast (outro v)\nhide\n\nwhen flag clicked\nhide\n\n@Outro \n\ndefine Create A Clone Of Type (type)\nswitch costume to (type)\ncreate clone of (_myself_ v)\n\ndefine Smooth Glide x: (x) y: (y) speed: (speed)\nrepeat until <<(round (x position)) = (round (x))> and <(round (y position)) = (round (y))>>\n    change x by (((round (x)) - (round (x position))) / (speed))\n    change y by (((round (y)) - (round (y position))) / (speed))\nend\ngo to x: (x) y: (y)\n\nwhen flag clicked\nhide\n\nwhen I start as a clone\nif <(costume [number v]) = [2]> then\n    go to [front v] layer\n    go to x: (0) y: (-300)\n    Smooth Glide x: (0) y: (0) speed: (16)\n    wait until <(wait1) = [1]>\n    wait (0.1) seconds\n    repeat (drop repeat)\n        change y by (drop)\n        change [drop v] by (-0.5)\n    end\n    hide\n    delete this clone\nend\nif <(costume [number v]) = [3]> then\n    go to [back v] layer\n    go [forward v] (1) layers\n    go to x: (0) y: (-300)\n    Smooth Glide x: (0) y: (0) speed: (16)\n    wait until <(wait1) = [1]>\n    wait (0.2) seconds\n    repeat (drop repeat)\n        change y by (drop)\n    end\n    hide\n    delete this clone\nend\nif <(costume [number v]) = [4]> then\n    go to [back v] layer\n    go [forward v] (2) layers\n    go to x: (0) y: (-300)\n    Smooth Glide x: (0) y: (0) speed: (16)\n    wait until <(wait1) = [1]>\n    wait (0.3) seconds\n    repeat (drop repeat)\n        change y by (drop)\n    end\n    hide\n    delete this clone\nend\nif <(costume [number v]) = [5]> then\n    go to [back v] layer\n    go [forward v] (1) layers\n    go to x: (0) y: (-300)\n    Smooth Glide x: (0) y: (0) speed: (16)\n    wait until <(wait1) = [1]>\n    wait (0.4) seconds\n    repeat (drop repeat)\n        change y by (drop)\n    end\n    hide\n    delete this clone\nend\nif <(costume [number v]) = [6]> then\n    go to [front v] layer\n    go [forward v] (1) layers\n    go to x: (0) y: (-300)\n    Smooth Glide x: (0) y: (0) speed: (16)\n    wait until <(wait1) = [1]>\n    wait (0.5) seconds\n    repeat (drop repeat)\n        change y by (drop)\n    end\n    hide\n    delete this clone\nend\nif <(costume [number v]) = [7]> then\n    go to x: (300) y: (0)\n    Smooth Glide x: (0) y: (1) speed: (16)\n    wait until <(wait1) = [1]>\n    repeat (20)\n        change x by (-10)\n        change [ghost v] effect by (5)\n    end\n    delete this clone\nend\n\nwhen I start as a clone\nif <(costume [number v]) = [9]> then\n    go to [front v] layer\n    point in direction (135)\n    Smooth turn: Direction [30] Speed [8]\n    forever\n        point in direction ((([sin v] of (logo effect1) ) * (5)) + (30))\n    end\nend\nif <(costume [number v]) = [10]> then\n    go to x: (0) y: (0)\n    go to [front v] layer\n    point in direction (-135)\n    Smooth turn: Direction [-30] Speed [8]\n    forever\n        point in direction ((([cos v] of (logo effect1) ) * (5)) + (-30))\n    end\nend\nif <(costume [number v]) = [11]> then\n    go to x: (0) y: (0)\n    point in direction (0)\n    go to [front v] layer\n    go to [front v] layer\n    forever\n        point in direction ((([tan v] of (logo effect1) ) * (5)) + (90))\n        set size to ((([sin v] of ((logo effect1) * (2)) ) * (20)) + (130)) %\n        change [logo effect1 v] by (3)\n    end\nend\nif <(costume [number v]) = [13]> then\n    go to x: (0) y: (0)\n    point in direction (90)\n    go to [front v] layer\n    go to [front v] layer\n    forever\n        go to x: (0) y: ((([sin v] of ((logo effect1) * (2)) ) * (20)) + (0))\n    end\nend\nif <(costume [number v]) = [14]> then\n    go to x: (0) y: (0)\n    point in direction (90)\n    go to [front v] layer\n    go to [front v] layer\n    go to [front v] layer\n    forever\n        go to x: (0) y: ((([cos v] of ((logo effect1) * (2)) ) * (20)) + (130))\n    end\nend\n\ndefine Smooth turn: Direction (directieo) Speed (speed)\nrepeat until <(round (direction)) = (round (directieo))>\n    turn right (((round (directieo)) - (round (direction))) / (speed)) degrees\nend\npoint in direction (directieo)\n\nwhen I receive [outro v]\nshow\nset volume to (100) %\nswitch costume to (sizer v)\nset size to (100) %\nswitch costume to (costume1 v)\ngo to x: (0) y: (0)\npoint in direction (90)\nswitch costume to (costume1 v)\nset [logo effect1 v] to [0]\nset [cos \(blue line\) v] to [0]\nset [drop v] to [7]\nset [wait1 v] to [0]\nset [drop repeat v] to [42]\nset [ghost v] effect to (100)\nrepeat (100)\n    change [ghost v] effect by (-1)\nend\nCreate A Clone Of Type [2]\nCreate A Clone Of Type [3]\nCreate A Clone Of Type [4]\nCreate A Clone Of Type [5]\nCreate A Clone Of Type [6]\nCreate A Clone Of Type [7]\nswitch costume to (costume1 v)\ngo to [back v] layer\ngo to [back v] layer\nwait (5) seconds\nchange [wait1 v] by (1)\nwait (1) seconds\nrepeat (100)\n    change [ghost v] effect by (1)\nend\nwait (2.7) seconds\nswitch costume to (costume8 v)\nset [ghost v] effect to (0)\nCreate A Clone Of Type [9]\nCreate A Clone Of Type [10]\nswitch costume to (sizer v)\nset size to (100) %\nswitch costume to (costume8 v)\nCreate A Clone Of Type [11]\nCreate A Clone Of Type [13]\nCreate A Clone Of Type [14]\nswitch costume to (costume8 v)\n\nstart sound [Highscore v]\n\nwhen I receive [outro v]\nforever\n    play sound [Highscore v] until done\nend\n\n
Welcome to my first 360 degrees Platformer\n- Dodge Lava and spikes\n- You can walljump\n-Stand on the cyan flag to get to the next level before your air runs out!!!\n-  Leave a ❤️ and ⭐\n- and have fun :)