OBLIQUE | Platformer

Instructions: <-------------(OBLIQUE)------------->\nHow to play: If you are on the hard mode the thunder follows you but if you're on normal mode the thunder landing area is randomized. There is a low detail mode that removes extra clones and graphical effects. WASD, arrow keys, or touch to move avoid spikes and get to the end :)\n

@Stage\n\nwhen flag clicked\nbroadcast (menu v)\nset [volume v] to [50]\n\nwhen I receive [go v]\nbroadcast (lose lighting v)\nforever\n    broadcast (tick v)\nend\n\nwhen I receive [go v]\nset [level v] to [1]\nwait until <(level) > [6]>\nbroadcast (night cutscene v) and wait\nwait until <(level) > [12]>\nbroadcast (day cutscene v)\nwait until <(level) = [16]>\nbroadcast (THE END :\) v)\nstop [this script v]\n\nwhen I receive [go v]\nplay sound [first v] until done\nforever\n    play sound [Alter v] until done\n    play sound [1049785_Madness-Combat-3-amp-4-Rem v] until done\nend\n\nwhen I receive [the end :\) v]\nstop [other scripts in sprite v]\nhide\n\nwhen I receive [tick v]\nset volume to (volume) %\n\n@menu\n\nwhen flag clicked\nset [low detail v] to [0]\nhide\ndelete this clone\n\nwhen I start as a clone\nif <(id) = [1]> then\n    switch costume to (bg city v)\n    set size to (100) %\n    clear graphic effects\n    go [forward v] (1) layers\n    point in direction (90)\n    go to x: (0) y: (0)\n    show\n    forever\n        go to x: ((0) + ((mouse x) / (-20))) y: ((0) + ((mouse y) / (-20)))\n    end\nend\nif <(id) = [2]> then\n    switch costume to (title v)\n    set size to (100) %\n    clear graphic effects\n    point in direction (90)\n    go to x: (0) y: (0)\n    go to [front v] layer\n    show\nend\nif <(id) = [3]> then\n    switch costume to (start v)\n    set size to (90) %\n    clear graphic effects\n    point in direction (90)\n    go to x: (-30) y: (0)\n    go to [front v] layer\n    show\n    forever\n        if <touching (mouse-pointer v)?> then\n            switch costume to (start selected v)\n            if <mouse down?> then\n                play sound [slect v] until done\n                broadcast (transition v)\n                broadcast (start v)\n                hide\n                delete this clone\n            end\n        else\n            switch costume to (start v)\n        end\n    end\nend\nif <(id) = [4]> then\n    switch costume to (hard button v)\n    set size to (90) %\n    clear graphic effects\n    point in direction (90)\n    go to x: (-30) y: (0)\n    go to [front v] layer\n    show\n    forever\n        if <touching (mouse-pointer v)?> then\n            switch costume to (hard button selected v)\n            if <mouse down?> then\n                play sound [slect v] until done\n                broadcast (transition v)\n                set [hard? v] to [1]\n                broadcast (start v)\n                hide\n                delete this clone\n            end\n        else\n            switch costume to (hard button v)\n        end\n    end\nend\nif <(id) = [7]> then\n    switch costume to (setting v)\n    set size to (90) %\n    clear graphic effects\n    point in direction (90)\n    go to x: (171) y: (143)\n    go to [front v] layer\n    show\n    forever\n        if <touching (mouse-pointer v)?> then\n            if <mouse down?> then\n                broadcast (low detail v)\n                set [low detail v] to [1]\n                broadcast (transition v)\n                play sound [slect v] until done\n                switch costume to (setting v)\n                delete this clone\n            end\n        end\n    end\nend\n\nwhen I receive [menu v]\nset [hard? v] to [0]\nset size to (100) %\nhide\nset [id v] to [1]\ncreate clone of (_myself_ v)\nset [id v] to [2]\ncreate clone of (_myself_ v)\nset [id v] to [3]\ncreate clone of (_myself_ v)\nset [id v] to [4]\ncreate clone of (_myself_ v)\nset [id v] to [5]\ncreate clone of (_myself_ v)\nset [id v] to [6]\ncreate clone of (_myself_ v)\nset [id v] to [7]\ncreate clone of (_myself_ v)\nforever\n    play sound [Alter v] until done\nend\n\nwhen I start as a clone\nif <(id) = [5]> then\n    switch costume to (bg color back v)\n    set size to (100) %\n    clear graphic effects\n    point in direction (90)\n    go to x: (0) y: (0)\n    go to [back v] layer\n    show\n    forever\n        repeat (2)\n            start sound [thunder v]\n            repeat (4)\n                change [brightness v] effect by (5)\n            end\n            repeat (1)\n                change [brightness v] effect by (-5)\n            end\n            wait (.1) seconds\n            repeat (10)\n                change [brightness v] effect by (5)\n            end\n            repeat (1)\n                change [brightness v] effect by (-5)\n            end\n            repeat (3)\n                change [brightness v] effect by (5)\n            end\n            repeat (15)\n                change [brightness v] effect by (-5)\n            end\n        end\n        clear graphic effects\n        wait (10) seconds\n    end\nend\nif <(id) = [6]> then\n    switch costume to (bg lighting v)\n    set size to (100) %\n    clear graphic effects\n    point in direction (90)\n    go to x: (0) y: (0)\n    go [backward v] (1) layers\n    show\n    forever\n        show\n        repeat (2)\n            repeat (4)\n                change [ghost v] effect by (-5)\n            end\n            repeat (1)\n                change [ghost v] effect by (5)\n            end\n            wait (.1) seconds\n            repeat (10)\n                change [ghost v] effect by (-5)\n            end\n            repeat (1)\n                change [ghost v] effect by (5)\n            end\n            repeat (3)\n                change [ghost v] effect by (-5)\n            end\n            repeat (15)\n                change [ghost v] effect by (5)\n            end\n        end\n        hide\n        clear graphic effects\n        wait (10) seconds\n    end\nend\n\nwhen I receive [start v]\nhide variable [volume v]\nstop [other scripts in sprite v]\nstop all sounds\nhide\ndelete this clone\n\nwhen I receive [menu v]\nshow variable [volume v]\nforever\n    set volume to (volume) %\nend\n\n@cutscene 1\n\nwhen flag clicked\nclear graphic effects\nset size to (100) %\ngo to x: (0) y: (0)\nhide\n\nwhen I receive [start v]\nswitch costume to (size v)\nset size to (270) %\nswitch costume to (panarama v)\ngo to x: (451) y: (320)\nshow\nrepeat (150)\n    change x by (-2)\nend\nbroadcast (transition v)\ngo to x: (0) y: (320)\nwait (.8) seconds\nshow\nrepeat (150)\n    change x by (2)\nend\ngo to x: (0) y: (320)\nbroadcast (transition v)\nwait (.8) seconds\nshow\nrepeat (300)\n    switch costume to (size v)\n    change size by (-.3)\n    switch costume to (panarama2 v)\n    change y by (-1)\nend\nwait (1) seconds\nswitch costume to (panarama3 v)\nwait (.5) seconds\nbroadcast (transition v)\nhide\nbroadcast (go v)\n\nwhen I receive [start v]\nwait (.1) seconds\nstart sound [Alter v]\nforever\n    set volume to (volume) %\nend\n\nwhen I receive [go v]\nstop all sounds\n\n@cutscene 2\n\nwhen I receive [night cutscene v]\ncreate clone of (_myself_ v)\nclear graphic effects\nset size to (133) %\ngo to x: (0) y: (-50)\nswitch costume to (city dim v)\nwait (.1) seconds\ngo to [front v] layer\nshow\nrepeat (150)\n    change size by (-0.22)\n    change y by (.2)\nend\n\nwhen flag clicked\nhide\ngo to x: (0) y: (0)\nclear graphic effects\nset size to (100) %\n\nwhen I start as a clone\ngo to x: (0) y: (0)\nclear graphic effects\nset size to (100) %\nswitch costume to (light v)\ngo to [front v] layer\nshow\nwait (2) seconds\nrepeat (46)\n    change [brightness v] effect by (-1)\n    wait (.025) seconds\nend\nswitch costume to (dark v)\nwait (1) seconds\nbroadcast (transition v)\nbroadcast (lose lighting v)\ndelete this clone\n\nwhen I receive [night cutscene v]\nwait (4) seconds\nswitch costume to (city light v)\n\nwhen I receive [night cutscene v]\nforever\n    go to [front v] layer\nend\n\nwhen I receive [lose lighting v]\nstop [other scripts in sprite v]\nhide\n\n@cutscene 3\n\nwhen I receive [day cutscene v]\ncreate clone of (_myself_ v)\nclear graphic effects\nset size to (133) %\ngo to x: (0) y: (-50)\nswitch costume to (city light v)\ngo to [front v] layer\nwait (.1) seconds\ngo to [front v] layer\nshow\nrepeat (150)\n    change size by (-0.22)\n    change y by (.2)\nend\n\nwhen flag clicked\nhide\ngo to x: (0) y: (0)\nclear graphic effects\nset size to (100) %\n\nwhen I start as a clone\nclear graphic effects\ngo to x: (0) y: (0)\ngo to [front v] layer\nset [brightness v] effect to (-46)\nset size to (100) %\nswitch costume to (light v)\nshow\nwait (2) seconds\nrepeat (46)\n    change [brightness v] effect by (1)\n    wait (.025) seconds\nend\nwait (1) seconds\nbroadcast (transition v)\nbroadcast (lose lighting v)\ndelete this clone\n\nwhen I receive [day cutscene v]\nwait (4) seconds\nswitch costume to (city dim v)\n\nwhen I receive [day cutscene v]\nforever\n    go to [front v] layer\nend\n\nwhen I receive [lose lighting v]\nstop [other scripts in sprite v]\nhide\n\n@transition\n\nwhen I receive [transition v]\nshow\nclear graphic effects\nwait (.5) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nswitch costume to (1 v)\nhide\nstop [other scripts in sprite v]\n\nwhen flag clicked\nhide\ngo to x: (0) y: (0)\nclear graphic effects\n\nwhen I receive [transition v]\nforever\n    go to [front v] layer\nend\n\n@player\n\nwhen I receive [the end :\) v]\nstop [other scripts in sprite v]\nhide\n\nwhen flag clicked\nhide\n\nwhen I receive [go v]\nset size to (70) %\nswitch costume to (normal v)\nshow\ngo to x: (-225) y: (-40)\npoint in direction (90)\nset [x move v] to [0]\nset [y move v] to [0]\nforever\n    clear graphic effects\n    change y by (-3)\n    if <touching (platform v)?> then\n        if <<<key (up arrow v) pressed?> or <key (w v) pressed?>> or <<mouse down?> and <(mouse y) > (y position)>>> then\n            switch costume to (player v)\n            set [y move v] to [8.5]\n        end\n    end\n    change y by (3)\n    if <(y move) > [-15]> then\n        change [y move v] by (-0.5)\n    end\n    change y by (-2)\n    if <not <touching (platform v)?>> then\n        change y by (-1)\n        set [in air v] to [1]\n        if <not <touching (platform v)?>> then\n            change y by (-1)\n            if <not <touching (platform v)?>> then\n                change y by (-1)\n                if <not <touching (platform v)?>> then\n                    change y by (-1)\n                    if <not <touching (platform v)?>> then\n                        change y by (-1)\n                        if <not <touching (platform v)?>> then\n                            change y by (5)\n                        end\n                    end\n                end\n            end\n        end\n    end\n    if <touching (platform v)?> then\n        set [in air v] to [0]\n    end\n    change y by (2)\n    change y by (y move)\n    if <touching (platform v)?> then\n        change y by (-2)\n        if <touching (platform v)?> then\n            change y by ((-1) * (y move))\n            set [y move v] to [-3]\n        end\n        change y by (2)\n    end\nend\n\nwhen I receive [go v]\nforever\n    if <<(x position) = [235]> or <(x position) > [235]>> then\n        if <(collect coins) = (minum collected)> then\n            set [x move v] to [0]\n            set [y move v] to [0]\n            hide\n            change [level v] by (1)\n            start sound [Collect v]\n            go to x: (-225) y: (-40)\n            broadcast (transition v)\n            broadcast (next level v)\n            show\n        end\n    end\nend\n\nwhen I receive [go v]\nforever\n    set [x move v] to ((x move) * (0.85))\n    change x by (x move)\n    if <touching (platform v)?> then\n        change y by (-2)\n        if <touching (platform v)?> then\n            change y by (1)\n            if <touching (platform v)?> then\n                change y by (1)\n                if <touching (platform v)?> then\n                    change y by (1)\n                    if <touching (platform v)?> then\n                        change y by (1)\n                        if <touching (platform v)?> then\n                            change y by (1)\n                            if <touching (platform v)?> then\n                                change y by (-5)\n                                change x by ((-1) * (x move))\n                                if <<<<key (up arrow v) pressed?> or <key (w v) pressed?>> or <<<mouse down?> and <(mouse x) > (x position)>> or <<mouse down?> and <(mouse x) < (x position)>>>> and <not <(x move) = [0]>>> then\n                                    set [y move v] to [10]\n                                    set [x move v] to (((x move) / ([abs v] of (x move) )) * (-10))\n                                else\n                                    set [x move v] to [0]\n                                end\n                            end\n                        end\n                    end\n                end\n            end\n        end\n        change y by (2)\n    end\nend\n\nwhen I receive [go v]\nforever\n    if <<<(y position) < [-175]> or <touching (hurt lighting v)?>> or <touching (ouch v)?>> then\n        hide\n        set [x move v] to [0]\n        set [y move v] to [0]\n        start sound [Crunch v]\n        broadcast (coin reset v) and wait\n        broadcast (coin check v)\n        show\n        if <not <(low detail) = [1]>> then\n            spark i fx (playerX) (playerY) (20)\n        end\n        glide (.1) secs to x: (-225) y: (-40)\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 move v] by (-1.5)\n        point in direction (-90)\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 move v] by (1.5)\n        point in direction (90)\n    end\n    if <<<key (down arrow v) pressed?> or <key (s v) pressed?>> and <(in air) = [0]>> then\n        switch costume to (player duck v)\n    else\n        switch costume to (player v)\n    end\nend\n\ndefine spark i fx (x) (y) (# of particles)\ngo to x: (x) y: (y)\nrepeat (# of particles)\n    create clone of (spark i v)\nend\n\nwhen I receive [tick v]\nset [playerx v] to (x position)\nset [playery v] to (y position)\n\nwhen I receive [tick v]\nset volume to (volume) %\n\n@platform\n\nwhen I receive [the end :\) v]\nstop [other scripts in sprite v]\nhide\n\nwhen I receive [go v]\nshow\nforever\n    switch costume to (level)\nend\n\nwhen flag clicked\nhide\nswitch costume to (1 v)\n\nwhen flag clicked\nswitch costume to (1 v)\nchange [ghost v] effect by (100)\nset [level v] to [1]\nhide\n\n@deco\n\nwhen I receive [the end :\) v]\nstop [other scripts in sprite v]\nhide\n\nwhen flag clicked\nswitch costume to (1 v)\nhide\n\nwhen I receive [go v]\nshow\nif <not <(low detail) = [1]>> then\n    create clone of (_myself_ v)\nend\ngo to x: (0) y: (0)\ngo to [front v] layer\nforever\n    switch costume to (level)\nend\n\nwhen I start as a clone\ngo to x: (0) y: (0)\ngo to [back v] layer\nset [brightness v] effect to (-30)\nset size to (100) %\nforever\n    switch costume to (level)\n    go to x: ((playerX) / (-30)) y: ((playerY) / (-30))\nend\n\n@ouch\n\nwhen I receive [the end :\) v]\nstop [other scripts in sprite v]\nhide\n\nwhen flag clicked\nswitch costume to (1 v)\nhide\n\nwhen I receive [go v]\nshow\ngo to x: (0) y: (0)\ngo to [front v] layer\nset [ghost v] effect to (100)\nforever\n    switch costume to (level)\nend\n\n@warning . sprites\n\nwhen flag clicked\nclear graphic effects\nset size to (100) %\ngo to x: (0) y: (120)\nhide\n\nwhen I receive [go v]\nshow\nrepeat until <(level) = [2]>\n    switch costume to (warning v)\n    wait (pick random (.1) to (.2)) seconds\n    switch costume to (warning 2 v)\n    wait (pick random (.2) to (.4)) seconds\n    switch costume to (warning v)\n    wait (pick random (.025) to (.01)) seconds\n    switch costume to (warning 2 v)\n    wait (.1) seconds\nend\nhide\nwait until <(level) = [4]>\nshow\ngo to [front v] layer\nrepeat until <(level) = [5]>\n    switch costume to (help v)\n    wait (pick random (.1) to (.2)) seconds\n    switch costume to (help 2 v)\n    wait (pick random (.2) to (.4)) seconds\n    switch costume to (help v)\n    wait (pick random (.025) to (.01)) seconds\n    switch costume to (help 2 v)\n    wait (.1) seconds\nend\nhide\n\n@bg\n\nwhen I receive [the end :\) v]\nstop [other scripts in sprite v]\nhide\n\nwhen flag clicked\nhide\ngo to x: (0) y: (0)\nclear graphic effects\nset size to (120) %\n\nwhen I receive [tick v]\ngo to x: ((playerX) / (-5)) y: ((playerY) / (-5))\ngo to [back v] layer\n\nwhen I receive [go v]\nshow\nforever\n    wait (.6) seconds\n    create clone of (particles v)\nend\n\nwhen I receive [go v]\nswitch costume to (day v)\nwait until <(level) > [6]>\nswitch costume to (night v)\nwait until <(level) > [12]>\nswitch costume to (morning v)\n\n@Particles\n\nwhen I start as a clone\nswitch costume to (spark v)\nset [ghost v] effect to (pick random (70) to (90))\nshow\nset size to (pick random (100) to (250)) %\ngo to [front v] layer\ngo to x: (pick random (240) to (-240)) y: (-180)\npoint in direction (pick random (-20) to (20))\nset [counter v] to (pick random (120) to (300))\n\nwhen flag clicked\nhide\n\nwhen I receive [begin v]\nset [counter v] to [0]\n\nwhen I receive [tick v]\nif <not <(low detail) = [1]>> then\n    change [counter v] by (-1)\n    if <(Counter) > [0]> then\n        move (1) steps\n    else\n        move (1) steps\n        change [ghost v] effect by (4)\n    end\n    if <(Counter) < [-10]> then\n        delete this clone\n    end\nend\n\nwhen I receive [menu v]\nif <not <(low detail) = [1]>> then\n    change [counter v] by (-1)\n    if <(Counter) > [0]> then\n        move (1) steps\n    else\n        move (1) steps\n        change [ghost v] effect by (4)\n    end\n    if <(Counter) < [-10]> then\n        delete this clone\n    end\nend\n\nwhen I receive [tick v]\nif <(low detail) = [1]> then\n    delete this clone\nend\n\n@Spark I\n\ndefine None\ngo to x: (x) y: (y)\nspark i fx (playerX) (playerY) (9)\nrepeat (# of particles)\n    create clone of (_myself_ v)\nend\n\nwhen I start as a clone\nif <(low detail) = [1]> then\n    delete this clone\nend\ngo to [back v] layer\ngo to x: (playerX) y: (playerY)\nset size to ((pick random (1) to (2)) * (100)) %\nset rotation style [don't rotate v]\npoint in direction (pick random (0) to (360))\nswitch costume to (pick random (1) to (3))\nclear graphic effects\nshow\nset [speed v] to [0]\nset [max v] to (pick random (5) to (15))\nrepeat (max)\n    change [speed v] by (1)\n    move (speed) steps\nend\nrepeat ((max) / (2))\n    change [speed v] by (-2)\n    move (speed) steps\n    change [ghost v] effect by ((100) / ((max) / (2)))\nend\ndelete this clone\n\nif <(low detail) = [1]> then\nend\n\n@thumb\n\nwhen flag clicked\ngo to x: (0) y: (0)\nset [level v] to [1]\nhide\n\nwhen I receive [the end :\) v]\nshow\nswitch costume to (win v)\nforever\n    go to [front v] layer\nend\n\nwhen I receive [the end :\) v]\nwait (3) seconds\nhide\nstop [other scripts in sprite v]\nbroadcast (menu v)\nset [level v] to [1]\n\n@hurt lighting\n\nwhen I receive [lose lighting v]\nif <(hard?) = [0]> then\n    wait (2) seconds\n    strike\n    forever\n        wait (1) seconds\n        strike\n    end\nend\n\nwhen flag clicked\ngo to x: (0) y: (0)\nset size to (100) %\nclear graphic effects\ngo to [front v] layer\nhide\n\ndefine strike\nset [warn go to v] to (pick random (-130) to (130))\nset [strike id v] to [1]\ncreate clone of (warn v)\nhide\nset [ghost v] effect to (100)\nswitch costume to (lighting v)\ngo to x: (warn go to) y: (0)\nwait (2) seconds\nstart sound [thunder v]\nshow\nrepeat (10)\n    change [ghost v] effect by (-10)\nend\nwait (.1) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\n\nwhen I receive [next level v]\nhide\ndelete this clone\n\ndefine strike HARD\nset [strike id v] to [2]\ncreate clone of (warn v)\nhide\nset [ghost v] effect to (100)\nswitch costume to (lighting v)\ngo to x: (playerX) y: (0)\nwait (1) seconds\nstart sound [thunder v]\nshow\nrepeat (10)\n    change [ghost v] effect by (-10)\nend\nwait (.1) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nhide\n\nwhen I receive [lose lighting v]\nif <(hard?) = [1]> then\n    wait (3) seconds\n    strike HARD\n    forever\n        strike HARD\n    end\nend\n\nwhen I receive [day cutscene v]\nstop [other scripts in sprite v]\nhide\ndelete this clone\n\nwhen I receive [night cutscene v]\nstop [other scripts in sprite v]\nhide\ndelete this clone\n\nwhen I receive [the end :\) v]\nstop [other scripts in sprite v]\nhide\ndelete this clone\n\nwhen I receive [tick v]\nset volume to (volume) %\n\n@rain drop\n\nwhen flag clicked\npoint in direction (180)\ngo to [front v] layer\nhide\nforever\n    clone (pick random (2) to (10))\n    wait (.01) seconds\nend\n\nwhen I start as a clone\ngo to x: (pick random (-240) to (250)) y: (200)\nshow\nset [ghost v] effect to (50)\nrepeat until <(y position) < [-180]>\n    move (drop speed) steps\nend\ndelete this clone\n\ndefine clone (rates)\nrepeat (rates)\n    set [drop speed v] to (pick random (20) to (30))\n    create clone of (_myself_ v)\nend\n\nwhen flag clicked\nforever\n    play sound [Rain v] until done\nend\n\nwhen I receive [low detail v]\nstop [other scripts in sprite v]\nhide\ndelete this clone\n\nwhen flag clicked\nforever\n    set volume to (volume) %\nend\n\n@warn\n\nwhen I start as a clone\nif <(strike id) = [1]> then\n    show\n    set size to (100) %\n    clear graphic effects\n    go to [front v] layer\n    switch costume to (warn v)\n    go to x: (warn go to) y: (172)\n    wait (2) seconds\n    delete this clone\nend\nif <(strike id) = [2]> then\n    show\n    set size to (100) %\n    clear graphic effects\n    go to [front v] layer\n    switch costume to (warn v)\n    go to x: (playerX) y: (172)\n    wait (1) seconds\n    delete this clone\nend\n\nwhen flag clicked\ngo to x: (0) y: (0)\nset size to (100) %\nclear graphic effects\ngo to [front v] layer\nhide\n\nwhen I receive [the end :\) v]\nstop [other scripts in sprite v]\nhide\ndelete this clone\n\nwhen I receive [night cutscene v]\nstop [other scripts in sprite v]\nhide\ndelete this clone\n\nwhen I receive [day cutscene v]\nstop [other scripts in sprite v]\nhide\ndelete this clone\n\n