Orbit || A 360° Platformer [#Games #All]

Instructions: Welcome to my newest game! ;D\n._._._._._._._._._._._._._._._._._._._._._._._._._._._._._.\nINSTRUCTIONS.\nArrow keys to move.  ||  [This is pretty easy, thats why \nAvoid spikes + lava.   ||  there is no skip buttons]

@Stage\n\n@Blank\n\n@Ball\n\nwhen I receive [start v]\nset [change? v] to [0]\n\ndefine Get Direction (dx) (dy)\nif <(dy) = [0]> then\n    if <(dx) > [0]> then\n        set [get direction? v] to [90]\n    else\n        set [get direction? v] to [-90]\n    end\nelse\n    set [get direction? v] to ([atan v] of ((dx) / (dy)) )\n    if <(dy) < [0]> then\n        if <(dx) > [0]> then\n            change [get direction? v] by (180)\n        else\n            if <(dx) < [0]> then\n                change [get direction? v] by (-180)\n            else\n                set [get direction? v] to [180]\n            end\n        end\n    end\nend\n\ndefine Move (sx) (sy)\nchange [position x v] by (sx)\nchange [position y v] by (sy)\nPosition\nif <touching color (#009933)?> then\n    repeat (6)\n        change [position x v] by ((1) * ([sin v] of ((Rotation) + (0)) ))\n        change [position y v] by ((1) * ([cos v] of ((Rotation) + (0)) ))\n        Position\n        if <not <touching color (#009933)?>> then\n            set [collided? v] to [1]\n            set [can jump? v] to [5]\n            stop [this script v]\n        end\n    end\n    change [position x v] by (((-6) * ([sin v] of ((Rotation) + (0)) )) - (sx))\n    change [position y v] by (((-6) * ([cos v] of ((Rotation) + (0)) )) - (sy))\n    Position\n    set [collided? v] to [2]\nelse\n    set [collided? v] to [0]\nend\n\ndefine Position\nset [tx v] to (((Position X) * ([cos v] of (Rotation) )) - ((Position Y) * ([sin v] of (Rotation) )))\nset [ty v] to (((Position X) * ([sin v] of (Rotation) )) + ((Position Y) * ([cos v] of (Rotation) )))\ngo to x: ((tx) - (Scroll X)) y: ((ty) - (Scroll Y))\n\ndefine Tick\nset [new speed x v] to [0]\nif <key (left arrow v) pressed?> then\n    switch costume to (costume2 v)\n    set [new speed x v] to [-5]\nelse\n    if <key (right arrow v) pressed?> then\n        switch costume to (costume1 v)\n        set [new speed x v] to [5]\n    else\n        switch costume to (ball v)\n    end\nend\nif <(Can Jump?) > [0]> then\n    change [can jump? v] by (-1)\n    if <key (up arrow v) pressed?> then\n        set [speed x v] to ((10) * ([sin v] of ((Rotation) + (0)) ))\n        set [speed y v] to ((10) * ([cos v] of ((Rotation) + (0)) ))\n    end\nend\nchange [speed x v] by ((1) * ([sin v] of ((Rotation) + (180)) ))\nchange [speed y v] by ((1) * ([cos v] of ((Rotation) + (180)) ))\nMove (Speed X) (Speed Y)\nif <(collided?) > [0]> then\n    set [speed x v] to [0]\n    set [speed y v] to [0]\nend\nif <not <(New Speed X) = [0]>> then\n    set [new speed y v] to ((New Speed X) * ([cos v] of ((Rotation) + (90)) ))\n    set [new speed x v] to ((New Speed X) * ([sin v] of ((Rotation) + (90)) ))\n    Move (New Speed X) (New Speed Y)\nend\nGet Direction (Position X) (Position Y)\nset [rotation v] to (Get Direction?)\nset [scroll x v] to (((Position X) * ([cos v] of (Rotation) )) - ((Position Y) * ([sin v] of (Rotation) )))\nset [scroll y v] to (((Position X) * ([sin v] of (Rotation) )) + ((Position Y) * ([cos v] of (Rotation) )))\nPosition\n\nMove ((Speed X) + (New Speed X)) ((Speed Y) + (New Speed Y))\n\nwhen flag clicked\ngo to [front v] layer\nset [level v] to [1]\nset [position x v] to [0]\nset [position y v] to [250]\nset [speed x v] to [0]\nset [speed y v] to [0]\nset [scroll x v] to [0]\nset [scroll y v] to [0]\nset [rotation v] to [0]\nset [can jump? v] to [0]\nGet Direction (Position X) (Position Y)\nset [rotation v] to (Get Direction?)\nset [scroll x v] to (((Position X) * ([cos v] of (Rotation) )) - ((Position Y) * ([sin v] of (Rotation) )))\nset [scroll y v] to (((Position X) * ([sin v] of (Rotation) )) + ((Position Y) * ([cos v] of (Rotation) )))\nPosition\nbroadcast (tick v) and wait\nforever\n    Tick\n    broadcast (tick v) and wait\nend\n\nset [speed x v] to [0]\nset [speed y v] to [0]\n\n\n\n\n\nswitch costume to (costume2 v)\nset [new speed x v] to [-5]\n\nwhen flag clicked\nforever\n    if <<touching color (#41ff40)?> and <(Level) = [1]>> then\n        go to [front v] layer\n        reset\n        broadcast (NEXT LEVEL v)\n        set [level v] to [2]\n    end\n    wait (0.00001) seconds\n    if <<touching color (#41ff40)?> and <(Level) = [2]>> then\n        go to [front v] layer\n        reset\n        broadcast (NEXT LEVEL v)\n        set [level v] to [3]\n    end\n    wait (0.00001) seconds\n    if <<touching color (#41ff40)?> and <(Level) = [3]>> then\n        go to [front v] layer\n        reset\n        broadcast (NEXT LEVEL v)\n        set [level v] to [4]\n    end\n    wait (0.00001) seconds\n    if <<touching color (#41ff40)?> and <(Level) = [4]>> then\n        go to [front v] layer\n        reset\n        broadcast (NEXT LEVEL v)\n        set [level v] to [5]\n    end\n    wait (0.00001) seconds\n    if <<touching color (#41ff40)?> and <(Level) = [5]>> then\n        go to [front v] layer\n        reset\n        broadcast (NEXT LEVEL v)\n        set [level v] to [6]\n    end\n    wait (0.00001) seconds\n    if <<touching color (#41ff40)?> and <(Level) = [6]>> then\n        go to [front v] layer\n        reset\n        broadcast (NEXT LEVEL v)\n        set [level v] to [7]\n    end\n    wait (0.00001) seconds\nend\n\nchange [level v] by (1)\n\nwhen flag clicked\nforever\n    if <<touching color (#f5f5f5)?> or <touching color (#c6c6c6)?>> then\n        set [position x v] to [0]\n        set [position y v] to [250]\n        set [speed x v] to [0]\n        set [speed y v] to [0]\n        set [scroll x v] to [0]\n        set [scroll y v] to [0]\n        set [rotation v] to [0]\n        set [can jump? v] to [0]\n    end\n    if <touching color (#ff0000)?> then\n        set [position x v] to [0]\n        set [position y v] to [250]\n        set [speed x v] to [0]\n        set [speed y v] to [0]\n        set [scroll x v] to [0]\n        set [scroll y v] to [0]\n        set [rotation v] to [0]\n        set [can jump? v] to [0]\n    end\nend\n\ngo to x: (0) y: (0)\n\n@Level\n\ndefine Position\ngo to x: ((0) - (Scroll X)) y: ((0) - (Scroll Y))\npoint in direction ((0) - (Rotation))\n\nwhen I receive [tick v]\nPosition\n\nwhen flag clicked\nswitch costume to (costume1 v)\nforever\n    switch costume to (Level)\nend\n\n@transition\n\nwhen flag clicked\nhide\n\nwhen I receive [next level v]\nset [trans on or off v] to [On]\ngo [forward v] (1) layers\ngo to [front v] layer\nset x to (500)\nshow\nrepeat (6)\n    change x by (-80)\nend\nwait (0.6) seconds\nchange x by (-15)\nrepeat (5)\n    change x by (-80)\nend\nset [trans on or off v] to [Off]\nhide\n\n@Clouds\n\nwhen flag clicked\nset [ghost v] effect to (50)\nhide\n\nwhen I start as a clone\ngo to [back v] layer\ngo to x: (200) y: (pick random (50) to (180))\nshow\nrepeat until <(x position) < [-200]>\n    change x by (-3)\n    if <<([costume name v] of [platform v]) > [6]> and <([costume name v] of [platform v]) < [11]>> then\n        hide\n        delete this clone\n    end\nend\nrepeat (10)\n    hide\n    delete this clone\nend\n\nwhen I receive [instructions v]\nhide\n\nwhen I receive [nonono v]\nshow\n\nwhen I receive [start v]\n\nrepeat (10)\n    set [ghost v] effect to (100)\n    hide\n    delete this clone\nend\n\nwhen flag clicked\nforever\n    wait (4) seconds\n    create clone of (_myself_ v)\nend\n\n@thumb\n\nwhen flag clicked\nforever\n    go to x: (0) y: (0)\n    show\n    set [ghost v] effect to (100)\n    go to [front v] layer\n    switch costume to (costume2 v)\nend\n\n@Sprite1\n\n