Parallax
@Stage\n\nwhen flag clicked\nInit\nbroadcast (Intro v)\n\ndefine Init\nhide variable [death v]\nhide variable [timer v]\nset [level v] to [0]\nset [player v] to [1]\nset [death v] to [0]\nset [colour v] to [1]\nset [credits v] to [0]\ndelete (all) of [level codes v]\nadd [,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,j,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,aaa,,,,,,,,,,,,,,e,,,,,,,d,,,,,,,,,,,,,,,,,,bbb,,i,,,,,,,,,,,,,,,,,,aaabbbb,,,,ccccccccc,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,] to [level codes v]\nadd [,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,j,,,,,,,,,,,,,,,,,,,aa,,,i,,,,,,,,,,,,,,,,,,aaa,,,bbb,,,ccc,,,,,,,,fff,,,fff,,,,,,,,,,,,,,,g,,e,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,ccc,,,aaa,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,] to [level codes v]\nadd [,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,e,,,,,,,d,,,,,,,,,,ccc,,,,,,,,,,,,,,,,,,d,,,fccccd,,,,,,,,,bbb,,fe,,,,,,,,,,,,,,e,,,fbbbb,,,,,,,,,,ccc,,f,,,d,,,,,,,,,,,,,,,fcccc,,,,,,,,,,bbb,,fj,,,ggffaaa,,,,e,,,,,bbb,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,i,,,,,,,,,,,bbb,,,,aaa,,,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,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,] to [level codes v]\nclear graphic effects\n\nwhen I receive [menu.main v]\nswitch backdrop to (haze v)\n\nwhen I receive [editor.play v]\nswitch backdrop to (plain v)\n\nwhen flag clicked\nset volume to (100) %\nforever\n    play sound [Ignition.mp3 v] until done\nend\n\nwhen I receive [editor.transition v]\nwait (0.6) seconds\nrepeat (20)\n    change volume by (-5)\nend\n\nwhen I receive [game.transition v]\nrepeat (10)\n    change volume by (-5)\nend\nwait (0.6) seconds\nrepeat (20)\n    change volume by (5)\nend\n\nbroadcast (game.transition v)\n\n@Intro Outro\n\nwhen I receive [intro v]\nset [brightness v] effect to (100)\ngo to x: (0) y: (0)\ngo to [front v] layer\nswitch costume to (avatar v)\nshow\nwait (0.4) seconds\nrepeat (20)\n    change [brightness v] effect by (-5)\nend\nwait (0.2) seconds\nbroadcast (menu.main v)\nwait (0.2) seconds\nrepeat (24)\n    change y by (((y position) + (5)) / (5))\nend\nhide\n\nwhen I receive [outro v]\nset [timer v] to (round (timer))\ngo to x: (0) y: (-320)\ngo to [front v] layer\nset [ghost v] effect to (0)\nswitch costume to (end message v)\nshow\nrepeat until <(y position) = [0]>\n    if <(round (((0) - (y position)) / (5))) > [0]> then\n        change y by (round (((0) - (y position)) / (5)))\n    else\n        change y by (1)\n    end\nend\nshow variable [death v]\nshow variable [timer v]\n\n@Title\n\nwhen flag clicked\nhide\n\nwhen I receive [menu.main v]\ngo to x: (0) y: (110)\nset [sin v] to [0]\nshow\nforever\n    change [sin v] by (4)\n    change y by (([sin v] of (sin) ) / (3))\nend\n\nwhen I receive [editor.play v]\nHide\n\nwhen I receive [game.play v]\nHide\n\ndefine Hide\nhide\nstop [other scripts in sprite v]\n\n@Buttons\n\nwhen flag clicked\nhide\n\nwhen I receive [menu.main v]\nInit\n\ndefine Init\ngo to x: (-100) y: (-120)\nswitch costume to (play v)\nrepeat (3)\n    create clone of (_myself_ v)\n    change x by (100)\n    next costume\nend\n\nwhen this sprite clicked\nif <(costume [number v]) = [1]> then\n    set [level v] to [0]\n    broadcast (game.transition v)\n    reset timer\nend\nif <(costume [number v]) = [2]> then\n    broadcast (editor.transition v)\nend\nif <(costume [number v]) = [3]> then\n    if <(Credits) = [0]> then\n        set [credits v] to [1]\n        broadcast (menu.credits v)\n    end\nend\n\nwhen I start as a clone\nshow\n\nwhen I receive [game.play v]\ndelete this clone\n\nwhen I receive [editor.play v]\ndelete this clone\n\n@Credits\n\nwhen flag clicked\nhide\n\nwhen I receive [menu.credits v]\nHide\ngo to x: (0) y: (0)\ncreate clone of (_myself_ v)\ngo to [front v] layer\nswitch costume to (credits v)\nset [ghost v] effect to (100)\nshow\nrepeat (10)\n    change [ghost v] effect by (-10)\nend\n\nwhen I start as a clone\ngo to x: (0) y: (-115)\nswitch costume to (close v)\ngo to [front v] layer\nset [ghost v] effect to (100)\nshow\nrepeat (10)\n    change [ghost v] effect by (-10)\nend\n\nwhen I receive [menu.credits.close v]\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nHide\n\ndefine Hide\nhide\ndelete this clone\n\nwhen this sprite clicked\nif <(costume [number v]) = [2]> then\n    set [credits v] to [0]\n    broadcast (menu.credits.close v)\nend\n\nwhen I receive [game.play v]\nset [credits v] to [0]\nHide\n\nwhen I receive [editor.play v]\nset [credits v] to [0]\nHide\n\n@Player\n\nwhen flag clicked\nhide\n\nwhen I receive [menu.main v]\nInit Menu\nforever\n    if <touching (mouse-pointer v)?> then\n        repeat (8)\n            change size by (((480) - (size)) / (2.5))\n        end\n        repeat until <not <touching (mouse-pointer v)?>>\n            if <mouse down?> then\n                change [player v] by (1)\n                if <(Player) = [5]> then\n                    set [player v] to [1]\n                end\n                switch costume to (Player)\n                wait until <not <mouse down?>>\n            end\n        end\n        repeat (8)\n            change size by (((358) - (size)) / (2.5))\n        end\n    end\nend\n\ndefine Block Detection\nif <touching (finish v)?> then\n    broadcast (game.transition v)\nend\nif <touching (elastic pad v)?> then\n    Bounce Up\n    set [vel y v] to [18]\nend\nif <touching (poison v)?> then\n    change [death v] by (1)\n    Init Play\nend\n\ndefine Hit Ground <>\nrepeat until <not <<touching (ground v)?> or <touching (inelastic pad v)?>>>\n    if <ceiling> then\n        change y by (-1)\n    else\n        change y by (1)\n    end\n    set [vel y v] to [0]\nend\n\nwhen I receive [editor.play v]\nhide\n\nwhen I receive [game.play v]\nInit Play\nforever\n    go to [front v] layer\n    change [vel y v] by (-1.2)\n    change y by (vel y)\n    Hit Ground <(vel y) > [0]>\n    set [vel x v] to ((vel x) * (0.75))\n    if <<key (left arrow v) pressed?> or <key (a v) pressed?>> then\n        change [vel x v] by (-1.35)\n    end\n    if <<key (right arrow v) pressed?> or <key (d v) pressed?>> then\n        change [vel x v] by (1.35)\n    end\n    if <([abs v] of (vel x) ) > [0.4]> then\n        Walk (vel x)\n    end\n    change y by (-1)\n    if <<<<key (up arrow v) pressed?> or <key (w v) pressed?>> and <touching (ground v)?>> and <not <touching (inelastic pad v)?>>> then\n        set [vel y v] to [12.8]\n    end\n    change y by (1)\n    if <(y position) < [-177]> then\n        change [death v] by (1)\n        Init Play\n    end\n    Block Detection\n    if <key (x v) pressed?> then\n        broadcast (game.transition v)\n    end\nend\n\ndefine None\nchange x by ((0) - (speed))\nif <(speed) < [0]> then\n    repeat until <<touching (ground v)?> or <touching (inelastic pad v)?>>\n        change x by (-1)\n    end\n    change x by (1)\nelse\n    repeat until <<touching (ground v)?> or <touching (inelastic pad v)?>>\n        change x by (1)\n    end\n    change x by (-1)\nend\nset [vel x v] to [0]\n\ndefine None\nchange x by (speed)\nif <<touching (ground v)?> or <touching (inelastic pad v)?>> then\n    Hit Wall (speed)\nend\n\ndefine Init Menu\ngo to x: (0) y: (10)\nset size to (360) %\nswitch costume to (Player)\nshow\n\nwhen I receive [editor.transition v]\nhide\nstop [other scripts in sprite v]\n\nwhen I receive [game.transition v]\nstop [other scripts in sprite v]\n\ndefine Bounce Up\nrepeat until <not <touching (elastic pad v)?>>\n    change y by (1)\nend\n\ndefine Init Play\nstop [other scripts in sprite v]\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nset [ghost v] effect to (100)\nset [vel x v] to [0]\nset [vel y v] to [0]\nset [colour v] to [1]\ngo to (start v)\nset size to (100) %\nshow\nrepeat (10)\n    change [ghost v] effect by (-10)\nend\n\n@Flavour Text\n\nwhen flag clicked\nhide\n\nwhen I receive [menu.main v]\ngo to x: (0) y: (-65)\nshow\nforever\n    switch costume to (Player)\nend\n\nwhen I receive [game.play v]\nhide\n\nwhen I receive [editor.play v]\nhide\n\n@Editor\n\nwhen flag clicked\nInit Main\n\nwhen I receive [block.destroy v]\nDestroy Clone\n\ndefine Destroy Clone\nif <touching (mouse-pointer v)?> then\n    change [clone count v] by (-0.5)\n    delete this clone\nend\n\ndefine None\nif <not <(item (item) of [current level code v]) = [,]>> then\n    broadcast (block.destroy v) and wait\nend\nif <(costume [number v]) = [1]> then\n    replace item (item) of [current level code v] with [a]\nend\nif <(costume [number v]) = [2]> then\n    replace item (item) of [current level code v] with [b]\nend\nif <(costume [number v]) = [3]> then\n    replace item (item) of [current level code v] with [c]\nend\nif <(costume [number v]) = [4]> then\n    replace item (item) of [current level code v] with [d]\nend\nif <(costume [number v]) = [5]> then\n    replace item (item) of [current level code v] with [e]\nend\nif <(costume [number v]) = [6]> then\n    replace item (item) of [current level code v] with [f]\nend\nif <(costume [number v]) = [7]> then\n    replace item (item) of [current level code v] with [g]\nend\nif <(costume [number v]) = [8]> then\n    replace item (item) of [current level code v] with [h]\nend\nif <(costume [number v]) = [9]> then\n    replace item (item) of [current level code v] with [i]\nend\nif <(costume [number v]) = [10]> then\n    replace item (item) of [current level code v] with [j]\nend\n\ndefine Compile\nset [level code ram v] to []\nset [count v] to [0]\nrepeat (300)\n    change [count v] by (1)\n    set [level code ram v] to (join (level code RAM) (item (count) of [current level code v]))\nend\ndelete (all) of [compiled level code \[space to close\] v]\nadd (level code RAM) to [compiled level code \[space to close\] v]\n\ndefine Select Mode\nif <key (1 v) pressed?> then\n    set [mode v] to [select]\nend\nif <key (2 v) pressed?> then\n    set [mode v] to [block]\nend\nif <key (3 v) pressed?> then\n    set [mode v] to [erase]\nend\nif <key (4 v) pressed?> then\n    set [mode v] to [select]\n    Compile\n    wait until <not <key (4 v) pressed?>>\n    hide list [compiled level code \[space to close\] v]\n    wait until <key (space v) pressed?>\n    show list [compiled level code \[space to close\] v]\nend\nif <key (5 v) pressed?> then\n    ask [Import level code] and wait\n    if <not <(length of (answer)) = [300]>> then\n        say [Invalid level code] for (3) seconds\n    else\n        broadcast (editor.clear v) and wait\n        Import Level (answer)\n        broadcast (editor.import v) and wait\n    end\nend\nif <key (i v) pressed?> then\n    broadcast (editor.instructions v) and wait\nend\n\ndefine Init Editor\nset [mode v] to [block]\nset [clone count v] to [0]\ndelete (all) of [current level code v]\nrepeat (300)\n    add [,] to [current level code v]\nend\nswitch costume to (ground v)\nshow\n\ndefine Constrain\nif <(x position) > [236]> then\n    set x to (228)\nend\nif <(y position) > [176]> then\n    set y to (168)\nend\n\ndefine Switch Costume\nif <key (right arrow v) pressed?> then\n    next costume\n    wait until <not <key (right arrow v) pressed?>>\nend\nif <key (left arrow v) pressed?> then\n    switch costume to ((costume [number v]) - (1))\n    wait until <not <key (left arrow v) pressed?>>\nend\n\ndefine None\nif <(costume) = [a]> then\n    switch costume to (ground v)\n    create clone of (_myself_ v)\nend\nif <(costume) = [b]> then\n    switch costume to (blue ground v)\n    create clone of (_myself_ v)\nend\nif <(costume) = [c]> then\n    switch costume to (orange ground v)\n    create clone of (_myself_ v)\nend\nif <(costume) = [d]> then\n    switch costume to (blue orb v)\n    create clone of (_myself_ v)\nend\nif <(costume) = [e]> then\n    switch costume to (orange orb v)\n    create clone of (_myself_ v)\nend\nif <(costume) = [f]> then\n    switch costume to (poison v)\n    create clone of (_myself_ v)\nend\nif <(costume) = [g]> then\n    switch costume to (elastic pad v)\n    create clone of (_myself_ v)\nend\nif <(costume) = [h]> then\n    switch costume to (inelastic pad v)\n    create clone of (_myself_ v)\nend\nif <(costume) = [i]> then\n    switch costume to (start v)\n    create clone of (_myself_ v)\nend\nif <(costume) = [j]> then\n    switch costume to (finish v)\n    create clone of (_myself_ v)\nend\n\nwhen I start as a clone\nclear graphic effects\nshow\nchange [clone count v] by (1)\n\ndefine Render\ngo to x: (-228) y: (168)\nset [clone count v] to [0]\nset [current v] to [0]\nrepeat (15)\n    repeat (20)\n        change [current v] by (1)\n        Switch (item (current) of [current level code v])\n        change x by (24)\n    end\n    go to x: (-228) y: ((y position) - (24))\nend\n\ndefine None\ndelete (all) of [current level code v]\nset [current v] to [0]\nrepeat (300)\n    change [current v] by (1)\n    add (letter (current) of (code)) to [current level code v]\nend\n\nwhen I receive [editor.import v]\nRender\n\nwhen I receive [editor.clear v]\ndelete this clone\n\nwhen I receive [editor.playtest v]\nCompile\nbroadcast (editor.clear v) and wait\nadd (item (1) of [compiled level code \[space to close\] v]) to [level codes v]\n\nwhen I receive [editor.play v]\nInit Editor\nbroadcast (editor.instructions v) and wait\nforever\n    Select Mode\n    if <not <(mode) = [select]>> then\n        go to x: (((round (((mouse x) + (12)) / (24))) * (24)) - (12)) y: ((round ((mouse y) / (24))) * (24))\n    end\n    if <(mode) = [block]> then\n        set [ghost v] effect to (0)\n    else\n        set [ghost v] effect to (100)\n    end\n    if <(mode) = [block]> then\n        Constrain\n        Switch Costume\n        if <mouse down?> then\n            if <<<(mouse x) > [-238]> and <(mouse x) < [238]>> and <<(mouse y) > [-178]> and <(mouse y) < [178]>>> then\n                if <(Clone Count) < [150]> then\n                    Update Level Code ((((x position) + (252)) / (24)) + ((20) * ((14) - (((y position) + (168)) / (24)))))\n                    create clone of (_myself_ v)\n                    wait until <not <mouse down?>>\n                end\n            else\n                say [Your mouse is off screen!] for (1) seconds\n            end\n        end\n    end\n    if <(mode) = [erase]> then\n        if <mouse down?> then\n            replace item ((((x position) + (252)) / (24)) + ((20) * ((14) - (((y position) + (168)) / (24))))) of [current level code v] with [,]\n            broadcast (block.destroy v) and wait\n            set [clone count v] to ([ceiling v] of (Clone Count) )\n            wait until <not <mouse down?>>\n        end\n    end\n    if <(Level) = [11]> then\n        wait until <(Level) = [0]>\n    end\nend\n\ndefine Init Main\nshow list [compiled level code \[space to close\] v]\nhide\n\n@Editor Play\n\nwhen flag clicked\nhide\n\nwhen I receive [editor.play v]\ngo to x: (170) y: (-152)\nshow\nforever\n    if <(Level) = [0]> then\n        switch costume to (play v)\n    end\n    if <(Level) = [11]> then\n        switch costume to (return v)\n    end\nend\n\nwhen this sprite clicked\nif <(Level) = [0]> then\n    broadcast (editor.playtest v) and wait\n    set [level v] to [11]\n    broadcast (game.transition v)\nelse\n    if <(Level) = [11]> then\n        delete (Level) of [level codes v]\n        broadcast (editor.transition v)\n    end\nend\n\n@Editor Instructions\n\nwhen flag clicked\nhide\n\nwhen I receive [editor.transition v]\ngo to x: (0) y: (-152)\nshow\nforever\n    if <touching (mouse-pointer v)?> then\n        set [ghost v] effect to (0)\n        switch costume to (tooltip v)\n    else\n        set [ghost v] effect to (60)\n        switch costume to (question mark v)\n    end\nend\n\nwhen I start as a clone\ngo to x: (0) y: (-320)\ngo to [front v] layer\nset [ghost v] effect to (0)\nswitch costume to (instruction panel v)\nshow\nrepeat until <(y position) = [0]>\n    if <(round (((0) - (y position)) / (5))) > [0]> then\n        change y by (round (((0) - (y position)) / (5)))\n    else\n        change y by (1)\n    end\nend\nwait until <key (space v) pressed?>\nrepeat (24)\n    change y by (((y position) + (5)) / (5))\nend\ndelete this clone\n\nwhen I receive [editor.instructions v]\ncreate clone of (_myself_ v)\nwait until <key (space v) pressed?>\n\nwhen I receive [game.transition v]\nhide\nstop [other scripts in sprite v]\n\n@Decoration\n\ndefine Render\ngo to x: (-228) y: (168)\nset [current v] to [0]\nrepeat (15)\n    repeat (20)\n        change [current v] by (1)\n        Switch (letter (current) of (item (Level) of [level codes v]))\n        change x by (24)\n    end\n    go to x: (-228) y: ((y position) - (24))\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [game.render v]\nRender\n\ndefine None\nif <(costume) = [b]> then\n    switch costume to (blue ground v)\n    create clone of (_myself_ v)\nend\nif <(costume) = [c]> then\n    switch costume to (orange ground v)\n    create clone of (_myself_ v)\nend\n\nwhen I start as a clone\ngo [backward v] (999) layers\nshow\nset [ghost v] effect to (70)\n\nwhen I receive [game.destroy v]\ndelete this clone\n\n@Ground\n\ndefine None\nif <(costume) = [a]> then\n    switch costume to (ground v)\n    create clone of (_myself_ v)\nend\nif <(costume) = [b]> then\n    switch costume to (blue ground v)\n    create clone of (_myself_ v)\nend\nif <(costume) = [c]> then\n    switch costume to (orange ground v)\n    create clone of (_myself_ v)\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [game.render v]\nRender\n\nwhen I start as a clone\nforever\n    if <(costume [number v]) = [1]> then\n        show\n    else\n        if <(Colour) = ((costume [number v]) - (1))> then\n            show\n        else\n            hide\n        end\n    end\nend\n\ndefine Render\ngo to x: (-228) y: (168)\nset [current v] to [0]\nrepeat (15)\n    repeat (20)\n        change [current v] by (1)\n        Switch (letter (current) of (item (Level) of [level codes v]))\n        change x by (24)\n    end\n    go to x: (-228) y: ((y position) - (24))\nend\n\nwhen I receive [game.destroy v]\ndelete this clone\n\n@Orb\n\nwhen flag clicked\nhide\n\ndefine None\nif <(costume) = [d]> then\n    switch costume to (blue orb v)\n    create clone of (_myself_ v)\nend\nif <(costume) = [e]> then\n    switch costume to (orange orb v)\n    create clone of (_myself_ v)\nend\n\ndefine Render\ngo to x: (-228) y: (168)\nset [current v] to [0]\nrepeat (15)\n    repeat (20)\n        change [current v] by (1)\n        Switch (letter (current) of (item (Level) of [level codes v]))\n        change x by (24)\n    end\n    go to x: (-228) y: ((y position) - (24))\nend\n\nwhen I receive [game.render v]\nRender\n\nwhen I start as a clone\nshow\nforever\n    if <touching (player v)?> then\n        set [colour v] to (costume [number v])\n    end\nend\n\nwhen I receive [game.destroy v]\ndelete this clone\n\n@Poison\n\nwhen flag clicked\nhide\n\ndefine Render\ngo to x: (-228) y: (168)\nset [current v] to [0]\nrepeat (15)\n    repeat (20)\n        change [current v] by (1)\n        if <(letter (current) of (item (Level) of [level codes v])) = [f]> then\n            create clone of (_myself_ v)\n        end\n        change x by (24)\n    end\n    go to x: (-228) y: ((y position) - (24))\nend\n\nwhen I receive [game.destroy v]\ndelete this clone\n\nwhen I start as a clone\nshow\n\nwhen I receive [game.render v]\nRender\n\n@Elastic Pad\n\nwhen flag clicked\nhide\n\ndefine Render\ngo to x: (-228) y: (168)\nset [current v] to [0]\nrepeat (15)\n    repeat (20)\n        change [current v] by (1)\n        if <(letter (current) of (item (Level) of [level codes v])) = [g]> then\n            create clone of (_myself_ v)\n        end\n        change x by (24)\n    end\n    go to x: (-228) y: ((y position) - (24))\nend\n\nwhen I receive [game.destroy v]\ndelete this clone\n\nwhen I start as a clone\nshow\n\nwhen I receive [game.render v]\nRender\n\n@Inelastic Pad\n\nwhen flag clicked\nhide\n\ndefine Render\ngo to x: (-228) y: (168)\nset [current v] to [0]\nrepeat (15)\n    repeat (20)\n        change [current v] by (1)\n        if <(letter (current) of (item (Level) of [level codes v])) = [h]> then\n            create clone of (_myself_ v)\n        end\n        change x by (24)\n    end\n    go to x: (-228) y: ((y position) - (24))\nend\n\nwhen I receive [game.destroy v]\ndelete this clone\n\nwhen I start as a clone\nshow\n\nwhen I receive [game.render v]\nRender\n\n@Start\n\nwhen flag clicked\nhide\n\ndefine Render\nhide\ngo to x: (-228) y: (168)\nset [current v] to [0]\nrepeat (15)\n    repeat (20)\n        change [current v] by (1)\n        if <(letter (current) of (item (Level) of [level codes v])) = [i]> then\n            show\n            stop [this script v]\n        end\n        change x by (24)\n    end\n    go to x: (-228) y: ((y position) - (24))\nend\n\nwhen I receive [game.render v]\nRender\n\nwhen I receive [game.destroy v]\nhide\n\n@Finish\n\nwhen flag clicked\nhide\n\ndefine Render\nhide\ngo to x: (-228) y: (168)\nset [current v] to [0]\nrepeat (15)\n    repeat (20)\n        change [current v] by (1)\n        if <(letter (current) of (item (Level) of [level codes v])) = [j]> then\n            show\n            stop [this script v]\n        end\n        change x by (24)\n    end\n    go to x: (-228) y: ((y position) - (24))\nend\n\nwhen I receive [game.render v]\nRender\n\nwhen I receive [game.destroy v]\nhide\n\n@Settings\n\nwhen flag clicked\nhide\n\nwhen I receive [menu.main v]\ngo to x: (213) y: (-152)\nswitch costume to (settings v)\nshow\nforever\n    hide\n    turn right (2) degrees\n    if <touching (mouse-pointer v)?> then\n        if <(clone) = [0]> then\n            if <mouse down?> then\n                set [clone v] to [1]\n                create clone of (_myself_ v)\n            end\n        end\n    end\nend\n\nwhen I start as a clone\ndelete this clone\n\n@Fade In/Out\n\nwhen flag clicked\nset [ghost v] effect to (100)\ngo to x: (0) y: (0)\nshow\n\nwhen I receive [game.transition v]\ngo to [front v] layer\nrepeat (10)\n    change [ghost v] effect by (-10)\nend\nbroadcast (game.destroy v)\nwait (0.4) seconds\nif <not <(Level) = [11]>> then\n    change [level v] by (1)\nend\nif <(Level) = [10]> then\n    broadcast (Outro v)\nelse\n    broadcast (game.render v)\n    wait (0.2) seconds\n    broadcast (game.play v)\nend\nrepeat (10)\n    change [ghost v] effect by (10)\nend\n\nwhen I receive [editor.transition v]\ngo to [front v] layer\nrepeat (10)\n    change [ghost v] effect by (-10)\nend\nbroadcast (game.destroy v)\nwait (0.4) seconds\nif <(Level) = [0]> then\n    broadcast (editor.play v)\nend\nif <(Level) = [11]> then\n    broadcast (editor.import v)\nend\nset [level v] to [0]\nwait (0.2) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\nend\n\n@Thumbnail\n\nwhen flag clicked\nhide\n\ngo to x: (0) y: (0)\ngo to [front v] layer\nshow\n\n