Super Mario Platformer Demo!

Instructions: Note: You have to be a scratcher not a new scratcher to play/use. And this is just an engine (something for you to make and design your own lvls ) not a game, THE CLOUDS ARE THE END \n\nTo use this, READ THESE CAREFULLY. FIRST give @griffpatch , @TheCactusMaster,  and @StratfordJames CREDIT. You DON'T have to remix this. PRESS "See inside" and in your top left, you should SEE a button that says "File." Click it, and you should SEE a button below it that says "Save to your computer," press it. Then CREATE a NEW project, hit the "File" button, and BELOW the "File" button, HIT the "Load from your computer" button. The cloud WILL still work\n\n                                -Controls-\n-WASD, cursor keys, or mobile touch = move player\n-T = toggle chat\n-N = toggle chat\n                            \n                                   -Credits-\n-@griffpatch for his awesome tutorials\n-@-Xaf- for amazing music\n-@StratfordJames for the player art\n-Me (@TheCactusMaster) for the rest\n-The people who helped me test:\n-@AUMSUMTHEGREATHULK\n-@-coolhawk-\n-@KingQuacks\n-@-zerx-\n\n\n#Multiplayer #Scrolling #Platformer #engine #games #all

@Stage\n\nif <[13] < (LEVEL)> then\n    switch backdrop to (backdrop4 v)\nend\nif <(LEVEL) > [5]> then\n    switch backdrop to (backdrop1 v)\nend\n\nwait (115) seconds\nwait (0) seconds\n\nwhen I receive [tick v]\nif <<(LEVEL) = [1]> or <<(LEVEL) = [2]> or <<(LEVEL) = [3]> or <<(LEVEL) = [4]> or <(LEVEL) = [5]>>>>> then\n    switch backdrop to (backdrop1 v)\nend\nif <<(LEVEL) = [6]> or <<(LEVEL) = [7]> or <<(LEVEL) = [8]> or <<(LEVEL) = [9]> or <<(LEVEL) = [10]> or <<(LEVEL) = [11]> or <<(LEVEL) = [12]> or <(LEVEL) = [13]>>>>>>>> then\n    switch backdrop to (backdrop3 v)\nend\nif <<(LEVEL) = [14]> or <<(LEVEL) = [15]> or <(LEVEL) = [16]>>> then\n    switch backdrop to (backdrop4 v)\nend\n\n@blank\n\n@Trampoline\n\nwhen flag clicked\nswitch costume to (1 v)\nforever\n    hide\n    if <(LEVEL) = [5]> then\n        show\n        go to x: (-145) y: (-72)\n    end\n    if <(LEVEL) = [12]> then\n        go to x: (50) y: (-65)\n        show\n    end\n    if <(LEVEL) = [14]> then\n        go to x: (65) y: (-85)\n        show\n    end\nend\n\nwhen flag clicked\nforever\n    if <touching (platformer boi v)?> then\n        switch costume to (1 v)\n        repeat (6)\n            wait (0.02) seconds\n            next costume\n        end\n        wait until <not <touching (platformer boi v)?>>\n    end\nend\n\n@Level\n\nwhen flag clicked\nset [level v] to [1]\nswitch costume to (costume1 v)\nrepeat (10)\n    go to x: (0) y: (0)\n    set size to (90) %\n    go to [front v] layer\n    show\nend\nforever\n    switch costume to (LEVEL)\nend\n\nwhen I receive [next level v]\nchange [level v] by (1)\n\n@Spikes\n\nwhen I receive [previous level v]\nswitch costume to ((costume [number v]) - (1))\n\nwhen backdrop switches to [backdrop7 v]\ngo to [front v] layer\n\nwhen flag clicked\nshow\nforever\n    switch costume to (LEVEL)\n    set size to (90) %\nend\n\n@Bouce bois\n\nwhen I receive [tick v]\nswitch costume to (LEVEL)\nif <<touching (platformer boi v)?> and <<key (up arrow v) pressed?> or <<key (w v) pressed?> or <<mouse down?> and <(y position) < (mouse y)>>>>> then\n    set [ghost v] effect to (10)\n    wait until <not <touching (platformer boi v)?>>\nelse\n    set [ghost v] effect to (40)\nend\n\n@portal\n\nwhen [timer v] > (0.1)\nhide\n\nwhen flag clicked\nswitch costume to (costume2 v)\ncreate clone of (_myself_ v)\nshow\nrepeat (10)\n    go to [front v] layer\nend\nforever\n    turn right (3) degrees\nend\n\nwhen flag clicked\nrepeat (10)\n    clear graphic effects\nend\nforever\n    show\n    if <(LEVEL) = [1]> then\n        go to x: (200) y: (0)\n    end\n    if <(LEVEL) = [2]> then\n        go to x: (200) y: (-50)\n    end\nend\n\nwhen I start as a clone\nswitch costume to (costume2 v)\nshow\nforever\n    turn left (3) degrees\n    go to [front v] layer\nend\n\nwhen I start as a clone\nrepeat (10)\n    clear graphic effects\nend\nforever\n    show\n    if <(LEVEL) = [1]> then\n        go to x: (200) y: (0)\n    end\n    if <(LEVEL) = [2]> then\n        go to x: (200) y: (-50)\n    end\nend\n\n@Decor\n\nwhen flag clicked\nrepeat (11)\n    go to [back v] layer\nend\nshow\nforever\n    wait (0.001) seconds\n    switch costume to (LEVEL)\nend\n\nhide\n\nwhen [space v] key pressed\nhide\n\n@Saw1\n\nwhen flag clicked\nforever\n    turn left (3) degrees\nend\n\nturn right (3) degrees\n\nwhen flag clicked\nshow\nforever\n    switch costume to (LEVEL)\n    go to [back v] layer\nend\n\nwhen flag clicked\nforever\n    if <(LEVEL) = [5]> then\n        go to x: (20) y: (-120)\n    end\n    if <(LEVEL) = [7]> then\n        go to x: (-80) y: (30)\n    end\n    if <(LEVEL) = [15]> then\n        go to x: (-80) y: (-90)\n    end\nend\n\n@Moving Spikes\n\nwhen flag clicked\nswitch costume to (ball-b2 v)\nforever\n    if <(LEVEL) = [6]> then\n        switch costume to (ball-b2 v)\n        wait (0.5) seconds\n        repeat (4)\n            wait (0.05) seconds\n            next costume\n        end\n        wait (1) seconds\n    end\n    if <(LEVEL) = [9]> then\n        switch costume to (spikes lvl9 v)\n        wait (0.7) seconds\n        switch costume to (spikes lvl10 v)\n        wait (0.7) seconds\n    end\nend\n\nwhen I receive [tick v]\nhide\nif <(LEVEL) = [6]> then\n    show\n    go to x: (20) y: (-120)\nend\nif <(LEVEL) = [9]> then\n    show\n    go to x: (20) y: (-120)\nend\n\n@Background stuff\n\nwhen I start as a clone\nshow\ngo to [back v] layer\npoint in direction (pick random (-40) to (-100))\ngo to x: (250) y: (pick random (-180) to (180))\nset size to (pick random (10) to (50)) %\nset [ghost v] effect to (pick random (85) to (95))\ngo to [back v] layer\nrepeat until <(x position) < [-200]>\n    change x by (-10)\nend\ndelete this clone\n\nwhen flag clicked\nforever\n    if <[5] < (LEVEL)> then\n        wait (0.005) seconds\n        hide\n        create clone of (_myself_ v)\n    end\nend\n\nwhen I start as a clone\nforever\n    go to [back v] layer\nend\n\n@Platformer Boi\n\nwhen I receive [restart v]\nReset\n\nwhen flag clicked\nset size to (37) %\n\nwhen I start as a clone\nif <<[13] < (LEVEL)> and <(LEVEL) < [16]>> then\n    delete this clone\nend\nshow\nrepeat (15)\n    if <<key (down arrow v) pressed?> or <<key (s v) pressed?> or <<mouse down?> and <(mouse y) < (y position)>>>> then\n        switch costume to (hello3 v)\n    else\n        switch costume to (hello9 v)\n    end\n    change size by (-1)\n    change [ghost v] effect by (7)\nend\ndelete this clone\n\nwhen flag clicked\nReset\n\nwhen I receive [previous level v]\nReset\n\nwhen I receive [next level v]\nReset\n\nwhen flag clicked\nrepeat (10)\n    go to [back v] layer\nend\nforever\n    if <touching (bouce bois2 v)?> then\n        set [y v] to [14]\n    end\n    wait (0.005) seconds\n    create clone of (_myself_ v)\n    if <<touching (trampoline v)?> or <<touching (trampoline v)?> or <<touching (trampoline3 v)?> or <touching (trampoline4 v)?>>>> then\n        set [y v] to [12]\n    end\n    if <touching (zoom v)?> then\n        change [x v] by (5)\n    end\n    if <<touching (bouce bois v)?> and <<key (up arrow v) pressed?> or <<key (w v) pressed?> or <<mouse down?> and <(y position) < (mouse y)>>>>> then\n        set [y v] to [7]\n    end\n    if <touching (portal v)?> then\n        broadcast (Next Level v)\n    end\n    if <<key (down arrow v) pressed?> or <<key (s v) pressed?> or <<mouse down?> and <(mouse y) < (y position)>>>> then\n        switch costume to (hello2 v)\n    else\n        switch costume to (hello5 v)\n    end\n    if <touching (ladder v)?> then\n        set [y v] to [-1]\n    end\n    if <<touching (ladder v)?> and <<key (up arrow v) pressed?> or <<key (w v) pressed?> or <<mouse down?> and <(y position) < (mouse y)>>>>> then\n        set [y v] to [5]\n    end\n    if <<touching (ladder v)?> and <touching (level v)?>> then\n        set [y v] to [0]\n    end\nend\n\nwhen flag clicked\n\nwhen this sprite clicked\nchange [color v] effect by (10)\n\nwhen flag clicked\ngo to [back v] layer\nset [color v] effect to (0)\nswitch costume to (hello5 v)\nshow\ngo to x: (-216) y: (0)\nset [x v] to [0]\nset [y v] to [0]\nforever\n    change [y v] by (-0.5)\n    if <<key (right arrow v) pressed?> or <<key (d v) pressed?> or <<mouse down?> and <(x position) < (mouse x)>>>> then\n        point in direction (90)\n        if <[4] < (costume [number v])> then\n            change [x v] by (0.8)\n        else\n            switch costume to (hello2 v)\n            change [x v] by (0.8)\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        point in direction (-90)\n        if <[4] < (costume [number v])> then\n            change [x v] by (-0.9)\n        else\n            switch costume to (hello3 v)\n            change [x v] by (-0.9)\n        end\n    end\n    set [x v] to ((x) * (0.9))\n    change x by (x)\n    if <<touching (level v)?> or <touching (moving platform v)?>> then\n        change y by (1)\n        if <<touching (level v)?> or <touching (moving platform v)?>> then\n            change y by (1)\n            if <<touching (level v)?> or <touching (moving platform v)?>> then\n                change y by (1)\n                if <<touching (level v)?> or <touching (moving platform v)?>> then\n                    change y by (1)\n                    if <<touching (level v)?> or <touching (moving platform v)?>> then\n                        change y by (1)\n                        if <<touching (level v)?> or <touching (moving platform v)?>> then\n                            change y by (1)\n                            if <<touching (level v)?> or <touching (moving platform v)?>> then\n                                change y by (-6)\n                                if <<key (up arrow v) pressed?> or <<key (w v) pressed?> or <<mouse down?> and <(y position) < (mouse y)>>>> then\n                                    set [y v] to [0]\n                                    if <(x) > [0]> then\n                                        set [x v] to [-10]\n                                    else\n                                        set [x v] to [10]\n                                    end\n                                else\n                                    change x by ((x) * (-1))\n                                    set [x v] to [0]\n                                end\n                            end\n                        end\n                    end\n                end\n            end\n        end\n    end\n    change y by (y)\n    if <<touching (level v)?> or <touching (moving platform v)?>> then\n        change y by ((y) * (-1))\n        set [y v] to [0]\n    end\n    change y by (-0.5)\n    if <<<touching (level v)?> or <touching (moving platform v)?>> and <<key (up arrow v) pressed?> or <<key (w v) pressed?> or <<mouse down?> and <(y position) < (mouse y)>>>>> then\n        if <[4] < (costume [number v])> then\n            set [y v] to [12]\n        else\n            set [y v] to [9]\n        end\n    end\n    change y by (0.5)\n    if <<touching (spikes v)?> or <<touching (saw1 v)?> or <<[-175] > (y position)> or <<touching (moving spikes v)?> or <<touching (smasher v)?> or <<touching (saw2 v)?> or >>>>>> then\n        set [player hidden? v] to [1]\n        repeat (10)\n            change [ghost v] effect by (10)\n            change [pixelate v] effect by (2)\n            wait (0.01) seconds\n        end\n        set [ghost v] effect to (0)\n        set [pixelate v] effect to (0)\n        set [player hidden? v] to [0]\n        Reset\n        broadcast (Restart v)\n    end\nend\n\ndefine Reset\nset [x v] to [0]\nset [yv v] to [0]\nset [y v] to [0]\ngo to x: (-216) y: (-50)\nshow\n\nset [y v] to [10]\nswitch costume to (hello4 v)\n\nwhen flag clicked\nforever\n    broadcast (Tick v)\nend\n\n@Saw2\n\nwhen flag clicked\nforever\n    turn left (3) degrees\nend\n\nwhen flag clicked\nshow\nforever\n    switch costume to (LEVEL)\n    go to [back v] layer\nend\n\nwhen flag clicked\nforever\n    if <(LEVEL) = [7]> then\n        go to x: (145) y: (50)\n    end\nend\n\n@Sprite3\n\nwhen flag clicked\nforever\n    if <(LEVEL) = [17]> then\n        hide\n    else\n        go to [front v] layer\n        show\n    end\nend\n\nwhen this sprite clicked\nbroadcast (Next Level v)\n\n@Sprite2\n\nwhen flag clicked\nswitch costume to (costume1 v)\nset volume to (100) %\ngo to [front v] layer\nshow\nplay sound [Elektronomia - Superhero \[NomiaTunes Release\] v] until done\nforever\n    play sound [Elektronomia - Superhero \[NomiaTunes Release\] v] until done\n    go to [front v] layer\n    show\nend\n\nwhen this sprite clicked\nif <(costume [number v]) = [1]> then\n    set volume to (0) %\nelse\n    set volume to (100) %\nend\nnext costume\n\nwhen I receive [next level v]\nrepeat (200)\n    go to [front v] layer\nend\n\n@Player's Shadow\n\nwhen flag clicked\nshow\nforever\n    if <<[5] < (LEVEL)> or <(player hidden?) = [1]>> then\n        wait (0.2) seconds\n        hide\n    else\n        show\n    end\n    go to (platformer boi v)\n    go to [back v] layer\n    set [ghost v] effect to (75)\nend\n\nwhen flag clicked\nset [player hidden? v] to [0]\n\n@Shadows2\n\nwhen I receive [previous level v]\nswitch costume to ((costume [number v]) - (1))\n\nwhen flag clicked\ngo to [back v] layer\ngo to x: (0) y: (0)\nshow\nforever\n    set [ghost v] effect to (30)\n    switch costume to (LEVEL)\n    set size to (100) %\nend\n\n@Smasher\n\nset size to (90) %\n\nswitch costume to (costume1 v)\n\nwhen I receive [tick v]\nhide\nif <(LEVEL) = [10]> then\n    go to x: (-35) y: (0)\n    show\nend\n\nwhen I receive [tick v]\n\nwhen flag clicked\nforever\n    switch costume to (costume1 v)\n    wait (1.65) seconds\n    repeat (2)\n        wait (0.07) seconds\n        next costume\n    end\n    wait (0.06) seconds\n    next costume\n    wait (1) seconds\nend\n\n@Smasher2\n\nset size to (90) %\n\nswitch costume to (costume1 v)\n\nwhen I receive [tick v]\nhide\nif <(LEVEL) = [11]> then\n    go to x: (105) y: (0)\n    show\nend\n\nwhen I receive [tick v]\n\nwhen flag clicked\nforever\n    switch costume to (costume1 v)\n    wait (1.65) seconds\n    repeat (2)\n        wait (0.07) seconds\n        next costume\n    end\n    wait (0.06) seconds\n    next costume\n    wait (1) seconds\nend\n\n@Smasher3\n\nset size to (90) %\n\nswitch costume to (costume1 v)\n\nwhen I receive [tick v]\nhide\nif <(LEVEL) = [11]> then\n    go to x: (-115) y: (0)\n    show\nend\n\nwhen I receive [tick v]\n\nwhen flag clicked\nforever\n    switch costume to (costume1 v)\n    wait (1.65) seconds\n    repeat (2)\n        wait (0.07) seconds\n        next costume\n    end\n    wait (0.06) seconds\n    next costume\n    wait (1) seconds\nend\n\n@Transition\n\nwhen flag clicked\nclear graphic effects\ngo to x: (400) y: (0)\nhide\n\nwhen I receive [next level v]\ngo to x: (-400) y: (0)\nclear graphic effects\nshow\ngo to [front v] layer\nrepeat (60)\n    move (15) steps\n    change [ghost v] effect by (1.5)\nend\nrepeat (4)\n    change [ghost v] effect by (10)\nend\nhide\n\n@Signs\n\nwhen I receive [tick v]\nif <<(LEVEL) = [1]> and <touching (platformer boi v)?>> then\n    say [Welcome! Use WASD, Arrow Keys, or Mobile to move. Make sure to read the instructions!] for (0.5) seconds\n    wait until <not <touching (platformer boi v)?>>\nend\n\nwhen I receive [tick v]\nhide\nif <(LEVEL) = [1]> then\n    go to [back v] layer\n    show\n    go to x: (-185) y: (-55)\nend\n\ndefine Say (text) (wait seconds)\nset [say v] to []\nset [letter v] to []\nrepeat (length of (text))\n    change [letter v] by (1)\n    set [say v] to (join (say) (letter (letter) of (text)))\n    say (say)\nend\nwait (wait seconds) seconds\nsay []\n\nwhen flag clicked\nrepeat (12)\n    wait (0.001) seconds\nend\n\nSay [Welcome! Use WASD, Arrow Keys, or Mobile to move. Make sure to read the instructions!] [4]\n\n@Ladder\n\nwhen I receive [tick v]\nswitch costume to (LEVEL)\ngo to [back v] layer\n\n@Enemies\n\nwhen I receive [restart v]\ndelete this clone\n\ndefine Clone (type) (x) (y)\ngo to x: (x) y: (y)\nswitch costume to (type)\nset [clone# v] to (type)\ncreate clone of (_myself_ v)\n\nwhen I start as a clone\nclear graphic effects\nset size to (37) %\nshow\nset [enemyx v] to [0]\nset [enemyy v] to [0]\ngo to [front v] layer\nforever\n    if <touching (enemies2 v)?> then\n        clear graphic effects\n        set rotation style [all around v]\n        repeat (20)\n            turn right (15) degrees\n            change y by (10)\n            change [ghost v] effect by (5)\n        end\n        delete this clone\n    end\n    change [enemyy v] by (-1)\n    if <([x position v] of [platformer boi v]) < ((x position) - (10))> then\n        change [enemyx v] by ((0) - ((Speed) / (3)))\n        point in direction (-90)\n    end\n    if <((x position) - (-10)) < ([x position v] of [platformer boi v])> then\n        change [enemyx v] by ((Speed) / (3))\n        point in direction (90)\n    end\n    set [enemyx v] to ((Enemyx) * (0.9))\n    change x by (Enemyx)\n    if <touching (level v)?> then\n        change y by (1)\n    end\n    if <touching (level v)?> then\n        change y by (1)\n    end\n    if <touching (level v)?> then\n        change y by (1)\n    end\n    if <touching (level v)?> then\n        change y by (1)\n    end\n    if <touching (level v)?> then\n        change y by (-4)\n        change x by ((Enemyx) * (-1))\n        if <(y position) < ([y position v] of [platformer boi v])> then\n            set [enemyy v] to [10]\n            if <([abs v] of (x2) ) = (x2)> then\n                set [enemyx v] to [-10]\n            else\n                set [enemyx v] to [10]\n            end\n        else\n            set [enemyx v] to [0]\n        end\n    end\n    change y by (Enemyy)\n    if <touching (level v)?> then\n        change y by ((Enemyy) - ((Enemyy) * (2)))\n        set [enemyy v] to [0]\n    end\n    change y by (-1)\n    if <<((y position) - (-50)) < ([x position v] of [platformer boi v])> and <touching (level v)?>> then\n        set [enemyy v] to [14]\n    end\n    change y by (1)\nend\n\nwhen flag clicked\nset [amount v] to [1]\nset [speed v] to [1]\n\nwhen I receive [clone v]\nif <(clone id) = [0]> then\n    create clone of (_myself_ v)\nend\n\nwhen I receive [deleteclones v]\ndelete this clone\n\nwhen flag clicked\nforever\n    if <(LEVEL) = [13]> then\n        broadcast (clone v)\n    else\n        delete this clone\n    end\nend\n\nwhen I start as a clone\nchange [clone id v] by (1)\n\nwhen I receive [restart v]\ndelete this clone\n\nwhen I receive [restart v]\nwait (0.075) seconds\nset [clone id v] to [0]\n\nwhen I receive [next level v]\ndelete this clone\n\nwhen flag clicked\nset [clone id v] to [0]\n\n@Sprite4\n\nwhen flag clicked\nforever\n    go to [front v] layer\n    show\nend\n\nwhen this sprite clicked\nbroadcast (Restart v)\n\n@Decor2\n\nwhen I receive [tick v]\nswitch costume to (LEVEL)\ngo to [back v] layer\n\n@Hitbox\n\nwhen flag clicked\nset [ghost v] effect to (100)\nforever\n    go to (platformer boi v)\nend\n\n@Bouce bois2\n\nwhen I receive [tick v]\nswitch costume to (LEVEL)\nif <touching (platformer boi v)?> then\n    set [ghost v] effect to (0)\n    wait until <not <touching (platformer boi v)?>>\nelse\n    set [ghost v] effect to (10)\nend\n\n@Sprite1\n\nwhen flag clicked\nset [ghost v] effect to (35)\nset size to (100) %\nforever\n    repeat (10)\n        change size by (2)\n    end\n    repeat (10)\n        change size by (-2)\n    end\nend\n\nwhen I receive [tick v]\ngo to (platformer boi v)\nhide\nif <<(LEVEL) = [14]> or <<(LEVEL) = [15]> or <(LEVEL) = [16]>>> then\n    show\n    go to [back v] layer\nend\n\n@Achievements\n\nwhen flag clicked\nset [deaths v] to [0]\nset [lvl10 v] to [0]\nset [done v] to [0]\nset [bounce v] to [0]\nset [easter egg v] to [0]\nset [skip v] to [0]\nset [climb v] to [0]\n\nwhen I receive [tick v]\n\n@Toenail\n\nwhen flag clicked\nhide\n\n