Zypher (3D Platformer) v.3

Instructions:                               Zypher (3D Platformer)\nPress space to begin.\nPress the arrow keys more movement. \nOrange-Yellow Platforms have no effect.\nGreen Platforms are the end of the level.\nBlue Platforms are trampolines, increasing your y velocity.\nRed Platforms damage you.\nPurple Platforms teleport you!\nYellow platforms are the secret stars!\n\nv.1 Release\nv.2 New Level\nv.3 New Level; Level 7, Radical Rotation

@Stage\n\n@3D Engine\n\ndefine ≈\nset [≈ v] to (((y2) - (y1)) / ((x2) - (x1)))\nif <(x1) > [240]> then\n    if <(x2) > [240]> then\n        stop [this script v]\n    else\n        SecondaryPoint [240] ((y1) + (((240) - (x1)) * (≈)))\n    end\nend\nif <(y1) > [240]> then\n    if <(y2) > [240]> then\n        stop [this script v]\n    else\n        SecondaryPoint ((x1) + (((180) - (y1)) / (≈))) [180]\n    end\nend\nif <(x1) < [-240]> then\n    if <(x2) < [-240]> then\n        stop [this script v]\n    else\n        SecondaryPoint [-240] ((y1) + (((-240) - (x1)) * (≈)))\n    end\nend\nif <(y1) < [-180]> then\n    if <(y2) < [-180]> then\n        stop [this script v]\n    else\n        SecondaryPoint ((x1) + (((-180) - (y1)) / (≈))) [-180]\n    end\nend\nif <(x2) > [240]> then\n    SecondaryPoint2 [240] ((y1) + (((240) - (x1)) * (≈)))\nend\nif <(y2) > [180]> then\n    SecondaryPoint2 ((x1) + (((180) - (y1)) / (≈))) [180]\nend\nif <(x2) < [-240]> then\n    SecondaryPoint2 [-240] ((y1) + (((-240) - (x1)) * (≈)))\nend\nif <(y2) < [-180]> then\n    SecondaryPoint2 ((x1) + (((-180) - (y1)) / (≈))) [-180]\nend\n\ndefine CC\nif <<(z1) < (DFC)> or <(z2) < (DFC)>> then\n    set [shortened v] to (((DFC) - (z1)) / ((z2) - (z1)))\n    if <(z1) < (DFC)> then\n        Point1 ((x1) + (((x2) - (x1)) * (shortened))) ((y1) + (((y2) - (y1)) * (shortened))) (DFC)\n    else\n        Point2 ((x1) + (((x2) - (x1)) * (shortened))) ((y1) + (((y2) - (y1)) * (shortened))) (DFC)\n    end\nend\n\ndefine Line From (x1) (y1) (z1) to (x2) (y2) (z2)\nPoint1 ((x1) - ((CamX) * (-1))) ((y1) - ((CamY) * (-1))) ((z1) - ((CamZ) * (-1)))\nPoint2 ((x2) - ((CamX) * (-1))) ((y2) - ((CamY) * (-1))) ((z2) - ((CamZ) * (-1)))\nif <not <<(z1) < (DFC)> and <(z2) < (DFC)>>> then\n    CC\n    SecondaryPoint ((ViewField) * ((x1) / (z1))) ((ViewField) * ((y1) / (z1)))\n    SecondaryPoint2 ((ViewField) * ((x2) / (z2))) ((ViewField) * ((y2) / (z2)))\n    ≈\n    go to x: (x1) y: (y1)\n    pen down\n    go to x: (x2) y: (y2)\n    pen up\nend\n\ndefine SecondaryPoint2 (x2) (y2)\nset [x2 v] to (x2)\nset [y2 v] to (y2)\n\ndefine Point1 (x1) (y1) (z1)\nset [x1 v] to (x1)\nset [y1 v] to (y1)\nset [z1 v] to (z1)\n\ndefine Point2 (x2) (y2) (z2)\nset [x2 v] to (x2)\nset [y2 v] to (y2)\nset [z2 v] to (z2)\n\ndefine SecondaryPoint (x1) (y1)\nset [x1 v] to (x1)\nset [y1 v] to (y1)\n\nwhen flag clicked\nstart\nforever\n    erase all\n    set pen size to (5)\n    if <(level) = [1]> then\n        Platform [500] [10] type: [normal]\n        Platform [500] [-15] type: [normal]\n        Platform [500] [-40] type: [normal]\n        Platform [500] [-65] type: [end]\n    else\n        if <(level) = [2]> then\n            Platform [500] [10] type: [normal]\n            Platform [500] [30] type: [bad]\n            Platform [400] [50] type: [end]\n            Platform [300] [-15] type: [bounce]\n        else\n            if <(level) = [3]> then\n                Platform [500] [10] type: [normal]\n                Platform [500] [0] type: [bad]\n                Platform [500] [-10] type: [bounce]\n                Platform [900] [0] type: [normal]\n                Platform [700] [0] type: [bounce]\n                Platform [800] [0] type: [bad]\n                Platform [900] [-20] type: [end]\n                Platform [800] [80] type: [bounce]\n                Platform [1000] [80] type: [bounce]\n                Platform [1200] [80] type: [bounce]\n                Platform [1410] [120] type: [bad]\n            else\n                if <(level) = [4]> then\n                    Platform [500] [10] type: [normal]\n                    Platform [500] (((40) * ([cos v] of (((2) * (deltacos)) / (3)) )) - (30)) type: [normal]\n                    Platform [500] [-90] type: [bounce]\n                    Platform [600] [-110] type: [normal]\n                    Platform [650] [-110] type: [bad]\n                    Platform [650] [-140] type: [bounce]\n                    Platform [1300] [100] type: [teleport]\n                    Platform [500] [100] type: [end]\n                    Platform [900] [-140] type: [teleport]\n                else\n                    if <(level) = [5]> then\n                        Platform [1100] [20] type: [bounce]\n                        Platform [700] [10] type: [bad]\n                        Platform [880] [10] type: [bad]\n                        Platform [1050] [10] type: [bad]\n                        Platform [1050] [15] type: [bad]\n                        Platform [1050] [5] type: [bad]\n                        Platform [1100] [10] type: [normal]\n                        Platform [500] [10] type: [bounce]\n                        Platform [900] [10] type: [bounce]\n                        Platform [710] [10] type: [bounce]\n                        Platform [1100] [60] type: [normal]\n                        Platform [1100] [80] type: [normal]\n                        Platform [1100] [100] type: [normal]\n                        Platform [1100] [120] type: [end]\n                        Platform [350] [10] type: [bad]\n                        Platform [250] [10] type: [bad]\n                    else\n                        if <(level) = [6]> then\n                            Platform [500] [10] type: [normal]\n                            Platform [530] [20] type: [normal]\n                            Platform [550] [30] type: [normal]\n                            Platform [350] [30] type: [bounce]\n                            Platform [350] [30] type: [bounce]\n                            Platform [570] [40] type: [bad]\n                            Platform [590] [50] type: [bad]\n                            Platform [610] [60] type: [bounce]\n                            Platform [500] [60] type: [normal]\n                            Platform [550] [60] type: [bounce]\n                            Platform [700] [60] type: [bad]\n                            Platform [800] [60] type: [bounce]\n                            Platform [900] [60] type: [bounce]\n                            Platform [1000] [60] type: [bad]\n                            Platform [1100] [60] type: [normal]\n                            Platform [1120] [70] type: [normal]\n                            Platform [1140] [80] type: [normal]\n                            Platform [1160] [90] type: [bad]\n                            Platform [1180] [100] type: [normal]\n                            Platform [1180] [120] type: [normal]\n                            Platform [1180] [140] type: [normal]\n                            Platform [1200] [160] type: [end]\n                        else\n                            if <(level) = [7]> then\n                                Platform [500] [10] type: [bounce]\n                                Platform [650] [0] type: [normal]\n                                Platform [700] (((40) * ([cos v] of (((3) * (deltacos)) / (3)) )) - (30)) type: [normal]\n                                Platform [750] (((40) * ([sin v] of (((3) * (deltacos)) / (3)) )) - (30)) type: [normal]\n                                Platform [800] (((40) * ([cos v] of (((3) * (deltacos)) / (3)) )) - (30)) type: [bounce]\n                                Platform [1000] (((40) * ([sin v] of (((3) * (deltacos)) / (3)) )) - (30)) type: [bounce]\n                                Platform [1000] (((40) * ([sin v] of (((3) * (deltacos)) / (3)) )) - (50)) type: [bad]\n                                Platform [1200] (((40) * ([cos v] of (((3) * (deltacos)) / (3)) )) - (50)) type: [normal]\n                                Platform [1200] (((40) * ([cos v] of (((3) * (deltacos)) / (3)) )) - (70)) type: [bounce]\n                                Platform [1200] (((40) * ([cos v] of (((3) * (deltacos)) / (3)) )) - (90)) type: [normal]\n                                Platform [1200] (((40) * ([cos v] of (((3) * (deltacos)) / (3)) )) - (110)) type: [normal]\n                                Platform [1200] (((40) * ([cos v] of (((3) * (deltacos)) / (3)) )) - (130)) type: [bad]\n                                Platform [1200] (((40) * ([cos v] of (((3) * (deltacos)) / (3)) )) - (130)) type: [end]\n                                Platform [1200] [10] type: [normal]\n                            else\n                                if <(level) = [8]> then\n                                    Platform [700] (((80) * ([cos v] of (((3) * (deltacos)) / (3)) )) - (30)) type: [bounce]\n                                    Platform [750] (((40) * ([sin v] of (((3) * (deltacos)) / (3)) )) - (30)) type: [bad]\n                                    Platform [800] (((109) * ([cos v] of (((3) * (deltacos)) / (3)) )) - (30)) type: [normal]\n                                    Platform [1000] (((70) * ([sin v] of (((3) * (deltacos)) / (3)) )) - (30)) type: [bounce]\n                                    Platform [1000] (((40) * ([sin v] of (((3) * (deltacos)) / (3)) )) - (50)) type: [normal]\n                                    Platform [1200] (((80) * ([cos v] of (((3) * (deltacos)) / (3)) )) - (50)) type: [bounce]\n                                    Platform [1200] (((40) * ([cos v] of (((3) * (deltacos)) / (3)) )) - (70)) type: [bounce]\n                                    Platform [1200] (((20) * ([cos v] of (((3) * (deltacos)) / (3)) )) - (90)) type: [bounce]\n                                    Platform [1200] (((40) * ([cos v] of (((3) * (deltacos)) / (3)) )) - (110)) type: [bounce]\n                                    Platform [1200] (((40) * ([cos v] of (((3) * (deltacos)) / (3)) )) - (130)) type: [bounce]\n                                    Platform [1200] (((40) * ([cos v] of (((3) * (deltacos)) / (3)) )) - (130)) type: [normal]\n                                end\n                            end\n                        end\n                    end\n                end\n            end\n        end\n    end\nend\n\ndefine RotationLine: (x1) (y1) (z1) to (x2) (y2) (z2) with an angle of: (θy)\nLine From (((x1) * (([cos v] of (θx) ) * ([cos v] of ((θy) + (θy)) ))) + (((y1) * ((([cos v] of (θx) ) * (([sin v] of ((θy) + (θy)) ) * ([sin v] of (θz) ))) - (([sin v] of (θx) ) * ([cos v] of (θz) )))) + ((z1) * ((([cos v] of (θx) ) * (([sin v] of ((θy) + (θy)) ) * ([cos v] of (θz) ))) + (([sin v] of (θx) ) * ([sin v] of (θz) )))))) (((x1) * (([sin v] of (θx) ) * ([cos v] of ((θy) + (θy)) ))) + (((y1) * ((([sin v] of (θx) ) * (([sin v] of ((θy) + (θy)) ) * ([sin v] of (θz) ))) + (([cos v] of (θx) ) * ([cos v] of (θz) )))) + ((z1) * ((([sin v] of (θx) ) * (([sin v] of ((θy) + (θy)) ) * ([cos v] of (θz) ))) - (([cos v] of (θx) ) * ([sin v] of (θz) )))))) (((x1) * ((-1) * ([sin v] of ((θy) + (θy)) ))) + (((y1) * (([cos v] of ((θy) + (θy)) ) * ([sin v] of (θz) ))) + ((z1) * (([cos v] of ((θy) + (θy)) ) * ([cos v] of (θz) ))))) to (((x2) * (([cos v] of (θx) ) * ([cos v] of ((θy) + (θy)) ))) + (((y2) * ((([cos v] of (θx) ) * (([sin v] of ((θy) + (θy)) ) * ([sin v] of (θz) ))) - (([sin v] of (θx) ) * ([cos v] of (θz) )))) + ((z2) * ((([cos v] of (θx) ) * (([sin v] of ((θy) + (θy)) ) * ([cos v] of (θz) ))) + (([sin v] of (θx) ) * ([sin v] of (θz) )))))) (((x2) * (([sin v] of (θx) ) * ([cos v] of ((θy) + (θy)) ))) + (((y2) * ((([sin v] of (θx) ) * (([sin v] of ((θy) + (θy)) ) * ([sin v] of ((θy) + (θy)) ))) + (([cos v] of (θx) ) * ([cos v] of (θz) )))) + ((z2) * ((([sin v] of (θx) ) * (([sin v] of ((θy) + (θy)) ) * ([cos v] of (θz) ))) - (([cos v] of (θx) ) * ([sin v] of (θz) )))))) (((x2) * ((-1) * ([sin v] of ((θy) + (θy)) ))) + (((y2) * (([cos v] of ((θy) + (θy)) ) * ([sin v] of (θz) ))) + ((z2) * (([cos v] of ((θy) + (θy)) ) * ([cos v] of (θz) )))))\n\ndefine start\nset [camx v] to [-30]\nset [camy v] to [-700]\nset [camz v] to [555]\nset [x vel v] to [0]\nset [y vel v] to [0]\nset [θy v] to [-280]\nset [deltacos v] to [0]\n\nwhen flag clicked\nset [level v] to [1]\nforever\n    if <(CamY) > [-300]> then\n        start\n    end\nend\n\ndefine Platform (y shift) (placementangle) type: (type)\nif < (type) contains [normal]?> then\n    set pen color to (#ffc60e)\nelse\n    if < (type) contains [end]?> then\n        set pen color to (#21e800)\n    else\n        if < (type) contains [bad]?> then\n            set pen color to (#ff0000)\n        else\n            if < (type) contains [bounce]?> then\n                set pen color to (#0090ff)\n            else\n                if < (type) contains [teleport]?> then\n                    set pen color to (#ff00d0)\n                else\n                    if < (type) contains [special]?> then\n                        set pen color to (#faff00)\n                    end\n                end\n            end\n        end\n    end\nend\nRotationLine: [500] (y shift) ((0) + (xshift)) to ((470) + (xshift)) (y shift) ((0) + (xshift)) with an angle of: (placementangle)\nRotationLine: [470] (y shift) ((0) + (xshift)) to ((470) + (xshift)) (y shift) ((60) + (xshift)) with an angle of: (placementangle)\nRotationLine: [470] (y shift) ((60) + (xshift)) to ((500) + (xshift)) (y shift) ((60) + (xshift)) with an angle of: (placementangle)\nRotationLine: [500] (y shift) ((60) + (xshift)) to ((500) + (xshift)) (y shift) ((0) + (xshift)) with an angle of: (placementangle)\n\nwhen I receive [message1 v]\nstart\n\nwhen I receive [message2 v]\nstart\n\nwhen flag clicked\nswitch costume to (costume1 v)\ncreate clone of (_myself_ v)\n\nwhen I start as a clone\nswitch costume to (costume2 v)\nforever\n    go to x: (0) y: (0)\nend\n\nwhen I receive [message1 v]\nchange [level v] by (0.5)\nwait (0.000001) seconds\nbroadcast (message3 v)\n\nwhen flag clicked\nforever\n    change [deltacos v] by (1)\nend\n\nwhen flag clicked\nforever\n    if <(level) = [1]> then\n        if <not <(touchyellow) = [true]>> then\n            Platform [300] [10] type: [special]\n        else\n            stop [this script v]\n        end\n    end\nend\n\nwhen flag clicked\nforever\n    if <(level) = [2]> then\n        if <not <(touchyellow) = [true]>> then\n            Platform [300] [-103] type: [special]\n        else\n            stop [this script v]\n        end\n    end\nend\n\nwhen flag clicked\nforever\n    if <(level) = [3]> then\n        if <not <(touchyellow) = [true]>> then\n            Platform [1400] [120] type: [special]\n        else\n            stop [this script v]\n        end\n    end\nend\n\nwhen flag clicked\nforever\n    if <(level) = [4]> then\n        if <not <(touchyellow) = [true]>> then\n            Platform [296] (((40) * ([sin v] of (((12) * (deltacos)) / (3)) )) - (29)) type: [special]\n        else\n            stop [this script v]\n        end\n    end\nend\n\nwhen flag clicked\nforever\n    if <(level) = [5]> then\n        if <not <(touchyellow) = [true]>> then\n            Platform [300] [10] type: [special]\n        else\n            stop [this script v]\n        end\n    end\nend\n\nwhen I receive [optionstart v]\nstart\n\nwhen flag clicked\nforever\n    if <(level) = [6]> then\n        if <not <(touchyellow) = [true]>> then\n            Platform [490] [60] type: [special]\n        else\n            stop [this script v]\n        end\n    end\nend\n\nPlatform [1250] [180] type: [bounce]\nPlatform [1210] [190] type: [bad]\n\nwhen flag clicked\nforever\n    if <(level) = [7]> then\n        if <not <(touchyellow) = [true]>> then\n            Platform [500] (((40) * ([cos v] of (((6) * (deltacos)) / (3)) )) - (130)) type: [special]\n        else\n            stop [this script v]\n        end\n    end\nend\n\nset [level v] to [7]\n\nPlatform [700] [10] type: [bad]\nPlatform [880] [10] type: [bad]\n\nPlatform [1050] [10] type: [bad]\nPlatform [1050] [15] type: [bad]\nPlatform [1050] [5] type: [bad]\nPlatform [1100] [10] type: [normal]\nPlatform [500] [10] type: [bounce]\nPlatform [900] [10] type: [bounce]\nPlatform [710] [10] type: [bounce]\nPlatform [1100] [60] type: [normal]\nPlatform [1100] [80] type: [normal]\nPlatform [1100] [100] type: [normal]\nPlatform [1100] [120] type: [end]\nPlatform [350] [10] type: [bad]\nPlatform [250] [10] type: [bad]\n\nset [level v] to [6]\n\nPlatform [800] [-10] type: [bounce]\nPlatform [950] [-20] type: [bounce]\nPlatform [1100] [-30] type: [bounce]\nPlatform [1250] [-40] type: [bounce]\nPlatform [1400] [-50] type: [bounce]\nPlatform [1550] [-60] type: [bounce]\nPlatform [1800] [-30] type: [bounce]\nPlatform [2000] [-40] type: [bounce]\nPlatform [2200] [-50] type: [bounce]\nPlatform [2400] [-60] type: [bounce]\n\nforever\n\nset [level v] to [7]\n\nif <(level) = [7]> then\n    change [deltacos v] by (1)\nend\n\n@3D Physics\n\ndefine Physics (gravity) (friction) (jumpheight) (speed) <touching>\nchange [camy v] by (y vel)\nchange [θy v] by (x vel)\nif <(menu) = [802]> then\n    if <touching> then\n        repeat ([abs v] of (y vel) )\n            if <touching> then\n                change [camy v] by ((([abs v] of (y vel) ) / (y vel)) * (-1))\n            end\n            set [y vel v] to [0]\n        end\n        if <key (up arrow v) pressed?> then\n            change [y vel v] by ((jumpheight) * (-1))\n        end\n        if <touching color (#0090ff)?> then\n            set [y vel v] to [-12]\n        end\n    else\n        change [y vel v] by ((gravity) * (-1))\n    end\n    set [x vel v] to ((x vel) * (friction))\n    if <key (right arrow v) pressed?> then\n        change [x vel v] by (speed)\n    end\n    if <key (left arrow v) pressed?> then\n        change [x vel v] by ((speed) * (-1))\n    end\n    if <touching color (#20e800)?> then\n        broadcast (message1 v)\n    end\n    if <touching color (#ff0000)?> then\n        broadcast (message2 v)\n    end\n    if <<touching color (#ff00cf)?> and <(level) = [4]>> then\n        set [θy v] to [-370]\n    end\nend\n\nwhen flag clicked\nbroadcast (start v)\n\nwhen I receive [start v]\nset [y vel v] to [0]\nset x to (0)\nforever\n    go to x: ((0) + ((x vel) * (15))) y: (-75)\n    Physics [-0.3] [0.9] [5] [0.1] <<<touching color (#ffc50e)?> or <touching color (#0090ff)?>> or <touching color (#fff600)?>>\n    if <(menu) = [801]> then\n        set [y vel v] to [0]\n        set [x vel v] to [0]\n    end\nend\n\nwhen flag clicked\nforever\n    if <touching color (#faff00)?> then\n        set [touchyellow v] to [true]\n    else\n        set [touchyellow v] to [false]\n    end\nend\n\n@Graphics\n\nwhen flag clicked\nstart graphics\n\ndefine start graphics\nclear graphic effects\nset [brightness v] effect to (100)\nwait (2) seconds\nrepeat (34)\n    change [pixelate v] effect by (3)\n    change [ghost v] effect by (3)\nend\n\nwhen I receive [message3 v]\nstart graphics\n\nwhen I receive [optionstart v]\nstart graphics\n\nwhen flag clicked\nforever\n    switch costume to (level)\nend\n\nswitch costume to (level)\n\n@Assets\n\nwhen flag clicked\nset [numberlevels v] to [7]\nset [touchgreen v] to [91]\nset [menu v] to [802]\ngo to x: (-95) y: (50)\nswitch costume to (1ns v)\nshow\nrepeat (4)\n    create clone of (_myself_ v)\n    next costume\n    change x by (60)\nend\ngo to x: (-95) y: (-10)\ncreate clone of (_myself_ v)\nchange x by (60)\nnext costume\ncreate clone of (_myself_ v)\nchange x by (60)\nnext costume\ncreate clone of (_myself_ v)\nhide\n\nwhen I start as a clone\ngo to [front v] layer\nset rotation style [don't rotate v]\npoint in direction (y position)\nforever\n    set y to ((direction) + ((-1) * (([y position v] of [slider v]) - (55))))\n    if <touching (mouse-pointer v)?> then\n        set size to (160) %\n        set [brightness v] effect to (20)\n    else\n        set size to (150) %\n        set [brightness v] effect to (0)\n    end\n    if <(y position) > [103]> then\n        set [ghost v] effect to (100)\n    else\n        set [ghost v] effect to (0)\n    end\n    if <(menu) = [801]> then\n        show\n    else\n        hide\n    end\n    if <(costume [number v]) < (((numberlevels) * (3)) + (1))> then\n        if <<(touchyellow) = [true]> and < (costume [name v]) contains (level)?>> then\n            switch costume to ((costume [number v]) + (numberlevels))\n        end\n        if <<(touchgreen) = [90]> and <(((costume [number v]) mod (numberlevels)) + (<((costume [number v]) mod (numberlevels)) = [0]> * (numberlevels))) = ((level) - (1))>> then\n            switch costume to ((costume [number v]) + ((2) * (numberlevels)))\n        end\n    end\n    if <<touching (mouse-pointer v)?> and <mouse down?>> then\n        set [level v] to (((letter (1) of (costume [name v])) + ()) - (0))\n        broadcast (optionstart v)\n        set [menu v] to [802]\n    end\nend\n\nwhen I receive [menu v]\nset [menu v] to [801]\n\nwhen I receive [message1 v]\nset [touchgreen v] to [90]\nwait (1) seconds\nset [touchgreen v] to [91]\n\nif <<<<(costume [number v]) > (numberlevels)> or <(costume [number v]) < (((2) * (numberlevels)) + (1))>> and <(touchgreen) = [90]>> and <(costume [number v]) = ((level) - (1))>> then\n    switch costume to ((costume [number v]) + ((2) * (numberlevels)))\nend\n\n@Layouts\n\nwhen flag clicked\ngo to x: (0) y: (0)\nswitch costume to (costume1 v)\ncreate clone of (_myself_ v)\nforever\n    if <(menu) = [801]> then\n        show\n    else\n        hide\n    end\nend\n\nwhen I start as a clone\ngo to x: (0) y: (0)\nswitch costume to (costume2 v)\nforever\n    go to [front v] layer\n    if <(menu) = [801]> then\n        show\n    else\n        hide\n    end\nend\n\n@Slider\n\nwhen flag clicked\nset y to (55)\nset x to (150)\ngo to [front v] layer\nforever\n    if <touching (mouse-pointer v)?> then\n        set [brightness v] effect to (20)\n    else\n        set [brightness v] effect to (0)\n    end\n    if <<mouse down?> and <touching (mouse-pointer v)?>> then\n        set y to (mouse y)\n        if <(y position) > [55]> then\n            set y to (55)\n        end\n        if <[-80] > (y position)> then\n            set y to (-80)\n        end\n    end\n    if <(menu) = [801]> then\n        show\n    else\n        hide\n    end\nend\n\n@Buttons\n\nwhen flag clicked\ngo to x: (215) y: (-154)\nset rotation style [don't rotate v]\nswitch costume to (costume1 v)\nforever\n    if <<touching (mouse-pointer v)?> = [1]> then\n        set [ghost v] effect to (50)\n    else\n        set [ghost v] effect to (0)\n    end\n    if <<(<touching (mouse-pointer v)?> * <mouse down?>) = [1]> or <key (space v) pressed?>> then\n        broadcast (menu v)\n    end\nend\n\nset [ghost v] effect to (50)\n\nwhen I start as a clone\nforever\n    go to [front v] layer\n    if <(direction) = [90]> then\n        switch costume to (costume2 v)\n        go to x: (-136) y: (-100)\n        if <<touching (mouse-pointer v)?> = [1]> then\n            set [ghost v] effect to (50)\n        else\n            set [ghost v] effect to (0)\n        end\n        if <(menu) = [801]> then\n            show\n        else\n            hide\n        end\n        if <(<touching (mouse-pointer v)?> * <mouse down?>) = [1]> then\n            set [menu v] to [802]\n            broadcast (message2 v)\n        end\n    end\nend\n\nwhen flag clicked\nhide\npoint in direction (90)\ncreate clone of (_myself_ v)\n\nwhen I receive [optionstart v]\nshow\n\n@Thumbnail\n\nwhen flag clicked\ngo to x: (0) y: (0)\nrepeat until <key (space v) pressed?>\n    show\nend\nrepeat (50)\n    change [pixelate v] effect by (2)\n    change [ghost v] effect by (2)\nend\nhide\n\nwhen [timer v] > (0.1)\nclear graphic effects\ngo to [front v] layer\nshow\n\nwhen flag clicked\nforever\n    reset timer\nend\n\ngo to [front v] layer\n\n@startbutton\n\nwhen flag clicked\nshow\ngo to x: (0) y: (-150)\nset [ghost v] effect to (100)\nset [pixelate v] effect to (100)\nwait (0.2) seconds\nrepeat (25)\n    change [ghost v] effect by (-4)\n    change [pixelate v] effect by (-4)\nend\n\nwhen flag clicked\nrepeat until <key (space v) pressed?>\n    go to [front v] layer\n    show\nend\nrepeat (5)\n    change [ghost v] effect by (-20)\nend\nhide\n\n