Illusions || Till the door ||A platformer || #trending #games #art #music 

Instructions: This is meant to be a series of platformers probably of 4 or 5 parts\n––\nAᴄᴄᴏᴜɴᴛꜱ:\nMain: @jindalsargun\nAlt: @sargunjindal\n––\nTʜɪɴɢꜱ ʏᴏᴜ ᴍɪɢʜᴛ ɴᴏᴛ ᴋɴᴏᴡ ᴀʙᴏᴜᴛ ᴛʜɪꜱ ᴘʟᴀᴛғᴏʀᴍᴇʀ:\nPortals: Go to the light shade portal to transport to the darker shaded portal.\nKey/Lock: Go to the key to unlock the lock.\nPurple stuff: changes your size to half.\nSword: Press space to swing sword and kill enemies. Unfortunately, you can only swing it one way.\nSettings: Press the setting button to restart or skip the level or mute/unmute the game.\nEaster eggs: Yes, there are 4 easter eggs hidden! Pls don't reveal their position in the comments. Each has a letter, type the letters sequentially in the comments!\n––\nPLEASE DON'T ADVERTISE HERE\n––\n❤️ and ⭐ if you want to :D\n––\nYou might like this one :)\nhttps://scratch.mit.edu/projects/643610530/\n––\n#prodannau loved and commented!\n#HenryWolfe loved and commented!\n#Hern1 commented!\n#----Dream---- loved and commented!\n#JackPigPro loved!\n#TrentonTNT loved and commented! \n––\nTʜᴀɴᴋꜱ ᴛᴏ:\n@ᴘɪᴢᴢᴀʀᴜꜱʜ for the intro\n@ᴢɪʏᴜ3 for snow and clouds\n@ᴇʟᴇᴄ_ɢᴀᴍᴇ for some saw code (edited by me)\n@CʜᴏᴄᴏʟᴀᴛᴇMɪʟᴋSᴛᴜᴅɪᴏꜱ for some story code (edited by me)\n@CʜᴇᴡɪɴɢFʀᴜɪᴛGᴜᴍ for some enemy code (heavily edited by me)\n––\nTᴀɢꜱ:\n#all #game #games #art #music #stories\n#jindalsargun #sargunjindal #platformer #platformers #pizzarush #ziyu3 #elec_games #level #levels #player #spikes #size #epck #changer #push #ups #green #purple #red #black #spike #spikes #lava #water #tampoline #trampolines #bounce #pads #saw #saws #moving #enemy #key #lock #trend #trending #portals #portal #teleportal #fun #cool #teleporters #ground #easter #egg #eggs #mobile #friendly #mobilefriendly #arrowkeys #ungeneric #WASD #explore #thumbnail #backdrop #sprite #illusion #illusions #till #the #door #series\n#be #happy #and #do #not #look #at #tags\n––

@Stage\n\nwhen flag clicked\nswitch backdrop to (1 v)\n\nwhen I receive [start v]\nswitch backdrop to (3 v)\n\nwhen I receive [story v]\nswitch backdrop to (2 v)\n\n@Sprite1\n\n@Sprite2\n\n@Sprite3\n\n@Sprite4\n\n@Sprite5\n\n@Intro \n\ndefine 🎥 Disable from Cam Control? <disable?>\nif <disable?> then\n    set [enabled? v] to [0]\nelse\n    set [enabled? v] to [1]\nend\n\ndefine Play Intro\nSet size to [100] %\npoint in direction (90)\ngo to x: (0) y: (0)\nset rotation style [all around v]\nhide\ndelete all of [\[intro\] cam x/y/z/r v]\nrepeat (4)\n    add [0] to [\[intro\] cam x/y/z/r v]\nend\nset [costume v] to [blank]\nset [\[intro\] keyframe v] to [1]\n🎥 Move cam to [0] [0] [0] [0]\n🎥 Transition x/y/z/s/r [0] [0] [1] [100] [90] speed: [1]\n🎥 Disable from Cam Control? \n🖼 Set effects c/b/g [0] [0] [0]\nClone same sprite [controller] spec: [0] [0] [0]\nClone sprites [1] [1]\nClone same sprite [100] [1]\nClone same sprite [SF] spec: [0] [0] [100]\nswitch costume to (text v)\nbroadcast (\[Intro\] listen for keyframes v)\nreset timer\nclear sound effects\nplay sound [Kudasai - Technicolor v] until done\nbroadcast (\[Intro\] delete clones v)\nwait (1) seconds\nbroadcast (story v)\nstop [other scripts in sprite v]\n\ndefine Set pos zrot: (x) (y) rot: (r) trans: (tx) (ty) scalar: (c)\nset [x v] to ((tx) + ((c) * ((([cos v] of (r) ) * (x)) - (([sin v] of (r) ) * (y)))))\nset [y v] to ((ty) + ((c) * ((([sin v] of (r) ) * (x)) + (([cos v] of (r) ) * (y)))))\n\ndefine 🎥 Cam set x/y/z/r (item) to: (val)\nreplace item (item) of [\[intro\] cam x/y/z/r v] with (val)\n\ndefine ⏱ Keyframe (keyframe)\nif <(\[Intro\] Keyframe) > (keyframe)> then\n\ndefine 🎥 Transition x/y/z/s/r (x) (y) (z) (s) (r) speed: (t)\nchange [x v] by (((round (x)) - (round (x))) / (t))\nchange [y v] by (((round (y)) - (round (y))) / (t))\nchange [z v] by (((round (z)) - (round (z))) / (t))\nchange [size v] by (((round (s)) - (round (size))) / (t))\nTransition direction (r) speed: (t)\n\nwhen I start as a clone\nif <(clone_id) = [controller]> then\n    🖼 Set effects c/b/g [0] [0] [100]\n    set [_v1 v] to [0]\n    set [_v2 v] to [0]\n    set [_v3 v] to [0]\n    set [_v4 v] to [8]\n    set [_v5 v] to [0]\n    \n        🎥 Cam set x/y/z/r [1] to: ((_v1) * ([sin v] of (_v2) ))\n        🎥 Cam set x/y/z/r [2] to: ((_v1) * ([cos v] of (_v3) ))\n        set [_v1 v] to ((_v1) * (.85))\n        change [_v2 v] by (40)\n        change [_v3 v] by (30)\n    end\nend\n\ndefine Clone sprites (id) (count)\nset [clone_id v] to (id)\nrepeat (count)\n    create clone of (_myself_ v)\n    change [clone_id v] by (1)\nend\nset [clone_id v] to [0]\n\ndefine Clone same sprite (id) (count)\nset [clone_val v] to [1]\nset [clone_id v] to (id)\nrepeat (count)\n    create clone of (_myself_ v)\n    change [clone_val v] by (1)\nend\nset [clone_id v] to [0]\n\nwhen I receive [\[intro\] keyframe signal v]\nif <(clone_id) = [controller]> then\n    set [_v1 v] to [0]\nend\n\nwhen I receive [\[intro\] listen for keyframes v]\nif <(clone_id) = [0]> then\n    repeat until <(\[Intro\] Keyframe) > (length of [keyframes v])>\n        wait until <(timer) > ((-.25) + (item (\[Intro\] Keyframe) of [keyframes v]))>\n        broadcast (\[Intro\] keyframe signal v)\n        change [\[intro\] keyframe v] by (1)\n    end\nend\n\ndefine 💥 Gradient shockwave\nClone same sprite [GS] [1]\n\ndefine 💥 Shockwave (x) (y) (s) (speed)\nset [_v1 v] to (s)\nset [_v3 v] to (speed)\nClone same sprite [S] spec: (x) (y) [0]\n\nwhen I start as a clone\nif <(clone_id) = [SF]> then\n    set [_v1 v] to [0]\n    \n        🖼 Set effects c/b/g [0] [100] ((100) - (_v1))\n        set [_v1 v] to ((_v1) * (.85))\n    end\nend\n\nwhen I receive [\[intro\] keyframe signal v]\nif <(clone_id) = [SF]> then\n    switch costume to (screen v)\n    Transition positions [0] [0] [100] speed: [1]\n    Transition direction [90] speed: [1]\n    go to [front v] layer\n    set [_v1 v] to [30]\n    delete this clone\nend\n\ndefine 🎥 Move cam to (x) (y) (z) (r)\nreplace item (1) of [\[intro\] cam x/y/z/r v] with (x)\nreplace item (2) of [\[intro\] cam x/y/z/r v] with (y)\nreplace item (3) of [\[intro\] cam x/y/z/r v] with (z)\nreplace item (4) of [\[intro\] cam x/y/z/r v] with (r)\n\nwhen I start as a clone\nif <(clone_id) = [SW]> then\n    Transition direction (direction) speed: [1]\n    Set size to [5000] %\n    switch costume to (join [shockwave1/] ((360) / (_v2)))\n    Transition positions (x) (y) (size) speed: [1]\n    set [_v1 v] to [0]\n    repeat ((3.2) * (costume))\n        Transition positions (x) (y) (_v5) speed: (_v3)\n        Transition direction ((direction) + (_v4)) speed: (_v3)\n        set [fisheye v] effect to (([ceiling v] of (([tan v] of (_v1) ) * (68.6)) ) * (_v1))\n        change [_v1 v] by (((round (90)) - (round (_v1))) / ((5) * (costume)))\n    end\n    repeat ((.8) * (costume))\n        Transition positions (x) (y) (_v5) speed: (_v3)\n        Transition direction ((direction) + (_v4)) speed: (_v3)\n        change [ghost v] effect by ((5) * (costume))\n    end\n    delete this clone\nend\n\nwhen I start as a clone\nif <(clone_id) = [CE]> then\n    switch costume to (join [circle] [explosion])\n    set [_v2 v] to [0]\n    repeat ((3.6) * (costume))\n        Transition positions ((x) + ((_v2) * ([sin v] of (direction) ))) ((y) + ((_v2) * ([cos v] of (direction) ))) (size) speed: [1]\n        Transition direction ((_v4) + (direction)) speed: (_v3)\n        change [_v2 v] by (((_v5) - (_v2)) / (_v3))\n        change [size v] by (((0) - (size)) / ((1.7) * (_v3)))\n    end\n    repeat ((.8) * (costume))\n        Transition positions ((x) + ((_v2) * ([sin v] of (direction) ))) ((y) + ((_v2) * ([cos v] of (direction) ))) (size) speed: [1]\n        Transition direction ((_v4) + (direction)) speed: (_v3)\n        change [_v2 v] by (((_v5) - (_v2)) / (_v3))\n        change [size v] by (((0) - (size)) / (_v3))\n        change [ghost v] effect by ((125) / (_v3))\n    end\n    delete this clone\nend\n\ndefine Change size by: (s) costume ph: (ph)\nSet size to ((size) + (s)) %\nswitch costume to (ph)\n\nwhen I start as a clone\nhide\ngo to [front v] layer\nif <(clone_id) = ((clone_id) * (1))> then\n    forever\n        if <(enabled?) = [1]> then\n            Set size to [99999999999] %\n            set x to (((x) - (item (1) of [\[intro\] cam x/y/z/r v])) * (((item (3) of [\[intro\] cam x/y/z/r v]) / (z)) + (1)))\n            set y to (((y) - (item (2) of [\[intro\] cam x/y/z/r v])) * (((item (3) of [\[intro\] cam x/y/z/r v]) / (z)) + (1)))\n            Set size to ((size) * (((item (3) of [\[intro\] cam x/y/z/r v]) / (z)) + (1))) %\n            switch costume to (costume)\n        else\n            Set size to [99999999999] %\n            set x to (x)\n            set y to (y)\n            Set size to (size) %\n            switch costume to (costume)\n        end\n        🖼 Set effects c/b/g (color) (brightness) (ghost)\n    end\nelse\n    Transition positions (x) (y) (size) speed: [1]\n    Transition direction (direction) speed: [1]\n    🖼 Set effects c/b/g (color) (brightness) (ghost)\n    🎥 Disable from Cam Control? \n    go [backward v] (3) layers\n    show\nend\n\ndefine Transition direction (r) speed: (t)\nturn right (((round (r)) - (round (direction))) / (t)) degrees\n\ndefine Set size to (size) %\nif <[100] > (size)> then\n    switch costume to (screen v)\nelse\n    switch costume to (blank v)\nend\nset size to (size) %\nswitch costume to (screen v)\n\ndefine Clone same sprite (id) spec: (x) (y) (s)\nset [clone_id v] to (id)\nset [x v] to (x)\nset [y v] to (y)\nset [size v] to (s)\ncreate clone of (_myself_ v)\nset [clone_id v] to [0]\n\ndefine 💥 Line explosion (x) (y) (s) (r) (zrot) (spread) (speed) (framespeed) (rot) (count)\nset [_v5 v] to (r)\nset [direction v] to (zrot)\nset [_v4 v] to (rot)\nset [_v3 v] to (speed)\nset [costume v] to (framespeed)\nrepeat (count)\n    Clone same sprite [LE] spec: (x) (y) (s)\n    change [direction v] by ((spread) / (count))\nend\n\nwhen I start as a clone\nif <(clone_id) = [LE]> then\n    set [_v1 v] to [1]\n    set [_v2 v] to [0]\n    repeat ((3.6) * (costume))\n        switch costume to (join [lineexplosion] (round (_v1)))\n        Transition positions ((x) + ((_v2) * ([sin v] of (direction) ))) ((y) + ((_v2) * ([cos v] of (direction) ))) (size) speed: [1]\n        Transition direction ((_v4) + (direction)) speed: (_v3)\n        change [_v2 v] by (((_v5) - (_v2)) / (_v3))\n        change [_v1 v] by (((round (11)) - (round (_v1))) / (costume))\n    end\n    repeat ((.8) * (costume))\n        switch costume to (join [lineexplosion] (round (_v1)))\n        Transition positions ((x) + ((_v2) * ([sin v] of (direction) ))) ((y) + ((_v2) * ([cos v] of (direction) ))) (size) speed: [1]\n        Transition direction ((_v4) + (direction)) speed: (_v3)\n        change [_v2 v] by (((_v5) - (_v2)) / (_v3))\n        change [_v1 v] by (((round (11)) - (round (_v1))) / (costume))\n        change [ghost v] effect by ((125) / (_v3))\n    end\n    delete this clone\nend\n\nwhen I start as a clone\nif <(clone_id) = [SE]> then\n    set [_v1 v] to [1]\n    set [_v2 v] to [0]\n    repeat until <(round (_v1)) = [22]>\n        switch costume to (join [splineexplosion] (round (_v1)))\n        Transition positions ((x) + ((_v2) * ([sin v] of (direction) ))) ((y) + ((_v2) * ([cos v] of (direction) ))) (size) speed: [1]\n        Transition direction ((_v4) + (direction)) speed: (_v3)\n        change [_v1 v] by ((5) / (costume))\n        change [_v2 v] by (((_v5) - (_v2)) / (_v3))\n    end\n    delete this clone\nend\n\ndefine 💥 Spline explosion (x) (y) (s) (r) (zrot) (spread) (speed) (framespeed) (rot) (count)\nset [_v5 v] to (r)\nset [direction v] to (zrot)\nset [_v4 v] to (rot)\nset [_v3 v] to (speed)\nset [costume v] to (framespeed)\nrepeat (count)\n    Clone same sprite [SE] spec: (x) (y) ((s) / (5))\n    change [direction v] by ((spread) / (count))\nend\n\ndefine 🖼 Set effects c/b/g (c) (b) (g)\nset [color v] to (c)\nset [brightness v] to (b)\nset [ghost v] to (g)\nset [color v] effect to (color)\nset [brightness v] effect to (brightness)\nset [ghost v] effect to (ghost)\n\ndefine 💥 Circle explosion (x) (y) (s) (r) (zrot) (spread) (speed) (framespeed) (rot) (count)\nset [_v5 v] to (r)\nset [direction v] to (zrot)\nset [_v4 v] to (rot)\nset [_v3 v] to (speed)\nset [costume v] to (framespeed)\nrepeat (count)\n    Clone same sprite [CE] spec: (x) (y) (s)\n    change [direction v] by ((spread) / (count))\nend\n\ndefine Transition positions (x) (y) (z) speed: (t)\nchange x by (((round (x)) - (round (x position))) / (t))\nchange y by (((round (y)) - (round (y position))) / (t))\nChange size by: (((round (z)) - (round (size))) / (t)) costume ph: (costume [name v])\n\ndefine 💥 Shockwave (x) (y) (s) (r) (zrot) (spread) (speed) (framespeed) (rot) (count)\nset [_v5 v] to (r)\nset [direction v] to (zrot)\nset [_v4 v] to (rot)\nset [_v3 v] to (speed)\nset [_v2 v] to (spread)\nset [costume v] to (framespeed)\nrepeat (count)\n    Clone same sprite [SW] spec: (x) (y) (s)\n    change [direction v] by ((360) / (count))\nend\n\nwhen I start as a clone\nif <(clone_id) = [GS]> then\n    🖼 Set effects c/b/g (color) [50] [0]\n    Transition positions [0] [0] [0] speed: [1]\n    switch costume to (gradientshock v)\n    repeat (25)\n        change [ghost v] effect by (4)\n        Transition positions [0] [0] [575] speed: [7]\n    end\n    delete this clone\nend\n\nwhen I start as a clone\nif <(clone_id) = [S]> then\n    switch costume to (shock v)\n    repeat until <(ghost) > [99]>\n        set [ghost v] effect to (ghost)\n        change [ghost v] by (((100) - (round (ghost))) / (_v3))\n        Transition positions (x) (y) (_v1) speed: (_v3)\n    end\n    delete this clone\nend\n\ndefine 💥 Sparkle explosion (x) (y) (s) (r) (zrot) (spread) (speed) (framespeed) (rot) (count)\nrepeat (count)\n    set [_v3 v] to (pick random (5) to (speed))\n    set [_v4 v] to (pick random (20) to (40))\n    set [costume v] to (pick random (10) to (30))\n    Clone same sprite [SP] spec: (pick random ((0) - (x)) to (x)) (pick random ((0) - (y)) to (y)) (pick random ((s) / (2.5)) to ((s) * (1.1)))\nend\n\nwhen I start as a clone\nif <(clone_id) = [SP]> then\n    Transition positions [0] [0] (size) speed: [1]\n    Transition direction [90] speed: [1]\n    switch costume to (sparkle v)\n    set [_v1 v] to [10]\n    set [_v2 v] to [0]\n    set [_v5 v] to [0]\n    set [z v] to [.9]\n    repeat until <[1] > (_v1)>\n        set [fisheye v] effect to ((5) * (round (((-45) + ((-45) * ([abs v] of ([sin v] of (_v2) ) ))) / (5))))\n        change [_v1 v] by (((0) - (round (_v1))) / (costume))\n        change [_v2 v] by (_v4)\n        Transition positions (x) (y) (((size) / (100)) * (((50) * ([sin v] of (_v2) )) + ([abs v] of (([sin v] of (_v2) ) * ((_v1) * (costume))) ))) speed: (_v3)\n    end\n    delete this clone\nend\n\nwhen I receive [\[intro\] delete clones v]\ndelete this clone\n\ndefine Setup\nstop [other scripts in sprite v]\nrepeat (1)\n    delete this clone\nend\n🖼 Set effects c/b/g [0] [0] [100]\nshow\nreset timer\nSet size to ([tan v] of (90) ) %\ngo to x: (-050000000000) y: (0)\nSet size to [1000] %\nswitch costume to (round (65))\nrepeat until <(costume [number v]) = [1]>\n    next costume\nend\nhide\n\ndefine 💥 Scattered shockwave explosion\nrepeat (10)\n    💥 Shockwave [0] [0] [50] (pick random (190) to (280)) (pick random (-180) to (180)) [45] (pick random (5) to (7)) (pick random (7) to (10)) [0] [1]\nend\n\nwhen I receive [\[intro\] listen for keyframes v]\nif <(clone_id) = [0]> then\n    ⏱ Keyframe [1]\n    🖼 Set effects c/b/g [0] [-100] [0]\nend\n\nwhen I start as a clone\nif <(clone_id) = [100]> then\n    🎥 Transition x/y/z/s/r [0] [0] [1] [1000] [90] speed: [1]\n    🎥 Disable from Cam Control? <>\n    🖼 Set effects c/b/g ((1) / (0)) [0] [100]\n    set [costume v] to [text]\n    ⏱ Keyframe [1]\n    show\n    set [_v1 v] to [0]\n    set [_v2 v] to [0]\n    set [_v3 v] to [0]\n    set [_v4 v] to [0]\n    set [_v5 v] to [40]\n    repeat until <(\[Intro\] Keyframe) > [5]>\n        set [x v] to ((_v5) * ([sin v] of (_v2) ))\n        set [y v] to ((_v5) * ([cos v] of (_v2) ))\n        change [size v] by (((round (110)) - (round (size))) / (5))\n        change [_v5 v] by (((_v3) - (_v5)) / (4))\n        set [_v3 v] to ((_v3) * (.85))\n        set [_v1 v] to ((_v1) * (.9))\n        change [_v2 v] by (40)\n        change [ghost v] by (-4)\n    end\n    ⏱ Keyframe [5]\n    set [ghost v] to [0]\n    \n        change [y v] by (((y) - (2)) / (5))\n        change [ghost v] by (5)\n    end\nend\n\ndefine Clone radial (x) (y) (s) (r) (fisheye) (frame)\nset [x v] to (x)\nset [y v] to (y)\nset [size v] to (s)\nset [direction v] to (r)\nset [_v4 v] to (f)\nset [_v5 v] to (frame)\nClone same sprite [2] [1]\n\nwhen I start as a clone\nif <(clone_id) = [1]> then\n    🎥 Transition x/y/z/s/r [0] [0] [1] [100] [90] speed: [1]\n    🎥 Disable from Cam Control? \n    🖼 Set effects c/b/g [0] [0] [100]\n    set [costume v] to [bg]\n    wait (.5) seconds\n    show\n    repeat (20)\n        change [ghost v] by (-5)\n    end\n    🎥 Transition x/y/z/s/r [0] [0] [1] [100] [90] speed: [1]\n    ⏱ Keyframe [2]\n    wait (.1) seconds\n    repeat until <(\[Intro\] Keyframe) > [3]>\n        change [brightness v] by (((round (-100)) - (round (brightness))) / (10))\n    end\n    wait (.1) seconds\n    repeat until <(\[Intro\] Keyframe) > [4]>\n        change [brightness v] by (((round (0)) - (round (brightness))) / (10))\n    end\n    ⏱ Keyframe [5]\n    \n        change [y v] by (((y) - (2)) / (5))\n        change [ghost v] by (1)\n    end\nend\n\nwhen I receive [\[intro\] listen for keyframes v]\nif <(clone_id) = [controller]> then\n    ⏱ Keyframe [1]\n    set [_v4 v] to [0]\n    set [_v5 v] to [0]\n    repeat until <(\[Intro\] Keyframe) > [2]>\n        change [_v5 v] by ((1) / (-200))\n        🎥 Cam set x/y/z/r [3] to: ((_v4) + (_v5))\n    end\n    repeat (5)\n        change [_v4 v] by ((1) / (50))\n        🎥 Cam set x/y/z/r [3] to: ((_v4) + (_v5))\n    end\n    repeat until <(\[Intro\] Keyframe) > [3]>\n        change [_v4 v] by (((.6) - (_v4)) / (7))\n        change [_v5 v] by ((1) / (200))\n        🎥 Cam set x/y/z/r [3] to: ((_v4) + (_v5))\n    end\n    repeat (5)\n        change [_v4 v] by ((1) / (-25))\n        🎥 Cam set x/y/z/r [3] to: ((_v4) + (_v5))\n    end\n    repeat until <(\[Intro\] Keyframe) > [4]>\n        change [_v4 v] by (((-.2) - (_v4)) / (8))\n        change [_v5 v] by ((1) / (-200))\n        🎥 Cam set x/y/z/r [3] to: ((_v4) + (_v5))\n    end\n    repeat (5)\n        change [_v4 v] by ((1) / (30))\n        🎥 Cam set x/y/z/r [3] to: ((_v4) + (_v5))\n    end\n    repeat until <(\[Intro\] Keyframe) > [5]>\n        change [_v4 v] by (((.1) - (_v4)) / (9))\n        change [_v5 v] by ((1) / (200))\n        🎥 Cam set x/y/z/r [3] to: ((_v4) + (_v5))\n    end\nend\n\nwhen I receive [\[intro\] keyframe signal v]\nif <(clone_id) = [100]> then\n    set [_v3 v] to [10]\nend\n\nwhen I start as a clone\nif <(clone_id) = [100]> then\n    ⏱ Keyframe [2]\n    repeat until <(\[Intro\] Keyframe) > [3]>\n        change [brightness v] by (((round (100)) - (round (brightness))) / (10))\n    end\n    repeat until <(\[Intro\] Keyframe) > [4]>\n        change [brightness v] by (((round (-100)) - (round (brightness))) / (10))\n    end\nend\n\nwhen I start as a clone\nif <(clone_id) = [100]> then\n    repeat until <(\[Intro\] Keyframe) > [4]>\n        point in direction ((90) + ((_v5) * ([sin v] of (_v4) )))\n        change [_v4 v] by (10)\n    end\n    set [_v4 v] to [0]\n    repeat (24)\n        turn right (_v4) degrees\n        change [_v4 v] by (1)\n    end\n    \n        turn right (((round (90)) - (direction)) / (7)) degrees\n    end\nend\n\nwhen flag clicked\nSetup\nPlay Intro\n\n@Story\n\nwhen I receive [story v]\nshow\nplay sound [ac creed OST Epic Medley v] until done\nplay sound [ac EA remixed version v] until done\nplay sound [ac creed OST Epic Medley v] until done\n\nwhen I receive [story v]\npoint in direction (90)\ngo to [front v] layer\nshow\ngo to x: (0) y: (0)\nswitch costume to (costume13 v)\nclear graphic effects\nwait (5) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nswitch costume to (costume1 v)\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.03) seconds\nend\nwait (3) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nswitch costume to (costume2 v)\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.03) seconds\nend\nwait (2) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nswitch costume to (costume3 v)\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.03) seconds\nend\nwait (2) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nswitch costume to (costume14 v)\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.03) seconds\nend\nwait (2) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nswitch costume to (costume4 v)\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.03) seconds\nend\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nswitch costume to (costume5 v)\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.03) seconds\nend\nwait (5) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nswitch costume to (costume6 v)\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.03) seconds\nend\nwait (5) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nswitch costume to (costume7 v)\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.03) seconds\nend\nwait (3) seconds\nswitch costume to (costume8 v)\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.03) seconds\nend\nwait (3) seconds\nrepeat (10)\n    next costume\n    wait (0.05) seconds\nend\npoint in direction (90)\nswitch costume to (costume9 v)\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.03) seconds\nend\nwait (5) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nswitch costume to (costume17 v)\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.03) seconds\nend\nwait (5) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nswitch costume to (costume10 v)\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.09) seconds\nend\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nswitch costume to (costume11 v)\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.09) seconds\nend\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nswitch costume to (costume12 v)\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.09) seconds\nend\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nswitch costume to (costume15 v)\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.09) seconds\nend\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nswitch costume to (costume16 v)\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.09) seconds\nend\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nswitch costume to (costume18 v)\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.09) seconds\nend\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nswitch costume to (costume19 v)\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.09) seconds\nend\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nswitch costume to (costume20 v)\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.09) seconds\nend\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nswitch costume to (costume21 v)\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.09) seconds\nend\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nswitch costume to (costume22 v)\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.09) seconds\nend\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nswitch costume to (costume23 v)\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.09) seconds\nend\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nswitch costume to (costume24 v)\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.09) seconds\nend\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nswitch costume to (costume25 v)\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (-10)\n    wait (0.09) seconds\nend\nwait (4) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\n    wait (0.03) seconds\nend\nstop all sounds\nstop [other scripts in sprite v]\nhide\nbroadcast (Start v)\n\nwhen I receive [skip story v]\nstop all sounds\nstop [other scripts in sprite v]\nhide\nbroadcast (Start v)\n\nwhen flag clicked\nhide\n\n@Skip story\n\nwhen flag clicked\ngo to [front v] layer\ngo to x: (0) y: (0)\nhide\n\nwhen I receive [start v]\nhide\n\nwhen I receive [story v]\nshow\nforever\n    go [forward v] (1) layers\n    go to [front v] layer\nend\n\nwhen this sprite clicked\nbroadcast (Skip story v)\n\n@snow \n\ndefine Update\nchange [angle v] by (0.5)\nset [i v] to [0]\nrepeat until <(i) = (maxParticles)>\n    replace item (i) of [y v] with ((item (i) of [y v]) - ((([cos v] of ((Angle) + (item (i) of [d v])) ) + (1)) + ((item (i) of [r v]) / (2))))\n    replace item (i) of [x v] with ((item (i) of [x v]) + (([sin v] of (Angle) ) * (2)))\n    if <<(item (i) of [x v]) > [245]> or <<(item (i) of [x v]) < [-245]> or <(item (i) of [y v]) < [-180]>>> then\n        if <((i) mod (3)) > [0]> then\n            replace item (i) of [x v] with (((pick random (0) to (0.99)) * (W)) - (240))\n            replace item (i) of [y v] with [190]\n        else\n            if <([sin v] of (Angle) ) > [0]> then\n                replace item (i) of [x v] with [-245]\n                replace item (i) of [y v] with (((pick random (0) to (0.99)) * (H)) - (180))\n            else\n                replace item (i) of [x v] with [245]\n                replace item (i) of [y v] with (((pick random (0) to (0.99)) * (H)) - (180))\n            end\n        end\n    end\n    change [i v] by (1)\nend\n\ndefine Draw\nerase all\nset [i v] to [0]\nrepeat until <(i) = (maxParticles)>\n    go to x: (item (i) of [x v]) y: (item (i) of [y v])\n    set pen size to (item (i) of [r v])\n    pen down\n    pen up\n    change [i v] by (1)\nend\nUpdate\n\nwhen I receive [start v]\ngo to [front v] layer\ngo [backward v] (1) layers\nset pen color to (#ffffff)\nset [h v] to [360]\nset [w v] to [480]\nset [angle v] to [0]\nset [maxparticles v] to [75]\ndelete (all) of [x v]\ndelete (all) of [y v]\ndelete (all) of [r v]\ndelete (all) of [d v]\nset [i v] to [0]\nrepeat until <(i) = (maxParticles)>\n    add (((W) * (pick random (0) to (0.99))) - (240)) to [x v]\n    add (((H) * (pick random (0) to (0.99))) - (180)) to [y v]\n    add (((pick random (0) to (0.99)) * (4)) + (1)) to [r v]\n    add ((maxParticles) * (pick random (0) to (0.99))) to [d v]\n    change [i v] by (1)\nend\nforever\n    Draw\nend\n\nwhen flag clicked\nerase all\n\n@ clouds \n\nwhen I start as a clone\nset size to (pick random (50) to (80)) %\nshow\ngo to [back v] layer\nset [ghost v] effect to (20)\nswitch costume to (pick random (1) to (4))\nif <(side) = [1]> then\n    go to x: (300) y: (pick random (150) to (100))\n    repeat until <(x position) < [-250]>\n        change x by (-1)\n    end\n    delete this clone\nend\nif <(side) = [2]> then\n    go to x: (-300) y: (pick random (150) to (100))\n    repeat until <(x position) > [250]>\n        change x by (1)\n    end\n    delete this clone\nend\n\nwhen I start as a clone\nforever\n    go [backward v] (1) layers\n    go to [back v] layer\nend\n\nwhen I receive [start v]\nhide\nforever\n    set [side v] to (pick random (1) to (2))\n    create clone of (_myself_ v)\n    wait (pick random (1) to (2)) seconds\nend\n\n@Player\n\nwhen I start as a clone\nclear graphic effects\nrepeat (10)\n    change [ghost v] effect by (10)\nend\ndelete this clone\n\nwhen flag clicked\nset [level v] to [1]\ngo to [front v] layer\nhide\n\nwhen I receive [start v]\nset size to (100) %\nshow\nset [signal v] to [disactivated]\npoint in direction (90)\ngo to x: (-190) y: (20)\nset [xs v] to [0]\nset [ys v] to [0]\nforever\n    if <<key (right arrow v) pressed?> or <<key (d v) pressed?> or <<mouse down?> and <(mouse x) > (x position)>>>> then\n        change [xs v] by (1.5)\n        switch costume to (right v)\n    end\n    if <<key (left arrow v) pressed?> or <<key (a v) pressed?> or <<mouse down?> and <(mouse x) < (x position)>>>> then\n        change [xs v] by (-1.5)\n        switch costume to (left v)\n    end\n    if <<<key (right arrow v) pressed?> or <<key (d v) pressed?> or <<mouse down?> and <(mouse x) > (x position)>>>> and <<key (up arrow v) pressed?> or <<key (w v) pressed?> or <<mouse down?> and <(mouse y) > (y position)>>>>> then\n        switch costume to (upright v)\n    end\n    if <<<key (left arrow v) pressed?> or <<key (a v) pressed?> or <<mouse down?> and <(mouse x) < (x position)>>>> and <<key (up arrow v) pressed?> or <<key (w v) pressed?> or <<mouse down?> and <(mouse y) > (y position)>>>>> then\n        switch costume to (upleft v)\n    end\n    if <not <<key (right arrow v) pressed?> or <<key (left arrow v) pressed?> or <<key (up arrow v) pressed?> or <<key (w v) pressed?> or <<key (a v) pressed?> or <<key (d v) pressed?> or <<<mouse down?> and <(mouse x) > (x position)>> or <<mouse down?> and <(mouse x) < (x position)>>>>>>>>>> then\n        switch costume to (normal 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 (down v)\n    end\n    change x by (Xs)\n    if <touching (ground v)?> then\n        change x by ((Xs) * (-1))\n        if <<key (up arrow v) pressed?> or <<key (w v) pressed?> or <<mouse down?> and <(mouse y) > (y position)>>>> then\n            if <(Xs) > [0]> then\n                set [xs v] to [-15]\n                set [ys v] to [10]\n            else\n                set [xs v] to [15]\n                set [ys v] to [10]\n            end\n        else\n            set [xs v] to [0]\n        end\n    else\n        set [xs v] to ((Xs) * (0.8))\n    end\n    change y by (Ys)\n    if <touching (ground v)?> then\n        change y by ((Ys) * (-1))\n        set [ys v] to [0]\n        if <<key (up arrow v) pressed?> or <<key (w v) pressed?> or <<mouse down?> and <(mouse y) > (y position)>>>> then\n            switch costume to (player - up v)\n            if <(Jumping) = [yes]> then\n                set [ys v] to [12]\n                set [jumping v] to [no]\n            end\n        end\n    else\n        change [ys v] by (-1)\n        set [jumping v] to [yes]\n    end\n    if <(x position) > [239]> then\n        set size to (100) %\n        change [level v] by (1)\n        go to x: (-190) y: (20)\n        set [xs v] to [0]\n        set [ys v] to [0]\n    end\n    if <<<touching (spikes v)?> or <(y position) < [-178]>> or <<touching (bullet v)?> or <<touching (saws v)?> or <<touching (enemy v)?> or <<touching (lock v)?> or <<touching (saws2 v)?> or <touching (lava v)?>>>>>>> then\n        set size to (100) %\n        set [xs v] to [0]\n        set [ys v] to [0]\n        go to x: (-190) y: (50)\n    end\n    if <touching (trampoline v)?> then\n        set [ys v] to [20]\n    end\n    if <touching (oppoline v)?> then\n        set [ys v] to [-20]\n    end\n    if <touching (water v)?> then\n        set [ys v] to [-1]\n        if <<<key (up arrow v) pressed?> or <key (w v) pressed?>> or <<mouse down?> and <(mouse y) > (y position)>>> then\n            set [ys v] to [5]\n        end\n        if <<<key (down arrow v) pressed?> or <key (s v) pressed?>> or <<mouse down?> and <(y position) > (mouse y)>>> then\n            set [ys v] to [-5]\n        end\n    end\n    if <touching (speed ups v)?> then\n        set [xs v] to [20]\n    end\n    if <touching (back ups v)?> then\n        set [xs v] to [-20]\n    end\n    if <touching (small become v)?> then\n        set size to (50) %\n    end\n    if <touching (large become v)?> then\n        set size to (100) %\n    end\nend\n\nwhen I receive [skip v]\nset size to (100) %\ngo to x: (-190) y: (50)\n\nwhen I receive [restart v]\nset size to (100) %\nset [xs v] to [0]\nset [ys v] to [0]\ngo to x: (-190) y: (50)\n\nif <(y position) < [-170]> then\n    change [level v] by (1)\n    to change level by going down\nend\nif <[167] < (y position)> then\n    change [level v] by (1)\n    to change level by going up\nend\n\nwhen I receive [portal v]\ngo to (portal 2 v)\n\nwhen flag clicked\nforever\n    create clone of (_myself_ v)\nend\n\nwhen I receive [start v]\nforever\n    if <(Level) = [2]> then\n        broadcast (Illusions v)\n        wait until <not <(Level) = [2]>>\n    end\n    if <(Level) = [3]> then\n        broadcast (Illusions v)\n        wait until <not <(Level) = [3]>>\n    end\n    if <(Level) = [4]> then\n        broadcast (Illusions v)\n        wait until <not <(Level) = [4]>>\n    end\n    if <(Level) = [5]> then\n        broadcast (Illusions v)\n        wait until <not <(Level) = [5]>>\n    end\n    if <(Level) = [6]> then\n        broadcast (Illusions v)\n        wait until <not <(Level) = [6]>>\n    end\n    if <(Level) = [7]> then\n        broadcast (Illusions v)\n        wait until <not <(Level) = [7]>>\n    end\n    if <(Level) = [8]> then\n        broadcast (Illusions v)\n        wait until <not <(Level) = [8]>>\n    end\n    if <(Level) = [9]> then\n        broadcast (Illusions v)\n        wait until <not <(Level) = [9]>>\n    end\n    if <(Level) = [10]> then\n        broadcast (Illusions v)\n        wait until <not <(Level) = [10]>>\n    end\n    if <(Level) = [11]> then\n        broadcast (Illusions v)\n        wait until <not <(Level) = [11]>>\n    end\n    if <(Level) = [12]> then\n        broadcast (Illusions v)\n        wait until <not <(Level) = [12]>>\n    end\n    if <(Level) = [13]> then\n        broadcast (Illusions v)\n        wait until <not <(Level) = [13]>>\n    end\n    if <(Level) = [14]> then\n        broadcast (Illusions v)\n        wait until <not <(Level) = [14]>>\n    end\n    if <(Level) = [15]> then\n        broadcast (Illusions v)\n        wait until <not <(Level) = [15]>>\n    end\nend\n\n@Settings\n\nwhen flag clicked\nset [settings v] to [0]\ngo to x: (0) y: (0)\nhide\n\nwhen this sprite clicked\nnext costume\nif <(costume [number v]) = [1]> then\n    set [settings v] to [0]\nend\nif <(costume [number v]) = [2]> then\n    set [settings v] to [1]\nend\n\nwhen I receive [start v]\nwait (0.1) seconds\nshow\nswitch costume to (costume1 v)\ngo to [front v] layer\n\n@restart\n\nwhen flag clicked\ngo to x: (0) y: (0)\nhide\nforever\n    go to [front v] layer\n    go [forward v] (1) layers\nend\n\nwhen I receive [start v]\nforever\n    if <(Settings) = [0]> then\n        hide\n    end\n    if <(Settings) = [1]> then\n        go to [front v] layer\n        show\n    end\nend\n\nwhen this sprite clicked\nbroadcast (restart v)\n\nbroadcast (Illusions v)\n\n@skip\n\nwhen flag clicked\nswitch costume to (costume1 v)\ngo to x: (0) y: (0)\nhide\nforever\n    go to [front v] layer\n    go [forward v] (1) layers\nend\n\nwhen I receive [start v]\nforever\n    if <(Settings) = [0]> then\n        hide\n    end\n    if <(Settings) = [1]> then\n        go to [front v] layer\n        show\n    end\nend\n\nwhen this sprite clicked\nif <not <(Level) = [15]>> then\n    change [level v] by (1)\n    broadcast (Skip v)\nelse\n    switch costume to (costume2 v)\n    show\nend\n\n@mute\n\nwhen I receive [start v]\nforever\n    play sound [Marshmello - Alone \(Official Music Video\)2 v] until done\nend\n\nwhen flag clicked\nswitch costume to (costume1 v)\ngo to x: (0) y: (0)\nhide\nforever\n    go to [front v] layer\n    go [forward v] (1) layers\nend\n\nwhen I receive [start v]\nforever\n    if <(Settings) = [0]> then\n        hide\n    end\n    if <(Settings) = [1]> then\n        go to [front v] layer\n        show\n    end\nend\n\nwhen this sprite clicked\nnext costume\n\nwhen I receive [start v]\nforever\n    if <(costume [number v]) = [1]> then\n        set volume to (100) %\n    end\n    if <(costume [number v]) = [2]> then\n        set volume to (0) %\n    end\nend\n\n@Ground\n\nwhen I receive [start v]\ngo to x: (0) y: (0)\nshow\nswitch costume to (1 v)\n\nwhen I receive [start v]\ngo to [front v] layer\ngo [backward v] (1) layers\nforever\n    switch costume to (Level)\nend\n\nwhen flag clicked\nhide\n\nbroadcast (Illusions v)\n\n@Spikes\n\nwhen I receive [start v]\ngo to x: (0) y: (0)\nshow\nswitch costume to (1 v)\ngo to [back v] layer\n\nwhen I receive [start v]\nforever\n    switch costume to (Level)\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [start v]\ngo to [back v] layer\ngo to x: (0) y: (0)\nshow\nswitch costume to (1 v)\nforever\n    switch costume to (Level)\nend\n\n@Lava\n\nwhen flag clicked\ngo to x: (0) y: (0)\nforever\n    repeat (30)\n        change y by (-0.4)\n    end\n    repeat (30)\n        change y by (0.4)\n    end\nend\n\nwhen I receive [start v]\ngo to x: (0) y: (0)\nshow\nswitch costume to (1 v)\nforever\n    go to [back v] layer\n    switch costume to (Level)\nend\n\nwhen flag clicked\nhide\n\nrepeat (30)\n    change y by (-0.4)\nend\nrepeat (30)\n    change y by (0.4)\nend\n\n@Water\n\nwhen flag clicked\nhide\n\nwhen I receive [start v]\ngo to x: (0) y: (0)\nshow\nswitch costume to (1 v)\nforever\n    go to [back v] layer\n    switch costume to (Level)\nend\n\nwhen flag clicked\nwait (0.5) seconds\ngo to x: (0) y: (0)\nforever\n    repeat (30)\n        change y by (-0.4)\n    end\n    repeat (30)\n        change y by (0.4)\n    end\nend\n\n@Trampoline\n\nwhen I receive [start v]\ngo to [back v] layer\ngo to x: (0) y: (0)\nshow\nswitch costume to (1 v)\nforever\n    switch costume to (Level)\nend\n\nwhen flag clicked\nhide\n\n@Speed Ups\n\nwhen I receive [start v]\ngo to [back v] layer\ngo to x: (0) y: (0)\nshow\nswitch costume to (1 v)\nforever\n    switch costume to (Level)\nend\n\nwhen flag clicked\nhide\n\n@Small become\n\nwhen I receive [start v]\ngo to [back v] layer\ngo to x: (0) y: (0)\nshow\nswitch costume to (1 v)\nforever\n    switch costume to (Level)\nend\n\nwhen flag clicked\nhide\n\n@Saws\n\nwhen flag clicked\ngo to [back v] layer\nhide\nforever\n    switch costume to (join [abc] (Level))\n    if <(costume [name v]) = (join [abc] (Level))> then\n        show\n        Tick (Level)\n    else\n        hide\n    end\nend\n\ndefine Tick (level)\n\n    if <(Level) = [2]> then\n        Move in position | Min [-145] Max [-60] Speed [75] turn [y]\n        Go to (Pos) [-115]\n    end\n    if <(Level) = [3]> then\n        Move in position | Min [-55] Max [-55] Speed [75] turn [y]\n        Go to (Pos) [-115]\n    end\n    if <(Level) = [4]> then\n        hide\n    end\n    if <(Level) = [6]> then\n        show\n        Move in position | Min [-20] Max [200] Speed [100] turn [y]\n        Go to (Pos) [19]\n    end\n    if <(Level) = [7]> then\n        hide\n    end\n    if <(Level) = [10]> then\n        show\n        Move in position | Min [-100] Max [60] Speed [100] turn [y]\n        Go to (Pos) [-115]\n    end\n    if <(Level) = [11]> then\n        hide\n    end\n    if <(Level) = [12]> then\n        hide\n    end\n    if <(Level) = [15]> then\n        show\n        Move in position | Min [-70] Max [40] Speed [90] turn [y]\n        Go to (Pos) [43]\n    end\nend\npoint in direction (90)\n\ndefine Move in position | Min (min) Max (max) Speed (s) turn (n?)\nif <(min) > (max)> then\n    if <((max) - (min)) = [0]> then\n        stop [this script v]\n    else\n        Move in position | Min (max) Max (min) Speed (s) turn []\n    end\nelse\n    set [pos v] to (((max) - (min)) / (2))\n    set [pos v] to (((Pos) + (min)) + (([sin v] of ((timer) * (s)) ) * (Pos)))\n    if <not <(n?) = [N]>> then\n        turn right ((s) / (10)) degrees\n    end\nend\n\ndefine Go to (x) (y)\ngo to x: (x) y: (y)\n\n@Enemy\n\nwhen I start as a clone\nshow\ngo to [front v] layer\nforever\n    if <<(Level) = [3]> or <<(Level) = [5]> or <(Level) = [23]>>> then\n        if <([x position v] of [player v]) < (x position)> then\n            change [enemy: xs v] by (-0.5)\n        end\n        if <(x position) < ([x position v] of [player v])> then\n            change [enemy: xs v] by (0.5)\n        end\n        set [enemy: xs v] to ((Enemy: Xs) * (0.9))\n        change x by (Enemy: Xs)\n        if <touching (ground v)?> then\n            change y by (1)\n        end\n        if <touching (ground v)?> then\n            change y by (1)\n        end\n        if <touching (ground v)?> then\n            change y by (1)\n        end\n        if <touching (ground v)?> then\n            change y by (1)\n        end\n        if <touching (ground v)?> then\n            change y by (-4)\n            change x by ((Enemy: Xs) * (-1))\n            if <(([y position v] of [player v]) - (50)) > (y position)> then\n                if <(Enemy: Xs) > [0]> then\n                    set [enemy: xs v] to [-10]\n                else\n                    set [enemy: xs v] to [10]\n                end\n                set [enemy: ys v] to [15]\n            else\n                set [enemy: xs v] to [0]\n            end\n        end\n        change [enemy: ys v] by (-1)\n        change y by (Enemy: Ys)\n        if <touching (ground v)?> then\n            change y by ((Enemy: Ys) - ((Enemy: Ys) * (2)))\n            set [enemy: ys v] to [0]\n        end\n        change y by (-1)\n        change y by (1)\n        if <touching (sword v)?> then\n            delete this clone\n        end\n    else\n        if <<(Level) = [4]> or <<(Level) = [6]> or <(Level) = [24]>>> then\n            delete this clone\n        end\n    end\nend\n\ndefine Clone at (x pos) (y pos)\ngo to x: (x pos) y: (y pos)\ncreate clone of (_myself_ v)\n\nwhen I receive [start v]\nforever\n    if <(Level) = [3]> then\n        Clone at [100] [-90]\n        wait until <not <(Level) = [3]>>\n    end\n    if <(Level) = [5]> then\n        Clone at [150] [100]\n        wait until <not <(Level) = [5]>>\n    end\nend\n\nwhen flag clicked\nforever\n    hide\n    go to [back v] layer\nend\n\n@Sword\n\nwhen flag clicked\nhide\n\nwhen I receive [start v]\nforever\n    if <key (space v) pressed?> then\n        wait until <not <key (space v) pressed?>>\n        show\n        point in direction (90)\n        repeat (9)\n            turn right (10) degrees\n        end\n        hide\n    end\nend\n\nwhen I receive [start v]\nforever\n    go to (player v)\nend\n\n@Portal 1\n\nwhen flag clicked\nhide\n\nwhen I receive [start v]\nset [sine v] to [0]\npoint in direction (90)\nset size to (100) %\nforever\n    change [sine v] by (5)\n    point in direction ((([sin v] of (sine) ) * (100)) + (0))\n    set size to ((([sin v] of ((sine) * (2)) ) * (5)) + (50)) %\n    go to [front v] layer\nend\n\nwhen I receive [start v]\nforever\n    switch costume to (Level)\n    if <touching (player v)?> then\n        broadcast (Portal v)\n    end\nend\n\nwhen I receive [start v]\nforever\n    if <(Level) = [1]> then\n        hide\n    end\n    if <(Level) = [7]> then\n        go to x: (-110) y: (-100)\n        show\n    end\n    if <(Level) = [8]> then\n        hide\n    end\n    if <(Level) = [9]> then\n        go to x: (-110) y: (-105)\n        show\n    end\n    if <(Level) = [10]> then\n        hide\n    end\n    if <(Level) = [15]> then\n        go to x: (43) y: (57)\n        show\n    end\nend\n\nrepeat (22)\n    change [level v] by (1)\nend\n\n@Portal 2\n\nwhen flag clicked\nhide\n\nwhen I receive [start v]\nshow\nset [sine v] to [0]\npoint in direction (90)\nset size to (100) %\nforever\n    change [sine v] by (5)\n    point in direction ((([sin v] of (sine) ) * (100)) + (0))\n    set size to ((([sin v] of ((sine) * (2)) ) * (5)) + (50)) %\n    go to [front v] layer\nend\n\nwhen I receive [start v]\nforever\n    switch costume to (Level)\nend\n\nwhen I receive [start v]\nforever\n    if <(Level) = [1]> then\n        hide\n    end\n    if <(Level) = [7]> then\n        go to x: (120) y: (-20)\n        show\n    end\n    if <(Level) = [8]> then\n        hide\n    end\n    if <(Level) = [9]> then\n        go to x: (-225) y: (-105)\n        show\n    end\n    if <(Level) = [10]> then\n        hide\n    end\n    if <(Level) = [15]> then\n        go to x: (-15) y: (-100)\n        show\n    end\nend\n\n@Key\n\nwhen flag clicked\nhide\n\nwhen I receive [start v]\nshow\ngo to x: (0) y: (0)\nforever\n    switch costume to (Level)\n    if <(Level) = [20]> then\n        show\n    end\nend\n\nwhen I receive [start v]\nforever\n    if <touching (player v)?> then\n        broadcast (Key v)\n        hide\n    end\nend\n\nwhen I receive [illusions v]\nshow\n\n@Lock\n\nwhen I receive [start v]\ngo to x: (0) y: (0)\nforever\n    switch costume to (Level)\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [key v]\nhide\n\nwhen I receive [start v]\nshow\nforever\n    if <(Level) = [20]> then\n        show\n    end\nend\n\nwhen I receive [illusions v]\nshow\n\n@Extra\n\nwhen I receive [start v]\ngo to x: (0) y: (0)\nshow\nswitch costume to (1 v)\n\nwhen I receive [start v]\ngo to [front v] layer\nforever\n    switch costume to (Level)\nend\n\nwhen flag clicked\nhide\n\nset [ghost v] effect to (0)\n\nbroadcast (Illusions v)\n\n@Illusions\n\nwhen I receive [start v]\ngo to x: (0) y: (0)\nshow\nswitch costume to (1 v)\n\nwhen I receive [start v]\nforever\n    go to [front v] layer\n    switch costume to (Level)\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [start v]\nforever\n    if <touching (player v)?> then\n        hide\n    end\nend\n\nwhen I receive [illusions v]\nshow\n\n@2nd Illusions\n\nwhen I receive [start v]\ngo to x: (0) y: (0)\nshow\nswitch costume to (1 v)\n\nwhen I receive [start v]\nforever\n    go to [front v] layer\n    switch costume to (Level)\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [start v]\nforever\n    if <touching (player v)?> then\n        hide\n    end\nend\n\nwhen I receive [illusions v]\nshow\n\n@3rd Illusions\n\nwhen I receive [start v]\ngo to x: (0) y: (0)\nshow\nswitch costume to (1 v)\n\nwhen I receive [start v]\nforever\n    go to [front v] layer\n    switch costume to (Level)\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [start v]\nforever\n    if <touching (player v)?> then\n        hide\n    end\nend\n\nwhen I receive [illusions v]\nshow\n\n@Thumbnail\n\nwhen flag clicked\nswitch costume to (costume3 v)\nshow\nset [ghost v] effect to (100)\ngo to [front v] layer\ngo to x: (0) y: (0)\nset volume to (100) %\n\n@Pfp\n\nwhen flag clicked\nforever\n    hide\nend\n\n