Abandoned Caverns // Scrolling Platformer #games #platformers
@Stage\n\n@Intro1\n\nwhen flag clicked\nhide\nwait (0.1) seconds\nclear graphic effects\nswitch costume to (bg v)\ncreate clone of (_myself_ v)\nwait (0.1) seconds\nswitch costume to (logo v)\ncreate clone of (_myself_ v)\nwait (0.8) seconds\nswitch costume to (text v)\ncreate clone of (_myself_ v)\nwait (2) seconds\nbroadcast (intro2 v)\n\nwhen I start as a clone\nif <(costume [name v]) = [bg]> then\n    go to x: (0) y: (0)\n    set size to (100) %\n    show\nend\nif <(costume [name v]) = [logo]> then\n    point in direction (0)\n    go to x: (0) y: (0)\n    set size to (0) %\n    show\n    repeat (20)\n        change size by (((100) - (size)) / (3))\n        turn right (((90) - (direction)) / (3)) degrees\n    end\n    wait (0.1) seconds\n    repeat (30)\n        change x by (((-110) - (x position)) / (3))\n    end\n    wait (0.2) seconds\nend\nif <(costume [name v]) = [text]> then\n    go to x: (0) y: (0)\n    set size to (100) %\n    go [backward v] (1) layers\n    show\n    repeat (30)\n        change x by (((40) - (x position)) / (3))\n    end\nend\n\nwhen I receive [intro2 v]\nif <(costume [name v]) = [bg]> then\n    wait (0.5) seconds\nend\nrepeat (10)\n    change [ghost v] effect by (10)\nend\ndelete this clone\n\n@Intro2\n\nwhen flag clicked\nhide\n\ndefine Change X Y and clone\nset [y v] to [-3]\ncreate clone of (_myself_ v)\nchange [y v] by (6)\ncreate clone of (_myself_ v)\nchange [intro: x v] by (3)\n\nwhen I start as a clone\nif <(Clone) = [Tiles]> then\n    switch costume to (tile 1 v)\n    set size to (0) %\n    go to [front v] layer\n    point in direction (45)\n    show\n    repeat (20)\n        switch costume to (blank 2 v)\n        go to x: ((62) * (Intro: x)) y: ((34) * (y))\n        change size by (((150) - (size)) / (10))\n        switch costume to (tile 1 v)\n    end\n    wait (2) seconds\n    delete this clone\nend\n\ndefine Clone Tiles\nset [intro: x v] to [-3]\nset [clone v] to [Tiles]\nrepeat (3)\n    Change X Y and clone\nend\n\nwhen I start as a clone\nif <(Clone) = [Tiles 2]> then\n    switch costume to (tile 1 v)\n    set size to (0) %\n    go to [front v] layer\n    point in direction (90)\n    show\n    repeat (20)\n        switch costume to (blank 2 v)\n        go to x: ((62) * (Intro: x)) y: ((34) * (y))\n        change size by (((150) - (size)) / (10))\n        switch costume to (tile 1 v)\n    end\n    wait (2) seconds\n    delete this clone\nend\n\ndefine Clone Tiles 2\nset [intro: x v] to [-1.5]\nset [clone v] to [Tiles 2]\nChange X Y and clone\nChange X Y and clone\n\nwhen I start as a clone\nif <(Clone) = [Main Tile]> then\n    switch costume to (tile 1 v)\n    set size to (0) %\n    go to [front v] layer\n    point in direction (90)\n    go to x: (0) y: (0)\n    show\n    repeat (20)\n        switch costume to (blank v)\n        change size by (((1200) - (size)) / (10))\n        switch costume to (tile 1 v)\n    end\n    wait (2) seconds\n    delete this clone\nend\n\nwhen I start as a clone\nif <(Clone) = [Circle]> then\n    switch costume to (circle v)\n    set size to (0) %\n    go to [front v] layer\n    point in direction (90)\n    go to x: (0) y: (0)\n    show\n    repeat (20)\n        switch costume to (blank v)\n        change size by (((1500) - (size)) / (7))\n        switch costume to (circle v)\n    end\n    wait (5) seconds\n    delete this clone\nend\n\nwhen I start as a clone\nif <(Clone) = [Slide]> then\n    switch costume to (slide v)\n    set size to (100) %\n    clear graphic effects\n    go to [front v] layer\n    point in direction (90)\n    go to x: (0) y: (-1000)\n    show\n    repeat (50)\n        switch costume to (blank v)\n        change size by (((100) - (size)) / (1))\n        change y by (((300) - (y position)) / (20))\n        switch costume to (slide v)\n    end\n    wait (1) seconds\n    delete this clone\nend\n\nwhen I start as a clone\nif <(Clone) = [Name]> then\n    switch costume to (c v)\n    set size to (100) %\n    clear graphic effects\n    go to [front v] layer\n    point in direction (90)\n    go to x: (0) y: (-300)\n    set [ghost v] effect to (100)\n    show\n    repeat (50)\n        change [ghost v] effect by (-25)\n        change y by (((0) - (y position)) / (7))\n    end\n    wait until <(timer) > [6]>\n    repeat (15)\n        change [ghost v] effect by (10)\n        change size by (((0) - (size)) / (3))\n    end\n    delete this clone\nend\n\nwhen I start as a clone\nif <(Clone) = [Cover]> then\n    switch costume to (cover v)\n    set size to (100) %\n    clear graphic effects\n    go to [front v] layer\n    point in direction (90)\n    go to x: (0) y: (0)\n    show\n    wait (1) seconds\n    delete this clone\nend\n\nwhen I start as a clone\nif <(Clone) = [Decoration 1]> then\n    switch costume to (decoration 1 v)\n    set size to (65) %\n    clear graphic effects\n    go to [front v] layer\n    point in direction (90)\n    go to x: (120) y: (-300)\n    show\n    repeat (50)\n        switch costume to (blank v)\n        change x by (((140) - (x position)) / (30))\n        change y by (((-115) - (y position)) / (30))\n        switch costume to (decoration 1 v)\n    end\n    wait until <(timer) > [6]>\n    repeat (25)\n        change x by (((0) - (x position)) / (3))\n        change y by (((0) - (y position)) / (3))\n        change size by (((0) - (size)) / (3))\n        change [ghost v] effect by (10)\n    end\n    delete this clone\nend\n\nwhen I start as a clone\nif <(Clone) = [Decoration 2]> then\n    switch costume to (decoration 2 v)\n    set size to (65) %\n    clear graphic effects\n    go to [front v] layer\n    point in direction (90)\n    go to x: (-300) y: (30)\n    show\n    repeat (50)\n        switch costume to (blank v)\n        change x by (((-175) - (x position)) / (30))\n        change y by (((75) - (y position)) / (30))\n        switch costume to (decoration 2 v)\n    end\n    wait until <(timer) > [6]>\n    repeat (25)\n        change x by (((0) - (x position)) / (3))\n        change y by (((0) - (y position)) / (3))\n        change size by (((0) - (size)) / (3))\n        change [ghost v] effect by (10)\n    end\n    delete this clone\nend\n\nwhen I start as a clone\nif <(Clone) = [Line 1]> then\n    switch costume to (line 1 v)\n    set size to (65) %\n    clear graphic effects\n    go to [front v] layer\n    set [brightness v] effect to (90)\n    point in direction (90)\n    go to x: (-90) y: (-125)\n    show\n    repeat until <(costume [number v]) = [21]>\n        next costume\n        wait (0.005) seconds\n    end\n    delete this clone\nend\n\nwhen I start as a clone\nif <(Clone) = [Line 2]> then\n    switch costume to (line 2 1 v)\n    set size to (65) %\n    clear graphic effects\n    go to [front v] layer\n    point in direction (-90)\n    go to x: (90) y: (125)\n    show\n    repeat until <(costume [number v]) = [40]>\n        next costume\n        wait (0.005) seconds\n    end\n    delete this clone\nend\n\nwhen I start as a clone\nif <(Clone) = [Line 3]> then\n    switch costume to (line 3 1 v)\n    set size to (65) %\n    clear graphic effects\n    go to [front v] layer\n    point in direction (90)\n    go to x: (-50) y: (-125)\n    show\n    repeat until <(costume [number v]) = [52]>\n        next costume\n        wait (0.005) seconds\n    end\n    delete this clone\nend\n\nwhen I start as a clone\nif <(Clone) = [Line 4]> then\n    switch costume to (line 4 1 v)\n    set size to (65) %\n    clear graphic effects\n    go to [front v] layer\n    set [brightness v] effect to (90)\n    point in direction (90)\n    go to x: (90) y: (50)\n    show\n    repeat until <(costume [number v]) = [63]>\n        next costume\n        wait (0.005) seconds\n    end\n    delete this clone\nend\n\nwhen I start as a clone\nif <(Clone) = [Circle 2]> then\n    switch costume to (circle v)\n    set size to (0) %\n    go to [front v] layer\n    point in direction (90)\n    go to x: (0) y: (0)\n    show\n    repeat (20)\n        switch costume to (blank v)\n        change size by (((1500) - (size)) / (7))\n        switch costume to (circle v)\n    end\n    wait until <(timer) > [6]>\n    repeat (15)\n        switch costume to (blank v)\n        change size by (((25) - (size)) / (5))\n        switch costume to (circle v)\n    end\n    set [i v] to [-1]\n    repeat (20)\n        change size by ((i) / (3))\n        change [i v] by (join [-] (([abs v] of (i) ) / (4)))\n        turn right ((i) / (-3)) degrees\n        change y by ((i) / (3))\n    end\n    delete this clone\nend\n\nwhen I receive [intro2 v]\nreset timer\nset size to (100) %\nclear graphic effects\nset volume to (100) %\nstart sound [Music v]\ngo to x: (0) y: (0)\npoint in direction (90)\nset [clone v] to [Circle]\ncreate clone of (_myself_ v)\nwait (0.2) seconds\nset [brightness v] effect to (-10)\nset [clone v] to [Circle]\ncreate clone of (_myself_ v)\nwait (0.2) seconds\nset [brightness v] effect to (20)\nClone Tiles\nrepeat (2)\n    wait (0.1) seconds\n    change [brightness v] effect by (-20)\n    Clone Tiles\nend\nwait (0) seconds\nset [brightness v] effect to (20)\nClone Tiles 2\nrepeat (2)\n    wait (0.1) seconds\n    change [brightness v] effect by (-20)\n    Clone Tiles 2\nend\nwait (0) seconds\nset [brightness v] effect to (0)\nset [clone v] to [Main Tile]\ncreate clone of (_myself_ v)\nwait (0.1) seconds\nset [brightness v] effect to (-10)\ncreate clone of (_myself_ v)\nwait (0.1) seconds\nset [brightness v] effect to (-20)\ncreate clone of (_myself_ v)\nwait (0.2) seconds\nclear graphic effects\nset [clone v] to [Slide]\ncreate clone of (_myself_ v)\nwait (1.5) seconds\nset [brightness v] effect to (100)\nset [clone v] to [Circle 2]\ncreate clone of (_myself_ v)\nwait (0.1) seconds\nset [clone v] to [Name]\ncreate clone of (_myself_ v)\nwait (0) seconds\nset [clone v] to [Cover]\ncreate clone of (_myself_ v)\nwait (0) seconds\nset [clone v] to [Decoration 1]\ncreate clone of (_myself_ v)\nwait (0) seconds\nset [clone v] to [Decoration 2]\ncreate clone of (_myself_ v)\nwait (0) seconds\nset [clone v] to [Line 1]\ncreate clone of (_myself_ v)\nwait (0.1) seconds\nset [clone v] to [Line 2]\ncreate clone of (_myself_ v)\nwait (0.5) seconds\nset [clone v] to [Line 3]\ncreate clone of (_myself_ v)\nwait (0.5) seconds\nset [clone v] to [Line 4]\ncreate clone of (_myself_ v)\nwait (0.5) seconds\nset [clone v] to [Line 3]\ncreate clone of (_myself_ v)\nwait (0.5) seconds\nset [clone v] to [Line 4]\ncreate clone of (_myself_ v)\nwait until <(timer) > [6]>\nwait (1) seconds\nbroadcast (start v)\n\n@Player\n\ndefine physics\nset [🔒 xv v] to ((🔒 xv) * (0.9))\nchange [🔒 x v] by (🔒 xv)\nposition\nset [🔒 slope v] to [1]\nrepeat until <<(🔒 slope) > [5]> or <not <<touching (levels hitbox v)?> or <touching (levels dynamic v)?>>>>\n    change [🔒 slope v] by (1)\n    change [🔒 y v] by (1)\n    position\nend\nif <(🔒 slope) > [5]> then\n    change [🔒 y v] by (-5)\n    repeat until <not <<touching (levels hitbox v)?> or <touching (levels dynamic v)?>>>\n        change [🔒 x v] by ((([abs v] of (🔒 xv) ) / (🔒 xv)) * (-2.5))\n        position\n    end\n    set [🔒 xv v] to [0]\nend\nif <not <<touching (levels hitbox v)?> or <touching (levels dynamic v)?>>> then\n    change [🔒 yv v] by (-1)\nend\nchange [🔒 y v] by (🔒 yv)\nposition\nif <<touching (levels hitbox v)?> or <touching (levels dynamic v)?>> then\n    repeat until <not <<touching (levels hitbox v)?> or <touching (levels dynamic v)?>>>\n        change [🔒 y v] by ((([abs v] of (🔒 yv) ) / (🔒 yv)) * (-1))\n        position\n    end\n    set [🔒 yv v] to [0]\nend\n\nwhen flag clicked\nhide\n\ndefine position\nset size to ((size) * (4)) %\ngo to x: (round ((🔒 x) - (🎥 cam x))) y: (round ((🔒 y) - (🎥 cam y)))\nset size to ((size) / (4)) %\nif <<(round (x position)) = (round ((🔒 x) - (🎥 cam x)))> and <(round (y position)) = (round ((🔒 y) - (🎥 cam y)))>> then\n    show\nelse\n    hide\nend\n\nwhen I receive [start v]\nset [🎥 cam x v] to [0]\nset [🎥 cam y v] to [0]\nset size to (60) %\nset rotation style [left-right v]\nshow\nforever\n    set [🔒 x v] to (checkpoint x)\n    set [🔒 y v] to (checkpoint y)\n    set [🔒 xv v] to [0]\n    set [🔒 yv v] to [0]\n    set [🔒 slope v] to [0]\n    position\n    clear graphic effects\n    repeat until <<(🔒 y) < [-300]> or <<(🔒 x) < [-280]> or <touching (levels danger v)?>>>\n        set [🔒 costume v] to (costume [name v])\n        switch costume to (hitbox v)\n        if <<(round (x position)) = (round ((🔒 x) - (🎥 cam x)))> and <(round (y position)) = (round ((🔒 y) - (🎥 cam y)))>> then\n            physics\n        end\n        change [🔒 xv v] by (<<<key (d v) pressed?> or <key (right arrow v) pressed?>> or <<mouse down?> and <(mouse x) > [0]>>> - <<<key (a v) pressed?> or <key (left arrow v) pressed?>> or <<mouse down?> and <(mouse x) < [0]>>>)\n        change [🔒 y v] by (-1)\n        position\n        if <<<touching (levels hitbox v)?> or <touching (levels dynamic v)?>> and <<<key (w v) pressed?> or <key (up arrow v) pressed?>> or <<mouse down?> and <(mouse y) > [0]>>>> then\n            set [🔒 yv v] to [18]\n        end\n        change [🔒 y v] by (1)\n        if <touching (bounce pads v)?> then\n            set [🔒 yv v] to [25]\n        end\n        if <(🔒 x) > [4530]> then\n            set [🔒 x v] to [4530]\n        end\n        if <(🔒 x) < [-220]> then\n            set [🔒 x v] to [-220]\n        end\n        change [🎥 cam x v] by (round (((🔒 x) - (🎥 cam x)) / (10)))\n        if <(🎥 cam x) < [0]> then\n            set [🎥 cam x v] to [0]\n        end\n        if <(🎥 cam x) > [4320]> then\n            set [🎥 cam x v] to [4320]\n        end\n        position\n        switch costume to (🔒 costume)\n        broadcast (🔒 player: animate v)\n        point in direction ((([abs v] of (🔒 xv) ) / (🔒 xv)) * (90))\n    end\n    repeat (10)\n        change [ghost v] effect by (10)\n        position\n    end\nend\n\nwhen I receive [🔒 player: animate v]\nif <<([floor v] of ([abs v] of (🔒 xv) ) ) > [0]> and <(round (🔒 yv)) = [0]>> then\n    next costume\n    if <(costume [name v]) = [hitbox]> then\n        next costume\n        next costume\n    end\n    wait (0.02) seconds\nelse\n    switch costume to (idle v)\nend\n\nset [🔒 x v] to [4230]\nset [🔒 y v] to [0]\n\n@Other Players\n\ndefine physics\nset [🔒 xv v] to ((🔒 xv) * (0.9))\nchange [🔒 x v] by (🔒 xv)\nposition\nset [🔒 slope v] to [1]\nrepeat until <<(🔒 slope) > [5]> or <not <<touching (levels hitbox v)?> or <touching (levels dynamic v)?>>>>\n    change [🔒 slope v] by (1)\n    change [🔒 y v] by (1)\n    position\nend\nif <(🔒 slope) > [5]> then\n    change [🔒 y v] by (-5)\n    repeat until <not <<touching (levels hitbox v)?> or <touching (levels dynamic v)?>>>\n        change [🔒 x v] by ((([abs v] of (🔒 xv) ) / (🔒 xv)) * (-2.5))\n        position\n    end\n    set [🔒 xv v] to [0]\nend\nif <not <<touching (levels hitbox v)?> or <touching (levels dynamic v)?>>> then\n    change [🔒 yv v] by (-1)\nend\nchange [🔒 y v] by (🔒 yv)\nposition\nif <<touching (levels hitbox v)?> or <touching (levels dynamic v)?>> then\n    repeat until <not <<touching (levels hitbox v)?> or <touching (levels dynamic v)?>>>\n        change [🔒 y v] by ((([abs v] of (🔒 yv) ) / (🔒 yv)) * (-1))\n        position\n    end\n    set [🔒 yv v] to [0]\nend\n\nwhen flag clicked\nhide\n\ndefine position\nset size to ((size) * (4)) %\ngo to x: (round ((🔒 x) - (🎥 cam x))) y: (round ((🔒 y) - (🎥 cam y)))\nset size to ((size) / (4)) %\nif <<(round (x position)) = (round ((🔒 x) - (🎥 cam x)))> and <(round (y position)) = (round ((🔒 y) - (🎥 cam y)))>> then\n    show\nelse\n    hide\nend\n\nwhen I receive [start v]\nforever\n    if <not <([🔒 x v] of [player v]) > [4340]>> then\n        wait (2) seconds\n        create clone of (_myself_ v)\n    end\nend\n\nwhen I start as a clone\nif <([🔒 x v] of [player v]) < [10]> then\n    set [🔒 x v] to [-300]\nelse\n    set [🔒 x v] to (([🔒 x v] of [player v]) - (300))\nend\nset [🔒 y v] to [0]\nset [🔒 xv v] to [0]\nset [🔒 yv v] to [0]\nset [🔒 slope v] to [0]\nset size to (60) %\nset rotation style [left-right v]\nset [brightness v] effect to (15)\nshow\nunstuck\nrepeat until <<([abs v] of (🔒 y) ) > [300]> or <<(🔒 x) > (([🔒 x v] of [player v]) + (450))> or <touching (levels danger v)?>>>\n    set [🔒 costume v] to (costume [name v])\n    switch costume to (hitbox v)\n    physics\n    change [🔒 xv v] by (1)\n    change [🔒 y v] by (-1)\n    position\n    if <<touching (levels hitbox v)?> or <touching (levels dynamic v)?>> then\n        change [🔒 y v] by (1)\n        position\n        change [🔒 x v] by (10)\n        position\n        if <<touching (levels hitbox v)?> or <<touching (levels dynamic v)?> or <<touching (levels danger v)?> or <touching (bounce pads v)?>>>> then\n            set [🔒 yv v] to [18]\n        end\n        change [🔒 x v] by (-10)\n        position\n    else\n        change [🔒 y v] by (1)\n        position\n    end\n    change [🔒 y v] by (-1)\n    position\n    if <<touching (levels hitbox v)?> or <touching (levels dynamic v)?>> then\n        change [🔒 y v] by (1)\n        change [🔒 x v] by (30)\n        change [🔒 y v] by (-30)\n        position\n        if <not <<touching (levels hitbox v)?> or <touching (levels dynamic v)?>>> then\n            set [🔒 yv v] to [18]\n        end\n        change [🔒 x v] by (-30)\n        change [🔒 y v] by (30)\n        position\n    else\n        change [🔒 y v] by (1)\n        position\n    end\n    if <touching (bounce pads v)?> then\n        set [🔒 yv v] to [25]\n    end\n    switch costume to (🔒 costume)\n    point in direction ((([abs v] of (🔒 xv) ) / (🔒 xv)) * (90))\nend\nif <touching (levels danger v)?> then\n    repeat (10)\n        change [ghost v] effect by (10)\n        position\n    end\nend\ndelete this clone\n\nwhen I start as a clone\nforever\n    if <<([floor v] of ([abs v] of (🔒 xv) ) ) > [0]> and <(round (🔒 yv)) = [0]>> then\n        next costume\n        if <(costume [name v]) = [hitbox]> then\n            next costume\n            next costume\n        end\n        wait (0.02) seconds\n    else\n        switch costume to (idle v)\n    end\nend\n\ndefine unstuck\nposition\nrepeat until <not <<touching (levels hitbox v)?> or <touching (levels dynamic v)?>>>\n    change [🔒 y v] by (1)\n    position\nend\n\n@Background\n\nwhen flag clicked\nhide\n\ndefine position\nset [🔒 costume v] to (costume [name v])\nswitch costume to (dummy v)\nset size to ((size) * (4)) %\nswitch costume to (🔒 costume)\ngo to x: (round ((🔒 x) - ((🎥 cam x) / (10)))) y: (round ((🔒 y) - (🎥 cam y)))\nset size to ((size) / (4)) %\nif <<(round (x position)) = (round ((🔒 x) - ((🎥 cam x) / (10))))> and <(round (y position)) = (round ((🔒 y) - (🎥 cam y)))>> then\n    show\nelse\n    hide\nend\n\nwhen I start as a clone\nset size to (100) %\ngo to [back v] layer\nforever\n    position\nend\n\nwhen I receive [start v]\nswitch costume to (dummy v)\nset [🔒 x v] to [-480]\nset [🔒 y v] to [0]\nrepeat (8)\n    next costume\n    if <(costume [name v]) = [dummy]> then\n        next costume\n    end\n    change [🔒 x v] by (480)\n    create clone of (_myself_ v)\nend\n\n@Levels\n\ndefine position\nset [🔒 costume v] to (costume [name v])\nswitch costume to (dummy v)\nset size to ((size) * (4)) %\nswitch costume to (fill v)\ngo to x: (round ((🔒 x) - (🎥 cam x))) y: (round ((🔒 y) - (🎥 cam y)))\nswitch costume to (🔒 costume)\nset size to ((size) / (4)) %\nif <<(round (x position)) = (round ((🔒 x) - (🎥 cam x)))> and <(round (y position)) = (round ((🔒 y) - (🎥 cam y)))>> then\n    show\nelse\n    hide\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [start v]\nswitch costume to (fill v)\nset [🔒 x v] to [-480]\nset [🔒 y v] to [0]\nrepeat (11)\n    next costume\n    change [🔒 x v] by (480)\n    create clone of (_myself_ v)\nend\n\nwhen I start as a clone\nset size to (100) %\nforever\n    position\nend\n\n@Levels Hitbox\n\ndefine position\nset [🔒 costume v] to (costume [name v])\nswitch costume to (dummy v)\nset size to ((size) * (4)) %\nswitch costume to (fill v)\ngo to x: (round ((🔒 x) - (🎥 cam x))) y: (round ((🔒 y) - (🎥 cam y)))\nswitch costume to (🔒 costume)\nset size to ((size) / (4)) %\nif <<(round (x position)) = (round ((🔒 x) - (🎥 cam x)))> and <(round (y position)) = (round ((🔒 y) - (🎥 cam y)))>> then\n    show\nelse\n    hide\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [start v]\nswitch costume to (fill v)\nset [🔒 x v] to [-480]\nset [🔒 y v] to [0]\nrepeat (11)\n    next costume\n    change [🔒 x v] by (480)\n    create clone of (_myself_ v)\nend\n\nwhen I start as a clone\nset size to (100) %\nset [ghost v] effect to (100)\nforever\n    position\nend\n\n@Levels Danger\n\ndefine position\nset [🔒 costume v] to (costume [name v])\nswitch costume to (dummy v)\nset size to ((size) * (4)) %\nswitch costume to (fill v)\ngo to x: (round ((🔒 x) - (🎥 cam x))) y: (round ((🔒 y) - (🎥 cam y)))\nswitch costume to (🔒 costume)\nset size to ((size) / (4)) %\nif <<(round (x position)) = (round ((🔒 x) - (🎥 cam x)))> and <(round (y position)) = (round ((🔒 y) - (🎥 cam y)))>> then\n    show\nelse\n    hide\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [start v]\nswitch costume to (fill v)\nset [🔒 x v] to [-480]\nset [🔒 y v] to [0]\nrepeat (11)\n    next costume\n    change [🔒 x v] by (480)\n    create clone of (_myself_ v)\nend\n\nwhen I start as a clone\nset size to (100) %\nset [ghost v] effect to (100)\nforever\n    position\nend\n\n@Levels Dynamic\n\ndefine position\nset [🔒 costume v] to (costume [name v])\nswitch costume to (dummy v)\nset size to ((size) * (4)) %\nswitch costume to (🔒 costume)\ngo to x: (round ((🔒 x) - (🎥 cam x))) y: (round ((🔒 y) - (🎥 cam y)))\nset size to ((size) / (4)) %\nif <<(round (x position)) = (round ((🔒 x) - (🎥 cam x)))> and <(round (y position)) = (round ((🔒 y) - (🎥 cam y)))>> then\n    show\nelse\n    hide\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [start v]\nswitch costume to (1 v)\nset [🔒 x v] to [900]\nset [🔒 y v] to [-30]\ncreate clone of (_myself_ v)\nswitch costume to (2 v)\nset [🔒 x v] to [3780]\nset [🔒 y v] to [20]\ncreate clone of (_myself_ v)\n\nwhen I start as a clone\nset size to (100) %\nforever\n    repeat (50)\n        change [🔒 x v] by (2)\n        position\n    end\n    repeat (20)\n        change [🔒 x v] by (1)\n        position\n    end\n    repeat (50)\n        change [🔒 x v] by (-2)\n        position\n    end\n    repeat (20)\n        change [🔒 x v] by (-1)\n        position\n    end\nend\n\n@Bounce Pads\n\ndefine position\nset [🔒 costume v] to (costume [name v])\nswitch costume to (dummy v)\nset size to ((size) * (4)) %\nswitch costume to (fill v)\ngo to x: (round ((🔒 x) - (🎥 cam x))) y: (round ((🔒 y) - (🎥 cam y)))\nswitch costume to (🔒 costume)\nset size to ((size) / (4)) %\nif <<(round (x position)) = (round ((🔒 x) - (🎥 cam x)))> and <(round (y position)) = (round ((🔒 y) - (🎥 cam y)))>> then\n    show\nelse\n    hide\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [start v]\nswitch costume to (fill v)\nset [🔒 x v] to [-480]\nset [🔒 y v] to [0]\nrepeat (11)\n    next costume\n    change [🔒 x v] by (480)\n    create clone of (_myself_ v)\nend\n\nwhen I start as a clone\nset size to (100) %\nset [ghost v] effect to (100)\nforever\n    position\nend\n\n@Checkpoints\n\ndefine position\nset [🔒 costume v] to (costume [name v])\nswitch costume to (dummy v)\nset size to ((size) * (4)) %\nswitch costume to (🔒 costume)\ngo to x: (round ((🔒 x) - (🎥 cam x))) y: (round ((🔒 y) - (🎥 cam y)))\nset size to ((size) / (4)) %\nif <<(round (x position)) = (round ((🔒 x) - (🎥 cam x)))> and <(round (y position)) = (round ((🔒 y) - (🎥 cam y)))>> then\n    show\nelse\n    hide\nend\n\nwhen flag clicked\nset [checkpoint x v] to [-150]\nset [checkpoint y v] to [-100]\nhide\n\nwhen I receive [start v]\nswitch costume to (checkpoint v)\nset [🔒 x v] to [1215]\nset [🔒 y v] to [-115]\ncreate clone of (_myself_ v)\nset [🔒 x v] to [3150]\nset [🔒 y v] to [-110]\ncreate clone of (_myself_ v)\nswitch costume to (end v)\nset [🔒 x v] to [4470]\nset [🔒 y v] to [-40]\ncreate clone of (_myself_ v)\n\nwhen I start as a clone\nset size to (100) %\nrepeat until <touching (player v)?>\n    position\nend\nturn right (45) degrees\nswitch costume to (join (costume [name v]) [ complete])\nset [checkpoint x v] to (🔒 x)\nset [checkpoint y v] to (🔒 y)\nset [🔒 effect v] to [100]\nif <(costume [name v]) = [end complete]> then\n    broadcast (end v)\nend\nforever\n    turn right (((90) - (direction)) / (3)) degrees\n    set [🔒 effect v] to ((🔒 effect) * (0.8))\n    set [brightness v] effect to (🔒 effect)\n    position\nend\n\n@End Message\n\nwhen flag clicked\nhide\n\nwhen I receive [end v]\ngo to x: (0) y: (0)\nset size to (100) %\nset [ghost v] effect to (100)\nshow\nrepeat (10)\n    change [ghost v] effect by (-10)\nend\nwait (2) seconds\nrepeat (20)\n    change [ghost v] effect by (5)\nend\nhide\n\n@Thumb\n\nwhen flag clicked\nhide\nforever\nend\n\nreset timer\n\nwhen [timer v] > (0)\n\ngo to x: (0) y: (0)\nset size to (100) %\ngo to [front v] layer\nshow\n\n
This is a collab with @Colorful_me_ so make sure to check her out!\n\n@Colorful_me_'s version: https://scratch.mit.edu/projects/474831699/\n\n◈ // Info\nA generic platformer\nEverything is possible(I've tested it myself multiple times)\n\n₸ // Instructions\n▶ Finish the course\n\nKeyboard:\nWASD / arrow keys to move\n\nMobile:\ntap left / right / top of screen to move(you'll figure it out)\n\n⇑ // Credits\nLevels by @Colorful_me_\nArt and code by me\n\n#games #scrolling #platformer #platformers #easy #hard #art