Block Rush 2 || Scrolling Platformer 

Instructions: Welcome to Block Rush 2!  This is a unique scrolling platformer with spikes, lava, bounce pads, and disappearing platforms.  However, there's one catch: you have a time limit to complete each level.  Behind you, a wall will start to form from falling blocks.  When the wall reaches the top of the screen, your time is up...\n\n**Instructions**\n-Complete each level before the falling blocks make it \n to the top of the screen\n-Avoid spikes, lava, and moving enemies\n-Y to skip level\n-Defeat the boss by jumping on his head\n-Enjoy!

@Stage\n\n@Platforms\n\ndefine tile (x) (y)\nshow\ngo to x: (x) y: (y)\nif <<not <(x position) = (x)>> or <not <(y position) = (y)>>> then\n    hide\nend\n\nwhen flag clicked\nhide\nwait until <(level) = [0]>\nwait until <(level) = [1]>\nset [id# v] to [0]\nrepeat (35)\n    change [id# v] by (1)\n    create clone of (_myself_ v)\nend\nstop [this script v]\n\nwhen I start as a clone\nif <(ID#) = [1]> then\n    switch costume to (platform v)\n    set size to (100) %\n    show at level [1] tile at [0] [-60] breakable [0]\nend\nif <(ID#) = [2]> then\n    switch costume to (platform v)\n    set size to (100) %\n    show at level [1] tile at [444] [-60] breakable [0]\nend\nif <(ID#) = [3]> then\n    switch costume to (platform2 v)\n    set size to (100) %\n    show at level [1] tile at [-190] [4] breakable [0]\nend\nif <(ID#) = [4]> then\n    switch costume to (platform2 v)\n    set size to (100) %\n    show at level [1] tile at [-190] [68] breakable [0]\nend\nif <(ID#) = [5]> then\n    switch costume to (platform2 v)\n    set size to (100) %\n    show at level [1] tile at [-190] [132] breakable [0]\nend\nif <(ID#) = [6]> then\n    switch costume to (platform3 v)\n    set size to (100) %\n    show at level [1] tile at [75] [65] breakable [0]\nend\nif <(ID#) = [7]> then\n    switch costume to (platform4 v)\n    set size to (100) %\n    show at level [1] tile at [732] [-62] breakable [0]\nend\nif <(ID#) = [8]> then\n    switch costume to (platform2 v)\n    set size to (100) %\n    show at level [1] tile at [831] [-60] breakable [0]\nend\nif <(ID#) = [9]> then\n    switch costume to (platform5 v)\n    set size to (100) %\n    show at level [2] tile at [0] [-60] breakable [0]\nend\nif <(ID#) = [10]> then\n    switch costume to (platform5 v)\n    set size to (100) %\n    show at level [2] tile at [200] [40] breakable [0]\nend\nif <(ID#) = [12]> then\n    switch costume to (platform5 v)\n    set size to (100) %\n    show at level [2] tile at [400] [140] breakable [0]\nend\nif <(ID#) = [13]> then\n    switch costume to (platform5 v)\n    set size to (100) %\n    show at level [2] tile at [600] [240] breakable [0]\nend\nif <(ID#) = [14]> then\n    switch costume to (platform6 v)\n    set size to (100) %\n    show at level [2] tile at [800] [320] breakable [0]\nend\nif <(ID#) = [15]> then\n    switch costume to (platform v)\n    set size to (100) %\n    show at level [3] tile at [0] [-60] breakable [0]\nend\nif <(ID#) = [16]> then\n    switch costume to (breakable v)\n    set size to (100) %\n    show at level [3] tile at [300] [50] breakable [1]\nend\nif <(ID#) = [17]> then\n    switch costume to (platform7 v)\n    set size to (100) %\n    show at level [3] tile at [300] [222] breakable [0]\nend\nif <(ID#) = [18]> then\n    switch costume to (breakable v)\n    set size to (100) %\n    show at level [3] tile at [500] [150] breakable [1]\nend\nif <(ID#) = [19]> then\n    switch costume to (platform7 v)\n    set size to (100) %\n    show at level [3] tile at [500] [322] breakable [0]\nend\nif <(ID#) = [20]> then\n    switch costume to (breakable v)\n    set size to (100) %\n    show at level [3] tile at [700] [250] breakable [1]\nend\nif <(ID#) = [21]> then\n    switch costume to (platform7 v)\n    set size to (100) %\n    show at level [3] tile at [700] [422] breakable [0]\nend\nif <(ID#) = [22]> then\n    switch costume to (platform v)\n    set size to (100) %\n    show at level [3] tile at [1050] [265] breakable [0]\nend\nif <(ID#) = [23]> then\n    switch costume to (platform4 v)\n    set size to (100) %\n    show at level [3] tile at [1338] [263] breakable [0]\nend\nif <(ID#) = [24]> then\n    switch costume to (platform6 v)\n    set size to (100) %\n    show at level [4] tile at [0] [-60] breakable [0]\nend\nif <(ID#) = [25]> then\n    switch costume to (platform7 v)\n    set size to (100) %\n    show at level [4] tile at [200] [240] breakable [0]\nend\nif <(ID#) = [26]> then\n    switch costume to (platform7 v)\n    set size to (100) %\n    show at level [4] tile at [400] [540] breakable [0]\nend\nif <(ID#) = [27]> then\n    switch costume to (platform7 v)\n    set size to (100) %\n    show at level [4] tile at [600] [840] breakable [0]\nend\nif <(ID#) = [28]> then\n    switch costume to (platform6 v)\n    set size to (100) %\n    show at level [4] tile at [800] [975] breakable [0]\nend\nif <(ID#) = [29]> then\n    switch costume to (platform6 v)\n    set size to (100) %\n    show at level [4] tile at [600] [1275] breakable [0]\nend\nif <(ID#) = [30]> then\n    switch costume to (platform v)\n    set size to (100) %\n    show at level [5] tile at [0] [-60] breakable [0]\nend\nif <(ID#) = [31]> then\n    switch costume to (conveyor v)\n    set size to (100) %\n    show at level [5] tile at [500] [-60] breakable [0]\nend\nif <(ID#) = [32]> then\n    switch costume to (platform v)\n    set size to (100) %\n    show at level [5] tile at [1000] [-60] breakable [0]\nend\nif <(ID#) = [33]> then\n    switch costume to (platform v)\n    set size to (100) %\n    show at level [6] tile at [0] [-100] breakable [0]\nend\nif <(ID#) = [34]> then\n    switch costume to (platform5 v)\n    set size to (100) %\n    show at level [6] tile at [-191] [27] breakable [0]\nend\nif <(ID#) = [35]> then\n    switch costume to (platform5 v)\n    set size to (100) %\n    show at level [6] tile at [191] [27] breakable [0]\nend\n\ndefine show at level (level) tile at (x) (y) breakable (break)\nhide\nwait until <(level) = (level)>\nrepeat until <(level) > (level)>\n    tile ((x) - (worldx)) ((y) - (worldy))\n    if <<(break) = [1]> and <(ground) = [1]>> then\n        test-touch (x) (y)\n    end\nend\ndelete this clone\n\ndefine test-touch (x) (y)\nchange size by (15)\nif <touching (player v)?> then\n    change size by (-15)\n    repeat (18)\n        tile ((x) - (worldx)) ((y) - (worldy))\n    end\n    repeat (20)\n        tile ((x) - (worldx)) ((y) - (worldy))\n        change [ghost v] effect by (5)\n    end\n    hide\n    wait until <(RESET_) = [1]>\n    set [ghost v] effect to (0)\nelse\n    change size by (-15)\nend\n\nwhen I receive [win v]\nstop [other scripts in sprite v]\nstop [this script v]\n\n@Intro\n\nwhen flag clicked\nset volume to (35) %\nstart sound [JJD  AudioBlade - Stellar Clip v]\nset [id# v] to [1]\ncreate clone of (_myself_ v)\nset [id# v] to [2]\ncreate clone of (_myself_ v)\nshow\npoint in direction (90)\nset size to (10) %\nswitch costume to (nothing v)\nset [ghost v] effect to (100)\nset size to (350) %\nswitch costume to (logo v)\nzoom in [1] [0] [1]\nwait until <(loop) = [5]>\nif <(end intro) = [0]> then\n    broadcast (Boom! v)\n    repeat (3)\n        size bounce [7] [0]\n        wait (0.5) seconds\n    end\nend\nstop [this script v]\n\nwhen I start as a clone\nif <(ID#) = [1]> then\n    show\n    point in direction (90)\n    go to x: (0) y: (0)\n    set [ghost v] effect to (0)\n    switch costume to (nothing v)\n    set size to (115) %\n    switch costume to (bg v)\n    go to [back v] layer\n    forever\n        turn right (0.35) degrees\n        if <(level) = [1]> then\n            delete this clone\n        end\n    end\nelse\n    if <<(ID#) = [2]> or <(ID#) > [5]>> then\n        if <(ID#) = [2]> then\n            show\n            point in direction (90)\n            go to x: (-165) y: (-165)\n            set [ghost v] effect to (0)\n            set size to (100) %\n            switch costume to (skip v)\n        end\n        if <(ID#) = [6]> then\n            point in direction (90)\n            go to x: (0) y: (0)\n            set [ghost v] effect to (0)\n            set size to (100) %\n            switch costume to (bg v)\n            go to [front v] layer\n            show\n        end\n    else\n        point in direction (90)\n        go to x: (0) y: (0)\n        switch costume to (nothing v)\n        set size to (5) %\n        show\n        set [ghost v] effect to (0)\n        go to [front v] layer\n        if <(ID#) = [3]> then\n            switch costume to (out1 v)\n        end\n        if <(ID#) = [4]> then\n            switch costume to (out2 v)\n        end\n        if <(ID#) = [5]> then\n            switch costume to (out3 v)\n        end\n        repeat (25)\n            switch costume to (nothing v)\n            change size by (35)\n            if <(ID#) = [3]> then\n                switch costume to (out1 v)\n            end\n            if <(ID#) = [4]> then\n                switch costume to (out2 v)\n            end\n            if <(ID#) = [5]> then\n                switch costume to (out3 v)\n            end\n        end\n        if <(ID#) = [5]> then\n            broadcast (Menu v)\n        end\n    end\nend\n\ndefine zoom in (loop#) (downsize) (logo)\nchange [ghost v] effect by (-10)\nif <(size) > [100]> then\n    switch costume to (nothing v)\nend\nchange size by ((loop#) * (-1))\nif <(logo) = [1]> then\n    switch costume to (logo v)\nelse\n    if <(logo) = [0]> then\n        switch costume to (thumbnail v)\n        go to [front v] layer\n    else\n        switch costume to (defeat v)\n        go to [front v] layer\n    end\nend\nif <(loop#) > [0]> then\n    if <<(loop#) < [50]> and <(downsize) = [0]>> then\n        zoom in ((loop#) + (5)) [0] (logo)\n    else\n        if <(loop#) < [1]> then\n            zoom in [0] [1] (logo)\n        else\n            zoom in ((loop#) - ((loop#) * (0.75))) [1] (logo)\n        end\n    end\nelse\n    stop [this script v]\nend\n\ndefine spin (speed)\nset [my variable v] to (speed)\nset [begin turn v] to [1]\nrepeat until <<(round (direction)) = [90]> and <(begin turn) = [0]>>\n    set [begin turn v] to [0]\n    turn right (my variable) degrees\n    if <(speed) > [0]> then\n        change [my variable v] by (-0.5)\n    else\n        change [my variable v] by (0.5)\n    end\nend\nchange [loop v] by (1)\nif <([abs v] of (direction) ) > [179]> then\n    spin (((speed) / ([abs v] of (speed) )) * (1))\nelse\n    spin ((speed) * (-0.5))\nend\n\nwhen flag clicked\nwait (0.3) seconds\nset [loop v] to [0]\nspin [20]\n\ndefine size bounce (bounce speed) (loop)\nset [bounce v] to (bounce speed)\nset [begin bounce v] to [1]\nrepeat until <<(round (size)) = [83]> and <(begin bounce) = [0]>>\n    set [begin bounce v] to [0]\n    change size by (bounce)\n    if <(bounce speed) > [0]> then\n        change [bounce v] by (-0.5)\n    else\n        change [bounce v] by (0.5)\n    end\nend\nif <(loop) < [4]> then\n    size bounce ((bounce speed) * (-0.5)) ((loop) + (1))\nelse\n    stop [this script v]\nend\n\nwhen flag clicked\nset [end intro v] to [0]\nforever\n    reset timer\n    if <mouse down?> then\n        set [end intro v] to [1]\n    end\nend\n\nwhen [timer v] > (0)\nbroadcast (end animation v)\n\nwhen I receive [boom! v]\nwait (6) seconds\nset [end intro v] to [1]\n\nwhen I receive [menu v]\nif <not <(costume [number v]) = [2]>> then\n    repeat (20)\n        change [ghost v] effect by (5)\n    end\n    hide\n    delete this clone\nend\n\nwhen flag clicked\nset [level v] to [0]\nset [defeat v] to [0]\nwait until <(end intro) = [1]>\nset [id# v] to [2]\nrepeat (3)\n    change [id# v] by (1)\n    create clone of (_myself_ v)\n    wait (0.2) seconds\nend\nrepeat (50)\n    change volume by (-1)\nend\nforever\n    reset timer\nend\n\nwhen I receive [end animation v]\nset [id# v] to [6]\ncreate clone of (_myself_ v)\nshow\npoint in direction (90)\ngo to x: (0) y: (0)\nset [ghost v] effect to (100)\nswitch costume to (nothing v)\nset size to (400) %\nif <(defeat) = [1]> then\n    zoom in [1] [0] [2]\nelse\n    switch costume to (thumbnail v)\n    zoom in [1] [0] [0]\nend\n\nwhen I receive [defeat v]\nswitch costume to (defeat v)\nset [defeat v] to [1]\nstop [all v]\n\n@Confetti\n\nwhen I receive [boom! v]\nrepeat (14)\n    repeat (10)\n        create clone of (_myself_ v)\n        create clone of (_myself_ v)\n        create clone of (_myself_ v)\n    end\nend\n\nwhen I start as a clone\nwait (pick random (0) to (1)) seconds\nshow\nset size to (20) %\nswitch costume to (pick random (0) to (4))\nset [color v] effect to (pick random (0) to (100))\nif <(pick random (1) to (2)) = [2]> then\n    go to x: (pick random (-160) to (-130)) y: (-300)\nelse\n    go to x: (pick random (130) to (160)) y: (-300)\nend\npoint in direction (pick random (-15) to (15))\nmove [26]\n\ndefine move (speed)\nif <(speed) < [1]> then\n    delete this clone\nelse\n    move (speed) steps\n    move ((speed) - (1))\nend\n\nwhen I receive [boom! v]\nrepeat (14)\n    repeat (10)\n        create clone of (_myself_ v)\n        create clone of (_myself_ v)\n        create clone of (_myself_ v)\n    end\nend\n\nwhen I receive [menu v]\ndelete this clone\n\nwhen I receive [win v]\nstop [other scripts in sprite v]\nstop [this script v]\n\n@Grunge\n\nwhen flag clicked\nset [ghost v] effect to (85)\nhide\nwait until <(level) = [0]>\nwait until <(level) = [1]>\nshow\nforever\n    go to [front v] layer\nend\n\nwhen I receive [win v]\nstop [other scripts in sprite v]\nstop [this script v]\n\n@Spikes, Lava, Saws, oh my...\n\nwhen flag clicked\nhide\nwait until <(level) = [0]>\nwait until <(level) = [1]>\nset [id# v] to [0]\nrepeat (24)\n    change [id# v] by (1)\n    create clone of (_myself_ v)\nend\n\ndefine tile (x) (y) level (mylevel) conveyor (move) (fade) (id#)\nshow\nif <(move) = [1]> then\n    go to x: ((x) - (worldx)) y: ((y) - (worldy))\n    if <<not <(x position) = ((x) - (worldx))>> or <not <(y position) = ((y) - (worldy))>>> then\n        hide\n    end\nelse\n    go to x: (x) y: (y)\n    if <<not <(x position) = (x)>> or <not <(y position) = (y)>>> then\n        hide\n    end\nend\nif <(level) > (mylevel)> then\n    delete this clone\nend\nif <(move) = [1]> then\n    if <(x) > [317]> then\n        set [ghost v] effect to (0)\n        tile ((x) - (3)) (y) level (mylevel) conveyor (move) [0] (id#)\n    else\n        if <(fade) < [11]> then\n            change [ghost v] effect by (10)\n            tile (x) (y) level (mylevel) conveyor (move) ((fade) + (1)) (id#)\n        else\n            wait (((id#) - (16)) * (2)) seconds\n            tile [690] (y) level (mylevel) conveyor (move) [0] (id#)\n        end\n    end\nend\n\nwhen I start as a clone\nhide\npoint in direction (90)\nif <(ID#) = [1]> then\n    wait until <(level) = [1]>\n    switch costume to (spike v)\n    set size to (75) %\n    go to [back v] layer\n    forever\n        tile ((400) - (worldx)) ((1.2) - (worldy)) level [1] conveyor [0] [] []\n    end\nend\nif <(ID#) = [2]> then\n    wait until <(level) = [1]>\n    switch costume to (spike v)\n    set size to (75) %\n    go to [back v] layer\n    forever\n        tile ((460) - (worldx)) ((1.2) - (worldy)) level [1] conveyor [0] [] []\n    end\nend\nif <(ID#) = [3]> then\n    wait until <(level) = [1]>\n    forever\n        tile ((732) - (worldx)) ((-62) - (worldy)) level [1] conveyor [0] [] []\n    end\nend\nif <(ID#) = [4]> then\n    wait until <(level) = [1]>\n    forever\n        tile ((732) - (worldx)) ((-62) - (worldy)) level [1] conveyor [0] [] []\n    end\nend\nif <(ID#) = [5]> then\n    wait until <(level) = [2]>\n    switch costume to (spike v)\n    set size to (75) %\n    go to [back v] layer\n    forever\n        tile ((800) - (worldx)) ((382) - (worldy)) level [2] conveyor [0] [] []\n    end\nend\nif <(ID#) = [6]> then\n    wait until <(level) = [3]>\n    switch costume to (spike v)\n    set size to (75) %\n    go to [back v] layer\n    forever\n        tile ((950) - (worldx)) ((326.2) - (worldy)) level [3] conveyor [0] [] []\n    end\nend\nif <(ID#) = [7]> then\n    wait until <(level) = [3]>\n    switch costume to (spike v)\n    set size to (75) %\n    go to [back v] layer\n    forever\n        tile ((1010) - (worldx)) ((326.2) - (worldy)) level [3] conveyor [0] [] []\n    end\nend\nif <(ID#) = [8]> then\n    wait until <(level) = [3]>\n    switch costume to (spike v)\n    set size to (75) %\n    go to [back v] layer\n    forever\n        tile ((1160) - (worldx)) ((326.2) - (worldy)) level [3] conveyor [0] [] []\n    end\nend\nif <(ID#) = [9]> then\n    wait until <(level) = [3]>\n    switch costume to (spike v)\n    set size to (75) %\n    go to [back v] layer\n    forever\n        tile ((1220) - (worldx)) ((326.2) - (worldy)) level [3] conveyor [0] [] []\n    end\nend\nif <(ID#) = [10]> then\n    wait until <(level) = [3]>\n    forever\n        tile ((1338) - (worldx)) ((263) - (worldy)) level [3] conveyor [0] [] []\n    end\nend\nif <(ID#) = [11]> then\n    wait until <(level) = [3]>\n    forever\n        tile ((1338) - (worldx)) ((263) - (worldy)) level [3] conveyor [0] [] []\n    end\nend\nif <(ID#) = [12]> then\n    wait until <(level) = [4]>\n    switch costume to (spike v)\n    set size to (75) %\n    go to [back v] layer\n    forever\n        tile ((180) - (worldx)) ((301.2) - (worldy)) level [4] conveyor [0] [] []\n    end\nend\nif <(ID#) = [13]> then\n    wait until <(level) = [4]>\n    switch costume to (spike v)\n    set size to (75) %\n    go to [back v] layer\n    forever\n        tile ((380) - (worldx)) ((601.2) - (worldy)) level [4] conveyor [0] [] []\n    end\nend\nif <(ID#) = [14]> then\n    wait until <(level) = [4]>\n    switch costume to (spike v)\n    set size to (75) %\n    go to [back v] layer\n    forever\n        tile ((580) - (worldx)) ((901.2) - (worldy)) level [4] conveyor [0] [] []\n    end\nend\nif <(ID#) = [15]> then\n    wait until <(level) = [4]>\n    point in direction (-90)\n    switch costume to (spike v)\n    set size to (75) %\n    go to [back v] layer\n    forever\n        tile ((570) - (worldx)) ((1213.8) - (worldy)) level [4] conveyor [0] [] []\n    end\nend\nif <(ID#) = [16]> then\n    wait until <(level) = [4]>\n    point in direction (-90)\n    switch costume to (spike v)\n    set size to (75) %\n    go to [back v] layer\n    forever\n        tile ((630) - (worldx)) ((1213.8) - (worldy)) level [4] conveyor [0] [] []\n    end\nend\nif <(ID#) = [17]> then\n    conveyor spike setup (ID#)\nend\nif <(ID#) = [18]> then\n    conveyor spike setup (ID#)\nend\nif <(ID#) = [19]> then\n    conveyor spike setup (ID#)\nend\nif <(ID#) = [20]> then\n    wait until <(level) = [5]>\n    switch costume to (spike v)\n    set size to (75) %\n    go to [back v] layer\n    forever\n        tile ((0) - (worldx)) ((1.2) - (worldy)) level [5] conveyor [0] [] []\n    end\nend\nif <(ID#) = [21]> then\n    wait until <(level) = [5]>\n    switch costume to (spike v)\n    set size to (75) %\n    go to [back v] layer\n    forever\n        tile ((50) - (worldx)) ((1.2) - (worldy)) level [5] conveyor [0] [] []\n    end\nend\nif <(ID#) = [22]> then\n    wait until <(level) = [5]>\n    switch costume to (spike v)\n    set size to (75) %\n    go to [back v] layer\n    forever\n        tile ((100) - (worldx)) ((1.2) - (worldy)) level [5] conveyor [0] [] []\n    end\nend\nif <(ID#) = [23]> then\n    wait until <(level) = [5]>\n    switch costume to (saw v)\n    set size to (150) %\n    forever\n        tile ((900) - (worldx)) ((-40) - (worldy)) level [5] conveyor [0] [] []\n        turn right (10) degrees\n    end\nend\nif <(ID#) = [24]> then\n    wait until <(level) = [5]>\n    switch costume to (saw v)\n    set size to (150) %\n    forever\n        tile ((1150) - (worldx)) ((-40) - (worldy)) level [5] conveyor [0] [] []\n        turn right (10) degrees\n    end\nend\n\ndefine lava animation (next)\nif <(next) = [1]> then\n    next costume\nelse\n    switch costume to ((costume [number v]) - (1))\nend\nwait (0.075) seconds\n\nwhen I start as a clone\nif <(ID#) = [3]> then\n    switch costume to (lava v)\n    change [color v] effect by (8)\n    set size to (100) %\n    set [ghost v] effect to (20)\n    go to [back v] layer\n    forever\n        repeat (7)\n            lava animation [1]\n        end\n        repeat (7)\n            lava animation [0]\n        end\n    end\nend\nif <(ID#) = [4]> then\n    switch costume to (lava v)\n    change [color v] effect by (0)\n    set size to (100) %\n    set [ghost v] effect to (20)\n    go to [back v] layer\n    wait (0.5) seconds\n    forever\n        repeat (7)\n            lava animation [1]\n        end\n        repeat (7)\n            lava animation [0]\n        end\n    end\nend\nif <(ID#) = [10]> then\n    switch costume to (lava v)\n    change [color v] effect by (8)\n    set size to (100) %\n    set [ghost v] effect to (20)\n    go to [back v] layer\n    forever\n        repeat (7)\n            lava animation [1]\n        end\n        repeat (7)\n            lava animation [0]\n        end\n    end\nend\nif <(ID#) = [11]> then\n    switch costume to (lava v)\n    change [color v] effect by (0)\n    set size to (100) %\n    set [ghost v] effect to (20)\n    go to [back v] layer\n    wait (0.5) seconds\n    forever\n        repeat (7)\n            lava animation [1]\n        end\n        repeat (7)\n            lava animation [0]\n        end\n    end\nend\n\ndefine conveyor spike setup (id#)\nwait until <(level) = [5]>\nwait (((id#) - (16)) * (2)) seconds\npoint in direction (90)\nswitch costume to (spike v)\nset size to (75) %\ngo to [back v] layer\nforever\n    tile [700] [0] level [5] conveyor [1] [0] (id#)\nend\n\nwhen I receive [win v]\nstop [other scripts in sprite v]\nstop [this script v]\n\n@Other\n\ndefine tile (x) (y)\nshow\ngo to x: (x) y: (y)\nif <<not <(x position) = (x)>> or <not <(y position) = (y)>>> then\n    hide\nend\n\nwhen flag clicked\nhide\nwait until <(level) = [0]>\nwait until <(level) = [1]>\nset [id# v] to [0]\nrepeat (3)\n    change [id# v] by (1)\n    create clone of (_myself_ v)\nend\nstop [this script v]\n\nwhen I start as a clone\nif <(ID#) = [1]> then\n    switch costume to (chain v)\n    set size to (37) %\n    show at level [3] tile at [300] [129]\nend\nif <(ID#) = [2]> then\n    switch costume to (chain v)\n    set size to (37) %\n    show at level [3] tile at [500] [229]\nend\nif <(ID#) = [3]> then\n    switch costume to (chain v)\n    set size to (37) %\n    show at level [3] tile at [700] [329]\nend\n\ndefine show at level (level) tile at (x) (y)\nhide\nwait until <(level) = (level)>\nrepeat until <(level) > (level)>\n    tile ((x) - (worldx)) ((y) - (worldy))\n    set size to (37) %\nend\ndelete this clone\n\nwhen I receive [win v]\nstop [other scripts in sprite v]\nstop [this script v]\n\n@Mobs\n\nwhen flag clicked\nhide\nwait until <(level) = [0]>\nwait until <(level) = [1]>\nset [id# v] to [0]\nrepeat (2)\n    change [id# v] by (1)\n    create clone of (_myself_ v)\nend\nstop [this script v]\n\ndefine tile (x) (y)\nshow\ngo to x: (x) y: (y)\nif <<not <(x position) = (x)>> or <not <(y position) = (y)>>> then\n    hide\nend\n\nwhen I start as a clone\nhide\nif <(ID#) = [1]> then\n    wait until <(level) = [2]>\n    repeat until <<(level) > [2]> or <<touching (player v)?> and <(ground) = [0]>>>\n        tile (((750) + (move x1)) - (worldx)) ((371) - (worldy))\n        if <(move x1) = [0]> then\n            switch costume to (mob v)\n        end\n        if <(move x1) = [100]> then\n            switch costume to (mob2 v)\n        end\n    end\n    delete this clone\nend\nif <(ID#) = [2]> then\n    wait until <(level) = [4]>\n    repeat until <<(level) > [4]> or <<touching (player v)?> and <(ground) = [0]>>>\n        tile (((750) + (move x1)) - (worldx)) ((1026) - (worldy))\n        if <(move x1) = [0]> then\n            switch costume to (mob v)\n        end\n        if <(move x1) = [100]> then\n            switch costume to (mob2 v)\n        end\n    end\n    delete this clone\nend\n\nwhen flag clicked\nwait until <(level) = [0]>\nwait until <(level) = [1]>\nset [move x1 v] to [0]\nforever\n    repeat (25)\n        change [move x1 v] by (4)\n    end\n    repeat (25)\n        change [move x1 v] by (-4)\n    end\nend\n\nwhen I receive [win v]\nstop [other scripts in sprite v]\nstop [this script v]\n\n@Trampoline\n\ndefine tile (x) (y)\nshow\ngo to x: (x) y: (y)\nif <<not <(x position) = (x)>> or <not <(y position) = (y)>>> then\n    hide\nend\n\nwhen flag clicked\nhide\nwait until <(level) = [0]>\nwait until <(level) = [1]>\nset [id# v] to [0]\nrepeat (4)\n    change [id# v] by (1)\n    create clone of (_myself_ v)\nend\nstop [this script v]\n\nwhen I start as a clone\nif <(ID#) = [1]> then\n    switch costume to (bounce1 v)\n    set size to (150) %\n    show at level [4] tile at [50] [-20]\nend\nif <(ID#) = [2]> then\n    switch costume to (bounce1 v)\n    set size to (150) %\n    show at level [4] tile at [230] [280]\nend\nif <(ID#) = [3]> then\n    switch costume to (bounce1 v)\n    set size to (150) %\n    show at level [4] tile at [430] [580]\nend\nif <(ID#) = [4]> then\n    switch costume to (bounce1 v)\n    set size to (150) %\n    show at level [4] tile at [630] [880]\nend\n\ndefine show at level (level) tile at (x) (y)\nhide\nwait until <(level) = (level)>\nrepeat until <(level) > (level)>\n    tile ((x) - (worldx)) ((y) - (worldy))\nend\ndelete this clone\n\nwhen I start as a clone\nforever\n    if <<touching (player v)?> and <(ground) = [0]>> then\n        broadcast (Bounce v)\n        repeat (5)\n            next costume\n        end\n        repeat (5)\n            switch costume to ((costume [number v]) - (1))\n        end\n    end\nend\n\nwhen I receive [win v]\nstop [other scripts in sprite v]\nstop [this script v]\n\n@Light\n\nwhen flag clicked\nhide\nwait until <(level) = [0]>\nwait until <(level) = [3]>\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)\n\nwhen I start as a clone\nif <(ID#) = [1]> then\n    set size to (125) %\n    switch costume to (light  v)\n    show\n    forever\n        go to x: (light x) y: (light y)\n        go to [back v] layer\n        go [forward v] (3) layers\n    end\nelse\n    if <(ID#) = [2]> then\n        set size to (103) %\n        switch costume to (gradient v)\n        show\n        forever\n            go to x: (light x) y: (light y)\n            if <(RESET_) = [1]> then\n                go to [back v] layer\n                wait until <(RESET_) = [0]>\n            else\n                go to [front v] layer\n            end\n        end\n    else\n        switch costume to (nothin' v)\n        set size to (350) %\n        show\n        switch costume to (light border v)\n        forever\n            go to x: (light x) y: (light y)\n            if <(RESET_) = [1]> then\n                switch costume to (dark v)\n                wait until <(RESET_) = [0]>\n            else\n                switch costume to (light border v)\n                go to [front v] layer\n            end\n        end\n    end\nend\n\nwhen I start as a clone\nwait until <(level) > [4]>\ndelete this clone\n\nwhen I receive [win v]\nstop [other scripts in sprite v]\nstop [this script v]\n\n@Portal\n\ndefine tile (x) (y)\ngo to x: (x) y: (y)\nif <<not <(x position) = (x)>> or <not <(y position) = (y)>>> then\n    hide\nend\nshow\n\nwhen flag clicked\nhide\nwait until <(level) = [0]>\nwait until <(level) = [1]>\ndelete all of [portal x v]\ndelete all of [portal y v]\nSet x to [1075] y [0]\nSet x to [1050] y [380]\nSet x to [1550] y [265]\nSet x to [1000] y [1100]\nSet x to [1500] y [0]\nSet x to [1000000] y [1000000]\nhide\nforever\n    tile ((item (level) of [portal x v]) - (worldx)) ((item (level) of [portal y v]) - (worldy))\n    if <(RESET_) = [1]> then\n        go to [front v] layer\n        wait until <(RESET_) = [0]>\n    end\nend\n\ndefine Set x to (x) y (y)\nadd (x) to [portal x v]\nadd (y) to [portal y v]\n\nwhen I receive [win v]\nstop [other scripts in sprite v]\nstop [this script v]\n\n@Info\n\nwhen flag clicked\ngo to x: (0) y: (0)\nset [ghost v] effect to (100)\nhide\nswitch costume to (level2 v)\n\nwhen flag clicked\nwait until <(level) = [0]>\nwait until <(level) = [1]>\nforever\n    wait until <(next) = [1]>\n    set [pause timer v] to [1]\n    if <(level) > [1]> then\n        next costume\n    end\n    wait (3) seconds\n    go to [front v] layer\n    show\n    repeat (20)\n        change [ghost v] effect by (-5)\n    end\n    wait until <(next) = [start]>\n    set [pause timer v] to [0]\n    repeat (20)\n        change [ghost v] effect by (5)\n    end\n    hide\nend\n\nwhen flag clicked\nwait until <(level) = [0]>\nwait until <(level) = [6]>\nif <<(timer) < (☁ Highscore)> and <(skipped a level UwU) = [0]>> then\n    set [☁ highscore v] to (round (timer))\nend\ngo to x: (0) y: (0)\nswitch costume to (player health v)\nforever\n    set [ghost v] effect to (0)\n    show\n    go to [front v] layer\n    if <(hp) > [0]> then\n        switch costume to (((hp) * (-1)) + (11))\n    end\nend\n\nwhen flag clicked\nwait until <(level) = [0]>\nwait until <(level) = [1]>\nset [timer v] to [0]\nset [pause timer v] to [0]\nforever\n    wait (0.033) seconds\n    if <<(level) < [6]> and <(pause timer) = [0]>> then\n        change [timer v] by (0.1)\n    end\nend\n\nwhen I receive [win v]\nstop [other scripts in sprite v]\ngo to x: (0) y: (0)\nshow\nset [ghost v] effect to (100)\nif <(skipped a level UwU) = [1]> then\n    switch costume to (score3 v)\nelse\n    if <(☁ Highscore) = (round (timer))> then\n        switch costume to (score2 v)\n    else\n        switch costume to (score v)\n    end\nend\nrepeat (20)\n    change [ghost v] effect by (-5)\nend\nshow variable [☁ highscore v]\nshow variable [timer v]\n\nwhen flag clicked\nhide variable [☁ highscore v]\nhide variable [timer v]\n\nwhen [timer v] > (0)\nhide variable [☁ highscore v]\nhide variable [timer v]\n\n@Boss\n\nwhen flag clicked\nhide\nwait until <(level) = [0]>\nwait until <(level) = [6]>\nswitch costume to (boss v)\nshow\ngo to x: (200) y: (75)\n\nwhen flag clicked\nwait until <(level) = [0]>\nwait until <(level) = [6]>\nwait (1) seconds\nset [boss yvel v] to [0]\nset [boss xvel v] to [0]\nforever\n    y physics\n    if <(boss hp) < [1]> then\n        broadcast (win v)\n    end\n    if <<(boss yvel) < [0]> and <<(boss ground) = [0]> and <touching (player v)?>>> then\n        if <(([y position v] of [player v]) + (45)) < (y position)> then\n            change [hp v] by (-1)\n            if <(hp) < [1]> then\n                broadcast (defeat v)\n            end\n            create clone of (_myself_ v)\n            start sound [Whack v]\n        end\n    end\nend\n\ndefine y physics\nchange [boss yvel v] by (-1)\nif <<<(pick random (1) to (13)) = [1]> and <(distance to [player v]) < [75]>> and <(boss ground) = [1]>> then\n    set [boss yvel v] to [15]\nend\nset [boss ground v] to [0]\nchange y by (boss yvel)\nif <touching (platforms v)?> then\n    repeat until <not <touching (platforms v)?>>\n        change y by (((boss yvel) / ([abs v] of (boss yvel) )) * (-1))\n    end\n    set [boss yvel v] to [0]\n    set [boss ground v] to [1]\nend\n\ndefine x physics\nchange x by (boss xvel)\nif <touching (platforms v)?> then\n    change x by ((boss xvel) * (-1))\n    set [boss xvel v] to [0]\nend\n\nwhen flag clicked\nwait until <(level) = [0]>\nwait until <(level) = [6]>\nset [boss xvel v] to [0]\nset [distance to player v] to [100]\nforever\n    if <<(distance to [player v]) > (distance to player)> and <(x position) < ([x position v] of [player v])>> then\n        switch costume to (boss v)\n        repeat until <<(boss xvel) = [10]> or <not <<(distance to [player v]) > (distance to player)> and <(x position) < ([x position v] of [player v])>>>>\n            if <(boss xvel) > [9]> then\n                set [boss xvel v] to [10]\n            else\n                change [boss xvel v] by (1)\n            end\n        end\n        if <<(distance to [player v]) > (distance to player)> and <(x position) < ([x position v] of [player v])>> then\n            repeat until <not <<(distance to [player v]) > (distance to player)> and <(x position) < ([x position v] of [player v])>>>\n                set [boss xvel v] to [10]\n            end\n        end\n        repeat until <<(boss xvel) = [0]> or <<(distance to [player v]) > (distance to player)> and <(x position) < ([x position v] of [player v])>>>\n            if <(boss xvel) < [0.75]> then\n                set [boss xvel v] to [0]\n            else\n                change [boss xvel v] by (((boss xvel) / ([abs v] of (boss xvel) )) * (-0.75))\n            end\n        end\n    end\n    if <<(distance to [player v]) > (distance to player)> and <(x position) > ([x position v] of [player v])>> then\n        switch costume to (boss2 v)\n        repeat until <<(boss xvel) = [-10]> or <not <<(distance to [player v]) > (distance to player)> and <(x position) > ([x position v] of [player v])>>>>\n            if <(boss xvel) < [-9]> then\n                set [boss xvel v] to [-10]\n            else\n                change [boss xvel v] by (-1)\n            end\n        end\n        if <<(distance to [player v]) > (distance to player)> and <(x position) > ([x position v] of [player v])>> then\n            repeat until <not <<(distance to [player v]) > (distance to player)> and <(x position) > ([x position v] of [player v])>>>\n                set [boss xvel v] to [-10]\n            end\n        end\n        repeat until <<(boss xvel) = [0]> or <<(distance to [player v]) > (distance to player)> and <(x position) > ([x position v] of [player v])>>>\n            if <(boss xvel) > [-0.75]> then\n                set [boss xvel v] to [0]\n            else\n                change [boss xvel v] by (((boss xvel) / ([abs v] of (boss xvel) )) * (-0.75))\n            end\n        end\n    end\nend\n\nwhen flag clicked\nwait until <(level) = [0]>\nwait until <(level) = [6]>\nwait (1) seconds\nforever\n    x physics\nend\n\nwhen I start as a clone\nchange y by (-17)\ngo to [front v] layer\nset size to (65) %\nswitch costume to (pow v)\nshow\nwait (0.3) seconds\ndelete this clone\n\nwhen I receive [win v]\nstop [other scripts in sprite v]\nstop [this script v]\n\n@Menu\n\nwhen flag clicked\nhide\nforever\n    change [mytimer v] by (1)\nend\n\nwhen I receive [menu v]\nset [help v] to [0]\nset [mytimer v] to [0]\nset [id# v] to [1]\ncreate clone of (_myself_ v)\nshow\nset size to (50) %\nswitch costume to (play v)\ngo to x: (-150) y: (0)\nforever\n    change y by (([cos v] of (((mytimer) + (1)) * (10)) ) * (5))\n    point in direction ((([cos v] of (((mytimer) + (1)) * (10)) ) * (5)) + (90))\n    if <<<mouse down?> and <touching (mouse-pointer v)?>> and <(level) = [0]>> then\n        set [level v] to [1]\n    end\n    if <<(help) = [1]> or <(level) > [0]>> then\n        hide\n    else\n        show\n    end\nend\n\nwhen I start as a clone\nif <(ID#) = [1]> then\n    show\n    set size to (50) %\n    switch costume to (help v)\n    go to x: (150) y: (0)\n    forever\n        change y by (([cos v] of (((mytimer) + (1)) * (10)) ) * (5))\n        point in direction ((([cos v] of (((mytimer) + (1)) * (10)) ) * (5)) + (90))\n        if <<mouse down?> and <touching (mouse-pointer v)?>> then\n            set [id# v] to [2]\n            set [help v] to [1]\n            create clone of (_myself_ v)\n        end\n        if <<(help) = [1]> or <(level) > [0]>> then\n            hide\n            if <(level) = [1]> then\n                delete this clone\n            end\n        else\n            show\n        end\n    end\nend\nif <(ID#) = [2]> then\n    show\n    set size to (100) %\n    set [ghost v] effect to (100)\n    switch costume to (how to play v)\n    point in direction (90)\n    go to x: (0) y: (0)\n    repeat (10)\n        change [ghost v] effect by (-10)\n    end\n    forever\n        go to [front v] layer\n        if <<mouse down?> or <key (space v) pressed?>> then\n            repeat (10)\n                change [ghost v] effect by (10)\n            end\n            set [help v] to [0]\n            delete this clone\n        end\n    end\nend\n\nwhen I receive [win v]\nstop [other scripts in sprite v]\nstop [this script v]\n\n@Parallax \n\ndefine tile (x) (y)\nshow\ngo to x: (x) y: (y)\nif <<not <(x position) = (x)>> or <not <(y position) = (y)>>> then\n    hide\nend\n\nwhen flag clicked\nhide\nwait until <(level) = [0]>\nwait until <(level) = [1]>\nset [ghost v] effect to (75)\ngo to [back v] layer\nswitch costume to (nothing v)\nset size to (350) %\nswitch costume to (parallax  v)\nshow\nforever\n    if <<<(level) = [1]> or <(level) = [6]>> or <<(level) = [3]> or <(level) = [4]>>> then\n        tile (((worldx) / (4)) * (-1)) (((worldy) / (4)) * (-1))\n    end\n    if <(level) = [2]> then\n        tile ((500) - ((worldx) / (4))) ((0) - ((worldy) / (4)))\n    end\n    if <(level) = [5]> then\n        tile ((250) - ((worldx) / (4))) ((-150) - ((worldy) / (4)))\n    end\n    go to [back v] layer\nend\n\nwhen I receive [win v]\nstop [other scripts in sprite v]\nstop [this script v]\n\n@Blocks\n\nwhen I start as a clone\nset size to (100) %\nset [ghost v] effect to (55)\nif <<(pick random (1) to (2)) = [1]> and <(xpos.) < [0.75]>> then\n    change [xpos. v] by (0.5)\n    switch costume to (block2 v)\nelse\n    change [xpos. v] by (0.25)\n    switch costume to (block v)\nend\nshow\ngo to [back v] layer\nset y to (175)\nif <(costume [number v]) = [1]> then\n    if <(xpos.) = [0.25]> then\n        set x to (-180)\n    end\n    if <(xpos.) = [0.5]> then\n        set x to (-60)\n    end\n    if <(xpos.) = [0.75]> then\n        set x to (60)\n    end\n    if <(xpos.) = [1]> then\n        set x to (180)\n    end\nelse\n    if <(xpos.) = [0.5]> then\n        set x to (-120)\n    end\n    if <(xpos.) = [0.75]> then\n        set x to (0)\n    end\n    if <(xpos.) = [1]> then\n        set x to (120)\n    end\nend\nrepeat ((50) - (layer))\n    change y by (-7)\n    go to [back v] layer\n    if <(level) = [6]> then\n        delete this clone\n    end\nend\nif <(xpos.) = [1]> then\n    change [layer v] by (3)\n    set [xpos. v] to [0]\nend\nif <(layer) < [108]> then\n    create clone of (_myself_ v)\nelse\n    broadcast (defeat v) and wait\nend\nforever\n    go to [back v] layer\n    if <(level) = [6]> then\n        delete this clone\n    end\nend\n\nwhen flag clicked\nwait until <(level) = [0]>\nwait until <(level) = [1]>\nforever\n    wait until <(next) = [1]>\n    repeat (3)\n        broadcast (Clear blocks v)\n    end\n    wait until <(next) = [start]>\n    wait (1) seconds\n    set [layer v] to [0]\n    set [xpos. v] to [0]\n    create clone of (_myself_ v)\n    wait until <(next) = []>\nend\n\nwhen flag clicked\nwait until <(level) = [0]>\nwait until <(level) = [1]>\nset [layer v] to [0]\nset [xpos. v] to [0]\ncreate clone of (_myself_ v)\nwait until <<(layer) > [105]> or <(level) = [6]>>\nif <(level) = [6]> then\n    broadcast (Clear blocks v)\nelse\n    broadcast (defeat v)\nend\nstop [other scripts in sprite v]\nstop [this script v]\n\nwhen I receive [clear blocks v]\ndelete this clone\n\nwhen I receive [win v]\nstop [other scripts in sprite v]\nstop [this script v]\n\n@Player\n\ndefine collide y\nif <touching (platforms v)?> then\n    repeat until <not <touching (platforms v)?>>\n        change [y v] by (((yvel) / ([abs v] of (yvel) )) * (-1))\n        go to x: ((x) - (worldx)) y: ((y) - (worldy))\n    end\n    if <(yvel) < [0]> then\n        set [ground v] to [1]\n    end\n    set [yvel v] to [0]\nend\n\ndefine collide x\nif <touching (platforms v)?> then\n    repeat (6)\n        if <touching (platforms v)?> then\n            change [y v] by (1)\n            go to x: ((x) - (worldx)) y: ((y) - (worldy))\n        else\n            stop [this script v]\n        end\n    end\n    change [y v] by (-6)\n    go to x: ((x) - (worldx)) y: ((y) - (worldy))\n    repeat until <not <touching (platforms v)?>>\n        change [x v] by (((xvel) / ([abs v] of (xvel) )) * (-1))\n        go to x: ((x) - (worldx)) y: ((y) - (worldy))\n    end\n    set [xvel v] to [0]\nend\nrepeat (6)\n    change [y v] by (-1)\n    go to x: ((x) - (worldx)) y: ((y) - (worldy))\n    if <touching (platforms v)?> then\n        repeat until <not <touching (platforms v)?>>\n            change [y v] by (1)\n            go to x: ((x) - (worldx)) y: ((y) - (worldy))\n        end\n        stop [this script v]\n    end\nend\nchange [y v] by (6)\ngo to x: ((x) - (worldx)) y: ((y) - (worldy))\n\nwhen flag clicked\nwait until <(level) = [0]>\nwait until <(level) = [1]>\nwait (0.5) seconds\nforever\n    if <(RESET_) = [0]> then\n        if <<<key (right arrow v) pressed?> or <key (d v) pressed?>> or <<mouse down?> and <(mouse x) > ((x position) + (15))>>> then\n            repeat until <<(RESET_) = [1]> or <<(xvel) = [10]> or <not <<<key (right arrow v) pressed?> or <key (d v) pressed?>> or <<mouse down?> and <(mouse x) > ((x position) + (15))>>>>>>\n                if <(xvel) > [9]> then\n                    set [xvel v] to [10]\n                else\n                    change [xvel v] by (1)\n                end\n            end\n            if <<<key (right arrow v) pressed?> or <key (d v) pressed?>> or <<mouse down?> and <(mouse x) > (x position)>>> then\n                repeat until <<(RESET_) = [1]> or <not <<<key (right arrow v) pressed?> or <key (d v) pressed?>> or <<mouse down?> and <(mouse x) > ((x position) + (15))>>>>>\n                    set [xvel v] to [10]\n                end\n                set [wall_jump v] to [0]\n            end\n            repeat until <<(RESET_) = [1]> or <<(xvel) = [0]> or <<<key (right arrow v) pressed?> or <key (d v) pressed?>> or <<mouse down?> and <(mouse x) > ((x position) + (15))>>>>>\n                if <(xvel) < [0.8]> then\n                    set [xvel v] to [0]\n                else\n                    change [xvel v] by (((xvel) / ([abs v] of (xvel) )) * (-0.75))\n                end\n            end\n        end\n        if <<<key (left arrow v) pressed?> or <key (a v) pressed?>> or <<mouse down?> and <(mouse x) < ((x position) - (15))>>> then\n            repeat until <<(RESET_) = [1]> or <<(xvel) = [-10]> or <not <<<key (left arrow v) pressed?> or <key (a v) pressed?>> or <<mouse down?> and <(mouse x) < ((x position) - (15))>>>>>>\n                if <(xvel) < [-9]> then\n                    set [xvel v] to [-10]\n                else\n                    change [xvel v] by (-1)\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                repeat until <<(RESET_) = [1]> or <not <<<key (left arrow v) pressed?> or <key (a v) pressed?>> or <<mouse down?> and <(mouse x) < ((x position) - (15))>>>>>\n                    set [xvel v] to [-10]\n                end\n                set [wall_jump v] to [0]\n            end\n            repeat until <<(RESET_) = [1]> or <<(xvel) = [0]> or <<<key (left arrow v) pressed?> or <key (a v) pressed?>> or <<mouse down?> and <(mouse x) < ((x position) - (15))>>>>>\n                if <(xvel) > [-0.8]> then\n                    set [xvel v] to [0]\n                else\n                    change [xvel v] by (((xvel) / ([abs v] of (xvel) )) * (-0.75))\n                end\n            end\n        end\n    end\nend\n\ndefine switch costume\nif <(xvel) = [0]> then\n    if <<(yvel) > [0]> and <(ground) = [0]>> then\n        switch costume to (player3 v)\n    else\n        switch costume to (player v)\n    end\nend\nif <(xvel) > [0]> then\n    if <<(yvel) > [0]> and <(ground) = [0]>> then\n        switch costume to (player4 v)\n    else\n        switch costume to (player2 v)\n    end\nend\nif <(xvel) < [0]> then\n    if <<(yvel) > [0]> and <(ground) = [0]>> then\n        switch costume to (player6 v)\n    else\n        switch costume to (player5 v)\n    end\nend\n\nwhen I receive [reset v]\nset [xvel v] to [0]\nset [yvel v] to [0]\nset [ground v] to [0]\nset [x v] to (item (level) of [reset x v])\nset [y v] to (item (level) of [reset y v])\nset [worldx v] to [0]\nset [worldy v] to [0]\nset [next v] to []\nset [taps v] to [0]\ngo to x: ((x) - (worldx)) y: ((y) - (worldy))\nset [light x v] to (x position)\nset [light y v] to (y position)\nwait (0.1) seconds\nset [reset_ v] to [0]\n\ndefine set x reset to (x) y (y)\nadd (x) to [reset x v]\nadd (y) to [reset y v]\n\nwhen I receive [bounce v]\nif <(RESET_) = [0]> then\n    set [yvel v] to [35]\nend\n\nwhen flag clicked\nwait until <(level) = [0]>\nwait until <(level) = [1]>\nset [taps v] to [0]\ndelete all of [reset x v]\ndelete all of [reset y v]\nset x reset to [-50] y [-8]\nset x reset to [0] y [56]\nset x reset to [0] y [-8]\nset x reset to [-50] y [-8]\nset x reset to [-150] y [-8]\ngo to [front v] layer\nshow\npoint in direction (90)\nset [reset_ v] to [1]\nbroadcast (reset v)\nstart sound [Caelum v]\nforever\n    switch costume\n    change [x v] by (xvel)\n    go to x: ((x) - (worldx)) y: ((y) - (worldy))\n    collide x\n    change [yvel v] by (-2)\n    set [ground v] to [0]\n    change [y v] by (yvel)\n    go to x: ((x) - (worldx)) y: ((y) - (worldy))\n    collide y\n    if <<<(username) = [2Amateurs]> and <key (down arrow v) pressed?>> or <<(ground) = [1]> and <<<key (up arrow v) pressed?> or <key (w v) pressed?>> or <<mouse down?> and <(mouse y) > ((y position) + (15))>>>>> then\n        set [yvel v] to [22]\n    end\n    go to x: ((x) - (worldx)) y: ((y) - (worldy))\n    if <(level) < [6]> then\n        change [worldy v] by (round (((y) - (worldy)) / (10)))\n        change [worldx v] by (round (((x) - (worldx)) / (10)))\n        if <<(y position) < [-100]> and <(y) > [0]>> then\n            change [worldy v] by ((y position) - (-100))\n        end\n    else\n        if <<<touching (boss v)?> and <(ground) = [0]>> and <(yvel) < [0]>> then\n            if <(y position) > (([y position v] of [boss v]) + (45))> then\n                change [boss hp v] by (-1)\n                create clone of (_myself_ v)\n                start sound [Whack v]\n            end\n        end\n    end\n    go to x: ((x) - (worldx)) y: ((y) - (worldy))\n    set [light x v] to (x position)\n    set [light y v] to (y position)\n    check for exit\nend\n\ndefine check for exit\nif <<<(y position) < [-180]> or <touching (spikes, lava, saws, oh my... v)?>> or <<key (r v) pressed?> or <<touching (mobs v)?> and <(ground) = [1]>>>> then\n    set [reset_ v] to [1]\n    set [xvel v] to (((xvel) / ([abs v] of (xvel) )) * (-5))\n    set [yvel v] to [24]\n    repeat until <(yvel) < [-45]>\n        change y by (yvel)\n        change x by (xvel)\n        change [yvel v] by (-2)\n        set [light x v] to (x position)\n        set [light y v] to (y position)\n        change [ghost v] effect by (5)\n        go to [front v] layer\n    end\n    broadcast (reset v)\n    wait until <(RESET_) = [0]>\n    switch costume to (player v)\n    go to x: ((x) - (worldx)) y: ((y) - (worldy))\n    repeat (20)\n        change [ghost v] effect by (-5)\n    end\nend\nif <<<touching (portal v)?> or <key (y v) pressed?>> or <<(taps) = [3]> or <<mouse down?> and <(taps) = [0]>>>> then\n    if <not <(level) = [6]>> then\n        if <<mouse down?> and <(taps) = [0]>> then\n            broadcast (triple_tap? v)\n        else\n            if <<key (y v) pressed?> or <(taps) = [3]>> then\n                set [skipped a level uwu v] to [1]\n            end\n            through portal\n        end\n    end\nend\n\ndefine through portal\nset [next v] to [1]\nset [reset_ v] to [1]\nset [xvel v] to [0]\nswitch costume to (player v)\nif <touching (portal v)?> then\n    repeat until <<(y position) < [-180]> or <(distance to [portal v]) < [1]>>\n        point towards (portal v)\n        move ((distance to [portal v]) / (7)) steps\n        point in direction (90)\n        go to [front v] layer\n        set [light x v] to (x position)\n        set [light y v] to (y position)\n    end\n    repeat (60)\n        turn right (xvel) degrees\n        change [xvel v] by (1)\n    end\nend\nif <touching (portal v)?> then\n    repeat (10)\n        turn right (xvel) degrees\n        change [ghost v] effect by (10)\n    end\nelse\n    go to x: (0) y: (0)\n    switch costume to (skipping v)\n    go to [front v] layer\n    wait (3) seconds\n    repeat (10)\n        change [ghost v] effect by (10)\n        go to [front v] layer\n    end\nend\nwait until <<mouse down?> or <key (space v) pressed?>>\nset [next v] to [start]\nwait (1) seconds\nchange [level v] by (1)\nbroadcast (reset v)\nwait until <(RESET_) = [0]>\npoint in direction (90)\nswitch costume to (player v)\ngo to x: ((x) - (worldx)) y: ((y) - (worldy))\nrepeat (20)\n    change [ghost v] effect by (-5)\nend\n\nwhen I receive [triple_tap? v]\nchange [taps v] by (1)\nwait until <not <mouse down?>>\nrepeat (2)\n    repeat until <mouse down?>\n        if <(taps) = [0]> then\n            stop [this script v]\n        end\n    end\n    repeat until <not <mouse down?>>\n        if <(taps) = [0]> then\n            stop [this script v]\n        end\n    end\n    change [taps v] by (1)\nend\n\nwhen I receive [triple_tap? v]\nrepeat until <<(taps) = [3]> or <(taps) = [0]>>\n    check for triple tap (taps)\nend\n\ndefine check for triple tap (taps)\nwait (0.33) seconds\nif <(taps) > (taps)> then\n    stop [this script v]\nelse\n    set [taps v] to [0]\nend\n\nwhen flag clicked\nset [next v] to []\nset [taps v] to [0]\nset [hp v] to [5]\nset [boss hp v] to [10]\nset [skipped a level uwu v] to [0]\nhide\n\nwhen I start as a clone\nchange y by (-15)\nset size to (65) %\nswitch costume to (pow v)\nshow\nwait (0.3) seconds\ndelete this clone\n\nwhen I receive [win v]\nstop [other scripts in sprite v]\nstop [this script v]\n\n