Wizard || A Platformer #Games


@Stage\n\nwhen I receive [clearalllists v]\nset [save code v] to []\ndelete all of [aboveblocktype v]\ndelete all of [aboveblockx v]\ndelete all of [aboveblocky v]\ndelete all of [blocktype v]\ndelete all of [blockx v]\ndelete all of [blocky v]\ndelete all of [bombx v]\ndelete all of [bomby v]\ndelete all of [breakx v]\ndelete all of [breaky v]\ndelete all of [deleteblocklist v]\ndelete all of [deleteenemylist v]\ndelete all of [deleteitemlist v]\ndelete all of [enemydir v]\ndelete all of [enemyextra v]\ndelete all of [enemystate v]\ndelete all of [enemytype v]\ndelete all of [enemyx v]\ndelete all of [enemyy v]\ndelete all of [enemyyvel v]\ndelete all of [entype v]\ndelete all of [enx v]\ndelete all of [eny v]\ndelete all of [hotbar v]\ndelete all of [itemdirection v]\ndelete all of [itemlist v]\ndelete all of [itemstate v]\ndelete all of [itemtype v]\ndelete all of [itemx v]\ndelete all of [itemy v]\ndelete all of [itemyvelocity v]\ndelete all of [particlemakedir v]\ndelete all of [particlemaketype v]\ndelete all of [particlemakex v]\ndelete all of [particlemakey v]\ndelete all of [pipedir v]\ndelete all of [pipetype v]\ndelete all of [pipex v]\ndelete all of [pipey v]\ndelete all of [semitype v]\ndelete all of [semix v]\ndelete all of [semiy v]\ndelete all of [uniquebounce v]\ndelete all of [uniquestate v]\ndelete all of [uniquetype v]\ndelete all of [uniquex v]\ndelete all of [uniquey v]\ndelete all of [untype v]\ndelete all of [unx v]\ndelete all of [uny v]\ndelete all of [enkey v]\ndelete all of [enemykey v]\ndelete all of [pipestate v]\n\nwhen flag clicked\nstart sound [Home v]\nforever\n    wait (0.1) seconds\n    if <<<<(EditMode) = [0]> and <(AllowMovement) = [1]>> and <<(Dead) = [0]> and <(HitGoal) = [0]>>> and <(Menu) = [0]>> then\n        wait (0.1) seconds\n        if <<(Timer) < [100]> and <(HurryUpPlayed?) = [0]>> then\n            if <(EditMode) = [0]> then\n                set [hurryupplayed? v] to [1]\n                play sound [100 Seconds v] until done\n            end\n        else\n            if <(StarTimer) > [0]> then\n                if <(EditMode) = [0]> then\n                    play sound [Star v] until done\n                end\n            else\n                if <(PTimer) > [0]> then\n                    if <(EditMode) = [0]> then\n                        play sound [PSwitch v] until done\n                    end\n                else\n                    if <<<(EditMode) = [0]> and <(AllowMovement) = [1]>> and <<(Dead) = [0]> and <(HitGoal) = [0]>>> then\n                        if <<(CurrentTheme) = [1]> or <(CurrentTheme) = [6]>> then\n                            if <(EditMode) = [0]> then\n                                play sound [1/6 v] until done\n                            end\n                        end\n                        if <<(CurrentTheme) = [2]> or <(CurrentTheme) = [5]>> then\n                            if <(EditMode) = [0]> then\n                                play sound [2/5 v] until done\n                            end\n                        end\n                        if <<(CurrentTheme) = [4]> or <(CurrentTheme) = [12]>> then\n                            if <(EditMode) = [0]> then\n                                play sound [4/12 v] until done\n                            end\n                        end\n                        if <(CurrentTheme) = [7]> then\n                            if <(EditMode) = [0]> then\n                                play sound [7 v] until done\n                            end\n                        end\n                        if <(CurrentTheme) = [3]> then\n                            if <(EditMode) = [0]> then\n                                play sound [3 v] until done\n                            end\n                        end\n                        if <(CurrentTheme) = [9]> then\n                            if <(EditMode) = [0]> then\n                                play sound [9 v] until done\n                            end\n                        end\n                        if <(CurrentTheme) = [10]> then\n                            if <(EditMode) = [0]> then\n                                play sound [10 v] until done\n                            end\n                        end\n                        if <(CurrentTheme) = [11]> then\n                            if <(EditMode) = [0]> then\n                                play sound [11 v] until done\n                            end\n                        end\n                    end\n                end\n            end\n        end\n    end\nend\n\n@Empty\n\nbroadcast (Save Code v)\n\nbroadcast (ClearLevel v)\n\n@Player\n\nwhen I receive [player update v]\nshow\nset [movedbyconveyer v] to [0]\nchange [gametimer v] by (0.01)\nset [noclipping v] to [0]\nchange y by (1)\nif <(EditMode) = [0]> then\n    go to x: ((PlayerX) + (MapX)) y: ((PlayerY) + (MapY))\n    set rotation style [don't rotate v]\n    if <<<(y position) < [-168]> or <(((y position) - (MapY)) / (32)) < (CurrentLavaLevel)>> and <<(Dead) = [0]> and <<(AllowMovement) = [1]> and <(AllowControl) = [1]>>>> then\n        broadcast (Death v)\n        broadcast (Environment Update v)\n        stop [this script v]\n    end\n    if <(StarTimer) > [0]> then\n        change [startimer v] by ((-1) / (30))\n        set [color v] effect to ((round ((((GameTimer) * (720)) mod (200)) / (25))) * (25))\n        if <(StarTimer) < [0]> then\n            set [startimer v] to [0]\n            stop all sounds\n            clear graphic effects\n        end\n    end\n    if <(AllowControl) = [1]> then\n        change [timer v] by ((-1) / (30))\n        if <<((Timer) + ((1) / (30))) > [100]> and <(Timer) < [100]>> then\n            stop all sounds\n        end\n        if <(Timer) < [0]> then\n            set [timer v] to [0]\n            broadcast (Death v)\n        end\n    end\n    if <(AllowMovement) = [1]> then\n        if <(PTimer) > [0]> then\n            change [ptimer v] by ((-1) / (30))\n            if <(PTimer) < [0]> then\n                set [ptimer v] to [0]\n                stop all sounds\n            end\n        end\n        if <(MaintainClimbing) = [1]> then\n            set [crouching v] to [0]\n            if <(Powerup) = [None]> then\n                set [small v] to [1]\n            else\n                set [small v] to [0]\n            end\n            PlayerHitboxSwitch\n            Climbing\n        else\n            set [small v] to [0]\n            if <(Crouching) = [1]> then\n                switch costume to (standhitbox v)\n                change y by (2)\n                if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n                    switch costume to (crouchhitbox v)\n                    set [small v] to [1]\n                else\n                    set [crouching v] to [0]\n                end\n                change y by (-2)\n            end\n            PlayerHitboxSwitch\n            if <(((y position) - (MapY)) / (32)) < (CurrentWaterLevel)> then\n                if <(Powerup) = [J]> then\n                    FrogMovement\n                else\n                    SwimmingYMovement\n                end\n            else\n                YMovement\n                if <(y position) > [160]> then\n                    set y to (160)\n                end\n                PlayerHitboxSwitch\n                XMovement\n            end\n            if <<(Drifting) = [1]> and <((GameTimer) mod (0.02)) < [0.01]>> then\n                add ((((x position) + ((XVel) * (-5))) - (MapX)) / (32)) to [particlemakex v]\n                add ((((y position) - (18)) - (MapY)) / (32)) to [particlemakey v]\n                add [Drift] to [particlemaketype v]\n                start sound [skid v]\n            end\n        end\n    end\nend\nset [playerx v] to ((x position) - (MapX))\nset [playery v] to ((y position) - (MapY))\nset y to ((round (y position)) - (1))\nif <<(MaintainClimbing) = [0]> and <(Climbing) = [1]>> then\n    set [climbing v] to [0]\n    if <<key (w v) pressed?> or <key (up arrow v) pressed?>> then\n        set [yvel v] to [3]\n    end\nend\nset [maintainclimbing v] to [0]\nbroadcast (Environment Update v)\n\ndefine XMovement\nset [drifting v] to [0]\nif <(SlidingExtra) > [0]> then\n    set [xvel v] to ((XVel) / (1.08))\nelse\n    if <(Crouching) = [1]> then\n        set [xvel v] to ((XVel) / (1.1))\n    else\n        if <<key (space v) pressed?> and <(AllowControl) = [1]>> then\n            set [xvel v] to ((XVel) / (1.2))\n        else\n            set [xvel v] to ((XVel) / (1.3))\n        end\n    end\nend\nif <<<<key (a v) pressed?> or <key (left arrow v) pressed?>> and <not <<key (d v) pressed?> or <key (right arrow v) pressed?>>>> and <(AllowControl) = [1]>> then\n    if <<(YVel) = [0]> or <<(YVel) = (Gravity)> or <<(RaccoonFloat) > [0]> or <(RaccoonFlight) > [0]>>>> then\n        point in direction (-90)\n    end\n    if <<(Crouching) = [0]> and <(SlidingExtra) = [0]>> then\n        if <<key (space v) pressed?> and <(AllowControl) = [1]>> then\n            change [xvel v] by (-1.2)\n            if <<(XVel) > [-1.2]> and <<(YVel) = [0]> or <(YVel) = (Gravity)>>> then\n                change [xvel v] by (1.15)\n                set [drifting v] to [1]\n            end\n        else\n            change [xvel v] by (-0.8)\n            if <<(XVel) > [-0.7]> and <<(YVel) = [0]> or <(YVel) = (Gravity)>>> then\n                change [xvel v] by (0.799)\n                set [drifting v] to [1]\n            end\n        end\n    end\nend\nif <<<<key (d v) pressed?> or <key (right arrow v) pressed?>> and <not <<key (a v) pressed?> or <key (left arrow v) pressed?>>>> and <(AllowControl) = [1]>> then\n    if <<(YVel) = [0]> or <<(YVel) = (Gravity)> or <<(RaccoonFloat) > [0]> or <(RaccoonFlight) > [0]>>>> then\n        point in direction (90)\n    end\n    if <<(Crouching) = [0]> and <(SlidingExtra) = [0]>> then\n        if <<key (space v) pressed?> and <(AllowControl) = [1]>> then\n            change [xvel v] by (1.2)\n            if <<(XVel) < [1.2]> and <<(YVel) = [0]> or <(YVel) = (Gravity)>>> then\n                change [xvel v] by (-1.15)\n                set [drifting v] to [1]\n            end\n        else\n            change [xvel v] by (0.8)\n            if <<(XVel) < [0.7]> and <<(YVel) = [0]> or <(YVel) = (Gravity)>>> then\n                change [xvel v] by (-0.799)\n                set [drifting v] to [1]\n            end\n        end\n    end\nend\nif <(RaccoonFlight) > [0]> then\n    if <([abs v] of (XVel) ) > [5.8]> then\n        set [xvel v] to ((([abs v] of (XVel) ) / (XVel)) * (5.8))\n    end\nend\nif <<<<(Powerup) = [J]> and <<(Crouching) = [0]> and <(SlidingExtra) = [0]>>> and <<(YVel) = [0]> or <(YVel) = (Gravity)>>> and <((((PlayerTimer) * (15)) mod (3)) + (1)) < [1.4]>> then\n    set [xvel v] to ((XVel) / (2))\nend\nset rotation style [don't rotate v]\nchange x by ((XVel) + (ConveyorXVel))\nPlayerHitboxSwitchSides\nset [xoffset v] to [0]\nif <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n    YSmoothing\nend\nif <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n    XSides\nend\nset [conveyorxvel v] to [0]\n\nwhen flag clicked\nswitch costume to (idlenone v)\nset size to (400) %\nset rotation style [left-right v]\nset [levelbyme? v] to [1]\nset [savingprocess v] to [0]\nset [originalspawnx v] to [0]\nset [originalspawny v] to [-64]\nset [goalx v] to [0]\nset [goaly v] to [-1]\nset [spawnx v] to [0]\nset [spawny v] to [-64]\nset [gametimer v] to [0]\nset [editmode v] to [0]\nset [itemlistno. v] to [1]\nset [itemmenu v] to [0]\nset [itemlistselected v] to [0]\nset [invincible v] to [0]\nset [groundlevel v] to [0]\nset [-1theme v] to [2]\nset [0theme v] to [1]\nset [1theme v] to [3]\nset [-1camera v] to [1]\nset [0camera v] to [1]\nset [1camera v] to [1]\nset [-1water v] to [-1]\nset [0water v] to [-1]\nset [1water v] to [-1]\nset [-1lava v] to [-1]\nset [0lava v] to [-1]\nset [1lava v] to [-1]\nset [fullleveltimer v] to [300]\nset [startimer v] to [0]\nset [hurryupplayed? v] to [0]\nset [startimer v] to [0]\nset [ptimer v] to [0]\ngo to x: (0) y: (0)\nbroadcast (ClearAllLists v) and wait\nHotbar\nItemList\n\ndefine YCeiling\nset [offset v] to [0]\nrepeat until <not <<touching (blocks v)?> or <touching (uniqueblocks v)?>>>\n    change [offset v] by (0.5)\n    change y by (-0.5)\n    if <(Offset) > [15]> then\n        set y to ((PlayerY) + (MapY))\n        stop [this script v]\n    end\nend\n\ndefine YFloor\nset [offset v] to [0]\nrepeat until <not <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <<not <(YVel) > [0]>> and <touching (semisolids v)?>>>>\n    change [offset v] by (0.5)\n    change y by (0.5)\n    if <(Offset) > [15]> then\n        set y to ((PlayerY) + (MapY))\n        stop [this script v]\n    end\nend\n\ndefine XSides\nset [offset v] to [-0.5]\nif <(((y position) - (MapY)) / (32)) < (CurrentWaterLevel)> then\n    set [xvel v] to ((XVel) / (2))\nelse\n    if <(ConveyorXVel) = [0]> then\n        if <key (space v) pressed?> then\n            set [xvel v] to ((XVel) / (25))\n        else\n            set [xvel v] to ((XVel) / (17))\n        end\n    else\n        set [xvel v] to ((XVel) / (1.2))\n    end\nend\nset [playerx v] to ((x position) - (MapX))\nrepeat until <<not <<touching (blocks v)?> or <touching (uniqueblocks v)?>>> or <(Offset) > [48]>>\n    change [offset v] by (0.5)\n    set [xoffset v] to (Offset)\n    set x to ((PlayerX) + (MapX))\n    change x by ((Offset) * (-1))\n    if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n        set x to ((PlayerX) + (MapX))\n        change x by (Offset)\n    else\n        stop [this script v]\n    end\nend\nif <(Offset) > [48]> then\n    set x to ((PlayerX) + (MapX))\n    set [xoffset v] to (Offset)\n    set [noclipping v] to [1]\n    stop [this script v]\nend\n\ndefine YMovement\nif <(YVel) > [-14]> then\n    change [yvel v] by (Gravity)\n    if <<(YVel) > [0]> and <not <<<key (w v) pressed?> or <key (up arrow v) pressed?>> and <(AllowControl) = [1]>>>> then\n        set [yvel v] to ((YVel) / (1.1))\n        if <(YVel) > [12]> then\n            set [yvel v] to ((YVel) / (1.8))\n        end\n    end\nelse\n    set [raccoonflightactive v] to [0]\nend\nif <(RaccoonWCooldown) = [1]> then\n    if <not <<key (w v) pressed?> or <key (up arrow v) pressed?>>> then\n        set [raccoonwcooldown v] to [0]\n    end\nend\nif <(RaccoonSpaceCooldown) = [1]> then\n    if <not <key (space v) pressed?>> then\n        set [raccoonspacecooldown v] to [0]\n    end\nend\nif <<<(Powerup) = [R]> and <(AllowControl) = [1]>> and <<(Holding) = [0]> and <<(Climbing) = [0]> and <<(Crouching) = [0]> and <(SlidingExtra) = [0]>>>>> then\n    if <(YVel) < [-2]> then\n        if <<<key (w v) pressed?> or <key (up arrow v) pressed?>> and <(RaccoonWCooldown) = [0]>> then\n            start sound [Float v]\n            set [raccoonfloat v] to [1]\n            set [raccoonwcooldown v] to [1]\n        end\n    end\n    if <(RaccoonFloat) > [0]> then\n        if <(YVel) > [6]> then\n            set [yvel v] to ((YVel) / (1.1))\n        end\n        if <(YVel) < [-2]> then\n            set [yvel v] to [-2]\n        end\n        change [raccoonfloat v] by (-0.1)\n        if <(RaccoonFloat) < [0]> then\n            set [raccoonfloat v] to [0]\n        end\n    end\n    if <(RaccoonFlightActive) = [1]> then\n        if <<<key (w v) pressed?> or <key (up arrow v) pressed?>> and <(RaccoonWCooldown) = [0]>> then\n            start sound [Float v]\n            set [raccoonflight v] to [1]\n            set [raccoonwcooldown v] to [1]\n        end\n        if <(RaccoonFlight) > [0]> then\n            if <(YVel) < [5]> then\n                set [yvel v] to [5]\n            end\n            change [raccoonflight v] by (-0.1)\n            if <(RaccoonFlight) < [0]> then\n                set [raccoonflight v] to [0]\n            end\n        end\n    end\n    if <<key (space v) pressed?> and <<(RaccoonSpaceCooldown) = [0]> and <(RaccoonSpin) = [0]>>> then\n        start sound [Spin v]\n        set [raccoonspin v] to [1]\n        set [raccoonspacecooldown v] to [1]\n        set [raccoonfloat v] to [0]\n        set [raccoonflight v] to [0]\n        set [playertimer v] to [0]\n        broadcast (SpinAttack v)\n    end\n    if <(RaccoonSpin) > [0]> then\n        change [raccoonspin v] by (-0.09)\n        if <(RaccoonSpin) < [0]> then\n            set [raccoonspin v] to [0]\n        end\n    end\nelse\n    set [raccoonfloat v] to [0]\n    set [raccoonflight v] to [0]\n    set [raccoonflightactive v] to [0]\n    set [raccoonspin v] to [0]\nend\nif <<(ThrowCooldown) = [0.2]> and <not <key (space v) pressed?>>> then\n    set [throwcooldown v] to [0]\nend\nif <<<<(Powerup) = [F]> or <(Powerup) = [H]>> and <(AllowControl) = [1]>> and <<(Holding) = [0]> and <<(Climbing) = [0]> and <<(Crouching) = [0]> and <(SlidingExtra) = [0]>>>>> then\n    if <<key (space v) pressed?> and <(ThrowCooldown) = [0]>> then\n        if <(Powerup) = [F]> then\n            start sound [Fireball v]\n            add (((x position) - (MapX)) / (32)) to [enemyx v]\n            add ((((y position) + (8)) - (MapY)) / (32)) to [enemyy v]\n            add [k] to [enemytype v]\n            add [0] to [enemystate v]\n            add [0] to [enemyyvel v]\n            add [0] to [enemyextra v]\n            add ((direction) / (1.5)) to [enemydir v]\n            add [0] to [enemykey v]\n        else\n            add (((x position) - (MapX)) / (32)) to [enemyx v]\n            add ((((y position) + (16)) - (MapY)) / (32)) to [enemyy v]\n            add [u] to [enemytype v]\n            add [0] to [enemystate v]\n            add [13] to [enemyyvel v]\n            add [0] to [enemyextra v]\n            add (direction) to [enemydir v]\n            add [0] to [enemykey v]\n        end\n        set [throwcooldown v] to [1]\n        set [playertimer v] to [0]\n    end\n    if <(ThrowCooldown) > [0]> then\n        change [throwcooldown v] by (-0.1)\n        if <(ThrowCooldown) < [0.2]> then\n            set [throwcooldown v] to [0.2]\n        end\n    end\nelse\n    set [throwcooldown v] to [0]\nend\nif <(YVel) > [0]> then\n    if <(Powerup) = [None]> then\n        switch costume to (risehitbox v)\n    end\nelse\n    switch costume to (fallhitbox v)\nend\nchange y by ((YVel) / (2))\nif <(YVel) > [0]> then\n    if <not <<touching (blocks v)?> or <touching (uniqueblocks v)?>>> then\n        change y by ((YVel) / (2))\n    end\nelse\n    if <not <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <touching (semisolids v)?>>> then\n        change y by ((YVel) / (2))\n    end\nend\nif <(YVel) > [0]> then\n    if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n        set [yvel v] to [1.1]\n        YCeiling\n    end\nelse\n    if <(YVel) > [-5]> then\n        change y by (-4)\n        if <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <touching (semisolids v)?>> then\n            GoingDownScript\n        else\n            change y by (4)\n        end\n    else\n        if <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <touching (semisolids v)?>> then\n            GoingDownScript\n        end\n    end\nend\nif <(SlidingExtra) > [0]> then\n    change [slidingextra v] by (-0.05)\n    if <<(SlidingExtra) < [0]> or <not <<key (s v) pressed?> or <key (down arrow v) pressed?>>>> then\n        set [slidingextra v] to [0]\n    end\nend\nif <<(YVel) = [0]> or <(YVel) = (Gravity)>> then\n    if <<<key (s v) pressed?> or <key (down arrow v) pressed?>> and <(AllowControl) = [1]>> then\n        Sliding\n        PlayerHitboxSwitch\n    else\n        if <<<key (w v) pressed?> or <key (up arrow v) pressed?>> and <(AllowControl) = [1]>> then\n            start sound [jump v]\n            set [yvel v] to (((15.2) + (([abs v] of (XVel) ) / (5.4))) + (<(Powerup) = [J]> * (2)))\n            if <(Crouching) = [1]> then\n                set [yvel v] to (Gravity)\n                change y by (24)\n                if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n                    if <([abs v] of (XVel) ) < [1]> then\n                        set [yvel v] to [4]\n                        change [xvel v] by ((direction) / (30))\n                    end\n                else\n                    set [yvel v] to (((15.2) + (([abs v] of (XVel) ) / (5.4))) + (<(Powerup) = [J]> * (2)))\n                    set [crouching v] to [0]\n                    set [small v] to [0]\n                end\n                change y by (-24)\n            else\n                if <<([abs v] of (XVel) ) > [7.19]> and <(Powerup) = [R]>> then\n                    set [raccoonflightactive v] to [1]\n                end\n            end\n        end\n    end\nend\n\ndefine YSmoothing\nif <(YVel) < [1]> then\n    set [offset v] to [0]\n    set [playery v] to ((y position) - (MapY))\n    repeat until <<not <<touching (blocks v)?> or <touching (uniqueblocks v)?>>> or <(Offset) > ((16) + ([abs v] of (XVel) ))>>\n        change [offset v] by (0.5)\n        set y to ((PlayerY) + (MapY))\n        change y by (Offset)\n    end\n    if <(Offset) > ((16) + ([abs v] of (XVel) ))> then\n        set y to ((PlayerY) + (MapY))\n    end\nend\n\nwhen I receive [costuming v]\nset rotation style [left-right v]\nif <<(RaccoonSpin) > [0]> or <(ThrowCooldown) > [0.5]>> then\n    change [playertimer v] by (0.01)\nelse\n    change [playertimer v] by ((0.01) + (([abs v] of (XVel) ) / (1000)))\nend\nif <(Kicked) > [0]> then\n    change [kicked v] by (-0.1)\n    if <(Kicked) < [0]> then\n        set [kicked v] to [0]\n    end\nend\nif <(Dead) = [1]> then\n    switch costume to (deadnone v)\nelse\n    if <(UsingDoor) = [0]> then\n        if <(Holding) = [0]> then\n            if <(Powerup) = [J]> then\n                FrogCostumes\n            else\n                if <(((y position) - (MapY)) / (32)) < (CurrentWaterLevel)> then\n                    SwimmingCostumes\n                else\n                    RegularCostumes\n                end\n            end\n        else\n            HoldCostumes\n        end\n    else\n        if <([abs v] of (UsingDoor) ) > [0]> then\n            switch costume to (join [Walk] (join (Powerup) (([floor v] of (((PlayerTimer) * ((15) + (<not <(Powerup) = [None]>> * (5)))) mod ((2) + (<not <(Powerup) = [None]>> * (2)))) ) + (1))))\n        end\n        if <([abs v] of (UsingDoor) ) > [0.75]> then\n            switch costume to (join [Idle] (Powerup))\n            set [playertimer v] to [0.07]\n        end\n        if <(UsingDoor) < [0.75]> then\n            set [brightness v] effect to ((((UsingDoor) * (1.33)) * (100)) - (100))\n        end\n        if <(UsingDoor) < [0]> then\n            set [brightness v] effect to (((UsingDoor) * (1.33)) * (100))\n        end\n        if <(UsingDoor) > [0]> then\n            change [usingdoor v] by (-0.05)\n            if <(UsingDoor) < [0]> then\n                set [usingdoor v] to [0]\n                clear graphic effects\n            end\n        end\n        if <(UsingDoor) < [0]> then\n            change [usingdoor v] by (0.05)\n            if <(UsingDoor) > [0]> then\n                set [usingdoor v] to [0]\n                clear graphic effects\n            end\n        end\n    end\nend\n\nwhen [e v] key pressed\nstop all sounds\nset [showfullhud v] to [1]\nset [ptimer v] to [0]\nset [startimer v] to [0]\nset [justedited v] to [0]\nset [hurryupplayed? v] to [0]\nset [levelbyme? v] to [1]\nif <<(PlacingPipes) = [0]> or <(EditMode) = [0]>> then\n    broadcast (StartLoop v)\n    if <(EditMode) = [0]> then\n        set [editmode v] to [1]\n        if <(y position) < [-120]> then\n            set y to (0)\n        end\n        if <([abs v] of (x position) ) > [100]> then\n            set x to (0)\n        end\n    else\n        set [spawnx v] to (OriginalSpawnX)\n        set [spawny v] to (OriginalSpawnY)\n        set [editmode v] to [0]\n    end\n    Convert\n    BasicReset\n    clear graphic effects\n    set [itemmenu v] to [0]\nend\n\nwhen [f v] key pressed\nset [justedited v] to [0]\nif <<(PlacingPipes) = [0]> and <not <(EditMode) = [0]>>> then\n    change [itemlistno. v] by (1)\n    if <(ItemListNo.) > (length of [itemlist v])> then\n        set [itemlistno. v] to [1]\n    end\n    set [costumeselected v] to (item (ItemListNo.) of [itemlist v])\nend\n\ndefine Convert\nset [redblueswitch v] to [0]\ndelete all of [itemdirection v]\ndelete all of [itemstate v]\ndelete all of [itemtype v]\ndelete all of [itemx v]\ndelete all of [itemy v]\ndelete all of [itemyvelocity v]\ndelete all of [enemyyvel v]\ndelete all of [enemystate v]\ndelete all of [enemytype v]\ndelete all of [enemyx v]\ndelete all of [enemyy v]\ndelete all of [enemydir v]\ndelete all of [enemyextra v]\ndelete all of [uniquebounce v]\ndelete all of [uniquestate v]\ndelete all of [uniquetype v]\ndelete all of [uniquex v]\ndelete all of [uniquey v]\ndelete all of [enemykey v]\ndelete all of [pipestate v]\nset [offset v] to [0]\nrepeat (length of [enx v])\n    change [offset v] by (1)\n    add (item (Offset) of [enx v]) to [enemyx v]\n    add (item (Offset) of [eny v]) to [enemyy v]\n    add (item (Offset) of [entype v]) to [enemytype v]\n    add (item (Offset) of [enkey v]) to [enemykey v]\n    add [0] to [enemystate v]\n    add [0] to [enemyyvel v]\n    add [-90] to [enemydir v]\n    add [0] to [enemyextra v]\nend\nset [offset v] to [0]\nrepeat (length of [unx v])\n    change [offset v] by (1)\n    add (item (Offset) of [unx v]) to [uniquex v]\n    add (item (Offset) of [uny v]) to [uniquey v]\n    if <(item (Offset) of [untype v]) = ["]> then\n        add ["] to [uniquetype v]\n    else\n        add (item (Offset) of [untype v]) to [uniquetype v]\n    end\n    add [0] to [uniquestate v]\n    add [0] to [uniquebounce v]\nend\nset [offset v] to [0]\nrepeat (length of [pipex v])\n    add [0] to [pipestate v]\nend\n\ndefine FindEnemyAt (x) (y)\nset [scanno. v] to [0]\nrepeat (length of [enx v])\n    change [scanno. v] by (1)\n    if <<(item (ScanNo.) of [enx v]) = (x)> and <(item (ScanNo.) of [eny v]) = (y)>> then\n        set [foundposition v] to [1]\n        stop [this script v]\n    end\nend\n\ndefine ItemList\ndelete all of [itemlist v]\nadd [1] to [itemlist v]\nadd [2] to [itemlist v]\nadd [3] to [itemlist v]\nadd [8] to [itemlist v]\nadd [!] to [itemlist v]\nadd [.] to [itemlist v]\nadd [$C] to [itemlist v]\nadd [$M] to [itemlist v]\nadd [$F] to [itemlist v]\nadd [$R] to [itemlist v]\nadd [$J] to [itemlist v]\nadd [$H] to [itemlist v]\nadd [$\(] to [itemlist v]\nadd [$o] to [itemlist v]\nadd [$S] to [itemlist v]\nadd [$U] to [itemlist v]\nadd [!C] to [itemlist v]\nadd [!M] to [itemlist v]\nadd [!F] to [itemlist v]\nadd [!R] to [itemlist v]\nadd [!J] to [itemlist v]\nadd [!H] to [itemlist v]\nadd [!\(] to [itemlist v]\nadd [!o] to [itemlist v]\nadd [!S] to [itemlist v]\nadd [!U] to [itemlist v]\nadd [,C] to [itemlist v]\nadd [,\(] to [itemlist v]\nadd [,U] to [itemlist v]\nadd ["] to [itemlist v]\nadd [*] to [itemlist v]\nadd [6] to [itemlist v]\nadd [\(] to [itemlist v]\nadd [%] to [itemlist v]\nadd [&] to [itemlist v]\nadd [4] to [itemlist v]\nadd [5] to [itemlist v]\nadd [7] to [itemlist v]\nadd [9] to [itemlist v]\nadd [10] to [itemlist v]\nadd [11] to [itemlist v]\nadd [12] to [itemlist v]\nadd [13] to [itemlist v]\nadd [14] to [itemlist v]\nadd [25] to [itemlist v]\nadd [23] to [itemlist v]\nadd [26] to [itemlist v]\nadd [24] to [itemlist v]\nadd [27] to [itemlist v]\nadd [15] to [itemlist v]\nadd [22] to [itemlist v]\nadd [16] to [itemlist v]\nadd [19] to [itemlist v]\nadd [18] to [itemlist v]\nadd [20] to [itemlist v]\nadd [28] to [itemlist v]\nadd [21] to [itemlist v]\nadd [a] to [itemlist v]\nadd [b] to [itemlist v]\nadd [e] to [itemlist v]\nadd [h] to [itemlist v]\nadd [i] to [itemlist v]\nadd [v] to [itemlist v]\nadd [d] to [itemlist v]\nadd [w] to [itemlist v]\nadd [f] to [itemlist v]\nadd [m] to [itemlist v]\nadd [s] to [itemlist v]\nadd [p] to [itemlist v]\nadd [n] to [itemlist v]\nadd [\)] to [itemlist v]\nadd [/] to [itemlist v]\nadd [17] to [itemlist v]\nadd [£1] to [itemlist v]\nadd [£2] to [itemlist v]\nadd [£3] to [itemlist v]\nadd [£4] to [itemlist v]\nadd [£7] to [itemlist v]\nadd [£8] to [itemlist v]\nadd [£5] to [itemlist v]\nadd [£6] to [itemlist v]\nadd [£9] to [itemlist v]\nadd [£10] to [itemlist v]\nadd [Key] to [itemlist v]\nadd [o] to [itemlist v]\nadd [+] to [itemlist v]\nadd ['] to [itemlist v]\nadd [#] to [itemlist v]\nadd [Water] to [itemlist v]\nadd [Lava] to [itemlist v]\nadd [Spawn] to [itemlist v]\nadd [-] to [itemlist v]\nadd [Goal] to [itemlist v]\n\ndefine Hotbar\ndelete all of [hotbar v]\nadd [1] to [hotbar v]\nadd [2] to [hotbar v]\nadd [!] to [hotbar v]\nadd [.] to [hotbar v]\nadd [4] to [hotbar v]\nadd [a] to [hotbar v]\nadd [b] to [hotbar v]\nadd [Goal] to [hotbar v]\nset [costumeselected v] to (item (ItemListNo.) of [hotbar v])\n\nwhen I receive [respawn v]\npoint in direction (90)\nclear graphic effects\nset [startimer v] to [0]\nset [ptimer v] to [0]\nset [hurryupplayed? v] to [0]\nset [gametimer v] to [0]\nset [mapx v] to ((SpawnX) * (-1))\nset [mapy v] to ((SpawnY) * (-1))\nset [playerx v] to (SpawnX)\nset [playery v] to (SpawnY)\nset [groundlevel v] to [0]\nset [coins v] to [0]\nif <(PlayerY) > [1124]> then\n    set [groundlevel v] to [1]\nend\nif <(PlayerY) < [-163]> then\n    set [groundlevel v] to [-1]\nend\nBasicReset\nConvert\ngo to x: ((SpawnX) + (MapX)) y: ((SpawnY) + (MapY))\nbroadcast (MapLimitsCheck v)\nwait (0) seconds\ngo to x: ((SpawnX) + (MapX)) y: ((SpawnY) + (MapY))\nBasicReset\ngo to x: ((SpawnX) + (MapX)) y: ((SpawnY) + (MapY))\n\nwhen I receive [powerup v]\nset [invincible v] to [1]\nif <not <(Powerup) = [R]>> then\n    set [raccoonfloat v] to [0]\nend\nset [crouching v] to [1]\nset [ghost v] effect to (100)\nwait (0.2) seconds\nset [ghost v] effect to (0)\nwait (0.2) seconds\nset [ghost v] effect to (100)\nwait (0.2) seconds\nset [ghost v] effect to (0)\nwait (0.2) seconds\nset [ghost v] effect to (100)\nwait (0.2) seconds\nset [ghost v] effect to (0)\nwait (0.4) seconds\nset [invincible v] to [0]\n\nwhen I receive [powerdown v]\nset [raccoonfloat v] to [0]\nif <(Powerup) = [None]> then\n    broadcast (Death v)\nelse\n    start sound [PowerDown v]\n    if <(Powerup) = [M]> then\n        set [powerup v] to [None]\n        set [crouching v] to [0]\n    else\n        set [powerup v] to [M]\n    end\n    set [invincible v] to [1]\n    set [ghost v] effect to (100)\n    wait (0.2) seconds\n    set [ghost v] effect to (0)\n    wait (0.2) seconds\n    set [ghost v] effect to (100)\n    wait (0.2) seconds\n    set [ghost v] effect to (0)\n    wait (0.2) seconds\n    set [ghost v] effect to (100)\n    wait (0.2) seconds\n    set [ghost v] effect to (0)\n    wait (0.4) seconds\n    set [invincible v] to [0]\nend\n\ndefine PlayerHitboxSwitch\nif <(Crouching) = [1]> then\n    switch costume to (crouchhitbox v)\n    set [small v] to [1]\nelse\n    switch costume to (standhitbox v)\n    if <(Powerup) = [None]> then\n        if <(YVel) > [0]> then\n            switch costume to (risehitbox v)\n        else\n            switch costume to (fallhitbox v)\n        end\n        set [small v] to [1]\n    end\nend\n\nwhen I receive [usepipe v]\ngo [backward v] (24) layers\nset [allowcontrol v] to [0]\nset [allowmovement v] to [0]\nset [usingpipe v] to [1]\nset [yvel v] to [0]\nset [crouching v] to [0]\nset [drifting v] to [0]\nif <<(StarTimer) = [0]> and <(PTimer) = [0]>> then\n    stop all sounds\nend\nif <(letter (1) of (item (PipeUsingNo.) of [pipedir v])) = [D]> then\n    set [xvel v] to [0]\n    if <(letter (2) of (item (PipeUsingNo.) of [pipedir v])) = [o]> then\n        set [playerx v] to ((item (PipeUsingNo.) of [pipex v]) * (32))\n        set [usingdoor v] to [1]\n        wait (0.6) seconds\n    else\n        set [xvel v] to [0]\n        set [playerx v] to (((item (PipeUsingNo.) of [pipex v]) * (32)) - (16))\n        repeat (15)\n            change [playery v] by (-2)\n        end\n        change [playery v] by (-1)\n    end\nend\nif <(letter (1) of (item (PipeUsingNo.) of [pipedir v])) = [U]> then\n    set [xvel v] to [0]\n    set [playerx v] to (((item (PipeUsingNo.) of [pipex v]) * (32)) - (16))\n    repeat (15)\n        change [playery v] by (2)\n    end\n    change [playery v] by (1)\nend\nif <<(item (PipeUsingNo.) of [pipedir v]) = [L1]> or <(item (PipeUsingNo.) of [pipedir v]) = [L2]>> then\n    set [xvel v] to [-2]\n    repeat (15)\n        change [playerx v] by (-2)\n    end\nend\nif <<(item (PipeUsingNo.) of [pipedir v]) = [R1]> or <(item (PipeUsingNo.) of [pipedir v]) = [R2]>> then\n    set [xvel v] to [2]\n    repeat (15)\n        change [playerx v] by (2)\n    end\nend\nbroadcast (PipeFadeFast v)\nwait (0.1) seconds\nset [gametimer v] to [0]\nset [mapx v] to ((PipeDestinationX) * (-1))\nset [mapy v] to ((PipeDestinationY) * (-1))\nset [playerx v] to (PipeDestinationX)\nset [playery v] to (PipeDestinationY)\nset [groundlevel v] to [0]\nif <(PlayerY) > [1124]> then\n    set [groundlevel v] to [1]\nend\nif <(PlayerY) < [-163]> then\n    set [groundlevel v] to [-1]\nend\nwait (0) seconds\nif <<(StarTimer) = [0]> and <(PTimer) = [0]>> then\n    stop all sounds\nend\nif <(letter (1) of (item (PipeDestinationNo.) of [pipedir v])) = [D]> then\n    set [xvel v] to [0]\n    if <(letter (2) of (item (PipeDestinationNo.) of [pipedir v])) = [o]> then\n        change [playery v] by (2)\n        set [usingdoor v] to [-1]\n        wait (0.6) seconds\n    else\n        change [playery v] by (-30)\n        repeat (15)\n            change [playery v] by (2)\n        end\n    end\nend\nif <(letter (1) of (item (PipeDestinationNo.) of [pipedir v])) = [U]> then\n    set [xvel v] to [0]\n    change [playery v] by (30)\n    repeat ((26) - (<(Powerup) = [None]> * (11)))\n        change [playery v] by (-2)\n    end\nend\nif <<(item (PipeDestinationNo.) of [pipedir v]) = [L1]> or <(item (PipeDestinationNo.) of [pipedir v]) = [L2]>> then\n    set [xvel v] to [-2]\n    change [playery v] by (1)\n    change [playerx v] by (-14)\n    repeat (15)\n        change [playerx v] by (2)\n    end\nend\nif <<(item (PipeDestinationNo.) of [pipedir v]) = [R1]> or <(item (PipeDestinationNo.) of [pipedir v]) = [R2]>> then\n    set [xvel v] to [2]\n    change [playery v] by (1)\n    change [playerx v] by (44)\n    repeat (15)\n        change [playerx v] by (-2)\n    end\nend\nset [xvel v] to [0]\nset [yvel v] to [-0.1]\nset [usingpipe v] to [0]\nset [allowcontrol v] to [1]\nset [allowmovement v] to [1]\ngo to [back v] layer\ngo [forward v] (8) layers\nif <not <(Powerup) = [None]>> then\n    switch costume to (standhitbox v)\n    change y by (2)\n    if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n        switch costume to (standnone v)\n        if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n            change y by (26)\n            if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n                change y by (-26)\n            else\n                change [playery v] by (26)\n                set [crouching v] to [1]\n            end\n        else\n            set [crouching v] to [1]\n        end\n    end\n    change y by (-2)\nend\n\ndefine HoldCostumes\nif <not <<(YVel) = [0]> or <(YVel) = (Gravity)>>> then\n    switch costume to (join [HoldJump] (Powerup))\n    set [playertimer v] to [0.07]\nelse\n    if <([abs v] of (XVel) ) > [0.05]> then\n        switch costume to (join [HoldRun] (join (Powerup) (([floor v] of (((PlayerTimer) * ((15) + (<not <(Powerup) = [None]>> * (5)))) mod ((2) + (<not <(Powerup) = [None]>> * (2)))) ) + (1))))\n    else\n        switch costume to (join [HoldIdle] (Powerup))\n        set [playertimer v] to [0.07]\n    end\nend\n\ndefine RegularCostumes\nif <(MaintainClimbing) = [1]> then\n    switch costume to (join [Climb] (join (Powerup) (([floor v] of (((PlayerTimer) * (15)) mod (2)) ) + (1))))\nelse\n    if <<(SlidingExtra) > [0]> and <([abs v] of (XVel) ) > [1]>> then\n        switch costume to (join [Slide] (Powerup))\n    else\n        if <(ThrowCooldown) > [0.2]> then\n            if <(Powerup) = [H]> then\n                if <not <<(YVel) = [0]> or <(YVel) = (Gravity)>>> then\n                    switch costume to (join [ThrowH] (([floor v] of (((PlayerTimer) * (20)) mod (2)) ) + (3)))\n                else\n                    switch costume to (join [ThrowH] (([floor v] of (((PlayerTimer) * (20)) mod (2)) ) + (1)))\n                end\n            else\n                if <not <<(YVel) = [0]> or <(YVel) = (Gravity)>>> then\n                    switch costume to (join [Throw] (([floor v] of (((PlayerTimer) * (20)) mod (2)) ) + (3)))\n                else\n                    switch costume to (join [Throw] (([floor v] of (((PlayerTimer) * (20)) mod (2)) ) + (1)))\n                end\n            end\n        else\n            if <(RaccoonSpin) > [0]> then\n                switch costume to (join [Spin] (([floor v] of (((PlayerTimer) * (40)) mod (4)) ) + (1)))\n            else\n                if <(RaccoonFlight) > [0]> then\n                    switch costume to (join [Fly] (([floor v] of (((PlayerTimer) * (30)) mod (4)) ) + (1)))\n                else\n                    if <(RaccoonFloat) > [0]> then\n                        switch costume to (join [Float] (([floor v] of (((PlayerTimer) * (30)) mod (4)) ) + (1)))\n                    else\n                        if <(Crouching) = [1]> then\n                            switch costume to (join [Crouch] (Powerup))\n                        else\n                            if <not <<(YVel) = [0]> or <(YVel) = (Gravity)>>> then\n                                if <([abs v] of (XVel) ) > [7.19]> then\n                                    switch costume to (join [Glide] (Powerup))\n                                else\n                                    switch costume to (join [Jump] (Powerup))\n                                end\n                                set [playertimer v] to [0.07]\n                            else\n                                if <(Drifting) = [1]> then\n                                    switch costume to (join [Drift] (Powerup))\n                                    set [playertimer v] to [0.07]\n                                else\n                                    if <(Kicked) > [0]> then\n                                        switch costume to (join [Kick] (Powerup))\n                                    else\n                                        if <([abs v] of (XVel) ) > [0.05]> then\n                                            if <([abs v] of (XVel) ) > [7.19]> then\n                                                switch costume to (join [Run] (join (Powerup) (([floor v] of (((PlayerTimer) * ((20) + (<not <(Powerup) = [None]>> * (5)))) mod ((2) + (<not <(Powerup) = [None]>> * (2)))) ) + (1))))\n                                            else\n                                                switch costume to (join [Walk] (join (Powerup) (([floor v] of (((PlayerTimer) * ((15) + (<not <(Powerup) = [None]>> * (5)))) mod ((2) + (<not <(Powerup) = [None]>> * (2)))) ) + (1))))\n                                            end\n                                        else\n                                            switch costume to (join [Idle] (Powerup))\n                                            set [playertimer v] to [0.07]\n                                        end\n                                    end\n                                end\n                            end\n                        end\n                    end\n                end\n            end\n        end\n    end\nend\n\ndefine Climbing\nset [yvel v] to ((YVel) / (2))\nset [xvel v] to ((XVel) / (2))\nif <<key (w v) pressed?> or <key (up arrow v) pressed?>> then\n    change [yvel v] by (1)\nend\nif <<key (s v) pressed?> or <key (down arrow v) pressed?>> then\n    change [yvel v] by (-1)\nend\nif <<key (d v) pressed?> or <key (right arrow v) pressed?>> then\n    change [xvel v] by (1)\nend\nif <<key (a v) pressed?> or <key (left arrow v) pressed?>> then\n    change [xvel v] by (-1)\nend\nif <(YVel) > [0]> then\n    if <(Powerup) = [None]> then\n        switch costume to (risehitbox v)\n    end\nelse\n    switch costume to (fallhitbox v)\nend\nchange y by ((YVel) / (2))\nif <(YVel) > [0]> then\n    if <not <<touching (blocks v)?> or <touching (uniqueblocks v)?>>> then\n        change y by ((YVel) / (2))\n    end\nelse\n    if <not <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <touching (semisolids v)?>>> then\n        change y by ((YVel) / (2))\n    end\nend\nif <(YVel) > [0]> then\n    if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n        set [yvel v] to [1.1]\n        YCeiling\n    end\nelse\n    if <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <touching (semisolids v)?>> then\n        if <(YVel) > [-5]> then\n            change y by (-4)\n            if <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <touching (semisolids v)?>> then\n                GoingDownScript\n            else\n                change y by (4)\n            end\n        else\n            if <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <touching (semisolids v)?>> then\n                GoingDownScript\n            end\n        end\n        set [maintainclimbing v] to [0]\n    end\nend\nif <(y position) > [160]> then\n    set y to (160)\nend\nset [drifting v] to [0]\nPlayerHitboxSwitchSides\nchange x by ((XVel) + (ConveyorXVel))\nset [xoffset v] to [0]\nif <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n    YSmoothing\nend\nif <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n    XSides\nend\nset [conveyorxvel v] to [0]\n\ndefine BasicReset\ngo to [back v] layer\ngo [forward v] (8) layers\nset [startimer v] to [0]\nset [hitgoal v] to [0]\nset [xvel v] to [0]\nset [yvel v] to (Gravity)\nset [crouching v] to [0]\nset [powerup v] to [None]\nset [usingpipe v] to [0]\nset [holding v] to [0]\nset [climbing v] to [0]\nset [maintainclimbing v] to [0]\nset [coins v] to [0]\nset [timer v] to (FullLevelTimer)\nset [dead v] to [0]\nset [keys v] to [0]\nset [redblueswitch v] to [0]\nset [allowcontrol v] to [0]\nif <(EditMode) = [0]> then\n    broadcast (BriefInvincibility v)\nend\n\nwhen I receive [death v]\nset [invincible v] to [1]\nset [allowcontrol v] to [0]\nset [allowmovement v] to [0]\nset [dead v] to [1]\nstop all sounds\nstart sound [Death v]\nwait (1) seconds\nif <(Dead) = [0]> then\n    stop [this script v]\nend\nset [yvel v] to [12]\ngo to [front v] layer\ngo [backward v] (13) layers\nif <(y position) < [-160]> then\n    wait (1.5) seconds\nelse\n    repeat (45)\n        change [yvel v] by (-1)\n        change [playery v] by (YVel)\n        if <(Dead) = [0]> then\n            stop [this script v]\n        end\n    end\nend\ngo to [back v] layer\ngo [forward v] (9) layers\nset [invincible v] to [0]\nbroadcast (FadeFast v)\nwait (0.5) seconds\nbroadcast (Respawn v)\nConvert\n\nwhen I receive [briefinvincibility v]\nset [invincible v] to [1]\nset [allowmovement v] to [0]\nset [allowcontrol v] to [0]\nwait (0.3) seconds\nset [allowmovement v] to [1]\nset [allowcontrol v] to [1]\nset [ghost v] effect to (100)\nwait (0.2) seconds\nset [ghost v] effect to (0)\nwait (0.2) seconds\nset [ghost v] effect to (100)\nwait (0.2) seconds\nset [ghost v] effect to (0)\nwait (0.2) seconds\nset [invincible v] to [0]\n\nwhen I receive [startlevelfull v]\nset [spawnx v] to (OriginalSpawnX)\nset [spawny v] to (OriginalSpawnY)\nset [editmode v] to [0]\nset [allowcontrol v] to [0]\nbroadcast (Respawn v)\n\nwhen [q v] key pressed\nset [justedited v] to [0]\nif <<(PlacingPipes) = [0]> and <not <(EditMode) = [0]>>> then\n    change [editmode v] by (1)\n    if <(EditMode) > [3]> then\n        set [editmode v] to [1]\n    end\nend\n\nwhen I receive [goal v]\nset [hitgoal v] to [1]\nset [allowcontrol v] to [0]\nset [invincible v] to [1]\nset [xvel v] to [0]\nset [climbing v] to [0]\nset [maintainclimbing v] to [0]\nstop all sounds\nstart sound [Goal v]\nwait until <<<(YVel) = [0]> or <(YVel) = (Gravity)>> or <<(y position) < [50]> or <(HitGoal) = [0]>>>\nrepeat (120)\n    if <not <(EditMode) = [0]>> then\n        set [yvel v] to [0]\n        set [xvel v] to [0]\n        stop [this script v]\n    end\n    point in direction (90)\n    set [xvel v] to [3]\n    if <(((y position) - (MapY)) / (32)) < (CurrentWaterLevel)> then\n        if <(y position) < [-20]> then\n            set [yvel v] to [6]\n        end\n    end\nend\nBasicReset\nif <(LevelByMe?) = [1]> then\n    broadcast (FadeOutInstant v)\n    broadcast (Respawn v)\n    set [editmode v] to [1]\n    go to x: ((SpawnX) + (MapX)) y: ((SpawnY) + (MapY))\nelse\n    broadcast (PipeFadeFast v)\n    broadcast (ReturnToMenu v)\n    stop all sounds\nend\n\nwhen I receive [menuupdate v]\nif <[1] = [1]> then\n    delete this clone\nend\nhide\n\ndefine SwimmingYMovement\nif <(YVel) = [1.1]> then\n    set [yvel v] to [0.7]\nend\nif <(YVel) > [-3]> then\n    change [yvel v] by ((Gravity) / (3))\n    if <<(YVel) > [0]> and <not <<<key (w v) pressed?> or <key (up arrow v) pressed?>> and <(AllowControl) = [1]>>>> then\n        set [yvel v] to ((YVel) / (1.1))\n    end\nend\nif <(YVel) > [8]> then\n    set [yvel v] to [8]\nend\nif <(YVel) < [-3]> then\n    set [yvel v] to [-3]\nend\nif <(RaccoonSpaceCooldown) = [1]> then\n    if <not <key (space v) pressed?>> then\n        set [raccoonspacecooldown v] to [0]\n    end\nend\nif <<<(Powerup) = [R]> and <(AllowControl) = [1]>> and <<(Holding) = [0]> and <<(Climbing) = [0]> and <<(Crouching) = [0]> and <(SlidingExtra) = [0]>>>>> then\n    if <<key (space v) pressed?> and <<(RaccoonSpaceCooldown) = [0]> and <(RaccoonSpin) = [0]>>> then\n        set [raccoonspin v] to [1]\n        start sound [Spin v]\n        set [raccoonspacecooldown v] to [1]\n        set [raccoonfloat v] to [0]\n        set [raccoonflight v] to [0]\n        set [playertimer v] to [0]\n        broadcast (SpinAttack v)\n    end\n    if <(RaccoonSpin) > [0]> then\n        change [raccoonspin v] by (-0.09)\n        if <(RaccoonSpin) < [0]> then\n            set [raccoonspin v] to [0]\n        end\n    end\nelse\n    set [raccoonspin v] to [0]\nend\nif <<(ThrowCooldown) = [0.2]> and <not <key (space v) pressed?>>> then\n    set [throwcooldown v] to [0]\nend\nif <<<<(Powerup) = [F]> or <(Powerup) = [H]>> and <(AllowControl) = [1]>> and <<(Holding) = [0]> and <<(Climbing) = [0]> and <<(Crouching) = [0]> and <(SlidingExtra) = [0]>>>>> then\n    if <<key (space v) pressed?> and <(ThrowCooldown) = [0]>> then\n        if <(Powerup) = [F]> then\n            start sound [Fireball v]\n            add (((x position) - (MapX)) / (32)) to [enemyx v]\n            add ((((y position) + (8)) - (MapY)) / (32)) to [enemyy v]\n            add [k] to [enemytype v]\n            add [0] to [enemystate v]\n            add [0] to [enemyyvel v]\n            add [0] to [enemyextra v]\n            add ((direction) / (1.5)) to [enemydir v]\n            add [0] to [enemykey v]\n        else\n            add (((x position) - (MapX)) / (32)) to [enemyx v]\n            add ((((y position) + (16)) - (MapY)) / (32)) to [enemyy v]\n            add [u] to [enemytype v]\n            add [0] to [enemystate v]\n            add [13] to [enemyyvel v]\n            add [0] to [enemyextra v]\n            add (direction) to [enemydir v]\n            add [0] to [enemykey v]\n        end\n        set [throwcooldown v] to [1]\n        set [playertimer v] to [0]\n    end\n    if <(ThrowCooldown) > [0]> then\n        change [throwcooldown v] by (-0.1)\n        if <(ThrowCooldown) < [0.2]> then\n            set [throwcooldown v] to [0.2]\n        end\n    end\nelse\n    set [throwcooldown v] to [0]\nend\nset [raccoonfloat v] to [0]\nset [raccoonflight v] to [0]\nset [raccoonflightactive v] to [0]\nif <(YVel) > [0]> then\n    if <(Powerup) = [None]> then\n        switch costume to (risehitbox v)\n    end\nelse\n    switch costume to (fallhitbox v)\nend\nchange y by ((YVel) / (2))\nif <(YVel) > [0]> then\n    if <not <<touching (blocks v)?> or <touching (uniqueblocks v)?>>> then\n        change y by ((YVel) / (2))\n    end\nelse\n    if <not <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <touching (semisolids v)?>>> then\n        change y by ((YVel) / (2))\n    end\nend\nif <(YVel) > [0]> then\n    if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n        set [yvel v] to [1.1]\n        YCeiling\n    end\nelse\n    if <(YVel) > [-5]> then\n        change y by (-4)\n        if <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <touching (semisolids v)?>> then\n            GoingDownScript\n        else\n            change y by (4)\n        end\n    else\n        if <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <touching (semisolids v)?>> then\n            GoingDownScript\n        end\n    end\n    set [maintainclimbing v] to [0]\nend\nif <(SlidingExtra) > [0]> then\n    change [slidingextra v] by (-0.05)\n    if <<(SlidingExtra) < [0]> or <not <<key (s v) pressed?> or <key (down arrow v) pressed?>>>> then\n        set [slidingextra v] to [0]\n    end\nend\nif <<<<key (s v) pressed?> or <key (down arrow v) pressed?>> and <(AllowControl) = [1]>> and <<(YVel) = [0]> or <(YVel) = (Gravity)>>> then\n    Sliding\n    PlayerHitboxSwitch\nelse\n    if <<<key (w v) pressed?> or <key (up arrow v) pressed?>> and <<(AllowControl) = [1]> and <(YVel) < [1]>>> then\n        if <not <((round ((YVel) * (10))) / (10)) = [0.4]>> then\n            start sound [swim v]\n        end\n        set [yvel v] to ((4.2) + (([abs v] of (XVel) ) / (5.4)))\n        if <(Crouching) = [1]> then\n            set [yvel v] to (Gravity)\n            change y by (24)\n            if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n                if <([abs v] of (XVel) ) < [1]> then\n                    set [yvel v] to [4]\n                    change [xvel v] by ((direction) / (30))\n                end\n            else\n                set [yvel v] to ((4.2) + (([abs v] of (XVel) ) / (5.4)))\n                set [crouching v] to [0]\n                set [small v] to [0]\n            end\n            change y by (-24)\n        else\n            if <<([abs v] of (XVel) ) > [7.19]> and <(Powerup) = [R]>> then\n                set [raccoonflightactive v] to [1]\n            end\n        end\n    end\nend\nif <not <(((y position) - (MapY)) / (32)) < (CurrentWaterLevel)>> then\n    if <<<key (w v) pressed?> or <key (up arrow v) pressed?>> and <(AllowControl) = [1]>> then\n        set [yvel v] to [8]\n    end\nend\nif <(y position) > [170]> then\n    set y to (170)\nend\nSwimmingXMovement\n\ndefine SwimmingXMovement\nset [drifting v] to [0]\nif <(SlidingExtra) > [0]> then\n    set [xvel v] to ((XVel) / (1.1))\nelse\n    if <(Crouching) = [1]> then\n        set [xvel v] to ((XVel) / (1.1))\n    else\n        if <key (space v) pressed?> then\n            set [xvel v] to ((XVel) / (1.14))\n        else\n            set [xvel v] to ((XVel) / (1.2))\n        end\n    end\nend\nif <<<<key (a v) pressed?> or <key (left arrow v) pressed?>> and <not <<key (d v) pressed?> or <key (right arrow v) pressed?>>>> and <(AllowControl) = [1]>> then\n    if <<(YVel) = [0]> or <<(YVel) = (Gravity)> or <(XVel) < [0]>>> then\n        point in direction (-90)\n    end\n    if <<(Crouching) = [0]> and <(SlidingExtra) = [0]>> then\n        if <<key (space v) pressed?> and <(AllowControl) = [1]>> then\n            change [xvel v] by (-0.6)\n            if <<(XVel) > [-0.6]> and <<(YVel) = [0]> or <(YVel) = (Gravity)>>> then\n                change [xvel v] by (0.55)\n                set [drifting v] to [1]\n            end\n        else\n            change [xvel v] by (-0.4)\n            if <<(XVel) > [-0.4]> and <<(YVel) = [0]> or <(YVel) = (Gravity)>>> then\n                change [xvel v] by (0.39)\n                set [drifting v] to [1]\n            end\n        end\n    end\nend\nif <<<<key (d v) pressed?> or <key (right arrow v) pressed?>> and <not <<key (a v) pressed?> or <key (left arrow v) pressed?>>>> and <(AllowControl) = [1]>> then\n    if <<(YVel) = [0]> or <<(YVel) = (Gravity)> or <(XVel) > [0]>>> then\n        point in direction (90)\n    end\n    if <<(Crouching) = [0]> and <(SlidingExtra) = [0]>> then\n        if <<key (space v) pressed?> and <(AllowControl) = [1]>> then\n            change [xvel v] by (0.6)\n            if <<(XVel) < [0.6]> and <<(YVel) = [0]> or <(YVel) = (Gravity)>>> then\n                change [xvel v] by (-0.55)\n                set [drifting v] to [1]\n            end\n        else\n            change [xvel v] by (0.4)\n            if <<(XVel) < [0.4]> and <<(YVel) = [0]> or <(YVel) = (Gravity)>>> then\n                change [xvel v] by (-0.39)\n                set [drifting v] to [1]\n            end\n        end\n    end\nend\nPlayerHitboxSwitchSides\nchange x by ((XVel) + (ConveyorXVel))\nset [xoffset v] to [0]\nif <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n    YSmoothing\nend\nif <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n    XSides\nend\nset [conveyorxvel v] to [0]\n\ndefine SwimmingCostumes\nif <(MaintainClimbing) = [1]> then\n    switch costume to (join [Climb] (join (Powerup) (([floor v] of (((PlayerTimer) * (15)) mod (2)) ) + (1))))\nelse\n    if <<(SlidingExtra) > [0]> and <([abs v] of (XVel) ) > [1]>> then\n        switch costume to (join [Slide] (Powerup))\n    else\n        if <(ThrowCooldown) > [0.2]> then\n            if <(Powerup) = [H]> then\n                if <not <<(YVel) = [0]> or <(YVel) = (Gravity)>>> then\n                    switch costume to (join [ThrowH] (([floor v] of (((PlayerTimer) * (20)) mod (2)) ) + (3)))\n                else\n                    switch costume to (join [ThrowH] (([floor v] of (((PlayerTimer) * (20)) mod (2)) ) + (1)))\n                end\n            else\n                if <not <<(YVel) = [0]> or <(YVel) = (Gravity)>>> then\n                    switch costume to (join [Throw] (([floor v] of (((PlayerTimer) * (20)) mod (2)) ) + (3)))\n                else\n                    switch costume to (join [Throw] (([floor v] of (((PlayerTimer) * (20)) mod (2)) ) + (1)))\n                end\n            end\n        else\n            if <(RaccoonSpin) > [0]> then\n                switch costume to (join [Spin] (([floor v] of (((PlayerTimer) * (40)) mod (4)) ) + (1)))\n            else\n                if <(Crouching) = [1]> then\n                    switch costume to (join [Crouch] (Powerup))\n                else\n                    if <not <<(YVel) = [0]> or <(YVel) = (Gravity)>>> then\n                        switch costume to (join [Swim] (join (Powerup) (([floor v] of (((PlayerTimer) * (12)) mod ((4) + (<not <(Powerup) = [None]>> * (1)))) ) + (1))))\n                    else\n                        if <(Drifting) = [1]> then\n                            switch costume to (join [Drift] (Powerup))\n                            set [playertimer v] to [0.07]\n                        else\n                            if <(Kicked) > [0]> then\n                                switch costume to (join [Kick] (Powerup))\n                            else\n                                if <([abs v] of (XVel) ) > [0.05]> then\n                                    if <([abs v] of (XVel) ) > [7.19]> then\n                                        switch costume to (join [Run] (join (Powerup) (([floor v] of (((PlayerTimer) * ((20) + (<not <(Powerup) = [None]>> * (5)))) mod ((2) + (<not <(Powerup) = [None]>> * (2)))) ) + (1))))\n                                    else\n                                        switch costume to (join [Walk] (join (Powerup) (([floor v] of (((PlayerTimer) * ((15) + (<not <(Powerup) = [None]>> * (5)))) mod ((2) + (<not <(Powerup) = [None]>> * (2)))) ) + (1))))\n                                    end\n                                else\n                                    switch costume to (join [Idle] (Powerup))\n                                    set [playertimer v] to [0.07]\n                                end\n                            end\n                        end\n                    end\n                end\n            end\n        end\n    end\nend\n\ndefine PlayerHitboxSwitchSides\nif <(Crouching) = [1]> then\n    switch costume to (crouchhitbox v)\n    set [small v] to [1]\nelse\n    switch costume to (sideshitbox v)\n    if <(Powerup) = [None]> then\n        switch costume to (sidesnone v)\n        set [small v] to [1]\n    end\nend\n\ndefine GoingDownScript\nYFloor\nset [raccoonwcooldown v] to [0]\nset [raccoonflightactive v] to [0]\nset [raccoonfloat v] to [0]\nif <<(YVel) < [-2]> and <([abs v] of (XVel) ) > [2]>> then\n    add (((x position) - (MapX)) / (32)) to [particlemakex v]\n    add ((((y position) - (18)) - (MapY)) / (32)) to [particlemakey v]\n    add [Drift] to [particlemaketype v]\nend\nset [yvel v] to (Gravity)\nif <<<<key (s v) pressed?> or <key (down arrow v) pressed?>> and <(Holding) = [0]>> and <<(AllowControl) = [1]> and <not <(Powerup) = [None]>>>> then\n    set [crouching v] to [1]\n    switch costume to (crouchhitbox v)\n    set [small v] to [1]\nend\n\ndefine Sliding\nif <(Powerup) = [H]> then\n    set [slidingextra v] to [0]\nelse\n    set rotation style [don't rotate v]\n    SlideLeft\n    SlideRight\n    PlayerHitboxSwitch\nend\n\ndefine SlideLeft\nswitch costume to (slidingleft v)\nset [offset v] to [0]\nset [playery v] to ((y position) - (MapY))\nrepeat until <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <(Offset) > [16]>>\n    change [offset v] by (0.5)\n    change y by (-1)\nend\nif <<(Offset) > [16]> or <(Offset) < [2]>> then\n    set y to ((PlayerY) + (MapY))\nelse\n    set y to ((PlayerY) + (MapY))\n    change y by ((Offset) / (-2))\n    set [slidingextra v] to [1]\n    change [xvel v] by ((Offset) / (-24))\n    if <(XVel) < [-8]> then\n        set [xvel v] to [-8]\n    end\nend\n\ndefine SlideRight\nswitch costume to (slidingright v)\nset [offset v] to [0]\nset [playery v] to ((y position) - (MapY))\nrepeat until <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <(Offset) > [16]>>\n    change [offset v] by (0.5)\n    change y by (-1)\nend\nif <<(Offset) > [16]> or <(Offset) < [2]>> then\n    set y to ((PlayerY) + (MapY))\n    SlideLeft\nelse\n    set y to ((PlayerY) + (MapY))\n    change y by ((Offset) / (-2))\n    set [slidingextra v] to [1]\n    change [xvel v] by ((Offset) / (16))\n    if <(XVel) > [8]> then\n        set [xvel v] to [8]\n    end\nend\n\nwhen [up arrow v] key pressed\nif <not <key (up arrow v) pressed?>> then\n    if <(ItemMenu) = [1]> then\n        change [inventoryscroll v] by (-0.5)\n        if <(InventoryScroll) < [0]> then\n            set [inventoryscroll v] to [0]\n        end\n    else\n        if <<(PlacingPipes) = [0]> and <not <(EditMode) = [0]>>> then\n            change [itemlistno. v] by (1)\n            if <(ItemListNo.) > (length of [hotbar v])> then\n                set [itemlistno. v] to [1]\n            end\n            set [costumeselected v] to (item (ItemListNo.) of [hotbar v])\n        end\n    end\nend\n\nwhen [down arrow v] key pressed\nif <not <key (down arrow v) pressed?>> then\n    if <(ItemMenu) = [1]> then\n        change [inventoryscroll v] by (0.5)\n        if <(InventoryScroll) > [5]> then\n            set [inventoryscroll v] to [5]\n        end\n    else\n        if <<(PlacingPipes) = [0]> and <not <(EditMode) = [0]>>> then\n            change [itemlistno. v] by (-1)\n            if <(ItemListNo.) < [1]> then\n                set [itemlistno. v] to (length of [hotbar v])\n            end\n            set [costumeselected v] to (item (ItemListNo.) of [hotbar v])\n        end\n    end\nend\n\nwhen [b v] key pressed\nset [justedited v] to [0]\nif <<(PlacingPipes) = [0]> and <not <(EditMode) = [0]>>> then\n    set [editmode v] to [1]\nend\n\nwhen [i v] key pressed\nset [justedited v] to [0]\nif <<(PlacingPipes) = [0]> and <not <(EditMode) = [0]>>> then\n    set [editmode v] to [3]\nend\n\ndefine FrogCostumes\nif <(MaintainClimbing) = [1]> then\n    switch costume to (join [Climb] (join (Powerup) (([floor v] of (((PlayerTimer) * (15)) mod (2)) ) + (1))))\nelse\n    if <<(SlidingExtra) > [0]> and <([abs v] of (XVel) ) > [1]>> then\n        switch costume to (join [Slide] (Powerup))\n    else\n        if <(Crouching) = [1]> then\n            switch costume to (join [Crouch] (Powerup))\n        else\n            if <not <<(YVel) = [0]> or <(YVel) = (Gravity)>>> then\n                if <(((y position) - (MapY)) / (32)) < (CurrentWaterLevel)> then\n                    if <<([abs v] of (YVel) ) > [1.2]> and <([abs v] of (YVel) ) > ([abs v] of (XVel) )>> then\n                        if <(YVel) > [0]> then\n                            switch costume to (join [SwimUpJ] (([floor v] of (((PlayerTimer) * (15)) mod (3)) ) + (1)))\n                        else\n                            switch costume to (join [SwimDownJ] (([floor v] of (((PlayerTimer) * (15)) mod (3)) ) + (1)))\n                        end\n                    else\n                        if <([abs v] of (XVel) ) > [0.1]> then\n                            switch costume to (join [SwimSidesJ] (([floor v] of (((PlayerTimer) * (15)) mod (3)) ) + (1)))\n                        else\n                            switch costume to (join [SwimIdleJ] (([floor v] of (((PlayerTimer) * (15)) mod (2)) ) + (1)))\n                        end\n                    end\n                else\n                    switch costume to (join [Jump] (Powerup))\n                    set [playertimer v] to [0.07]\n                end\n            else\n                if <(Kicked) > [0]> then\n                    switch costume to (join [Kick] (Powerup))\n                else\n                    if <([abs v] of (XVel) ) > [0.05]> then\n                        switch costume to (join [Walk] (join (Powerup) (([floor v] of (((PlayerTimer) * (15)) mod (3)) ) + (1))))\n                    else\n                        switch costume to (join [Idle] (Powerup))\n                        set [playertimer v] to [0.07]\n                    end\n                end\n            end\n        end\n    end\nend\n\ndefine FrogMovement\nif <(YVel) = [1.1]> then\n    set [yvel v] to [-1]\nend\nif <(YVel) > [8]> then\n    set [yvel v] to [8]\nend\nif <(YVel) < [-8]> then\n    set [yvel v] to [-8]\nend\nset [raccoonfloat v] to [0]\nset [raccoonflight v] to [0]\nset [throwcooldown v] to [0]\nset [raccoonspin v] to [0]\nset [raccoonflightactive v] to [0]\nif <<key (w v) pressed?> or <key (up arrow v) pressed?>> then\n    change [yvel v] by (0.6)\nend\nif <<key (s v) pressed?> or <key (down arrow v) pressed?>> then\n    change [yvel v] by (-0.6)\nend\nif <key (space v) pressed?> then\n    set [yvel v] to ((YVel) / (1.14))\nelse\n    set [yvel v] to ((YVel) / (1.2))\nend\nif <(YVel) > [0]> then\n    if <(Powerup) = [None]> then\n        switch costume to (risehitbox v)\n    end\nelse\n    switch costume to (fallhitbox v)\nend\nchange y by ((YVel) / (2))\nif <(YVel) > [0]> then\n    if <not <<touching (blocks v)?> or <touching (uniqueblocks v)?>>> then\n        change y by ((YVel) / (2))\n    end\nelse\n    if <not <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <touching (semisolids v)?>>> then\n        change y by ((YVel) / (2))\n    end\nend\nif <(YVel) > [0]> then\n    if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n        set [yvel v] to [1.1]\n        YCeiling\n    end\nelse\n    if <(YVel) > [-5]> then\n        change y by (-4)\n        if <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <touching (semisolids v)?>> then\n            GoingDownScript\n        else\n            change y by (4)\n        end\n    else\n        if <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <touching (semisolids v)?>> then\n            GoingDownScript\n        end\n    end\n    set [maintainclimbing v] to [0]\nend\nif <(SlidingExtra) > [0]> then\n    change [slidingextra v] by (-0.05)\n    if <<(SlidingExtra) < [0]> or <not <<key (s v) pressed?> or <key (down arrow v) pressed?>>>> then\n        set [slidingextra v] to [0]\n    end\nend\nif <<<<key (s v) pressed?> or <key (down arrow v) pressed?>> and <(AllowControl) = [1]>> and <<(YVel) = [0]> or <(YVel) = (Gravity)>>> then\n    Sliding\n    PlayerHitboxSwitch\nelse\n    if <not <<(YVel) = [0]> or <(YVel) = (Gravity)>>> then\n        if <<((((PlayerTimer) * (15)) mod (9)) + (1)) < [1.4]> and <(([abs v] of (YVel) ) + ([abs v] of (XVel) )) > [1]>> then\n            start sound [swim v]\n        end\n    end\n    if <<<key (w v) pressed?> or <key (up arrow v) pressed?>> and <<(AllowControl) = [1]> and <(YVel) < [1]>>> then\n        if <<(YVel) = [0]> or <(YVel) = (Gravity)>> then\n            set [yvel v] to [4]\n            start sound [swim v]\n        end\n        if <(Crouching) = [1]> then\n            set [yvel v] to (Gravity)\n            change y by (24)\n            if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n                if <([abs v] of (XVel) ) < [1]> then\n                    set [yvel v] to [4]\n                    change [xvel v] by ((direction) / (30))\n                end\n            else\n                set [crouching v] to [0]\n                set [small v] to [0]\n            end\n            change y by (-24)\n        else\n            if <<([abs v] of (XVel) ) > [7.19]> and <(Powerup) = [R]>> then\n                set [raccoonflightactive v] to [1]\n            end\n        end\n    end\nend\nif <not <(((y position) - (MapY)) / (32)) < (CurrentWaterLevel)>> then\n    if <<<key (w v) pressed?> or <key (up arrow v) pressed?>> and <(AllowControl) = [1]>> then\n        set [yvel v] to [8]\n    end\nend\nif <(y position) > [160]> then\n    set y to (160)\nend\nSwimmingXMovement\n\nwhen [v v] key pressed\nset [justedited v] to [0]\nif <not <(EditMode) = [0]>> then\n    if <(ItemMenu) = [1]> then\n        set [itemmenu v] to [0.9]\n        set [itemlistselected v] to [0]\n    else\n        set [itemmenu v] to [1]\n    end\nend\n\nwhen I receive [returntomenu v]\nset [menu v] to [1]\nbroadcast (FadeOutInstant v)\n\nwhen [r v] key pressed\nif <<not <(EditMode) = [0]>> and <(Menu) = [0]>> then\n    if <(ShowFullHUD) = [1]> then\n        set [showfullhud v] to [0]\n    else\n        set [showfullhud v] to [1]\n    end\nend\n\n@Blocks\n\nwhen flag clicked\ndelete all of [blocktype v]\ndelete all of [blockx v]\ndelete all of [blocky v]\ndelete all of [pipedir v]\ndelete all of [pipetype v]\ndelete all of [pipex v]\ndelete all of [pipey v]\ndelete all of [pipestate v]\nswitch costume to (block v)\nset size to (400) %\nset rotation style [don't rotate v]\npoint in direction (90)\nset [costumeselected v] to [1]\n\nwhen I receive [map update v]\nif <[1] = [1]> then\n    delete this clone\nend\nif <((length of [pipex v]) mod (2)) = [1]> then\n    set [placingpipes v] to [1]\nelse\n    set [placingpipes v] to [0]\nend\nshow\nclear graphic effects\nif <not <mouse down?>> then\n    set [justedited v] to [0]\nend\nif <(CostumeSelected) = [Pick]> then\n    set [costumeselected v] to [1]\n    set [blocktypeselected v] to [Block]\n    set [editmode v] to [3]\nend\nif <<<mouse down?> and <(mouse y) > [-121]>> and <<(ItemMenu) = [0]> and <<(TouchingMenu) = [0]> and <<(SavingProcess) = [0]> and <not <(join (round (((mouse x) - (MapX)) / (32))) (round (((mouse y) - (MapY)) / (32)))) = (JustEdited)>>>>>> then\n    if <(EditMode) = [1]> then\n        BlockTypeSelected\n        set [scanlength v] to (length of [blockx v])\n        if <(length of [semix v]) > (ScanLength)> then\n            set [scanlength v] to (length of [semix v])\n        end\n        if <(length of [enx v]) > (ScanLength)> then\n            set [scanlength v] to (length of [enx v])\n        end\n        if <(length of [unx v]) > (ScanLength)> then\n            set [scanlength v] to (length of [unx v])\n        end\n        if <(length of [pipex v]) > (ScanLength)> then\n            set [scanlength v] to (length of [pipex v])\n        end\n        Attempt Placement\n    end\n    if <(EditMode) = [2]> then\n        set [scanlength v] to (length of [blockx v])\n        if <(length of [semix v]) > (ScanLength)> then\n            set [scanlength v] to (length of [semix v])\n        end\n        if <(length of [enx v]) > (ScanLength)> then\n            set [scanlength v] to (length of [enx v])\n        end\n        if <(length of [unx v]) > (ScanLength)> then\n            set [scanlength v] to (length of [unx v])\n        end\n        if <(length of [pipex v]) > (ScanLength)> then\n            set [scanlength v] to (length of [pipex v])\n        end\n        ScanFor (round (((mouse x) - (MapX)) / (32))) (round (((mouse y) - (MapY)) / (32)))\n        if <(FoundPosition) = [1]> then\n            if <(FoundInList) = [Block]> then\n                delete (ScanNo.) of [blockx v]\n                delete (ScanNo.) of [blocky v]\n                delete (ScanNo.) of [blocktype v]\n            end\n            if <(FoundInList) = [Enemy]> then\n                delete (ScanNo.) of [enx v]\n                delete (ScanNo.) of [eny v]\n                delete (ScanNo.) of [entype v]\n                delete (ScanNo.) of [enkey v]\n            end\n            if <(FoundInList) = [Semi]> then\n                delete (ScanNo.) of [semix v]\n                delete (ScanNo.) of [semiy v]\n                delete (ScanNo.) of [semitype v]\n            end\n            if <(FoundInList) = [Unique]> then\n                delete (ScanNo.) of [unx v]\n                delete (ScanNo.) of [uny v]\n                delete (ScanNo.) of [untype v]\n            end\n            if <(FoundInList) = [Pipe]> then\n                delete (ScanNo.) of [pipedir v]\n                delete (ScanNo.) of [pipetype v]\n                delete (ScanNo.) of [pipex v]\n                delete (ScanNo.) of [pipey v]\n                if <((ScanNo.) mod (2)) = [0]> then\n                    delete ((ScanNo.) - (1)) of [pipedir v]\n                    delete ((ScanNo.) - (1)) of [pipetype v]\n                    delete ((ScanNo.) - (1)) of [pipex v]\n                    delete ((ScanNo.) - (1)) of [pipey v]\n                else\n                    delete (ScanNo.) of [pipedir v]\n                    delete (ScanNo.) of [pipetype v]\n                    delete (ScanNo.) of [pipex v]\n                    delete (ScanNo.) of [pipey v]\n                end\n            end\n            Fix Surroundings\n        end\n    end\n    if <(EditMode) = [3]> then\n        ScanFor (round (((mouse x) - (MapX)) / (32))) (round (((mouse y) - (MapY)) / (32)))\n        if <(FoundPosition) = [1]> then\n            CheckBlock'sType\n            if <<(FoundInList) = [Block]> or <(FoundInList) = [Semi]>> then\n                set [costumeselected v] to (BlockTypeBeingEdited)\n                if <(CostumeSelected) = [Pick]> then\n                    set [costumeselected v] to [1]\n                end\n            else\n                set [costumeselected v] to (BlockTypeBeingEditedFull)\n                if <(CostumeSelected) = [l]> then\n                    set [costumeselected v] to [Key]\n                end\n                if <(CostumeSelected) = [Pick]> then\n                    set [costumeselected v] to [1]\n                end\n            end\n        else\n            if <<((round (((mouse x) - (MapX)) / (32))) * (32)) = (OriginalSpawnX)> and <((round (((mouse y) - (MapY)) / (32))) * (32)) = (OriginalSpawnY)>> then\n                set [costumeselected v] to [Spawn]\n                set [foundposition v] to [1]\n            end\n            if <<((round (((mouse x) - (MapX)) / (32))) * (32)) = (GoalX)> and <((round (((mouse y) - (MapY)) / (32))) * (32)) = (GoalY)>> then\n                set [costumeselected v] to [Goal]\n                set [foundposition v] to [1]\n            end\n        end\n        if <(FoundPosition) = [1]> then\n            set [editmode v] to [1]\n            set [itemmenu v] to [0.5]\n        end\n    end\n    set [justedited v] to (join (round (((mouse x) - (MapX)) / (32))) (round (((mouse y) - (MapY)) / (32))))\nend\nLoad Blocks\nGoToMouse\nhide\nset [ghost v] effect to (50)\nif <(EditMode) = [1]> then\n    BlockTypeSelected\n    if <<(BlockTypeSelected) = [Block]> or <(BlockTypeSelected) = [Semi]>> then\n        switch costume to (join (CostumeSelected) [b])\n    else\n        switch costume to (CostumeSelected)\n        if <(BlockTypeSelected) = [Pipe]> then\n            if <(CostumeSelected) = [£1]> then\n                if <((length of [pipex v]) mod (2)) = [0]> then\n                    switch costume to (£11 v)\n                else\n                    switch costume to (£12 v)\n                end\n            end\n            if <(CostumeSelected) = [£2]> then\n                switch costume to (£2 v)\n            end\n            if <(CostumeSelected) = [£3]> then\n                if <((length of [pipex v]) mod (2)) = [0]> then\n                    switch costume to (£31 v)\n                else\n                    switch costume to (£32 v)\n                end\n            end\n            if <(CostumeSelected) = [£4]> then\n                switch costume to (£4 v)\n            end\n            if <(CostumeSelected) = [£5]> then\n                if <((length of [pipex v]) mod (2)) = [0]> then\n                    switch costume to (£51 v)\n                else\n                    switch costume to (£52 v)\n                end\n            end\n            if <(CostumeSelected) = [£6]> then\n                switch costume to (£61 v)\n            end\n            if <(CostumeSelected) = [£7]> then\n                if <((length of [pipex v]) mod (2)) = [0]> then\n                    switch costume to (£71 v)\n                else\n                    switch costume to (£72 v)\n                end\n            end\n            if <(CostumeSelected) = [£8]> then\n                switch costume to (£81 v)\n            end\n            if <(CostumeSelected) = [£9]> then\n                switch costume to (£9 v)\n            end\n            if <(CostumeSelected) = [£10]> then\n                switch costume to (£10 v)\n            end\n        end\n    end\nend\nif <(EditMode) = [2]> then\n    switch costume to (erase v)\nend\nif <(EditMode) = [3]> then\n    switch costume to (pick v)\nend\nbroadcast (EnemyUpdate v)\n\ndefine Load Blocks\nif <[1] = [1]> then\n    delete this clone\nend\nset [blockno. v] to ((item # of (round (((MapX) / (-32)) - (8))) in [blockx v]) - (1))\nif <(BlockNo.) < [0]> then\n    set [blockno. v] to [0]\nend\nrepeat ((length of [blockx v]) - (BlockNo.))\n    change [blockno. v] by (1)\n    set [x v] to (((item (BlockNo.) of [blockx v]) * (32)) + (MapX))\n    set [y v] to (((item (BlockNo.) of [blocky v]) * (32)) + (MapY))\n    go to x: (X) y: (Y)\n    if <(X) > [242]> then\n        set [blockno. v] to [0]\n        if <not <(EditMode) = [0]>> then\n            PlayerSpawnShow\n        end\n        stop [this script v]\n    end\n    if <<([abs v] of (X) ) < [242]> and <([abs v] of (Y) ) < [182]>> then\n        if <(EditMode) = [0]> then\n            switch costume to (block v)\n            if <<(item (BlockNo.) of [blocktype v]) = [10b]> or <(item (BlockNo.) of [blocktype v]) = [13b]>> then\n                switch costume to (sloperight v)\n            end\n            if <<(item (BlockNo.) of [blocktype v]) = [11b]> or <(item (BlockNo.) of [blocktype v]) = [14b]>> then\n                switch costume to (slopeleft v)\n            end\n        else\n            switch costume to (item (BlockNo.) of [blocktype v])\n        end\n        if <(EditMode) = [0]> then\n            if <<<(letter (length of (item (BlockNo.) of [blocktype v])) of (item (BlockNo.) of [blocktype v])) = [a]> and <not <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [64]> and <([abs v] of ((y position) - ([y position v] of [player v])) ) < [64]>>>> or <<(item (BlockNo.) of [blocktype v]) = [23j]> or <<(item (BlockNo.) of [blocktype v]) = [23l]> or <(item (BlockNo.) of [blocktype v]) = [23m]>>>> then\n                switch costume to (item (BlockNo.) of [blocktype v])\n                stamp\n            else\n                create clone of (_myself_ v)\n            end\n        else\n            stamp\n        end\n    end\nend\nset [blockno. v] to [0]\nif <not <(EditMode) = [0]>> then\n    PlayerSpawnShow\nend\n\ndefine Attempt Placement\nScanFor (round (((mouse x) - (MapX)) / (32))) (round (((mouse y) - (MapY)) / (32)))\nCheckBlock'sType\nif <(BlockTypeBeingEdited) = (CostumeSelected)> then\n    stop [this script v]\nend\nif <<<((round (((mouse x) - (MapX)) / (32))) * (32)) = (OriginalSpawnX)> and <((round (((mouse y) - (MapY)) / (32))) * (32)) = (OriginalSpawnY)>> or <<((round (((mouse x) - (MapX)) / (32))) * (32)) = (GoalX)> and <((round (((mouse y) - (MapY)) / (32))) * (32)) = (GoalY)>>> then\n    stop [this script v]\nend\nif <(FoundPosition) = [0]> then\n    MakePlacement\nelse\n    if <not <<(CostumeSelected) = [Water]> or <(CostumeSelected) = [Lava]>>> then\n        if <(FoundInList) = [Block]> then\n            delete (ScanNo.) of [blocktype v]\n            delete (ScanNo.) of [blockx v]\n            delete (ScanNo.) of [blocky v]\n        end\n        if <(FoundInList) = [Semi]> then\n            if <(BlockTypeSelected) = [Enemy]> then\n        end\n        if <(FoundInList) = [Enemy]> then\n            if <<(CostumeSelected) = [Key]> and <not <<(item (ScanNo.) of [entype v]) = [o]> or <(item (ScanNo.) of [entype v]) = [l]>>>> then\n                if <(item (ScanNo.) of [enkey v]) = [1]> then\n                    replace item (ScanNo.) of [enkey v] with [0]\n                else\n                    replace item (ScanNo.) of [enkey v] with [1]\n                end\n                set [justedited v] to (join (round (((mouse x) - (MapX)) / (32))) (round (((mouse y) - (MapY)) / (32))))\n                stop [this script v]\n            else\n                delete (ScanNo.) of [entype v]\n                delete (ScanNo.) of [enx v]\n                delete (ScanNo.) of [eny v]\n                delete (ScanNo.) of [enkey v]\n            end\n        end\n        if <(FoundInList) = [Unique]> then\n            delete (ScanNo.) of [untype v]\n            delete (ScanNo.) of [unx v]\n            delete (ScanNo.) of [uny v]\n        end\n        if <(FoundInList) = [Pipe]> then\n            if <(BlockTypeSelected) = [Enemy]> then\n        end\n    end\n    MakePlacement\nend\n\ndefine ScanFor (x) (y)\nset [foundinlist v] to []\nset [foundposition v] to [0]\nset [scanno. v] to ((item # of ((x) - (2)) in [blockx v]) - (2))\nrepeat until <<(item (ScanNo.) of [blockx v]) > ((x) + (2))> or <(ScanNo.) > (length of [blockx v])>>\n    change [scanno. v] by (1)\n    if <<(item (ScanNo.) of [blockx v]) = (x)> and <(item (ScanNo.) of [blocky v]) = (y)>> then\n        set [foundinlist v] to [Block]\n        set [foundposition v] to [1]\n        stop [this script v]\n    end\nend\nset [scanno. v] to ((item # of ((x) - (2)) in [semix v]) - (2))\nrepeat until <<(item (ScanNo.) of [semix v]) > ((x) + (2))> or <(ScanNo.) > (length of [semix v])>>\n    change [scanno. v] by (1)\n    if <<(item (ScanNo.) of [semix v]) = (x)> and <(item (ScanNo.) of [semiy v]) = (y)>> then\n        set [foundinlist v] to [Semi]\n        set [foundposition v] to [1]\n        set [foundinsemiat v] to (ScanNo.)\n        if <(FixingSurroundings) = [1]> then\n            stop [this script v]\n        end\n    end\nend\nif <<(FixingSurroundings) = [0]> or <<(ThisBlock'sType) = [4]> or <(ThisBlock'sType) = [5]>>> then\n    set [scanno. v] to ((item # of ((x) - (2)) in [unx v]) - (2))\n    repeat until <<(item (ScanNo.) of [unx v]) > ((x) + (2))> or <(ScanNo.) > (length of [unx v])>>\n        change [scanno. v] by (1)\n        if <<(item (ScanNo.) of [unx v]) = (x)> and <(item (ScanNo.) of [uny v]) = (y)>> then\n            set [foundinlist v] to [Unique]\n            set [foundposition v] to [1]\n            stop [this script v]\n        end\n    end\nend\nif <(FixingSurroundings) = [0]> then\n    set [scanno. v] to [0]\n    repeat (length of [pipex v])\n        change [scanno. v] by (1)\n        if <<(item (ScanNo.) of [pipex v]) = (x)> and <(item (ScanNo.) of [pipey v]) = (y)>> then\n            set [foundinlist v] to [Pipe]\n            set [foundposition v] to [1]\n            set [foundinpipeat v] to (ScanNo.)\n        end\n    end\n    set [scanno. v] to [0]\n    repeat (length of [enx v])\n        change [scanno. v] by (1)\n        if <<(item (ScanNo.) of [enx v]) = (x)> and <(item (ScanNo.) of [eny v]) = (y)>> then\n            set [foundinlist v] to [Enemy]\n            set [foundposition v] to [1]\n            stop [this script v]\n        end\n    end\n    if <(FoundPosition) = [1]> then\n        if <(FoundInList) = [Semi]> then\n            set [scanno. v] to (FoundInSemiAt)\n        end\n        if <(FoundInList) = [Pipe]> then\n            set [scanno. v] to (FoundInPipeAt)\n        end\n    end\nend\n\ndefine Find Placement (x) (y)\nif <(BlockTypeSelected) = [Block]> then\n    set [scanno. v] to ((item # of (x) in [blockx v]) - (1))\n    repeat until <<not <(item (ScanNo.) of [blockx v]) < (x)>> or <(ScanNo.) > (length of [blockx v])>>\n        change [scanno. v] by (1)\n    end\n    if <(ScanNo.) > (length of [blockx v])> then\n        set [scanno. v] to ((length of [blockx v]) + (1))\n    end\n    set [placementno. v] to (ScanNo.)\nend\nif <(BlockTypeSelected) = [Semi]> then\n    set [scanno. v] to ((item # of (x) in [semix v]) - (1))\n    repeat until <<not <(item (ScanNo.) of [semix v]) < (x)>> or <(ScanNo.) > (length of [semix v])>>\n        change [scanno. v] by (1)\n    end\n    if <(ScanNo.) > (length of [semix v])> then\n        set [scanno. v] to ((length of [semix v]) + (1))\n    end\n    set [placementno. v] to (ScanNo.)\nend\nif <<(BlockTypeSelected) = [Enemy]> or <(BlockTypeSelected) = [Key]>> then\n    set [scanno. v] to ((item # of (x) in [eny v]) - (1))\n    repeat until <<not <(item (ScanNo.) of [eny v]) < (y)>> or <(ScanNo.) > (length of [eny v])>>\n        change [scanno. v] by (1)\n    end\n    if <(ScanNo.) > (length of [eny v])> then\n        set [scanno. v] to ((length of [eny v]) + (1))\n    end\n    set [placementno. v] to (ScanNo.)\nend\nif <(BlockTypeSelected) = [Unique]> then\n    set [scanno. v] to ((item # of (x) in [unx v]) - (1))\n    repeat until <<not <(item (ScanNo.) of [unx v]) < (x)>> or <(ScanNo.) > (length of [unx v])>>\n        change [scanno. v] by (1)\n    end\n    if <(ScanNo.) > (length of [unx v])> then\n        set [scanno. v] to ((length of [unx v]) + (1))\n    end\n    set [placementno. v] to (ScanNo.)\nend\nif <(BlockTypeSelected) = [Pipe]> then\n    set [scanno. v] to ((length of [pipex v]) + (1))\n    set [placementno. v] to (ScanNo.)\nend\n\ndefine Fix Costume\nif <(FixingSurroundings) = [1]> then\n    CheckBlock'sType\n    set [thisblock'stype v] to (BlockTypeBeingEdited)\n    set [thisblockstypefull v] to (BlockTypeBeingEditedFull)\nend\nset [sides v] to []\nset [pipesides v] to []\nset [semisides v] to []\nScanFor ((round (((x position) - (MapX)) / (32))) + (1)) (round (((y position) - (MapY)) / (32)))\nCheckBlock'sType\nif <<(FoundPosition) = [1]> and <<(BlockTypeBeingEdited) = (ThisBlock'sType)> or <<<(ThisBlock'sType) = [5]> and <not <<(BlockTypeBeingEdited) = [\]> or <(FoundInList) = [Semi]>>>> or <<<<(ThisBlock'sType) = [9]> and <<(BlockTypeBeingEdited) = [10]> or <(BlockTypeBeingEdited) = [11]>>> or <<(ThisBlock'sType) = [12]> and <<(BlockTypeBeingEdited) = [13]> or <(BlockTypeBeingEdited) = [14]>>>> or <<<(ThisBlock'sType) = [3]> and <(BlockTypeBeingEdited) = [2]>> or <<(ThisBlock'sType) = [8]> and <<(BlockTypeBeingEdited) = [2]> or <(BlockTypeBeingEdited) = [3]>>>>>>>> then\n    set [sides v] to (join (Sides) [R])\n    if <<(ThisBlock'sType) = [5]> and <(BlockTypeBeingEdited) = [4]>> then\n        set [pipesides v] to (join (PipeSides) [R])\n    end\nend\nScanFor (round (((x position) - (MapX)) / (32))) ((round (((y position) - (MapY)) / (32))) + (1))\nCheckBlock'sType\nif <<<(FoundPosition) = [1]> and <<(BlockTypeBeingEdited) = (ThisBlock'sType)> or <<<(ThisBlock'sType) = [4]> and <not <<(BlockTypeBeingEdited) = [\]> or <(FoundInList) = [Semi]>>>> or <<<<(ThisBlock'sType) = [9]> and <<(BlockTypeBeingEdited) = [10]> or <(BlockTypeBeingEdited) = [11]>>> or <<(ThisBlock'sType) = [12]> and <<(BlockTypeBeingEdited) = [13]> or <(BlockTypeBeingEdited) = [14]>>>> or <<<(ThisBlock'sType) = [3]> and <(BlockTypeBeingEdited) = [2]>> or <<(ThisBlock'sType) = [8]> and <<(BlockTypeBeingEdited) = [2]> or <(BlockTypeBeingEdited) = [3]>>>>>>>> or <<((round (((y position) - (MapY)) / (32))) - (1)) = [-7]> or <<((round (((y position) - (MapY)) / (32))) - (1)) = [34]> or <((round (((y position) - (MapY)) / (32))) - (1)) = [76]>>>> then\n    set [sides v] to (join (Sides) [U])\n    if <<(ThisBlock'sType) = [4]> and <(BlockTypeBeingEdited) = [5]>> then\n        set [pipesides v] to (join (PipeSides) [U])\n    end\nend\nScanFor ((round (((x position) - (MapX)) / (32))) - (1)) (round (((y position) - (MapY)) / (32)))\nCheckBlock'sType\nif <<(FoundPosition) = [1]> and <<(BlockTypeBeingEdited) = (ThisBlock'sType)> or <<<(ThisBlock'sType) = [5]> and <not <<(BlockTypeBeingEdited) = [\]> or <(FoundInList) = [Semi]>>>> or <<<<(ThisBlock'sType) = [9]> and <<(BlockTypeBeingEdited) = [10]> or <(BlockTypeBeingEdited) = [11]>>> or <<(ThisBlock'sType) = [12]> and <<(BlockTypeBeingEdited) = [13]> or <(BlockTypeBeingEdited) = [14]>>>> or <<<(ThisBlock'sType) = [3]> and <(BlockTypeBeingEdited) = [2]>> or <<(ThisBlock'sType) = [8]> and <<(BlockTypeBeingEdited) = [2]> or <(BlockTypeBeingEdited) = [3]>>>>>>>> then\n    set [sides v] to (join (Sides) [L])\n    if <<(ThisBlock'sType) = [5]> and <(BlockTypeBeingEdited) = [4]>> then\n        set [pipesides v] to (join (PipeSides) [L])\n    end\n    if <<<(ThisBlock'sType) = [3]> and <(BlockTypeBeingEdited) = [2]>> or <<(ThisBlock'sType) = [8]> and <<(BlockTypeBeingEdited) = [2]> or <(BlockTypeBeingEdited) = [3]>>>> then\n        set [semisides v] to (join (SemiSides) [L])\n    end\n    if <<<(ThisBlock'sType) = [3]> and <<(BlockTypeBeingEditedFull) = [2f]> or <(BlockTypeBeingEditedFull) = [2l]>>> or <<(ThisBlock'sType) = [8]> and <<<(BlockTypeBeingEditedFull) = [2f]> or <(BlockTypeBeingEditedFull) = [2l]>> or <<(BlockTypeBeingEditedFull) = [3f]> or <(BlockTypeBeingEditedFull) = [3l]>>>>> then\n        set [semisides v] to (join (SemiSides) [U])\n    end\nend\nScanFor (round (((x position) - (MapX)) / (32))) ((round (((y position) - (MapY)) / (32))) - (1))\nCheckBlock'sType\nif <<<(FoundPosition) = [1]> and <<(BlockTypeBeingEdited) = (ThisBlock'sType)> or <<<(ThisBlock'sType) = [4]> and <not <<(BlockTypeBeingEdited) = [\]> or <(FoundInList) = [Semi]>>>> or <<<<(ThisBlock'sType) = [9]> and <<(BlockTypeBeingEdited) = [10]> or <(BlockTypeBeingEdited) = [11]>>> or <<(ThisBlock'sType) = [12]> and <<(BlockTypeBeingEdited) = [13]> or <(BlockTypeBeingEdited) = [14]>>>> or <<<(ThisBlock'sType) = [3]> and <(BlockTypeBeingEdited) = [2]>> or <<(ThisBlock'sType) = [8]> and <<(BlockTypeBeingEdited) = [2]> or <(BlockTypeBeingEdited) = [3]>>>>>>>> or <<((round (((y position) - (MapY)) / (32))) - (1)) = [-6]> or <<((round (((y position) - (MapY)) / (32))) - (1)) = [35]> or <((round (((y position) - (MapY)) / (32))) - (1)) = [-48]>>>> then\n    set [sides v] to (join (Sides) [D])\n    if <<(ThisBlock'sType) = [4]> and <(BlockTypeBeingEdited) = [5]>> then\n        set [pipesides v] to (join (PipeSides) [D])\n    end\nend\nif <not <(ThisBlock'sType) = [x]>> then\n    switch costume to (join (ThisBlock'sType) [a])\n    if < (SemiSides) contains [L]?> then\n        switch costume to (join (ThisBlock'sType) [q])\n        if < (SemiSides) contains [U]?> then\n            switch costume to (join (ThisBlock'sType) [r])\n        end\n    end\n    if <(length of (Sides)) = [3]> then\n        if <not < (Sides) contains [U]?>> then\n            switch costume to (join (ThisBlock'sType) [b])\n            if < (PipeSides) contains [R]?> then\n                switch costume to (join (ThisBlock'sType) [p])\n            end\n            if < (PipeSides) contains [L]?> then\n                switch costume to (join (ThisBlock'sType) [q])\n            end\n        end\n        if <not < (Sides) contains [D]?>> then\n            switch costume to (join (ThisBlock'sType) [d])\n            if < (PipeSides) contains [R]?> then\n                switch costume to (join (ThisBlock'sType) [r])\n            end\n            if < (PipeSides) contains [L]?> then\n                switch costume to (join (ThisBlock'sType) [s])\n            end\n            if < (SemiSides) contains [L]?> then\n                switch costume to (join (ThisBlock'sType) [p])\n            end\n        end\n        if <not < (Sides) contains [L]?>> then\n            switch costume to (join (ThisBlock'sType) [e])\n            if < (PipeSides) contains [U]?> then\n                switch costume to (join (ThisBlock'sType) [q])\n            end\n            if < (PipeSides) contains [D]?> then\n                switch costume to (join (ThisBlock'sType) [p])\n            end\n        end\n        if <not < (Sides) contains [R]?>> then\n            switch costume to (join (ThisBlock'sType) [c])\n            if < (PipeSides) contains [U]?> then\n                switch costume to (join (ThisBlock'sType) [s])\n            end\n            if < (PipeSides) contains [D]?> then\n                switch costume to (join (ThisBlock'sType) [r])\n            end\n        end\n    end\n    if <(length of (Sides)) = [2]> then\n        if << (Sides) contains [U]?> and < (Sides) contains [D]?>> then\n            switch costume to (join (ThisBlock'sType) [j])\n        end\n        if << (Sides) contains [L]?> and < (Sides) contains [R]?>> then\n            switch costume to (join (ThisBlock'sType) [k])\n        end\n        if << (Sides) contains [L]?> and < (Sides) contains [D]?>> then\n            switch costume to (join (ThisBlock'sType) [f])\n        end\n        if << (Sides) contains [L]?> and < (Sides) contains [U]?>> then\n            switch costume to (join (ThisBlock'sType) [g])\n        end\n        if << (Sides) contains [R]?> and < (Sides) contains [U]?>> then\n            switch costume to (join (ThisBlock'sType) [h])\n        end\n        if << (Sides) contains [R]?> and < (Sides) contains [D]?>> then\n            switch costume to (join (ThisBlock'sType) [i])\n        end\n    end\n    if <(length of (Sides)) = [1]> then\n        if <(Sides) = [U]> then\n            switch costume to (join (ThisBlock'sType) [m])\n        end\n        if <(Sides) = [D]> then\n            switch costume to (join (ThisBlock'sType) [l])\n        end\n        if <(Sides) = [L]> then\n            switch costume to (join (ThisBlock'sType) [o])\n        end\n        if <(Sides) = [R]> then\n            switch costume to (join (ThisBlock'sType) [n])\n        end\n    end\n    if <(length of (Sides)) = [0]> then\n        switch costume to (join (ThisBlock'sType) [b])\n    end\n    if <(ThisBlock'sType) = [6]> then\n        switch costume to (join (ThisBlock'sType) [b])\n    end\n    if <(ThisBlock'sType) = [10]> then\n        switch costume to (10b v)\n        if < (Sides) contains [U]?> then\n            switch costume to (10c v)\n        end\n    end\n    if <(ThisBlock'sType) = [11]> then\n        switch costume to (11b v)\n        if < (Sides) contains [U]?> then\n            switch costume to (11c v)\n        end\n    end\n    if <(ThisBlock'sType) = [13]> then\n        switch costume to (13b v)\n        if < (Sides) contains [U]?> then\n            switch costume to (13c v)\n        end\n    end\n    if <(ThisBlock'sType) = [14]> then\n        switch costume to (14b v)\n        if < (Sides) contains [U]?> then\n            switch costume to (14c v)\n        end\n    end\n    if <(ThisBlock'sType) = [17]> then\n        switch costume to (17b v)\n        if < (Sides) contains [U]?> then\n            switch costume to (17c v)\n        end\n    end\n    if <(ThisBlock'sType) = [18]> then\n        switch costume to (18a v)\n        if < (Sides) contains [U]?> then\n            switch costume to (18c v)\n        end\n    end\n    if <(ThisBlock'sType) = [19]> then\n        if <((ScanNo.) mod (4)) < [2]> then\n            switch costume to (19a v)\n        else\n            switch costume to (19c v)\n        end\n    end\n    if <(ThisBlock'sType) = [20]> then\n        switch costume to (20a v)\n    end\n    if <(ThisBlock'sType) = [21]> then\n        switch costume to (21a v)\n        if < (Sides) contains [R]?> then\n            switch costume to (21c v)\n        end\n    end\n    if <(ThisBlock'sType) = [22]> then\n        switch costume to (22b v)\n        if <(length of (Sides)) = [4]> then\n            switch costume to (22a v)\n        end\n    end\n    if <(ThisBlock'sType) = [24]> then\n        switch costume to (24a v)\n    end\n    if <(ThisBlock'sType) = [26]> then\n        switch costume to (26a v)\n        if < (Sides) contains [D]?> then\n            switch costume to (26c v)\n        end\n    end\n    if <(ThisBlock'sType) = [27]> then\n        switch costume to (27k v)\n        if < (Sides) contains [R]?> then\n            switch costume to (27f v)\n        end\n        if < (Sides) contains [L]?> then\n            switch costume to (27i v)\n        end\n        if << (Sides) contains [L]?> and < (Sides) contains [R]?>> then\n            switch costume to (27b v)\n        end\n    end\n    if <(ThisBlock'sType) = [28]> then\n        switch costume to (28a v)\n    end\nend\nset [thisblockstypefull v] to (costume [name v])\n\ndefine GoToMouse\ngo to x: (((round (((mouse x) - (MapX)) / (32))) * (32)) + (MapX)) y: (((round (((mouse y) - (MapY)) / (32))) * (32)) + (MapY))\n\ndefine Fix Surroundings\nset [fixingsurroundings v] to [1]\nGoToMouse\nchange x by (32)\nScanFor (round (((x position) - (MapX)) / (32))) (round (((y position) - (MapY)) / (32)))\nif <<(FoundPosition) = [1]> and <<(FoundInList) = [Block]> or <(FoundInList) = [Semi]>>> then\n    set [placementno. v] to (ScanNo.)\n    set [placementlist v] to (FoundInList)\n    Fix Costume\n    Replace Costume\nend\nGoToMouse\nchange y by (32)\nScanFor (round (((x position) - (MapX)) / (32))) (round (((y position) - (MapY)) / (32)))\nif <<(FoundPosition) = [1]> and <<(FoundInList) = [Block]> or <(FoundInList) = [Semi]>>> then\n    set [placementno. v] to (ScanNo.)\n    set [placementlist v] to (FoundInList)\n    Fix Costume\n    Replace Costume\nend\nGoToMouse\nchange x by (-32)\nScanFor (round (((x position) - (MapX)) / (32))) (round (((y position) - (MapY)) / (32)))\nif <<(FoundPosition) = [1]> and <<(FoundInList) = [Block]> or <(FoundInList) = [Semi]>>> then\n    set [placementno. v] to (ScanNo.)\n    set [placementlist v] to (FoundInList)\n    Fix Costume\n    Replace Costume\nend\nGoToMouse\nchange y by (-32)\nScanFor (round (((x position) - (MapX)) / (32))) (round (((y position) - (MapY)) / (32)))\nif <<(FoundPosition) = [1]> and <<(FoundInList) = [Block]> or <(FoundInList) = [Semi]>>> then\n    set [placementno. v] to (ScanNo.)\n    set [placementlist v] to (FoundInList)\n    Fix Costume\n    Replace Costume\nend\nset [fixingsurroundings v] to [0]\n\nwhen I receive [costuming v]\nif <(BlockNo.) > [0]> then\n    switch costume to (item (BlockNo.) of [blocktype v])\nend\nif <not <(EditMode) = [0]>> then\n    show\nend\n\ndefine Replace Costume\nif <(PlacementList) = [Block]> then\n    replace item (PlacementNo.) of [blocktype v] with (costume [name v])\nend\nif <(PlacementList) = [Semi]> then\n    replace item (PlacementNo.) of [semitype v] with (costume [name v])\nend\n\ndefine CheckBlock'sType\nset [blocktypebeingedited v] to []\nset [blocktypebeingeditedfull v] to []\nif <(FoundInList) = [Block]> then\n    if <(round (join (letter (1) of (item (ScanNo.) of [blocktype v])) (letter (2) of (item (ScanNo.) of [blocktype v])))) = [0]> then\n        set [blocktypebeingedited v] to (letter (1) of (item (ScanNo.) of [blocktype v]))\n    else\n        set [blocktypebeingedited v] to (join (letter (1) of (item (ScanNo.) of [blocktype v])) (letter (2) of (item (ScanNo.) of [blocktype v])))\n    end\n    set [blocktypebeingeditedfull v] to (item (ScanNo.) of [blocktype v])\nend\nif <(FoundInList) = [Semi]> then\n    if <(round (join (letter (1) of (item (ScanNo.) of [semitype v])) (letter (2) of (item (ScanNo.) of [semitype v])))) = [0]> then\n        set [blocktypebeingedited v] to (letter (1) of (item (ScanNo.) of [semitype v]))\n    else\n        set [blocktypebeingedited v] to (join (letter (1) of (item (ScanNo.) of [semitype v])) (letter (2) of (item (ScanNo.) of [semitype v])))\n    end\n    set [blocktypebeingeditedfull v] to (item (ScanNo.) of [semitype v])\nend\nif <(FoundInList) = [Enemy]> then\n    set [blocktypebeingedited v] to [\]\n    if <(EditMode) = [3]> then\n        set [blocktypebeingeditedfull v] to (item (ScanNo.) of [entype v])\n    else\n        set [blocktypebeingeditedfull v] to [\]\n    end\nend\nif <(FoundInList) = [Unique]> then\n    set [blocktypebeingedited v] to [0]\n    if <(EditMode) = [3]> then\n        set [blocktypebeingeditedfull v] to (item (ScanNo.) of [untype v])\n    else\n        set [blocktypebeingeditedfull v] to [0]\n    end\n    if <<<(item (ScanNo.) of [untype v]) = [.]> or <(letter (1) of (item (ScanNo.) of [untype v])) = [,]>> or <<(item (ScanNo.) of [untype v]) = [#]> or <<(item (ScanNo.) of [untype v]) = [']> or <(item (ScanNo.) of [untype v]) = [\(]>>>> then\n        set [blocktypebeingedited v] to [\]\n    end\nend\nif <(FoundInList) = [Pipe]> then\n    set [blocktypebeingedited v] to [\]\n    if <(EditMode) = [3]> then\n        set [blocktypebeingeditedfull v] to (item (ScanNo.) of [pipetype v])\n    else\n        set [blocktypebeingeditedfull v] to [\]\n    end\nend\n\ndefine BlockTypeSelected\nif <(CostumeSelected) < [100]> then\n    set [blocktypeselected v] to [Unique]\nelse\n    set [blocktypeselected v] to [Enemy]\nend\nif <<<<(CostumeSelected) = [1]> or <(CostumeSelected) = [14]>> or <<<(CostumeSelected) = [11]> or <(CostumeSelected) = [15]>> or <<(CostumeSelected) = [12]> or <(CostumeSelected) = [13]>>>> or <<<(CostumeSelected) = [4]> or <<(CostumeSelected) = [16]> or <(CostumeSelected) = [17]>>> or <<<(CostumeSelected) = [5]> or <(CostumeSelected) = [22]>> or <<(CostumeSelected) = [7]> or <<(CostumeSelected) = [9]> or <(CostumeSelected) = [10]>>>>>> then\n    set [blocktypeselected v] to [Block]\nend\nif <<<<(CostumeSelected) = [2]> or <(CostumeSelected) = [18]>> or <<(CostumeSelected) = [19]> or <(CostumeSelected) = [20]>>> or <<<<(CostumeSelected) = [21]> or <(CostumeSelected) = [26]>> or <<(CostumeSelected) = [3]> or <(CostumeSelected) = [25]>>> or <<<(CostumeSelected) = [6]> or <(CostumeSelected) = [28]>> or <<<(CostumeSelected) = [8]> or <(CostumeSelected) = [27]>> or <<(CostumeSelected) = [23]> or <(CostumeSelected) = [24]>>>>>> then\n    set [blocktypeselected v] to [Semi]\nend\nif <(letter (1) of (CostumeSelected)) = [£]> then\n    set [blocktypeselected v] to [Pipe]\nend\nif <(CostumeSelected) = [Spawn]> then\n    set [blocktypeselected v] to [Spawn]\nend\nif <(CostumeSelected) = [Goal]> then\n    set [blocktypeselected v] to [Goal]\nend\nif <(CostumeSelected) = [Water]> then\n    set [blocktypeselected v] to [Water]\nend\nif <(CostumeSelected) = [Lava]> then\n    set [blocktypeselected v] to [Lava]\nend\nif <(CostumeSelected) = [Key]> then\n    set [blocktypeselected v] to [Key]\nend\n\ndefine MakePlacement\nset [thisblock'stype v] to (CostumeSelected)\nFind Placement (round (((mouse x) - (MapX)) / (32))) (round (((mouse y) - (MapY)) / (32)))\nGoToMouse\nFix Costume\nif <not <(costume [name v]) = [Block]>> then\n    BlockTypeSelected\n    if <(BlockTypeSelected) = [Block]> then\n        insert (round (((mouse x) - (MapX)) / (32))) at (PlacementNo.) of [blockx v] \n        insert (round (((mouse y) - (MapY)) / (32))) at (PlacementNo.) of [blocky v] \n        insert (costume [name v]) at (PlacementNo.) of [blocktype v] \n    end\n    if <(BlockTypeSelected) = [Semi]> then\n        insert (round (((mouse x) - (MapX)) / (32))) at (PlacementNo.) of [semix v] \n        insert (round (((mouse y) - (MapY)) / (32))) at (PlacementNo.) of [semiy v] \n        insert (costume [name v]) at (PlacementNo.) of [semitype v] \n    end\n    if <(BlockTypeSelected) = [Enemy]> then\n        insert (round (((mouse x) - (MapX)) / (32))) at (PlacementNo.) of [enx v] \n        insert (round (((mouse y) - (MapY)) / (32))) at (PlacementNo.) of [eny v] \n        insert (CostumeSelected) at (PlacementNo.) of [entype v] \n        insert [0] at (PlacementNo.) of [enkey v] \n    end\n    if <(BlockTypeSelected) = [Unique]> then\n        insert (round (((mouse x) - (MapX)) / (32))) at (PlacementNo.) of [unx v] \n        insert (round (((mouse y) - (MapY)) / (32))) at (PlacementNo.) of [uny v] \n        insert (costume [name v]) at (PlacementNo.) of [untype v] \n    end\n    if <(BlockTypeSelected) = [Pipe]> then\n        insert (round (((mouse x) - (MapX)) / (32))) at (PlacementNo.) of [pipex v] \n        insert (round (((mouse y) - (MapY)) / (32))) at (PlacementNo.) of [pipey v] \n        insert (CostumeSelected) at (PlacementNo.) of [pipetype v] \n        if <(CostumeSelected) = [£1]> then\n            insert [D1] at (PlacementNo.) of [pipedir v] \n        end\n        if <(CostumeSelected) = [£2]> then\n            insert [D2] at (PlacementNo.) of [pipedir v] \n        end\n        if <(CostumeSelected) = [£3]> then\n            insert [U1] at (PlacementNo.) of [pipedir v] \n        end\n        if <(CostumeSelected) = [£4]> then\n            insert [U2] at (PlacementNo.) of [pipedir v] \n        end\n        if <(CostumeSelected) = [£5]> then\n            insert [R1] at (PlacementNo.) of [pipedir v] \n        end\n        if <(CostumeSelected) = [£6]> then\n            insert [R2] at (PlacementNo.) of [pipedir v] \n        end\n        if <(CostumeSelected) = [£7]> then\n            insert [L1] at (PlacementNo.) of [pipedir v] \n        end\n        if <(CostumeSelected) = [£8]> then\n            insert [L2] at (PlacementNo.) of [pipedir v] \n        end\n        if <(CostumeSelected) = [£9]> then\n            insert [Door] at (PlacementNo.) of [pipedir v] \n        end\n        if <(CostumeSelected) = [£10]> then\n            insert [DoorL] at (PlacementNo.) of [pipedir v] \n        end\n        insert [0] at (PlacementNo.) of [pipestate v] \n    end\n    if <(BlockTypeSelected) = [Spawn]> then\n        set [originalspawnx v] to ((round (((mouse x) - (MapX)) / (32))) * (32))\n        set [originalspawny v] to ((round (((mouse y) - (MapY)) / (32))) * (32))\n        set [spawnx v] to (OriginalSpawnX)\n        set [spawny v] to (OriginalSpawnY)\n    end\n    if <(BlockTypeSelected) = [Goal]> then\n        set [goalx v] to ((round (((mouse x) - (MapX)) / (32))) * (32))\n        set [goaly v] to ((round (((mouse y) - (MapY)) / (32))) * (32))\n        set [goallevel v] to (GroundLevel)\n    end\n    if <(BlockTypeSelected) = [Water]> then\n        if <(GroundLevel) = [1]> then\n            set [1water v] to ((round (((mouse y) - (MapY)) / (32))) * (32))\n        end\n        if <(GroundLevel) = [0]> then\n            set [0water v] to ((round (((mouse y) - (MapY)) / (32))) * (32))\n        end\n        if <(GroundLevel) = [-1]> then\n            set [-1water v] to ((round (((mouse y) - (MapY)) / (32))) * (32))\n        end\n        set [costumeselected v] to (item (1) of [hotbar v])\n        set [itemmenu v] to [0.9]\n    end\n    if <(BlockTypeSelected) = [Lava]> then\n        if <(GroundLevel) = [1]> then\n            set [1lava v] to ((round (((mouse y) - (MapY)) / (32))) * (32))\n        end\n        if <(GroundLevel) = [0]> then\n            set [0lava v] to ((round (((mouse y) - (MapY)) / (32))) * (32))\n        end\n        if <(GroundLevel) = [-1]> then\n            set [-1lava v] to ((round (((mouse y) - (MapY)) / (32))) * (32))\n        end\n        set [costumeselected v] to (item (1) of [hotbar v])\n        set [itemmenu v] to [0.9]\n    end\n    if <(BlockTypeSelected) = [Key]> then\n        insert (round (((mouse x) - (MapX)) / (32))) at (PlacementNo.) of [enx v] \n        insert (round (((mouse y) - (MapY)) / (32))) at (PlacementNo.) of [eny v] \n        insert [l] at (PlacementNo.) of [entype v] \n        insert [1] at (PlacementNo.) of [enkey v] \n    end\n    set [justedited v] to (join (round (((mouse x) - (MapX)) / (32))) (round (((mouse y) - (MapY)) / (32))))\n    change [scanlength v] by (1)\nend\nFix Surroundings\n\ndefine PlayerSpawnShow\ngo to x: ((OriginalSpawnX) + (MapX)) y: ((OriginalSpawnY) + (MapY))\nif <<([abs v] of (x position) ) < [240]> and <([abs v] of (y position) ) < [180]>> then\n    switch costume to (spawn v)\n    stamp\nend\n\nwhen I receive [menuupdate v]\nif <[1] = [1]> then\n    delete this clone\nend\nhide\n\n@UniqueBlocks\n\nwhen flag clicked\ndelete all of [untype v]\ndelete all of [unx v]\ndelete all of [uny v]\nset size to (400) %\nset rotation style [don't rotate v]\npoint in direction (90)\nhide\n\nwhen I receive [map update v]\nif <[1] = [1]> then\n    delete this clone\nend\ndelete all of [aboveblocktype v]\ndelete all of [aboveblockx v]\ndelete all of [aboveblocky v]\nset [conveyerdistance v] to [30]\nif <(length of [deleteblocklist v]) > [0]> then\n    DeleteBlocks\nend\nif <(length of [vinebeaddedatx v]) > [0]> then\n    AddVines\nend\nshow\nLoad Unique\nhide\n\ndefine Load Unique\nif <[1] = [1]> then\n    delete this clone\nend\nif <(EditMode) = [0]> then\n    set [uniqueno. v] to ((item # of (round (((MapX) / (-32)) - (8))) in [uniquex v]) - (1))\n    if <(UniqueNo.) < [0]> then\n        set [uniqueno. v] to [0]\n    end\n    repeat ((length of [uniquex v]) - (UniqueNo.))\n        change [uniqueno. v] by (1)\n        set [x v] to (((item (UniqueNo.) of [uniquex v]) * (32)) + (MapX))\n        set [y v] to (((item (UniqueNo.) of [uniquey v]) * (32)) + (MapY))\n        if <(X) > [242]> then\n            set [uniqueno. v] to [0]\n            GoalShow\n            stop [this script v]\n        end\n        if <<([abs v] of (X) ) < [242]> and <([abs v] of (Y) ) < [182]>> then\n            go to x: (X) y: (Y)\n            switch costume to (hitbox v)\n            if <<<<(item (UniqueNo.) of [uniquetype v]) = [\(]> or <<(item (UniqueNo.) of [uniquetype v]) = [-]> or <<<(item (UniqueNo.) of [uniquetype v]) = [.]> and <(PTimer) = [0]>> or <<(item (UniqueNo.) of [uniquetype v]) = [!]> and <not <(PTimer) = [0]>>>>>> or <(letter (1) of (item (UniqueNo.) of [uniquetype v])) = [,]>> or <<<(item (UniqueNo.) of [uniquetype v]) = [#]> and <(RedBlueSwitch) = [0]>> or <<(item (UniqueNo.) of [uniquetype v]) = [']> and <(RedBlueSwitch) = [1]>>>> then\n                hide\n                create clone of (_myself_ v)\n                show\n            else\n                create clone of (_myself_ v)\n            end\n        end\n    end\nelse\n    set [uniqueno. v] to ((item # of (round (((MapX) / (-32)) - (8))) in [unx v]) - (1))\n    if <(UniqueNo.) < [0]> then\n        set [uniqueno. v] to [0]\n    end\n    repeat ((length of [unx v]) - (UniqueNo.))\n        change [uniqueno. v] by (1)\n        set [x v] to (((item (UniqueNo.) of [unx v]) * (32)) + (MapX))\n        set [y v] to (((item (UniqueNo.) of [uny v]) * (32)) + (MapY))\n        go to x: (X) y: (Y)\n        if <(X) > [242]> then\n            set [uniqueno. v] to [0]\n            GoalShow\n            stop [this script v]\n        end\n        if <<([abs v] of (X) ) < [242]> and <([abs v] of (Y) ) < [182]>> then\n            switch costume to (join (item (UniqueNo.) of [untype v]) [1])\n            stamp\n        end\n    end\nend\nGoalShow\nset [uniqueno. v] to [0]\n\nwhen I receive [costuming v]\nif <(UniqueNo.) > [0]> then\n    if <not <(item (UniqueNo.) of [uniquebounce v]) = [0]>> then\n        change y by (([sin v] of ((item (UniqueNo.) of [uniquebounce v]) * (2400)) ) * (8))\n        change size by (([sin v] of ((item (UniqueNo.) of [uniquebounce v]) * (2400)) ) * (50))\n        replace item (UniqueNo.) of [uniquebounce v] with ((item (UniqueNo.) of [uniquebounce v]) + (0.009))\n        if <(item (UniqueNo.) of [uniquebounce v]) > [0.08]> then\n            replace item (UniqueNo.) of [uniquebounce v] with [0]\n        end\n        go [forward v] (4) layers\n    end\n    if <(item (UniqueNo.) of [uniquetype v]) = ["]> then\n        switch costume to (join ["] (([floor v] of (((GameTimer) * (15)) mod (4)) ) + (1)))\n        stop [this script v]\n    end\n    if <<(letter (1) of (item (UniqueNo.) of [uniquetype v])) = [$]> and <not <(item (UniqueNo.) of [uniquetype v]) = [$]>>> then\n        switch costume to (join [$] (([floor v] of (((GameTimer) * (15)) mod (4)) ) + (1)))\n        stop [this script v]\n    end\n    if <(item (UniqueNo.) of [uniquetype v]) = [$]> then\n        switch costume to ($ v)\n        stop [this script v]\n    end\n    if <(item (UniqueNo.) of [uniquetype v]) = [%]> then\n        if <(PTimer) = [0]> then\n            switch costume to (join [%] (([floor v] of (((GameTimer) * (45)) mod (4)) ) + (2)))\n        else\n            switch costume to (%2 v)\n        end\n        stop [this script v]\n    end\n    if <(item (UniqueNo.) of [uniquetype v]) = [&]> then\n        if <(PTimer) = [0]> then\n            switch costume to (join [&] (([floor v] of (((GameTimer) * (45)) mod (4)) ) + (2)))\n        else\n            switch costume to (&2 v)\n        end\n        stop [this script v]\n    end\n    if <(item (UniqueNo.) of [uniquetype v]) = [*]> then\n        switch costume to (*1 v)\n        stop [this script v]\n    end\n    if <(item (UniqueNo.) of [uniquetype v]) = [\(]> then\n        show\n        switch costume to (join [\(] (([floor v] of (((GameTimer) * (15)) mod (4)) ) + (1)))\n        stamp\n        delete this clone\n    end\n    if <(item (UniqueNo.) of [uniquetype v]) = [\)]> then\n        switch costume to (join [\)] (([floor v] of (((GameTimer) * (15)) mod (2)) ) + (1)))\n        stop [this script v]\n    end\n    if <(item (UniqueNo.) of [uniquetype v]) = [-]> then\n        if <<((item (UniqueNo.) of [uniquex v]) * (32)) = (SpawnX)> and <((item (UniqueNo.) of [uniquey v]) * (32)) = (SpawnY)>> then\n            switch costume to (-5 v)\n            if <(item (UniqueNo.) of [uniquestate v]) > [0]> then\n                switch costume to (-4 v)\n            end\n            if <(item (UniqueNo.) of [uniquestate v]) > [0.33]> then\n                switch costume to (-3 v)\n            end\n            if <(item (UniqueNo.) of [uniquestate v]) > [0.66]> then\n                switch costume to (-2 v)\n            end\n        else\n            switch costume to (-1 v)\n        end\n        stamp\n        delete this clone\n    end\n    if <(item (UniqueNo.) of [uniquetype v]) = [+]> then\n        if <(RedBlueSwitch) = [0]> then\n            switch costume to (+1 v)\n        else\n            switch costume to (+2 v)\n        end\n        stop [this script v]\n    end\n    if <(item (UniqueNo.) of [uniquetype v]) = [']> then\n        show\n        if <(RedBlueSwitch) = [0]> then\n            switch costume to ('1 v)\n        else\n            switch costume to ('2 v)\n            stamp\n            delete this clone\n        end\n    end\n    if <(item (UniqueNo.) of [uniquetype v]) = [#]> then\n        show\n        if <(RedBlueSwitch) = [0]> then\n            switch costume to (#1 v)\n            stamp\n            delete this clone\n        else\n            switch costume to (#2 v)\n        end\n    end\n    if <(item (UniqueNo.) of [uniquetype v]) = [/]> then\n        switch costume to (/1 v)\n    end\n    if <<<(item (UniqueNo.) of [uniquetype v]) = [.]> and <(PTimer) = [0]>> or <<(item (UniqueNo.) of [uniquetype v]) = [!]> and <not <(PTimer) = [0]>>>> then\n        if <(PTimer) = [0]> then\n            switch costume to (join [.] (([floor v] of (((GameTimer) * (15)) mod (4)) ) + (1)))\n        else\n            switch costume to (.1 v)\n        end\n        stamp\n        stop [this script v]\n    end\n    if <<<(letter (1) of (item (UniqueNo.) of [uniquetype v])) = [!]> and <not <(item (UniqueNo.) of [uniquetype v]) = [!]>>> or <<<(item (UniqueNo.) of [uniquetype v]) = [!]> and <(PTimer) = [0]>> or <<(item (UniqueNo.) of [uniquetype v]) = [.]> and <not <(PTimer) = [0]>>>>> then\n        if <(PTimer) = [0]> then\n            switch costume to (join [!] (([floor v] of (((GameTimer) * (15)) mod (4)) ) + (1)))\n        else\n            switch costume to (!1 v)\n        end\n        stop [this script v]\n    end\nend\n\nwhen I receive [environment update v]\nif <<(UniqueNo.) > [0]> and <(AllowMovement) = [1]>> then\n    if <<<(letter (1) of (item (UniqueNo.) of [uniquetype v])) = [!]> and <not <(item (UniqueNo.) of [uniquetype v]) = [!]>>> or <<<(item (UniqueNo.) of [uniquetype v]) = [!]> and <(PTimer) = [0]>> or <<(item (UniqueNo.) of [uniquetype v]) = [.]> and <not <(PTimer) = [0]>>>>> then\n        if <<<(YVel) = [1.1]> and <(Crouching) = [0]>> or <<(YVel) = [4]> and <(Crouching) = [1]>>> then\n            if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [27]> and <<((y position) - ([y position v] of [player v])) < ((64) - ((Small) * (30)))> and <((y position) - ([y position v] of [player v])) > ((32) - ((Small) * (32)))>>> then\n                if <<<(Climbing) = [1]> and <<key (w v) pressed?> or <key (up arrow v) pressed?>>> or <(Climbing) = [0]>> then\n                    if <<<(item (UniqueNo.) of [uniquetype v]) = [!]> and <(PTimer) = [0]>> or <<(item (UniqueNo.) of [uniquetype v]) = [.]> and <not <(PTimer) = [0]>>>> then\n                        if <(item (UniqueNo.) of [uniquebounce v]) = [0]> then\n                            replace item (UniqueNo.) of [uniquebounce v] with [0.01]\n                            start sound [Bump v]\n                        end\n                        if <not <(Powerup) = [None]>> then\n                            add (UniqueNo.) to [deleteblocklist v]\n                            add (item (UniqueNo.) of [uniquex v]) to [particlemakex v]\n                            add (item (UniqueNo.) of [uniquey v]) to [particlemakey v]\n                            add [Brick] to [particlemaketype v]\n                            start sound [BrickShatter v]\n                        end\n                    else\n                        ItemBlockUsed\n                    end\n                    set [blockbouncex v] to (x position)\n                    set [blockbouncey v] to ((y position) + (32))\n                    broadcast (BouncedBlock v)\n                end\n            end\n        end\n        stop [this script v]\n    end\n    if <(item (UniqueNo.) of [uniquetype v]) = ["]> then\n        if <<<(YVel) = [1.1]> and <(Crouching) = [0]>> or <<(YVel) = [4]> and <(Crouching) = [1]>>> then\n            if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [27]> and <<((y position) - ([y position v] of [player v])) < ((64) - ((Small) * (30)))> and <((y position) - ([y position v] of [player v])) > ((32) - ((Small) * (32)))>>> then\n                if <<<(Climbing) = [1]> and <<key (w v) pressed?> or <key (up arrow v) pressed?>>> or <(Climbing) = [0]>> then\n                    if <(item (UniqueNo.) of [uniquebounce v]) = [0]> then\n                        replace item (UniqueNo.) of [uniquebounce v] with [0.01]\n                        start sound [Bump v]\n                    end\n                    add (x position) to [aboveblockx v]\n                    add ((y position) + (32)) to [aboveblocky v]\n                    add [Note] to [aboveblocktype v]\n                    broadcast (NoteBouncedBlock v)\n                end\n            end\n        end\n        switch costume to (abovescan v)\n        if <<touching (enemies + other v)?> or <touching (items v)?>> then\n            if <(item (UniqueNo.) of [uniquebounce v]) = [0]> then\n                replace item (UniqueNo.) of [uniquebounce v] with [0.01]\n                start sound [Bump v]\n            end\n            add (x position) to [aboveblockx v]\n            add ((y position) + (32)) to [aboveblocky v]\n            add [Note] to [aboveblocktype v]\n            broadcast (NoteBouncedBlock v)\n        end\n        stop [this script v]\n    end\n    if <<(letter (1) of (item (UniqueNo.) of [uniquetype v])) = [$]> and <not <(item (UniqueNo.) of [uniquetype v]) = [$]>>> then\n        if <<<(YVel) = [1.1]> and <(Crouching) = [0]>> or <<(YVel) = [4]> and <(Crouching) = [1]>>> then\n            if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [27]> and <<((y position) - ([y position v] of [player v])) < ((64) - ((Small) * (30)))> and <((y position) - ([y position v] of [player v])) > ((32) - ((Small) * (32)))>>> then\n                if <<<(Climbing) = [1]> and <<key (w v) pressed?> or <key (up arrow v) pressed?>>> or <(Climbing) = [0]>> then\n                    ItemBlockUsed\n                    set [blockbouncex v] to (x position)\n                    set [blockbouncey v] to ((y position) + (32))\n                    broadcast (BouncedBlock v)\n                end\n            end\n        end\n        stop [this script v]\n    end\n    if <<(item (UniqueNo.) of [uniquetype v]) = [%]> and <(PTimer) = [0]>> then\n        switch costume to (abovescan v)\n        if <<touching (enemies + other v)?> or <touching (items v)?>> then\n            add (x position) to [aboveblockx v]\n            add ((y position) + (32)) to [aboveblocky v]\n            add [Left] to [aboveblocktype v]\n            broadcast (NoteBouncedBlock v)\n        end\n        switch costume to (hitbox v)\n        stop [this script v]\n    end\n    if <<(item (UniqueNo.) of [uniquetype v]) = [&]> and <(PTimer) = [0]>> then\n        switch costume to (abovescan v)\n        if <<touching (enemies + other v)?> or <touching (items v)?>> then\n            add (x position) to [aboveblockx v]\n            add ((y position) + (32)) to [aboveblocky v]\n            add [Right] to [aboveblocktype v]\n            broadcast (NoteBouncedBlock v)\n        end\n        switch costume to (hitbox v)\n        stop [this script v]\n    end\n    if <(item (UniqueNo.) of [uniquetype v]) = [\(]> then\n        if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [24]> and <<((y position) - ([y position v] of [player v])) < ((48) - ((Small) * (24)))> and <<((y position) - ([y position v] of [player v])) > [-24]> and <(Holding) = [0]>>>> then\n            if <<<<key (w v) pressed?> or <key (s v) pressed?>> or <<key (up arrow v) pressed?> or <key (down arrow v) pressed?>>> and <not <<(YVel) = [0]> or <(YVel) = (Gravity)>>>> then\n                set [climbing v] to [1]\n            end\n            if <(Climbing) = [1]> then\n                set [maintainclimbing v] to [1]\n            end\n        end\n        stop [this script v]\n    end\n    if <(item (UniqueNo.) of [uniquetype v]) = [\)]> then\n        if <<<([abs v] of ((x position) - ([x position v] of [player v])) ) < [30]> and <<<<<key (d v) pressed?> or <key (right arrow v) pressed?>> or <<key (a v) pressed?> or <key (left arrow v) pressed?>>> or <not <(ConveyorXVel) = [0]>>> and <<((y position) - ([y position v] of [player v])) > [-30]> and <((y position) - ([y position v] of [player v])) < ((48) - ((Small) * (24)))>>>> or <<<([abs v] of ((x position) - ([x position v] of [player v])) ) < [27]> and <<((y position) - ([y position v] of [player v])) > [-34]> and <((y position) - ([y position v] of [player v])) < [-24]>>> or <<<([abs v] of ((x position) - ([x position v] of [player v])) ) < [27]> and <<(YVel) = [1.1]> or <(YVel) = [4]>>> and <<((y position) - ([y position v] of [player v])) < ((64) - ((Small) * (30)))> and <((y position) - ([y position v] of [player v])) > ((32) - ((Small) * (32)))>>>>> then\n            if <<(Invincible) = [0]> and <(AllowControl) = [1]>> then\n                broadcast (Powerdown v)\n            end\n        end\n        stop [this script v]\n    end\n    if <(item (UniqueNo.) of [uniquetype v]) = [-]> then\n        if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [24]> and <<((y position) - ([y position v] of [player v])) < ((48) - ((Small) * (24)))> and <((y position) - ([y position v] of [player v])) > [-48]>>> then\n            if <not <<((item (UniqueNo.) of [uniquex v]) * (32)) = (SpawnX)> and <((item (UniqueNo.) of [uniquey v]) * (32)) = (SpawnY)>>> then\n                set [spawnx v] to ((item (UniqueNo.) of [uniquex v]) * (32))\n                set [spawny v] to ((item (UniqueNo.) of [uniquey v]) * (32))\n                replace item (UniqueNo.) of [uniquestate v] with [1]\n                start sound [clear v]\n            end\n        end\n        if <(item (UniqueNo.) of [uniquestate v]) > [0]> then\n            replace item (UniqueNo.) of [uniquestate v] with ((item (UniqueNo.) of [uniquestate v]) - (0.15))\n            if <(item (UniqueNo.) of [uniquestate v]) < [0]> then\n                replace item (UniqueNo.) of [uniquestate v] with [0]\n            end\n        end\n        stop [this script v]\n    end\n    if <(item (UniqueNo.) of [uniquetype v]) = [+]> then\n        if <<<(YVel) = [1.1]> and <(Crouching) = [0]>> or <<(YVel) = [4]> and <(Crouching) = [1]>>> then\n            if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [27]> and <<((y position) - ([y position v] of [player v])) < ((64) - ((Small) * (30)))> and <((y position) - ([y position v] of [player v])) > ((32) - ((Small) * (32)))>>> then\n                if <<<(Climbing) = [1]> and <<key (w v) pressed?> or <key (up arrow v) pressed?>>> or <(Climbing) = [0]>> then\n                    if <(item (UniqueNo.) of [uniquebounce v]) = [0]> then\n                        replace item (UniqueNo.) of [uniquebounce v] with [0.01]\n                        BlockInteractedWith\n                        set [blockbouncex v] to (x position)\n                        set [blockbouncey v] to ((y position) + (32))\n                        broadcast (BouncedBlock v)\n                    end\n                end\n            end\n        end\n        stop [this script v]\n    end\n    if <(item (UniqueNo.) of [uniquetype v]) = [/]> then\n        replace item (UniqueNo.) of [uniquestate v] with ((item (UniqueNo.) of [uniquestate v]) + (0.01))\n        if <(item (UniqueNo.) of [uniquestate v]) > [1.2]> then\n            add (item (UniqueNo.) of [uniquex v]) to [enemyx v]\n            add (item (UniqueNo.) of [uniquey v]) to [enemyy v]\n            add [r] to [enemytype v]\n            add [0] to [enemystate v]\n            add [0] to [enemyyvel v]\n            add [0] to [enemyextra v]\n            if <([x position v] of [player v]) > (x position)> then\n                add [90] to [enemydir v]\n            else\n                add [-90] to [enemydir v]\n            end\n            add [0] to [enemykey v]\n            replace item (UniqueNo.) of [uniquestate v] with [0]\n            if <([x position v] of [player v]) > (x position)> then\n                add ((item (UniqueNo.) of [uniquex v]) + (0.5)) to [particlemakex v]\n            else\n                add ((item (UniqueNo.) of [uniquex v]) - (0.5)) to [particlemakex v]\n            end\n            add (item (UniqueNo.) of [uniquey v]) to [particlemakey v]\n            add [0] to [particlemakedir v]\n            add [Poof] to [particlemaketype v]\n            start sound [bomb-omb v]\n        end\n        stop [this script v]\n    end\n    if <<<(item (UniqueNo.) of [uniquetype v]) = [.]> and <(PTimer) = [0]>> or <<(item (UniqueNo.) of [uniquetype v]) = [!]> and <not <(PTimer) = [0]>>>> then\n        show\n        if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [24]> and <<((y position) - ([y position v] of [player v])) < ((48) - ((Small) * (24)))> and <((y position) - ([y position v] of [player v])) > [-24]>>> then\n            CoinCollected\n        end\n        stop [this script v]\n    end\nend\n\ndefine DeleteBlocks\nrepeat (length of [deleteblocklist v])\n    delete (item (1) of [deleteblocklist v]) of [uniquetype v]\n    delete (item (1) of [deleteblocklist v]) of [uniquex v]\n    delete (item (1) of [deleteblocklist v]) of [uniquey v]\n    delete (item (1) of [deleteblocklist v]) of [uniquebounce v]\n    delete (item (1) of [deleteblocklist v]) of [uniquestate v]\n    RealignKilledBlocksList (item (1) of [deleteblocklist v])\n    delete (1) of [deleteblocklist v]\nend\n\nwhen I receive [thwompbreakblock v]\nif <<(UniqueNo.) > [0]> and <not <<(item (UniqueNo.) of [uniquetype v]) = [\(]> or <(item (UniqueNo.) of [uniquetype v]) = [-]>>>> then\n    BreakBlock\nend\n\ndefine BreakBlock\nset [offset v] to [0]\nrepeat (length of [breakx v])\n    change [offset v] by (1)\n    if <<([abs v] of ((x position) - (item (Offset) of [breakx v])) ) < [26]> and <([abs v] of ((y position) - ((item (Offset) of [breaky v]) + (<<<(item (UniqueNo.) of [uniquetype v]) = [.]> and <(PTimer) = [0]>> or <<(item (UniqueNo.) of [uniquetype v]) = [!]> and <not <(PTimer) = [0]>>>> * (32)))) ) < [16]>> then\n        BlockInteractedWith\n    end\nend\n\nwhen I receive [shellbreakblock v]\nif <(UniqueNo.) > [0]> then\n    if <<([abs v] of ((x position) - (BreakX)) ) < [26]> and <([abs v] of ((y position) - (BreakY)) ) < [16]>> then\n        BlockInteractedWith\n    end\nend\n\nwhen I receive [background update v]\nif <<(UniqueNo.) > [0]> and <(AllowMovement) = [1]>> then\n    if <(item (UniqueNo.) of [uniquetype v]) = ["]> then\n        if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [27]> and <<((y position) - ([y position v] of [player v])) < [-28]> and <((y position) - ([y position v] of [player v])) > [-36]>>> then\n            if <<key (w v) pressed?> or <key (up arrow v) pressed?>> then\n                set [yvel v] to [20]\n            else\n                set [yvel v] to [12]\n            end\n            set [xvel v] to [0]\n            if <(item (UniqueNo.) of [uniquebounce v]) = [0]> then\n                replace item (UniqueNo.) of [uniquebounce v] with [0.01]\n                start sound [Bump v]\n            end\n        end\n        stop [this script v]\n    end\n    if <<(item (UniqueNo.) of [uniquetype v]) = [%]> and <(PTimer) = [0]>> then\n        if <([abs v] of ((x position) - ([x position v] of [player v])) ) < (ConveyerDistance)> then\n            if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [30]> and <<((y position) - ([y position v] of [player v])) < [-28]> and <((y position) - ([y position v] of [player v])) > [-34]>>> then\n                set [conveyorxvel v] to [-2]\n                set [conveyerdistance v] to ([abs v] of ((x position) - ([x position v] of [player v])) )\n                set [movedbyconveyer v] to [1]\n            end\n        end\n        stop [this script v]\n    end\n    if <<(item (UniqueNo.) of [uniquetype v]) = [&]> and <(PTimer) = [0]>> then\n        if <([abs v] of ((x position) - ([x position v] of [player v])) ) < (ConveyerDistance)> then\n            if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [30]> and <<((y position) - ([y position v] of [player v])) < [-28]> and <((y position) - ([y position v] of [player v])) > [-36]>>> then\n                set [conveyorxvel v] to [2]\n                set [conveyerdistance v] to ([abs v] of ((x position) - ([x position v] of [player v])) )\n                set [movedbyconveyer v] to [1]\n            end\n        end\n        stop [this script v]\n    end\n    if <<(letter (1) of (item (UniqueNo.) of [uniquetype v])) = [,]> and <(item (UniqueNo.) of [uniquestate v]) = [0]>> then\n        if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [27]> and <<((y position) - ([y position v] of [player v])) < ((64) - ((Small) * (28)))> and <((y position) - ([y position v] of [player v])) > ((32) - ((Small) * (32)))>>> then\n            if <<<<(Climbing) = [1]> and <<key (w v) pressed?> or <key (up arrow v) pressed?>>> or <(Climbing) = [0]>> and <(YVel) > [0]>> then\n                ItemBlockUsed\n                replace item (UniqueNo.) of [uniquestate v] with [1]\n            end\n        end\n        stop [this script v]\n    end\nend\n\nwhen I receive [bombbreakblock v]\nif <<(UniqueNo.) > [0]> and <not <<<(item (UniqueNo.) of [uniquetype v]) = [\(]> or <(item (UniqueNo.) of [uniquetype v]) = ["]>> or <(item (UniqueNo.) of [uniquetype v]) = [-]>>>> then\n    BombBreakBlock\nend\n\ndefine BombBreakBlock\nset [offset v] to [0]\nrepeat (length of [bombx v])\n    change [offset v] by (1)\n    if <<([abs v] of ((x position) - (item (Offset) of [bombx v])) ) < [24]> and <([abs v] of ((y position) - (item (Offset) of [bomby v])) ) < [24]>> then\n        if <<<(item (UniqueNo.) of [uniquetype v]) = [.]> and <(PTimer) = [0]>> or <<(item (UniqueNo.) of [uniquetype v]) = [!]> and <not <(PTimer) = [0]>>>> then\n            CoinCollected\n        else\n            add (UniqueNo.) to [deleteblocklist v]\n            add (item (UniqueNo.) of [uniquex v]) to [particlemakex v]\n            add (item (UniqueNo.) of [uniquey v]) to [particlemakey v]\n            add [Brick] to [particlemaketype v]\n            start sound [BrickShatter v]\n        end\n        stop [this script v]\n    end\nend\n\ndefine SpawnItemFromBlock\nstart sound [ItemSprout v]\nadd [90] to [itemdirection v]\nadd [0] to [itemstate v]\nif <<(Powerup) = [None]> and <not <<(letter (2) of (item (UniqueNo.) of [uniquetype v])) = [S]> or <(letter (2) of (item (UniqueNo.) of [uniquetype v])) = [U]>>>> then\n    add [M] to [itemtype v]\nelse\n    add (letter (2) of (item (UniqueNo.) of [uniquetype v])) to [itemtype v]\nend\nadd (item (UniqueNo.) of [uniquex v]) to [itemx v]\nadd ((item (UniqueNo.) of [uniquey v]) + (0.25)) to [itemy v]\nadd [0] to [itemyvelocity v]\n\ndefine ItemBlockUsed\nstart sound [Bump v]\nreplace item (UniqueNo.) of [uniquebounce v] with [0.01]\nif <(letter (2) of (item (UniqueNo.) of [uniquetype v])) = [C]> then\n    add [Coin] to [particlemaketype v]\n    add (item (UniqueNo.) of [uniquex v]) to [particlemakex v]\n    add ((item (UniqueNo.) of [uniquey v]) + (1)) to [particlemakey v]\n    add [0] to [particlemakedir v]\n    start sound [Coin v]\nelse\n    if <(letter (2) of (item (UniqueNo.) of [uniquetype v])) = [\(]> then\n        add (item (UniqueNo.) of [uniquex v]) to [enemyx v]\n        add ((item (UniqueNo.) of [uniquey v]) + (0.25)) to [enemyy v]\n        add [g] to [enemytype v]\n        add [0.2] to [enemystate v]\n        add [0] to [enemyyvel v]\n        add [0] to [enemyextra v]\n        add [90] to [enemydir v]\n        add [0] to [enemykey v]\n        start sound [ItemSprout v]\n    else\n        if <(letter (2) of (item (UniqueNo.) of [uniquetype v])) = [o]> then\n            add (item (UniqueNo.) of [uniquex v]) to [enemyx v]\n            add ((item (UniqueNo.) of [uniquey v]) + (1)) to [enemyy v]\n            add [o] to [enemytype v]\n            add [0] to [enemystate v]\n            add [0] to [enemyyvel v]\n            add [0] to [enemyextra v]\n            add [-90] to [enemydir v]\n            add [0] to [enemykey v]\n        else\n            SpawnItemFromBlock\n        end\n    end\nend\nreplace item (UniqueNo.) of [uniquetype v] with [$]\n\ndefine GoalShow\nif <not <(GoalY) = [-1]>> then\n    switch costume to (goal v)\n    go to x: ((GoalX) + (MapX)) y: ((GoalY) + (MapY))\n    if <<([abs v] of (x position) ) < [240]> and <([abs v] of (y position) ) < [190]>> then\n        stamp\n        if <<<([abs v] of ((x position) - ([x position v] of [player v])) ) < [36]> and <<((y position) - ([y position v] of [player v])) < ((65) - ((Small) * (32)))> and <((y position) - ([y position v] of [player v])) > [-50]>>> and <<(HitGoal) = [0]> and <<(AllowControl) = [1]> and <(EditMode) = [0]>>>> then\n            broadcast (Goal v)\n        end\n    end\nend\n\nwhen I receive [menuupdate v]\nif <[1] = [1]> then\n    delete this clone\nend\nhide\n\ndefine BlockInteractedWith\nstart sound [Bump v]\nif <<<(letter (1) of (item (UniqueNo.) of [uniquetype v])) = [!]> and <not <(item (UniqueNo.) of [uniquetype v]) = [!]>>> or <<<(item (UniqueNo.) of [uniquetype v]) = [!]> and <(PTimer) = [0]>> or <<(item (UniqueNo.) of [uniquetype v]) = [.]> and <not <(PTimer) = [0]>>>>> then\n    if <<<(item (UniqueNo.) of [uniquetype v]) = [!]> and <(PTimer) = [0]>> or <<(item (UniqueNo.) of [uniquetype v]) = [.]> and <not <(PTimer) = [0]>>>> then\n        add (UniqueNo.) to [deleteblocklist v]\n        add (item (UniqueNo.) of [uniquex v]) to [particlemakex v]\n        add (item (UniqueNo.) of [uniquey v]) to [particlemakey v]\n        add [Brick] to [particlemaketype v]\n        start sound [BrickShatter v]\n    else\n        ItemBlockUsed\n    end\nend\nif <(item (UniqueNo.) of [uniquetype v]) = ["]> then\n    add (x position) to [aboveblockx v]\n    add ((y position) + (32)) to [aboveblocky v]\n    broadcast (NoteBouncedBlock v)\n    replace item (UniqueNo.) of [uniquebounce v] with [0.01]\nend\nif <<(letter (1) of (item (UniqueNo.) of [uniquetype v])) = [$]> and <not <(item (UniqueNo.) of [uniquetype v]) = [$]>>> then\n    ItemBlockUsed\nend\nif <(item (UniqueNo.) of [uniquetype v]) = [+]> then\n    if <(RedBlueSwitch) = [1]> then\n        set [redblueswitch v] to [0]\n    else\n        set [redblueswitch v] to [1]\n    end\n    replace item (UniqueNo.) of [uniquebounce v] with [0.01]\nend\nif <<<(item (UniqueNo.) of [uniquetype v]) = [.]> and <(PTimer) = [0]>> or <<(item (UniqueNo.) of [uniquetype v]) = [!]> and <not <(PTimer) = [0]>>>> then\n    CoinCollected\nend\n\nwhen I receive [spinattack v]\nif <(UniqueNo.) > [0]> then\n    if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [40]> and <([abs v] of ((y position) - ([y position v] of [player v])) ) < [16]>> then\n        BlockInteractedWith\n    end\nend\n\ndefine AddVines\nrepeat (length of [vinebeaddedatx v])\n    set [offset v] to (item # of ((item (1) of [vinebeaddedatx v]) - (6)) in [uniquex v])\n    repeat until <<not <(item (Offset) of [uniquex v]) < (item (1) of [vinebeaddedatx v])>> or <(Offset) > (length of [uniquex v])>>\n        change [offset v] by (1)\n    end\n    if <(Offset) > (length of [uniquex v])> then\n        set [offset v] to ((length of [uniquex v]) + (1))\n    end\n    insert [0] at (Offset) of [uniquebounce v] \n    insert [0] at (Offset) of [uniquestate v] \n    insert [\(] at (Offset) of [uniquetype v] \n    insert (item (1) of [vinebeaddedatx v]) at (Offset) of [uniquex v] \n    insert (item (1) of [vinebeaddedaty v]) at (Offset) of [uniquey v] \n    delete (1) of [vinebeaddedatx v]\n    delete (1) of [vinebeaddedaty v]\nend\n\ndefine RealignKilledBlocksList (deleteno.)\nset [offset v] to [0]\nrepeat (length of [deleteblocklist v])\n    change [offset v] by (1)\n    if <(item (Offset) of [deleteblocklist v]) > (deleteno.)> then\n        replace item (Offset) of [deleteblocklist v] with ((item (Offset) of [deleteblocklist v]) - (1))\n    end\nend\n\nwhen I receive [shellhit v]\nif <<(UniqueNo.) > [0]> and <<<(item (UniqueNo.) of [uniquetype v]) = [.]> and <(PTimer) = [0]>> or <<(item (UniqueNo.) of [uniquetype v]) = [!]> and <not <(PTimer) = [0]>>>>> then\n    if <<([abs v] of ((x position) - (ShellHitX)) ) < [16]> and <([abs v] of ((y position) - (ShellHitY)) ) < [28]>> then\n        CoinCollected\n    end\nend\n\ndefine CoinCollected\nstart sound [Coin v]\nadd (UniqueNo.) to [deleteblocklist v]\nadd [Coin] to [particlemaketype v]\nadd (item (UniqueNo.) of [uniquex v]) to [particlemakex v]\nadd (item (UniqueNo.) of [uniquey v]) to [particlemakey v]\nadd [0] to [particlemakedir v]\ndelete this clone\n\n@SemiSolids\n\nwhen flag clicked\ndelete all of [semitype v]\ndelete all of [semix v]\ndelete all of [semiy v]\nset size to (400) %\nset rotation style [don't rotate v]\npoint in direction (90)\nhide\n\nwhen I receive [map update v]\nif <[1] = [1]> then\n    delete this clone\nend\nclear graphic effects\nshow\nLoad Blocks\nhide\n\ndefine Load Blocks\nif <[1] = [1]> then\n    delete this clone\nend\nset [blockno. v] to ((item # of (round (((MapX) / (-32)) - (8))) in [semix v]) - (1))\nif <(BlockNo.) < [0]> then\n    set [blockno. v] to [0]\nend\nrepeat ((length of [semix v]) - (BlockNo.))\n    change [blockno. v] by (1)\n    set [x v] to (((item (BlockNo.) of [semix v]) * (32)) + (MapX))\n    set [y v] to (((item (BlockNo.) of [semiy v]) * (32)) + (MapY))\n    go to x: (X) y: (Y)\n    if <(X) > [240]> then\n        set [blockno. v] to [0]\n        stop [this script v]\n    end\n    if <<([abs v] of (X) ) < [242]> and <([abs v] of (Y) ) < [182]>> then\n        hide\n        switch costume to (hitbox v)\n        set [semisolidtype v] to (letter (length of (item (BlockNo.) of [semitype v])) of (item (BlockNo.) of [semitype v]))\n        if <<<<(SemiSolidType) = [b]> or <(SemiSolidType) = [f]>> or <(SemiSolidType) = [i]>> or <<(SemiSolidType) = [o]> or <<(SemiSolidType) = [n]> or <<(SemiSolidType) = [k]> or <(SemiSolidType) = [l]>>>>> then\n            show\n        end\n        if <<(SemiSolidType) = [a]> or <not <(EditMode) = [0]>>> then\n            switch costume to (item (BlockNo.) of [semitype v])\n            stamp\n        else\n            create clone of (_myself_ v)\n        end\n    end\nend\nset [blockno. v] to [0]\n\nwhen I receive [costuming v]\nif <(BlockNo.) > [0]> then\n    switch costume to (item (BlockNo.) of [semitype v])\n    show\n    go to x: (X) y: (Y)\n    stamp\n    delete this clone\nelse\n    WaterShow\nend\n\nwhen I receive [menuupdate v]\nif <[1] = [1]> then\n    delete this clone\nend\nhide\n\ndefine WaterShow\nif <(GroundLevel) = [1]> then\n    if <(1Theme) = [7]> then\n        set [currentwaterlevel v] to (((2800) / (32)) + (0.6))\n        Water [2800]\n    else\n        set [currentwaterlevel v] to (((1Water) / (32)) + (0.6))\n        Water (1Water)\n    end\nend\nif <(GroundLevel) = [0]> then\n    if <(0Theme) = [7]> then\n        set [currentwaterlevel v] to (((2800) / (32)) + (0.6))\n        Water [2800]\n    else\n        set [currentwaterlevel v] to (((0Water) / (32)) + (0.6))\n        Water (0Water)\n    end\nend\nif <(GroundLevel) = [-1]> then\n    if <(-1Theme) = [7]> then\n        set [currentwaterlevel v] to (((2800) / (32)) + (0.6))\n        Water [2800]\n    else\n        set [currentwaterlevel v] to (((-1Water) / (32)) + (0.6))\n        Water (-1Water)\n    end\nend\n\ndefine Water (y)\nif <<(y) = [-1]> and <not <<(CostumeSelected) = [Water]> and <(EditMode) = [1]>>>> then\n    set [currentwaterlevel v] to [$]\nelse\n    show\n    set [ghost v] effect to (50)\n    if <<(CostumeSelected) = [Water]> and <(EditMode) = [1]>> then\n        switch costume to (costume1 v)\n        set size to (400) %\n        switch costume to (join [Water] (([floor v] of (((GameTimer) * (15)) mod (4)) ) + (1)))\n        go to x: ((MapX) mod (32)) y: (((round (((mouse y) - (MapY)) / (32))) * (32)) + (MapY))\n        set [currentwaterlevel v] to [$]\n    else\n        switch costume to (costume1 v)\n        set size to (400) %\n        switch costume to (join [Water] (([floor v] of (((GameTimer) * (15)) mod (4)) ) + (1)))\n        go to x: ((MapX) mod (32)) y: ((y) + (MapY))\n        if <(y position) > [280]> then\n            switch costume to (costume1 v)\n            set size to (400) %\n            switch costume to (join [Water] (([floor v] of (((GameTimer) * (15)) mod (4)) ) + (1)))\n            go to x: ((MapX) mod (32)) y: (288)\n            set [ghost v] effect to (50)\n        end\n        if <(y position) < [-180]> then\n            hide\n        end\n    end\nend\n\n@Background\n\nwhen flag clicked\nset [cloneno. v] to [1]\ncreate clone of (_myself_ v)\nset [cloneno. v] to [0]\nset [menu v] to [1]\nshow list [save code v]\nbroadcast (StartLoop v)\n\nwhen I receive [background update v]\nif <(CloneNo.) = [0]> then\n    erase all\n    if <(EditMode) = [0]> then\n        if <<(AllowMovement) = [1]> or <(GameTimer) < [0.4]>> then\n            if <(HitGoal) = [1]> then\n                set [mapx v] to ((GoalX) * (-1))\n                set [mapy v] to (((GoalY) - (60)) * (-1))\n            else\n                if <(GroundLevel) = [1]> then\n                    CameraMovement (1Camera)\n                end\n                if <(GroundLevel) = [0]> then\n                    CameraMovement (0Camera)\n                end\n                if <(GroundLevel) = [-1]> then\n                    CameraMovement (-1Camera)\n                end\n            end\n        end\n    else\n        if <(ItemMenu) = [0]> then\n            if <<key (w v) pressed?> or <key (up arrow v) pressed?>> then\n                change [mapy v] by ((-5) * ((<key (space v) pressed?> * (2)) + (1)))\n            end\n            if <<key (s v) pressed?> or <key (down arrow v) pressed?>> then\n                change [mapy v] by ((5) * ((<key (space v) pressed?> * (2)) + (1)))\n            end\n            if <<key (d v) pressed?> or <key (right arrow v) pressed?>> then\n                change [mapx v] by ((-5) * ((<key (space v) pressed?> * (2)) + (1)))\n            end\n            if <<key (a v) pressed?> or <key (left arrow v) pressed?>> then\n                change [mapx v] by ((5) * ((<key (space v) pressed?> * (2)) + (1)))\n            end\n        end\n    end\n    MapLimits\nend\nswitch costume to (costume1 v)\nset size to (400) %\nif <(GroundLevel) = [1]> then\n    set [currenttheme v] to (1Theme)\nend\nif <(GroundLevel) = [0]> then\n    set [currenttheme v] to (0Theme)\nend\nif <(GroundLevel) = [-1]> then\n    set [currenttheme v] to (-1Theme)\nend\nswitch costume to (CurrentTheme)\nif <(CurrentTheme) = [9]> then\n    if <<((GameTimer) mod (2)) < [1.31]> and <not <((GameTimer) mod (2)) < [1.2]>>> then\n        switch costume to (costume1 v)\n        set size to (400) %\n        if <((GameTimer) mod (2)) < [1.30]> then\n            switch costume to (9-6 v)\n        end\n        if <((GameTimer) mod (2)) < [1.28]> then\n            switch costume to (9-3/5 v)\n        end\n        if <((GameTimer) mod (2)) < [1.26]> then\n            switch costume to (9-2/4 v)\n        end\n        if <((GameTimer) mod (2)) < [1.24]> then\n            switch costume to (9-3/5 v)\n        end\n        if <((GameTimer) mod (2)) < [1.22]> then\n            switch costume to (9-2/4 v)\n            if <<((GameTimer) mod (2)) < [1.21]> and <(EditMode) = [0]>> then\n                start sound [thunder v]\n            end\n        end\n    end\nend\ngo to x: ((((MapX) / (2)) mod (1024)) + ((CloneNo.) * (-1024))) y: (((MapY) / (2)) + ((<(GroundLevel) = [1]> * (664)) + ((<(GroundLevel) = [0]> * (8)) + (<(GroundLevel) = [-1]> * (-664)))))\nif <([abs v] of ((((MapX) / (2)) mod (1024)) + ((CloneNo.) * (-1024))) ) < [740]> then\n    show\n    stamp\n    hide\nend\nif <<not <(GoalY) = [-1]>> and <(GoalLevel) = (GroundLevel)>> then\n    switch costume to (costume1 v)\n    set size to (400) %\n    switch costume to (end v)\n    go to x: ((GoalX) + (MapX)) y: ((MapY) mod (32))\n    if <([abs v] of (x position) ) < [465]> then\n        show\n        stamp\n        hide\n    end\nend\nif <(CloneNo.) = [0]> then\n    broadcast (Map Update v)\nend\n\nwhen I receive [maplimitscheck v]\nMapLimits\n\ndefine MapLimits\nif <(CameraShake) > [0]> then\n    change [mapx v] by (round (([sin v] of ((CameraShake) * (360)) ) * (5)))\n    change [camerashake v] by (-0.2)\n    if <(CameraShake) < [0.05]> then\n        set [camerashake v] to [0]\n    end\nend\nif <(GroundLevel) = [1]> then\n    if <(MapY) > [-1256]> then\n        set [mapy v] to [-1256]\n    end\n    if <(MapY) < [-2314]> then\n        set [mapy v] to [-2314]\n    end\nend\nif <(GroundLevel) = [0]> then\n    if <(MapY) > [56]> then\n        set [mapy v] to [56]\n    end\n    if <(MapY) < [-970]> then\n        set [mapy v] to [-970]\n    end\nend\nif <(GroundLevel) = [-1]> then\n    if <(MapY) > [1400]> then\n        set [mapy v] to [1400]\n    end\n    if <(MapY) < [342]> then\n        set [mapy v] to [342]\n    end\nend\nif <<<(MapX) < ((GoalX) * (-1))> and <<(EditMode) = [0]> or <<not <(EditMode) = [0]>> and <not <(CostumeSelected) = [Goal]>>>>> and <<(GroundLevel) = (GoalLevel)> and <not <(GoalY) = [-1]>>>> then\n    set [mapx v] to ((GoalX) * (-1))\nend\n\ndefine CameraMovement (type)\nif <(type) = [1]> then\n    change [mapx v] by (round ((((PlayerX) * (-1)) - (MapX)) / (2)))\n    if <(((PlayerY) * (-1)) - (MapY)) < [0]> then\n        if <([abs v] of (((PlayerY) * (-1)) - (MapY)) ) > [40]> then\n            change [mapy v] by (round ((round ((((PlayerY) * (-1)) - (MapY)) / (2))) - ((([abs v] of (((PlayerY) * (-1)) - (MapY)) ) / (((PlayerY) * (-1)) - (MapY))) * (20))))\n        end\n    else\n        change [mapy v] by (round ((((PlayerY) * (-1)) - (MapY)) / (2)))\n    end\nend\nif <(type) = [2]> then\n    change [mapx v] by (round ((((PlayerX) * (-1)) - (MapX)) / (2)))\n    if <(((PlayerY) * (-1)) - (MapY)) < [0]> then\n        if <([abs v] of (((PlayerY) * (-1)) - (MapY)) ) > [40]> then\n            change [mapy v] by (round ((round ((((PlayerY) * (-1)) - (MapY)) / (2))) - ((([abs v] of (((PlayerY) * (-1)) - (MapY)) ) / (((PlayerY) * (-1)) - (MapY))) * (20))))\n        end\n    else\n        change [mapy v] by (round ((((PlayerY) * (-1)) - (MapY)) / (2)))\n    end\n    if <(MapX) > [0]> then\n        set [mapx v] to [0]\n    end\nend\nif <(type) = [3]> then\n    change [mapx v] by (round ((((PlayerX) * (-1)) - (MapX)) / (2)))\nend\nif <(type) = [4]> then\n    if <(((PlayerY) * (-1)) - (MapY)) < [0]> then\n        if <([abs v] of (((PlayerY) * (-1)) - (MapY)) ) > [40]> then\n            change [mapy v] by (round ((round ((((PlayerY) * (-1)) - (MapY)) / (2))) - ((([abs v] of (((PlayerY) * (-1)) - (MapY)) ) / (((PlayerY) * (-1)) - (MapY))) * (20))))\n        end\n    else\n        change [mapy v] by (round ((((PlayerY) * (-1)) - (MapY)) / (2)))\n    end\nend\nif <(type) = [5]> then\n    if <(round ((((PlayerX) * (-1)) - (MapX)) / (2))) < [0]> then\n        change [mapx v] by (round ((((PlayerX) * (-1)) - (MapX)) / (2)))\n    end\nend\nif <(type) = [6]> then\n    if <(((PlayerY) * (-1)) - (MapY)) < [-40]> then\n        change [mapy v] by (round ((round ((((PlayerY) * (-1)) - (MapY)) / (2))) - ((([abs v] of (((PlayerY) * (-1)) - (MapY)) ) / (((PlayerY) * (-1)) - (MapY))) * (20))))\n    end\nend\nif <(type) = [8]> then\n    if <(AllowControl) = [1]> then\n        change [mapx v] by (-1)\n    end\nend\nif <(type) = [9]> then\n    if <(AllowControl) = [1]> then\n        change [mapy v] by (-1)\n    end\nend\n\nwhen I receive [menuupdate v]\nerase all\n\nwhen flag clicked\nswitch costume to (main v)\nset [brightness v] effect to (-100)\nwait (2.5) seconds\nclear graphic effects\nif <(Menu) = [1]> then\n    set [brightness v] effect to (25)\n    repeat (10)\n        change [brightness v] effect by (-2.5)\n    end\n    clear graphic effects\nend\n\nwhen I receive [transitiontomaker v]\nclear graphic effects\n\nwhen I receive [startloop v]\nreset timer\nwait (0) seconds\nforever\n    if <(Menu) = [0]> then\n        broadcast (Background Update v)\n    end\n    if <(Menu) = [0.5]> then\n        broadcast (LevelIntroUpdate v)\n        set [allowcontrol v] to [0]\n    end\n    if <(Menu) = [1]> then\n        broadcast (MenuUpdate v)\n        show\n        go to x: (0) y: (0)\n        switch costume to (main v)\n        change [gametimer v] by (0.01)\n        set [allowcontrol v] to [0]\n    end\n    set [fps v] to ((1) / (timer))\n    reset timer\nend\n\n@Enemies + Other\n\nwhen flag clicked\ndelete all of [entype v]\ndelete all of [enx v]\ndelete all of [eny v]\nset [enemygravity v] to [0.98]\nset size to (400) %\nset rotation style [left-right v]\npoint in direction (90)\nhide\n\nwhen I receive [enemyupdate v]\nif <[1] = [1]> then\n    delete this clone\nend\ndelete all of [breakx v]\ndelete all of [breaky v]\ndelete all of [bombx v]\ndelete all of [bomby v]\nset [shellhitx v] to [0]\nset [shellhity v] to [0]\nif <(length of [deleteenemylist v]) > [0]> then\n    DeleteEnemies\nend\nswitch costume to (hitbox v)\nhide\nLoad Enemies\nbroadcast (Enemy Bumping Update v)\n\ndefine Load Enemies\nif <[1] = [1]> then\n    delete this clone\nend\nset [enemyno. v] to [0]\nif <(EditMode) = [0]> then\n    repeat (length of [enemyx v])\n        change [enemyno. v] by (1)\n        set [x v] to (((item (EnemyNo.) of [enemyx v]) * (32)) + (MapX))\n        set [y v] to (((item (EnemyNo.) of [enemyy v]) * (32)) + (MapY))\n        go to x: (X) y: (Y)\n        if <<([abs v] of ((X) + ((<(item (EnemyNo.) of [enemytype v]) = [d]> * (16)) + (<<(item (EnemyNo.) of [enemytype v]) = [h]> or <(item (EnemyNo.) of [enemytype v]) = [i]>> * (-16)))) ) < [226]> and <<(Y) > ((-140) + (<(item (EnemyNo.) of [enemytype v]) = [d]> * (26)))> and <(Y) < [180]>>> then\n            create clone of (_myself_ v)\n        end\n    end\nelse\n    repeat (length of [enx v])\n        change [enemyno. v] by (1)\n        set [x v] to (((item (EnemyNo.) of [enx v]) * (32)) + (MapX))\n        set [y v] to (((item (EnemyNo.) of [eny v]) * (32)) + (MapY))\n        go to x: (X) y: (Y)\n        if <<([abs v] of (X) ) < [240]> and <([abs v] of (Y) ) < [180]>> then\n            point in direction (-90)\n            switch costume to (join (item (EnemyNo.) of [entype v]) [1])\n            stamp\n            if <<(item (EnemyNo.) of [enkey v]) = [1]> and <not <(item (EnemyNo.) of [entype v]) = [l]>>> then\n                change x by (12)\n                change y by (12)\n                switch costume to (l1 v)\n                stamp\n            end\n        end\n    end\nend\nset [enemyno. v] to [0]\n\ndefine FindFloor\nset [offset v] to [0]\nif <<touching (enemies + other v)?> and <not <<<(item (EnemyNo.) of [enemytype v]) = [b]> or <(item (EnemyNo.) of [enemytype v]) = [e]>> and <(item (EnemyNo.) of [enemystate v]) = [2]>>>> then\n    replace item (EnemyNo.) of [enemyyvel v] with [0]\n    repeat until <not <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <<touching (semisolids v)?> or <touching (enemies + other v)?>>>>\n        change y by (1)\n        change [offset v] by (1)\n        if <(Offset) > [18]> then\n            set y to (Y)\n            stop [this script v]\n        end\n    end\nelse\n    repeat until <not <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <touching (semisolids v)?>>>\n        change y by (1)\n        change [offset v] by (1)\n        if <(Offset) > [12]> then\n            set y to (Y)\n            stop [this script v]\n        end\n    end\nend\n\ndefine FindCeiling\nset [offset v] to [0]\nrepeat until <not <<touching (blocks v)?> or <touching (uniqueblocks v)?>>>\n    change [offset v] by (1)\n    change y by (-1)\n    if <(Offset) > [47]> then\n        set y to (Y)\n        stop [this script v]\n    end\nend\n\nwhen I receive [environment update v]\nif <(EnemyNo.) > [0]> then\n    if <(AllowControl) = [0]> then\n        stop [this script v]\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [a]> then\n        BasicDamagePlayer\n        if <(SlidingExtra) = [0]> then\n            if <<<([abs v] of ((x position) - ([x position v] of [player v])) ) < [28]> and <([abs v] of ((y position) - ([y position v] of [player v])) ) < [28]>> and <([y position v] of [player v]) > ((y position) + (4))>> then\n                add (EnemyNo.) to [deleteenemylist v]\n                add (((x position) - (MapX)) / (32)) to [particlemakex v]\n                add (((y position) - (MapY)) / (32)) to [particlemakey v]\n                add [GSquash] to [particlemaketype v]\n                set [yvel v] to [16]\n                start sound [Stomp v]\n            end\n        end\n    end\n    if <<(item (EnemyNo.) of [enemytype v]) = [b]> or <(item (EnemyNo.) of [enemytype v]) = [e]>> then\n        BasicDamagePlayer\n        if <(item (EnemyNo.) of [enemystate v]) = [2]> then\n            switch costume to (shellcheck v)\n            if <<touching (enemies + other v)?> or <touching (uniqueblocks v)?>> then\n                set [shellhitx v] to (x position)\n                set [shellhity v] to (y position)\n                set [shellhitno. v] to (EnemyNo.)\n                broadcast (ShellHit v)\n            end\n            switch costume to (hitbox3 v)\n        end\n        if <(SlidingExtra) = [0]> then\n            if <(item (EnemyNo.) of [enemystate v]) = [1]> then\n                if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < ((28) + (<key (space v) pressed?> * (6)))> and <([abs v] of ((y position) - ([y position v] of [player v])) ) < [14]>> then\n                    if <<key (space v) pressed?> and <<(Holding) = [0]> and <<(item (EnemyNo.) of [enemyyvel v]) = [0]> or <(item (EnemyNo.) of [enemyyvel v]) = (EnemyGravity)>>>> then\n                        if <(item (EnemyNo.) of [enemytype v]) = [b]> then\n                            set [holding v] to [GKoopaShell]\n                        else\n                            set [holding v] to [RKoopaShell]\n                        end\n                        set [holdingtimer v] to [0]\n                        add (EnemyNo.) to [deleteenemylist v]\n                        hide\n                    else\n                        replace item (EnemyNo.) of [enemystate v] with [2]\n                        replace item (EnemyNo.) of [enemydir v] with ([direction v] of [player v])\n                        set [kicked v] to [1]\n                        start sound [Kick v]\n                    end\n                end\n            end\n            if <<<([abs v] of ((x position) - ([x position v] of [player v])) ) < [28]> and <([abs v] of ((y position) - ([y position v] of [player v])) ) < [28]>> and <<([y position v] of [player v]) > ((y position) + (4))> and <(YVel) < [6]>>> then\n                start sound [Stomp v]\n                if <(item (EnemyNo.) of [enemystate v]) = [2]> then\n                    replace item (EnemyNo.) of [enemystate v] with [1]\n                else\n                    if <(item (EnemyNo.) of [enemystate v]) = [1]> then\n                        replace item (EnemyNo.) of [enemystate v] with [2]\n                    end\n                end\n                if <(item (EnemyNo.) of [enemystate v]) = [0]> then\n                    replace item (EnemyNo.) of [enemystate v] with [1]\n                    if <(item (EnemyNo.) of [enemykey v]) = [1]> then\n                        NewKey (((x position) - (MapX)) / (32)) (((y position) - (MapY)) / (32))\n                        replace item (EnemyNo.) of [enemykey v] with [0]\n                    end\n                end\n                replace item (EnemyNo.) of [enemydir v] with ([direction v] of [player v])\n                set [yvel v] to [16]\n            end\n        end\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [d]> then\n        ThwompDamagePlayer\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [f]> then\n        if <(item (EnemyNo.) of [enemystate v]) = [0]> then\n            BasicDamagePlayer\n        end\n        if <(SlidingExtra) = [0]> then\n            if <(item (EnemyNo.) of [enemystate v]) > [0]> then\n                if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < ((28) + (<key (space v) pressed?> * (6)))> and <([abs v] of ((y position) - ([y position v] of [player v])) ) < [14]>> then\n                    if <<<key (space v) pressed?> and <(item (EnemyNo.) of [enemystate v]) < [10]>> and <<(Holding) = [0]> and <<(item (EnemyNo.) of [enemyyvel v]) = [0]> or <(item (EnemyNo.) of [enemyyvel v]) = (EnemyGravity)>>>> then\n                        set [holding v] to [Bomb]\n                        set [holdingtimer v] to (item (EnemyNo.) of [enemystate v])\n                        add (EnemyNo.) to [deleteenemylist v]\n                        hide\n                    end\n                end\n                replace item (EnemyNo.) of [enemystate v] with ((item (EnemyNo.) of [enemystate v]) + (0.1))\n                if <(item (EnemyNo.) of [enemystate v]) > [12]> then\n                    add (((x position) - (MapX)) / (32)) to [particlemakex v]\n                    add (((y position) - (MapY)) / (32)) to [particlemakey v]\n                    add [Explosion] to [particlemaketype v]\n                    BombExplosion\n                    start sound [bomb-omb v]\n                end\n            end\n            if <<<([abs v] of ((x position) - ([x position v] of [player v])) ) < [28]> and <([abs v] of ((y position) - ([y position v] of [player v])) ) < [28]>> and <([y position v] of [player v]) > ((y position) + (4))>> then\n                if <(item (EnemyNo.) of [enemystate v]) = [0]> then\n                    replace item (EnemyNo.) of [enemystate v] with [1]\n                    set [yvel v] to [16]\n                    start sound [Stomp v]\n                    if <(item (EnemyNo.) of [enemykey v]) = [1]> then\n                        NewKey (((x position) - (MapX)) / (32)) (((y position) - (MapY)) / (32))\n                        replace item (EnemyNo.) of [enemykey v] with [0]\n                    end\n                end\n            end\n        end\n    end\n    if <<(item (EnemyNo.) of [enemytype v]) = [h]> or <(item (EnemyNo.) of [enemytype v]) = [i]>> then\n        PlantDamagePlayer\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [j]> then\n        FireballDamagePlayer\n        if <<([abs v] of (x position) ) > [220]> or <([abs v] of (y position) ) > [160]>> then\n            add (EnemyNo.) to [deleteenemylist v]\n            delete this clone\n        end\n        hide\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [k]> then\n        show\n        if <touching (enemies + other v)?> then\n            set [fireballhitx v] to (x position)\n            set [fireballhity v] to (y position)\n            set [fireballno.hit v] to (EnemyNo.)\n            broadcast (FireballHit v)\n        end\n        if <<([abs v] of (x position) ) > [220]> or <([abs v] of (y position) ) > [160]>> then\n            add (EnemyNo.) to [deleteenemylist v]\n            delete this clone\n        end\n        hide\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [l]> then\n        if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [24]> and <<((y position) - ([y position v] of [player v])) < ((48) - ((Small) * (24)))> and <((y position) - ([y position v] of [player v])) > [-24]>>> then\n            add (EnemyNo.) to [deleteenemylist v]\n            delete this clone\n        end\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [m]> then\n        BasicDamagePlayer\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [n]> then\n        BoomBoomDamagePlayer\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [o]> then\n        if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [27]> and <<((y position) - ([y position v] of [player v])) < [-16]> and <((y position) - ([y position v] of [player v])) > [-36]>>> then\n            PTimer\n        end\n        if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < ((28) + (<key (space v) pressed?> * (6)))> and <([abs v] of ((y position) - ([y position v] of [player v])) ) < [14]>> then\n            if <<key (space v) pressed?> and <<<(Holding) = [0]> and <(PTimer) = [0]>> and <<(item (EnemyNo.) of [enemyyvel v]) = [0]> or <(item (EnemyNo.) of [enemyyvel v]) = (EnemyGravity)>>>> then\n                set [holding v] to [PSwitch]\n                set [holdingtimer v] to [1]\n                add (EnemyNo.) to [deleteenemylist v]\n                hide\n            end\n        end\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [p]> then\n        BasicDamagePlayer\n        if <(SlidingExtra) = [0]> then\n            if <<<([abs v] of ((x position) - ([x position v] of [player v])) ) < [28]> and <([abs v] of ((y position) - ([y position v] of [player v])) ) < [28]>> and <([y position v] of [player v]) > ((y position) + (4))>> then\n                add (EnemyNo.) to [deleteenemylist v]\n                set [yvel v] to [16]\n                start sound [Stomp v]\n            end\n        end\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [q]> then\n        if <<([abs v] of (x position) ) > [220]> or <([abs v] of (y position) ) > [160]>> then\n            add (EnemyNo.) to [deleteenemylist v]\n            delete this clone\n        end\n        if <(item (EnemyNo.) of [enemyextra v]) > [1]> then\n            BasicDamagePlayer\n        end\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [r]> then\n        BasicDamagePlayer\n        if <(SlidingExtra) = [0]> then\n            if <<<([abs v] of ((x position) - ([x position v] of [player v])) ) < [28]> and <([abs v] of ((y position) - ([y position v] of [player v])) ) < [28]>> and <([y position v] of [player v]) > ((y position) + (4))>> then\n                add (EnemyNo.) to [deleteenemylist v]\n                set [yvel v] to [16]\n                start sound [hit1 v]\n            end\n        end\n        if <<([abs v] of (x position) ) > [220]> or <([abs v] of (y position) ) > [160]>> then\n            add (EnemyNo.) to [deleteenemylist v]\n            delete this clone\n        end\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [s]> then\n        replace item (EnemyNo.) of [enemyextra v] with ((item (EnemyNo.) of [enemyextra v]) + (0.01))\n        if <(item (EnemyNo.) of [enemyextra v]) > [1]> then\n            ThrowHammer\n            replace item (EnemyNo.) of [enemyextra v] with [0]\n        end\n        BasicDamagePlayer\n        if <(SlidingExtra) = [0]> then\n            if <<<([abs v] of ((x position) - ([x position v] of [player v])) ) < [28]> and <([abs v] of ((y position) - ([y position v] of [player v])) ) < [28]>> and <([y position v] of [player v]) > ((y position) + (4))>> then\n                add (EnemyNo.) to [deleteenemylist v]\n                set [yvel v] to [16]\n                start sound [Stomp v]\n            end\n        end\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [t]> then\n        BasicDamagePlayer\n        if <<([abs v] of (x position) ) > [220]> or <([abs v] of (y position) ) > [160]>> then\n            add (EnemyNo.) to [deleteenemylist v]\n            delete this clone\n        end\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [u]> then\n        show\n        if <touching (enemies + other v)?> then\n            set [fireballhitx v] to (x position)\n            set [fireballhity v] to (y position)\n            set [fireballno.hit v] to (EnemyNo.)\n            broadcast (HammerHit v)\n        end\n        if <<([abs v] of (x position) ) > [220]> or <([abs v] of (y position) ) > [160]>> then\n            add (EnemyNo.) to [deleteenemylist v]\n            delete this clone\n        end\n        hide\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [v]> then\n        if <(item (EnemyNo.) of [enemystate v]) = [0]> then\n            BasicDamagePlayer\n            if <(SlidingExtra) = [0]> then\n                if <<<([abs v] of ((x position) - ([x position v] of [player v])) ) < [28]> and <([abs v] of ((y position) - ([y position v] of [player v])) ) < [28]>> and <([y position v] of [player v]) > ((y position) + (4))>> then\n                    replace item (EnemyNo.) of [enemystate v] with [1]\n                    set [yvel v] to [16]\n                    start sound [dry bones v]\n                end\n            end\n        else\n            replace item (EnemyNo.) of [enemyextra v] with ((item (EnemyNo.) of [enemyextra v]) + (0.01))\n            if <(item (EnemyNo.) of [enemyextra v]) > [1.8]> then\n                replace item (EnemyNo.) of [enemystate v] with [0]\n                replace item (EnemyNo.) of [enemyextra v] with [0]\n            end\n        end\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [w]> then\n        BasicDamagePlayer\n    end\nelse\n    broadcast (Costuming v)\nend\n\ndefine XFix\nset [offset v] to [0]\nrepeat until <not <<touching (blocks v)?> or <touching (uniqueblocks v)?>>>\n    change [offset v] by (0.5)\n    set x to (X)\n    change x by (Offset)\n    if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n        set x to (X)\n        change x by ((Offset) * (-1))\n    end\n    if <(Offset) > [25]> then\n        set x to (X)\n        if <<(item (EnemyNo.) of [enemytype v]) = [o]> or <<(item (EnemyNo.) of [enemyyvel v]) = [0.5]> or <(item (EnemyNo.) of [enemyyvel v]) = [-0.48]>>> then\n            stop [this script v]\n        else\n            EnemyDeathByOther\n            delete this clone\n        end\n    end\nend\n\nwhen I receive [bouncedblock v]\nif <(EnemyNo.) > [0]> then\n    if <<([abs v] of ((x position) - (BlockBounceX)) ) < [28]> and <([abs v] of ((y position) - (BlockBounceY)) ) < [24]>> then\n        if <not <(item (EnemyNo.) of [enemytype v]) = [o]>> then\n            EnemyDeathByOther\n        end\n    end\nend\n\nwhen I receive [costuming v]\nif <(EnemyNo.) > [0]> then\n    if <(item (EnemyNo.) of [enemytype v]) = [a]> then\n        set rotation style [don't rotate v]\n        switch costume to (join [a] (([floor v] of (((GameTimer) * (15)) mod (2)) ) + (1)))\n        stop [this script v]\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [b]> then\n        if <(item (EnemyNo.) of [enemystate v]) = [0]> then\n            set rotation style [left-right v]\n            switch costume to (join [b] (([floor v] of (((GameTimer) * (15)) mod (2)) ) + (1)))\n        end\n        if <(item (EnemyNo.) of [enemystate v]) = [1]> then\n            set rotation style [don't rotate v]\n            switch costume to (b3 v)\n        end\n        if <(item (EnemyNo.) of [enemystate v]) = [2]> then\n            set rotation style [don't rotate v]\n            switch costume to (join [b] (([floor v] of (((GameTimer) * (15)) mod (4)) ) + (3)))\n        end\n        stop [this script v]\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [c]> then\n        switch costume to (join [c] (([floor v] of (((GameTimer) * (15)) mod (4)) ) + (1)))\n        stop [this script v]\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [d]> then\n        show\n        switch costume to (d1 v)\n        stop [this script v]\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [e]> then\n        if <(item (EnemyNo.) of [enemystate v]) = [0]> then\n            set rotation style [left-right v]\n            switch costume to (join [e] (([floor v] of (((GameTimer) * (15)) mod (2)) ) + (1)))\n        end\n        if <(item (EnemyNo.) of [enemystate v]) = [1]> then\n            set rotation style [don't rotate v]\n            switch costume to (e3 v)\n        end\n        if <(item (EnemyNo.) of [enemystate v]) = [2]> then\n            set rotation style [don't rotate v]\n            switch costume to (join [e] (([floor v] of (((GameTimer) * (15)) mod (4)) ) + (3)))\n        end\n        stop [this script v]\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [f]> then\n        if <(item (EnemyNo.) of [enemystate v]) = [0]> then\n            set rotation style [left-right v]\n            switch costume to (join [f] (([floor v] of (((GameTimer) * (15)) mod (2)) ) + (1)))\n        end\n        if <(item (EnemyNo.) of [enemystate v]) > [0]> then\n            set rotation style [left-right v]\n            switch costume to (join [f] (([floor v] of (((GameTimer) * (15)) mod (2)) ) + (3)))\n        end\n        if <(item (EnemyNo.) of [enemystate v]) > [2]> then\n            set rotation style [left-right v]\n            switch costume to (join [f] (([floor v] of (((GameTimer) * (30)) mod (4)) ) + (3)))\n        end\n        stop [this script v]\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [g]> then\n        switch costume to (join [g] (([floor v] of (((GameTimer) * (15)) mod (2)) ) + (1)))\n        show\n        stop [this script v]\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [h]> then\n        switch costume to (join [h] (([floor v] of (((GameTimer) * (15)) mod (2)) ) + (1)))\n        if <<(item (EnemyNo.) of [enemystate v]) > [5]> or <(item (EnemyNo.) of [enemystate v]) < [1]>> then\n            switch costume to (join [h] (([floor v] of (((GameTimer) * (15)) mod (2)) ) + (3)))\n        end\n        show\n        stop [this script v]\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [i]> then\n        if <([x position v] of [player v]) > ((x position) - (16))> then\n            if <([y position v] of [player v]) > ((y position) + (15))> then\n                switch costume to (i6 v)\n            else\n                switch costume to (i5 v)\n            end\n        else\n            if <([y position v] of [player v]) > ((y position) + (15))> then\n                switch costume to (i2 v)\n            else\n                switch costume to (i1 v)\n            end\n        end\n        if <<(item (EnemyNo.) of [enemystate v]) > [5]> or <(item (EnemyNo.) of [enemystate v]) < [1]>> then\n            if <([x position v] of [player v]) > ((x position) - (16))> then\n                if <([y position v] of [player v]) > ((y position) + (15))> then\n                    switch costume to (i8 v)\n                else\n                    switch costume to (i7 v)\n                end\n            else\n                if <([y position v] of [player v]) > ((y position) + (15))> then\n                    switch costume to (i4 v)\n                else\n                    switch costume to (i3 v)\n                end\n            end\n        end\n        show\n        stop [this script v]\n    end\n    if <<(item (EnemyNo.) of [enemytype v]) = [j]> or <(item (EnemyNo.) of [enemytype v]) = [k]>> then\n        switch costume to (join [j] (([floor v] of (((GameTimer) * (15)) mod (4)) ) + (1)))\n        go [forward v] (9) layers\n        show\n        stop [this script v]\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [l]> then\n        switch costume to (join [l] (([floor v] of (((GameTimer) * (15)) mod (4)) ) + (1)))\n        change y by (([sin v] of ((GameTimer) * (720)) ) * (2))\n        show\n        stop [this script v]\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [m]> then\n        switch costume to (join [m] (([floor v] of (((GameTimer) * (15)) mod (2)) ) + (1)))\n        stop [this script v]\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [n]> then\n        if <<(item (EnemyNo.) of [enemystate v]) = [0]> or <(item (EnemyNo.) of [enemystate v]) = [2]>> then\n            switch costume to (n1 v)\n        end\n        if <(item (EnemyNo.) of [enemystate v]) = [1]> then\n            switch costume to (n2 v)\n        end\n        if <(item (EnemyNo.) of [enemystate v]) = [3]> then\n            switch costume to (join [n] (([floor v] of (((GameTimer) * (30)) mod (4)) ) + (4)))\n        end\n        if <(item (EnemyNo.) of [enemystate v]) = [4]> then\n            switch costume to (join [n] (([floor v] of (((GameTimer) * (30)) mod (4)) ) + (8)))\n            show\n        end\n        stop [this script v]\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [o]> then\n        set rotation style [left-right v]\n        point in direction (-90)\n        if <(PTimer) = [0]> then\n            switch costume to (join [o] (([floor v] of (((GameTimer) * (15)) mod (4)) ) + (1)))\n        else\n            switch costume to (o5 v)\n        end\n        stop [this script v]\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [p]> then\n        if <<(item (EnemyNo.) of [enemyextra v]) < [2]> or <(item (EnemyNo.) of [enemyextra v]) > [5.3]>> then\n            switch costume to (join [p] (([floor v] of (((GameTimer) * (15)) mod (2)) ) + (1)))\n        else\n            switch costume to (join [p] (([floor v] of (((GameTimer) * (15)) mod (2)) ) + (6)))\n            if <(item (EnemyNo.) of [enemyextra v]) < [4.5]> then\n                switch costume to (p5 v)\n            end\n            if <(item (EnemyNo.) of [enemyextra v]) < [3.5]> then\n                switch costume to (p4 v)\n            end\n            if <(item (EnemyNo.) of [enemyextra v]) < [2.5]> then\n                switch costume to (p3 v)\n            end\n        end\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [q]> then\n        show\n        if <<(item (EnemyNo.) of [enemyextra v]) < [1]> and <not <(item (EnemyNo.) of [enemyyvel v]) < [-1]>>> then\n            go [backward v] (20) layers\n        else\n            go to [front v] layer\n            go [backward v] (16) layers\n        end\n        switch costume to (join [q] (([floor v] of (((GameTimer) * (15)) mod (2)) ) + (1)))\n        stop [this script v]\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [r]> then\n        switch costume to (r1 v)\n        stop [this script v]\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [s]> then\n        if <(item (EnemyNo.) of [enemyextra v]) > [0.6]> then\n            switch costume to (join [s] (([floor v] of (((GameTimer) * (15)) mod (2)) ) + (3)))\n        else\n            switch costume to (join [s] (([floor v] of (((GameTimer) * (15)) mod (2)) ) + (1)))\n        end\n        stop [this script v]\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [t]> then\n        show\n        set rotation style [all around v]\n        point in direction ((([floor v] of (((GameTimer) * (30)) mod (8)) ) + (1)) * (45))\n        switch costume to (t1 v)\n        go to [front v] layer\n        go [backward v] (12) layers\n        stop [this script v]\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [u]> then\n        show\n        set rotation style [all around v]\n        point in direction ((([floor v] of (((GameTimer) * (30)) mod (8)) ) + (1)) * (45))\n        switch costume to (u1 v)\n        go to [front v] layer\n        go [backward v] (14) layers\n        stop [this script v]\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [v]> then\n        show\n        if <(item (EnemyNo.) of [enemystate v]) = [0]> then\n            switch costume to (join [v] (([floor v] of (((GameTimer) * (15)) mod (2)) ) + (1)))\n        else\n            switch costume to (v4 v)\n            if <(item (EnemyNo.) of [enemyextra v]) < [0.05]> then\n                switch costume to (v3 v)\n            end\n            if <(item (EnemyNo.) of [enemyextra v]) > [1.65]> then\n                switch costume to (v4 v)\n            end\n            if <(item (EnemyNo.) of [enemyextra v]) > [1.7]> then\n                switch costume to (v6 v)\n            end\n            if <(item (EnemyNo.) of [enemyextra v]) > [1.75]> then\n                switch costume to (v3 v)\n            end\n        end\n    end\n    if <(item (EnemyNo.) of [enemytype v]) = [w]> then\n        if <(item (EnemyNo.) of [enemyextra v]) = [Fallen]> then\n            set rotation style [left-right v]\n        else\n            set rotation style [all around v]\n        end\n        turn right (180) degrees\n        switch costume to (join [w] (([floor v] of (((GameTimer) * (15)) mod (2)) ) + (2)))\n    end\nend\n\ndefine BasicYMovement\nif <(((y position) - (MapY)) / (32)) < (CurrentWaterLevel)> then\n    if <not <(item (EnemyNo.) of [enemytype v]) = [m]>> then\n        if <(item (EnemyNo.) of [enemyyvel v]) > [-2]> then\n            replace item (EnemyNo.) of [enemyyvel v] with ((item (EnemyNo.) of [enemyyvel v]) - ((EnemyGravity) / (2)))\n        end\n        if <(item (EnemyNo.) of [enemyyvel v]) < [-2]> then\n            replace item (EnemyNo.) of [enemyyvel v] with [-2]\n        end\n        if <(item (EnemyNo.) of [enemyyvel v]) > [10]> then\n            replace item (EnemyNo.) of [enemyyvel v] with [10]\n        end\n    end\nelse\n    if <(item (EnemyNo.) of [enemyyvel v]) > [-8]> then\n        replace item (EnemyNo.) of [enemyyvel v] with ((item (EnemyNo.) of [enemyyvel v]) - (EnemyGravity))\n    end\n    if <(item (EnemyNo.) of [enemyyvel v]) < [-8]> then\n        replace item (EnemyNo.) of [enemyyvel v] with [-8]\n    end\nend\nchange y by (item (EnemyNo.) of [enemyyvel v])\nif <(item (EnemyNo.) of [enemyyvel v]) > [0]> then\n    if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n        replace item (EnemyNo.) of [enemyyvel v] with [0.5]\n        FindCeiling\n    end\nelse\n    switch costume to (bottom v)\n    if <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <<touching (semisolids v)?> or <<touching (enemies + other v)?> and <not <<<(item (EnemyNo.) of [enemytype v]) = [b]> or <(item (EnemyNo.) of [enemytype v]) = [e]>> and <(item (EnemyNo.) of [enemystate v]) = [2]>>>>>> then\n        if <<(item (EnemyNo.) of [enemytype v]) = [f]> and <(item (EnemyNo.) of [enemystate v]) = [1]>> then\n            if <([abs v] of (item (EnemyNo.) of [enemyyvel v]) ) > [4]> then\n                replace item (EnemyNo.) of [enemyyvel v] with (([abs v] of (item (EnemyNo.) of [enemyyvel v]) ) / (1.4))\n            else\n                replace item (EnemyNo.) of [enemyyvel v] with [0]\n            end\n        else\n            replace item (EnemyNo.) of [enemyyvel v] with [0]\n        end\n        FindFloor\n    end\n    switch costume to (hitbox v)\nend\n\ndefine BasicXMovement (speed)\nswitch costume to (hitbox v)\nif <(item (EnemyNo.) of [enemytype v]) = [n]> then\n    switch costume to (boomboom v)\nend\nchange y by (1)\nchange x by ((direction) / ((90) / (speed)))\nif <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n    YSmoothing ((2) + ((speed) * (3)))\nend\nif <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n    if <<<(item (EnemyNo.) of [enemytype v]) = [b]> or <(item (EnemyNo.) of [enemytype v]) = [e]>> and <(item (EnemyNo.) of [enemystate v]) = [2]>> then\n        if <touching (uniqueblocks v)?> then\n            set y to (((round (((y position) - (MapY)) / (32))) * (32)) + (MapY))\n            change y by (2)\n            move (8) steps\n            set [breakx v] to (x position)\n            set [breaky v] to (y position)\n            move (-8) steps\n            broadcast (ShellBreakBlock v)\n            replace item (EnemyNo.) of [enemyyvel v] with [0]\n        end\n    end\n    XFix\n    turn right (180) degrees\n    if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n        turn right (180) degrees\n    end\n    if <not <(item (EnemyNo.) of [enemytype v]) = [n]>> then\n        replace item (EnemyNo.) of [enemydir v] with (direction)\n    end\nend\nif <<(item (EnemyNo.) of [enemytype v]) = [e]> and <<(item (EnemyNo.) of [enemyyvel v]) = [0]> and <(item (EnemyNo.) of [enemystate v]) = [0]>>> then\n    switch costume to (hitboxfloorcheck v)\n    if <not <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <<touching (semisolids v)?> or <touching (enemies + other v)?>>>> then\n        turn right (180) degrees\n        replace item (EnemyNo.) of [enemydir v] with (direction)\n    end\n    switch costume to (hitbox v)\nend\nchange y by (-1)\n\ndefine DeleteEnemies\nrepeat (length of [deleteenemylist v])\n    if <(item (item (1) of [deleteenemylist v]) of [enemykey v]) = [1]> then\n        NewKey (item (item (1) of [deleteenemylist v]) of [enemyx v]) (item (item (1) of [deleteenemylist v]) of [enemyy v])\n    end\n    delete (item (1) of [deleteenemylist v]) of [enemydir v]\n    delete (item (1) of [deleteenemylist v]) of [enemystate v]\n    delete (item (1) of [deleteenemylist v]) of [enemytype v]\n    delete (item (1) of [deleteenemylist v]) of [enemyx v]\n    delete (item (1) of [deleteenemylist v]) of [enemyy v]\n    delete (item (1) of [deleteenemylist v]) of [enemyyvel v]\n    delete (item (1) of [deleteenemylist v]) of [enemyextra v]\n    delete (item (1) of [deleteenemylist v]) of [enemykey v]\n    RealignKilledEnemiesList (item (1) of [deleteenemylist v])\n    delete (1) of [deleteenemylist v]\nend\n\nwhen I receive [shellhit v]\nif <not <(EnemyNo.) = [0]>> then\n    if <<<([abs v] of (((x position) - ((16) * <<(item (EnemyNo.) of [enemytype v]) = [h]> or <(item (EnemyNo.) of [enemytype v]) = [i]>>)) - (ShellHitX)) ) < [28]> and <([abs v] of ((y position) - (ShellHitY)) ) < [16]>> and <not <(EnemyNo.) = (ShellHitNo.)>>> then\n        if <not <(item (EnemyNo.) of [enemytype v]) = [o]>> then\n            if <not <<(item (EnemyNo.) of [enemytype v]) = [l]> or <(item (EnemyNo.) of [enemytype v]) = [v]>>> then\n                start sound [hit1 v]\n            end\n            EnemyDeathByOther\n        end\n    end\nend\n\ndefine EnemyDeathByOther\nif <(item (EnemyNo.) of [enemytype v]) = [a]> then\n    add [a2] to [particlemaketype v]\nend\nif <(item (EnemyNo.) of [enemytype v]) = [b]> then\n    if <(item (EnemyNo.) of [enemystate v]) = [0]> then\n        add [b1] to [particlemaketype v]\n    else\n        add [b2] to [particlemaketype v]\n    end\nend\nif <(item (EnemyNo.) of [enemytype v]) = [e]> then\n    if <(item (EnemyNo.) of [enemystate v]) = [0]> then\n        add [e1] to [particlemaketype v]\n    else\n        add [e2] to [particlemaketype v]\n    end\nend\nif <(item (EnemyNo.) of [enemytype v]) = [f]> then\n    add [f] to [particlemaketype v]\nend\nif <<(item (EnemyNo.) of [enemytype v]) = [h]> or <(item (EnemyNo.) of [enemytype v]) = [i]>> then\n    add [h] to [particlemaketype v]\nend\nif <(item (EnemyNo.) of [enemytype v]) = [m]> then\n    add [m] to [particlemaketype v]\nend\nif <(item (EnemyNo.) of [enemytype v]) = [p]> then\n    add [p] to [particlemaketype v]\nend\nif <(item (EnemyNo.) of [enemytype v]) = [q]> then\n    add [q] to [particlemaketype v]\nend\nif <(item (EnemyNo.) of [enemytype v]) = [r]> then\n    add [Poof] to [particlemaketype v]\nend\nif <(item (EnemyNo.) of [enemytype v]) = [s]> then\n    add [s] to [particlemaketype v]\nend\nif <(item (EnemyNo.) of [enemytype v]) = [w]> then\n    add [w] to [particlemaketype v]\nend\nif <not <<<(item (EnemyNo.) of [enemytype v]) = [d]> or <(item (EnemyNo.) of [enemytype v]) = [v]>> or <<(item (EnemyNo.) of [enemytype v]) = [j]> or <<(item (EnemyNo.) of [enemytype v]) = [k]> or <(item (EnemyNo.) of [enemytype v]) = [n]>>>>> then\n    add (EnemyNo.) to [deleteenemylist v]\n    if <not <(item (EnemyNo.) of [enemytype v]) = [l]>> then\n        add ((((x position) - (<<(item (EnemyNo.) of [enemytype v]) = [h]> or <(item (EnemyNo.) of [enemytype v]) = [i]>> * (16))) - (MapX)) / (32)) to [particlemakex v]\n        add (((y position) - (MapY)) / (32)) to [particlemakey v]\n        add ((([abs v] of ((x position) - (ShellHitX)) ) / ((x position) - (ShellHitX))) * (90)) to [particlemakedir v]\n    end\n    delete this clone\nend\nif <<(item (EnemyNo.) of [enemytype v]) = [n]> and <not <(item (EnemyNo.) of [enemystate v]) = [4]>>> then\n    replace item (EnemyNo.) of [enemystate v] with [4]\n    replace item (EnemyNo.) of [enemyyvel v] with [1]\n    replace item (EnemyNo.) of [enemydir v] with ((item (EnemyNo.) of [enemydir v]) - (1))\n    replace item (EnemyNo.) of [enemyextra v] with [0]\nend\nif <(item (EnemyNo.) of [enemytype v]) = [v]> then\n    if <(item (EnemyNo.) of [enemystate v]) = [0]> then\n        start sound [dry bones v]\n        replace item (EnemyNo.) of [enemystate v] with [1]\n    end\nend\n\ndefine ThwompMovement\nif <(item (EnemyNo.) of [enemystate v]) > [2]> then\n    replace item (EnemyNo.) of [enemystate v] with ((item (EnemyNo.) of [enemystate v]) + (0.1))\n    if <(item (EnemyNo.) of [enemystate v]) > [3]> then\n        replace item (EnemyNo.) of [enemystate v] with [0]\n    end\nend\nif <(item (EnemyNo.) of [enemystate v]) = [2]> then\n    change y by (2)\n    if <(((y position) - (MapY)) / (32)) > (item (EnemyNo.) of [enemyextra v])> then\n        set y to (((item (EnemyNo.) of [enemyextra v]) * (32)) + (MapY))\n        replace item (EnemyNo.) of [enemystate v] with [2.05]\n    end\nend\nif <<(item (EnemyNo.) of [enemystate v]) > [1]> and <(item (EnemyNo.) of [enemystate v]) < [2]>> then\n    replace item (EnemyNo.) of [enemystate v] with ((item (EnemyNo.) of [enemystate v]) + (0.05))\n    if <(item (EnemyNo.) of [enemystate v]) > [2]> then\n        replace item (EnemyNo.) of [enemystate v] with [2]\n    end\nend\nif <(item (EnemyNo.) of [enemystate v]) = [1]> then\n    if <(item (EnemyNo.) of [enemyyvel v]) > [-16]> then\n        replace item (EnemyNo.) of [enemyyvel v] with ((item (EnemyNo.) of [enemyyvel v]) - (EnemyGravity))\n    end\n    change y by (item (EnemyNo.) of [enemyyvel v])\n    if <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <touching (semisolids v)?>> then\n        add ((x position) + (16)) to [breakx v]\n        add ((y position) - (48)) to [breaky v]\n        broadcast (ThwompBreakBlock v)\n        replace item (EnemyNo.) of [enemyyvel v] with [0]\n        FindFloor\n        replace item (EnemyNo.) of [enemystate v] with [1.05]\n        set [camerashake v] to [1]\n        start sound [Thwomp v]\n    end\nend\nif <(item (EnemyNo.) of [enemystate v]) = [0]> then\n    if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [96]> and <([y position v] of [player v]) < (y position)>> then\n        replace item (EnemyNo.) of [enemyextra v] with (((y position) - (MapY)) / (32))\n        replace item (EnemyNo.) of [enemystate v] with [1]\n        replace item (EnemyNo.) of [enemyyvel v] with [0]\n    end\nend\n\nwhen I receive [enemy bumping update v]\nif <(EnemyNo.) > [0]> then\n    if <<<(item (EnemyNo.) of [enemytype v]) = [c]> or <(item (EnemyNo.) of [enemytype v]) = [l]>> or <<(item (EnemyNo.) of [enemytype v]) = [b]> or <(item (EnemyNo.) of [enemytype v]) = [e]>>> then\n        show\n    end\n    if <<(item (EnemyNo.) of [enemytype v]) = [h]> or <(item (EnemyNo.) of [enemytype v]) = [i]>> then\n        show\n        switch costume to (hitbox2 v)\n    end\nelse\n    broadcast (Player Update v)\nend\n\nif <<(costume [name v]) = [Hitbox3]> and <not <<<(item (EnemyNo.) of [enemytype v]) = [b]> or <(item (EnemyNo.) of [enemytype v]) = [e]>> and <(item (EnemyNo.) of [enemystate v]) = [2]>>>> then\n    switch costume to (hitbox4 v)\n    if <touching (enemies + other v)?> then\n        turn right (180) degrees\n        replace item (EnemyNo.) of [enemydir v] with (direction)\n        XFix\n    end\n    switch costume to (hitbox3 v)\nend\n\nwhen I receive [thwompbreakblock v]\nif <<(EnemyNo.) > [0]> and <not <<(item (EnemyNo.) of [enemytype v]) = [g]> or <(item (EnemyNo.) of [enemytype v]) = [u]>>>> then\n    if <(length of [breakx v]) > [0]> then\n        ThwompCrush\n    end\nend\n\ndefine ThwompCrush\nset [offset v] to [0]\nrepeat (length of [breakx v])\n    change [offset v] by (1)\n    if <<([abs v] of (((x position) - ((16) * <<(item (EnemyNo.) of [enemytype v]) = [h]> or <(item (EnemyNo.) of [enemytype v]) = [i]>>)) - (item (Offset) of [breakx v])) ) < [32]> and <([abs v] of ((y position) - ((item (Offset) of [breaky v]) + (32))) ) < [16]>> then\n        if <(item (EnemyNo.) of [enemytype v]) = [o]> then\n            PTimer\n        else\n            if <not <(item (EnemyNo.) of [enemytype v]) = [v]>> then\n                start sound [hit1 v]\n            end\n            EnemyDeathByOther\n        end\n        stop [this script v]\n    end\nend\n\nwhen I receive [notebouncedblock v]\nif <<(EnemyNo.) > [0]> and <not <(item (EnemyNo.) of [enemytype v]) = [d]>>> then\n    if <(length of [aboveblockx v]) > [0]> then\n        NoteBlockBounce/Conveyer\n    end\nend\n\ndefine NoteBlockBounce/Conveyer\nset [offset v] to [0]\nrepeat (length of [aboveblockx v])\n    change [offset v] by (1)\n    if <<([abs v] of ((x position) - (item (Offset) of [aboveblockx v])) ) < [29]> and <<((y position) - (item (Offset) of [aboveblocky v])) < ((8) + (<(item (EnemyNo.) of [enemytype v]) = [d]> * (24)))> and <((y position) - (item (Offset) of [aboveblocky v])) > [-8]>>> then\n        if <(item (Offset) of [aboveblocktype v]) = [Note]> then\n            change y by (15)\n            if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n                replace item (EnemyNo.) of [enemyyvel v] with [2]\n            else\n                replace item (EnemyNo.) of [enemyyvel v] with [14.6]\n            end\n            change y by (-15)\n            stop [this script v]\n        else\n            if <(item (Offset) of [aboveblocktype v]) = [Left]> then\n                replace item (EnemyNo.) of [enemyx v] with ((item (EnemyNo.) of [enemyx v]) - ((1) / (34.4)))\n            else\n                replace item (EnemyNo.) of [enemyx v] with ((item (EnemyNo.) of [enemyx v]) + ((1) / (34.4)))\n            end\n            stop [this script v]\n        end\n    end\nend\n\ndefine BasicDamagePlayer\nif <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [24]> and <<((y position) - ([y position v] of [player v])) < ((48) - ((Small) * (24)))> and <((y position) - ([y position v] of [player v])) > [-4]>>> then\n    if <<(SlidingExtra) = [0]> or <(item (EnemyNo.) of [enemytype v]) = [t]>> then\n        AttemptToDamagePlayer\n    else\n        start sound [hit1 v]\n        EnemyDeathByOther\n    end\nend\n\ndefine ThwompDamagePlayer\nif <<([abs v] of (((x position) + (16)) - ([x position v] of [player v])) ) < [32]> and <<(((y position) - (16)) - ([y position v] of [player v])) < ((54) - ((Small) * (24)))> and <(((y position) - (16)) - ([y position v] of [player v])) > [-42]>>> then\n    AttemptToDamagePlayer\nend\n\ndefine BombExplosion\nadd (x position) to [bombx v]\nadd (y position) to [bomby v]\nadd ((x position) + (32)) to [bombx v]\nadd (y position) to [bomby v]\nadd ((x position) - (32)) to [bombx v]\nadd (y position) to [bomby v]\nadd (x position) to [bombx v]\nadd ((y position) + (32)) to [bomby v]\nadd (x position) to [bombx v]\nadd ((y position) - (32)) to [bomby v]\nbroadcast (BombBreakBlock v)\nif <(distance to [player v]) < [32]> then\n    if <<(Invincible) = [0]> and <(StarTimer) = [0]>> then\n        broadcast (Powerdown v)\n    end\nend\n\nwhen I receive [bombbreakblock v]\nif <<(EnemyNo.) > [0]> and <not <<(item (EnemyNo.) of [enemytype v]) = [g]> or <(item (EnemyNo.) of [enemytype v]) = [u]>>>> then\n    if <(length of [bombx v]) > [0]> then\n        Bomb\n    end\nend\n\ndefine Bomb\nset [offset v] to [0]\nrepeat (length of [bombx v])\n    change [offset v] by (1)\n    if <<([abs v] of (((x position) - ((16) * <<(item (EnemyNo.) of [enemytype v]) = [h]> or <(item (EnemyNo.) of [enemytype v]) = [i]>>)) - (item (Offset) of [bombx v])) ) < [16]> and <([abs v] of ((y position) - (item (Offset) of [bomby v])) ) < [16]>> then\n        if <<(item (EnemyNo.) of [enemytype v]) = [f]> and <(item (EnemyNo.) of [enemystate v]) > [11.9]>> then\n            add (EnemyNo.) to [deleteenemylist v]\n            stop [this script v]\n        else\n            if <(item (EnemyNo.) of [enemytype v]) = [o]> then\n                PTimer\n            else\n                if <not <(item (EnemyNo.) of [enemytype v]) = [v]>> then\n                    start sound [hit1 v]\n                end\n                EnemyDeathByOther\n            end\n            stop [this script v]\n        end\n    end\nend\n\ndefine VinePlant\nchange y by ((32) / (16))\nreplace item (EnemyNo.) of [enemystate v] with ((item (EnemyNo.) of [enemystate v]) + ((1) / (16)))\nif <<(((item (EnemyNo.) of [enemystate v]) - ((1) / (16))) mod (1)) > [0.9]> and <((item (EnemyNo.) of [enemystate v]) mod (1)) < [0.1]>> then\n    switch costume to (vineplant v)\n    if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n        add (EnemyNo.) to [deleteenemylist v]\n    else\n        add (round (((x position) - (MapX)) / (32))) to [vinebeaddedatx v]\n        add (round (((y position) - (MapY)) / (32))) to [vinebeaddedaty v]\n    end\nend\n\ndefine PlantMovement\nchange y by (16)\nif <(AllowControl) = [1]> then\n    replace item (EnemyNo.) of [enemystate v] with ((item (EnemyNo.) of [enemystate v]) + ((1) / (16)))\nend\nif <(item (EnemyNo.) of [enemystate v]) < [2]> then\n    change y by ((-64) - ((item (EnemyNo.) of [enemystate v]) * (-32)))\nelse\n    if <(item (EnemyNo.) of [enemystate v]) < [4]> then\nend\n\ndefine PlantDamagePlayer\nif <<([abs v] of (((x position) - (16)) - ([x position v] of [player v])) ) < [24]> and <<((y position) - ([y position v] of [player v])) < (((48) - (<<(item (EnemyNo.) of [enemystate v]) > [5]> or <(item (EnemyNo.) of [enemystate v]) < [1]>> * (12))) - ((Small) * (24)))> and <((y position) - ([y position v] of [player v])) > [-32]>>> then\n    AttemptToDamagePlayer\nend\n\ndefine PlantFireball\nif <<((item (EnemyNo.) of [enemystate v]) - ((1) / (16))) < [3]> and <not <(item (EnemyNo.) of [enemystate v]) < [3]>>> then\n    start sound [EnemyFireball v]\n    add ((((x position) - (16)) - (MapX)) / (32)) to [enemyx v]\n    add ((((y position) + (16)) - (MapY)) / (32)) to [enemyy v]\n    add [j] to [enemytype v]\n    add [0] to [enemystate v]\n    add [0] to [enemyyvel v]\n    add [0] to [enemyextra v]\n    if <([x position v] of [player v]) > ((x position) - (16))> then\n        if <([y position v] of [player v]) > ((y position) + (15))> then\n            add [45] to [enemydir v]\n        else\n            add [135] to [enemydir v]\n        end\n    else\n        if <([y position v] of [player v]) > ((y position) + (15))> then\n            add [-45] to [enemydir v]\n        else\n            add [-135] to [enemydir v]\n        end\n    end\nend\n\ndefine PlantFireballMovement\nswitch costume to (fireballhitbox v)\nmove (3) steps\nif <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n    add (((x position) - (MapX)) / (32)) to [particlemakex v]\n    add (((y position) - (MapY)) / (32)) to [particlemakey v]\n    add [Drift] to [particlemaketype v]\n    add [0] to [particlemakedir v]\n    add (EnemyNo.) to [deleteenemylist v]\nend\n\ndefine FireballDamagePlayer\nif <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [24]> and <<((y position) - ([y position v] of [player v])) < ((48) - ((Small) * (24)))> and <((y position) - ([y position v] of [player v])) > [-4]>>> then\n    if <<(Powerup) = [H]> and <(Crouching) = [1]>> then\n        add (((x position) - (MapX)) / (32)) to [particlemakex v]\n        add (((y position) - (MapY)) / (32)) to [particlemakey v]\n        add [Drift] to [particlemaketype v]\n        add [0] to [particlemakedir v]\n        add (EnemyNo.) to [deleteenemylist v]\n        delete this clone\n    else\n        AttemptToDamagePlayer\n    end\nend\n\nwhen I receive [menuupdate v]\nif <[1] = [1]> then\n    delete this clone\nend\nhide\n\nwhen I receive [spinattack v]\nif <<(EnemyNo.) > [0]> and <not <(item (EnemyNo.) of [enemytype v]) = [g]>>> then\n    if <<([abs v] of (((x position) - ((16) * <<(item (EnemyNo.) of [enemytype v]) = [h]> or <(item (EnemyNo.) of [enemytype v]) = [i]>>)) - ([x position v] of [player v])) ) < [56]> and <([abs v] of ((y position) - ([y position v] of [player v])) ) < [16]>> then\n        if <(item (EnemyNo.) of [enemytype v]) = [o]> then\n            PTimer\n        else\n            if <not <(item (EnemyNo.) of [enemytype v]) = [v]>> then\n                start sound [hit1 v]\n            end\n            EnemyDeathByOther\n        end\n        stop [this script v]\n    end\nend\n\ndefine YSmoothing (height)\nrepeat (height)\n    if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n        change y by (0.5)\n    else\n        stop [this script v]\n    end\nend\nif <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n    change y by ((height) / (-2))\nend\n\ndefine FireballMovement\nswitch costume to (fireballhitbox v)\nmove (7) steps\nif <(direction) > [0]> then\n    turn right (8) degrees\n    if <(direction) > [135]> then\n        point in direction (135)\n    end\nelse\n    turn left (8) degrees\n    if <(direction) < [-135]> then\n        point in direction (-135)\n    end\nend\nif <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <<touching (semisolids v)?> and <([abs v] of (direction) ) > [90]>>> then\n    move (-6) steps\n    if <([abs v] of (direction) ) > [90]> then\n        point in direction ((180) - (direction))\n    else\n        point in direction ((direction) * (-1))\n    end\n    move (6) steps\n    replace item (EnemyNo.) of [enemystate v] with ((item (EnemyNo.) of [enemystate v]) + (1))\n    if <<(item (EnemyNo.) of [enemystate v]) > [6]> or <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <<touching (semisolids v)?> and <([abs v] of (direction) ) > [90]>>>> then\n        add (EnemyNo.) to [deleteenemylist v]\n        add (((x position) - (MapX)) / (32)) to [particlemakex v]\n        add (((y position) - (MapY)) / (32)) to [particlemakey v]\n        add [Drift] to [particlemaketype v]\n        delete this clone\n    end\nend\nreplace item (EnemyNo.) of [enemydir v] with (direction)\n\ndefine PositionTheVine\nset [offset v] to (item # of ((round (((x position) - (MapX)) / (32))) - (1)) in [uniquex v])\nrepeat until <<not <(item (Offset) of [uniquex v]) < (round (((x position) - (MapX)) / (32)))>> or <(Offset) > (length of [uniquex v])>>\n    change [offset v] by (1)\nend\nif <(Offset) > (length of [uniquex v])> then\n    set [offset v] to ((length of [uniquex v]) + (1))\nend\n\nwhen I receive [fireballhit v]\nif <not <(EnemyNo.) = [0]>> then\n    if <<([abs v] of (((x position) - ((16) * <<(item (EnemyNo.) of [enemytype v]) = [h]> or <(item (EnemyNo.) of [enemytype v]) = [i]>>)) - (FireballHitX)) ) < [28]> and <([abs v] of ((y position) - (FireballHitY)) ) < [24]>> then\n        if <not <<<<(item (EnemyNo.) of [enemytype v]) = [o]> or <<(item (EnemyNo.) of [enemytype v]) = [v]> and <not <(item (EnemyNo.) of [enemystate v]) = [0]>>>> or <<(item (EnemyNo.) of [enemytype v]) = [c]> or <(item (EnemyNo.) of [enemytype v]) = [l]>>> or <<(item (EnemyNo.) of [enemytype v]) = [j]> or <(item (EnemyNo.) of [enemytype v]) = [k]>>>> then\n            if <(item (EnemyNo.) of [enemytype v]) = [n]> then\n                if <not <<(item (EnemyNo.) of [enemystate v]) = [4]> or <<(item (EnemyNo.) of [enemystate v]) = [0]> or <(item (EnemyNo.) of [enemystate v]) = [2]>>>> then\n                    replace item (EnemyNo.) of [enemystate v] with [4]\n                    replace item (EnemyNo.) of [enemyyvel v] with [1]\n                    replace item (EnemyNo.) of [enemydir v] with ((item (EnemyNo.) of [enemydir v]) - (0.67))\n                    replace item (EnemyNo.) of [enemyextra v] with [0]\n                    start sound [hit1 v]\n                end\n            else\n                if <not <<(item (EnemyNo.) of [enemytype v]) = [d]> or <(item (EnemyNo.) of [enemytype v]) = [v]>>> then\n                    add (((x position) - (MapX)) / (32)) to [particlemakex v]\n                    add (((y position) - (MapY)) / (32)) to [particlemakey v]\n                    add [Drift] to [particlemaketype v]\n                    add (EnemyNo.) to [deleteenemylist v]\n                    start sound [hit1 v]\n                end\n            end\n            add (FireballNo.Hit) to [deleteenemylist v]\n            add (((FireballHitX) - (MapX)) / (32)) to [particlemakex v]\n            add (((FireballHitY) - (MapY)) / (32)) to [particlemakey v]\n            add [Drift] to [particlemaketype v]\n            if <not <<(item (EnemyNo.) of [enemytype v]) = [n]> or <<(item (EnemyNo.) of [enemytype v]) = [d]> or <(item (EnemyNo.) of [enemytype v]) = [v]>>>> then\n                delete this clone\n            end\n        end\n    end\nend\n\ndefine NewKey (x) (y)\nchange [keys v] by (1)\nadd [Key] to [particlemaketype v]\nadd (x) to [particlemakex v]\nadd (y) to [particlemakey v]\nadd [0] to [particlemakedir v]\nstart sound [Coin v]\n\ndefine CheepCheepMovement\nif <(((y position) - (MapY)) / (32)) < (CurrentWaterLevel)> then\n    if <([abs v] of (item (EnemyNo.) of [enemyyvel v]) ) > [0.1]> then\n        BasicYMovement\n        replace item (EnemyNo.) of [enemyyvel v] with ((item (EnemyNo.) of [enemyyvel v]) / (1.154))\n        if <not <([abs v] of (item (EnemyNo.) of [enemyyvel v]) ) > [0.1]>> then\n            replace item (EnemyNo.) of [enemyyvel v] with [0]\n        end\n    end\n    BasicXMovement [1]\nelse\n    BasicYMovement\n    if <<(item (EnemyNo.) of [enemyyvel v]) = [0]> or <(item (EnemyNo.) of [enemyyvel v]) = (EnemyGravity)>> then\n        if <(((GameTimer) + ((EnemyNo.) / (8))) mod (1)) < [0.05]> then\n            replace item (EnemyNo.) of [enemyyvel v] with [8]\n        end\n    else\n        BasicXMovement [1]\n    end\nend\n\ndefine BoomBoomMovement\nswitch costume to (boomboom v)\nreplace item (EnemyNo.) of [enemyextra v] with ((item (EnemyNo.) of [enemyextra v]) + (0.1))\nif <(item (EnemyNo.) of [enemystate v]) = [4]> then\n    hide\n    if <(item (EnemyNo.) of [enemyextra v]) > [5]> then\n        replace item (EnemyNo.) of [enemystate v] with [0]\n        replace item (EnemyNo.) of [enemyextra v] with [0]\n        if <(item (EnemyNo.) of [enemydir v]) < [-92.9]> then\n            add (((x position) - (MapX)) / (32)) to [particlemakex v]\n            add (((y position) - (MapY)) / (32)) to [particlemakey v]\n            add [Explosion] to [particlemaketype v]\n            add (EnemyNo.) to [deleteenemylist v]\n            delete this clone\n        end\n    end\nelse\n    if <(item (EnemyNo.) of [enemystate v]) = [3]> then\n        BasicYMovement\n        if <(x position) > ([x position v] of [player v])> then\n            point in direction (-90)\n        else\n            point in direction (90)\n        end\n        if <([abs v] of ((x position) - ([x position v] of [player v])) ) > [16]> then\n            BasicXMovement [4]\n        end\n        if <(item (EnemyNo.) of [enemyextra v]) > [8]> then\n            replace item (EnemyNo.) of [enemystate v] with [0]\n            replace item (EnemyNo.) of [enemyextra v] with [-2]\n        end\n    end\n    if <(item (EnemyNo.) of [enemystate v]) = [2]> then\n        BasicYMovement\n        BasicXMovement [0]\n        if <(item (EnemyNo.) of [enemyextra v]) > [2]> then\n            replace item (EnemyNo.) of [enemystate v] with [3]\n            replace item (EnemyNo.) of [enemyextra v] with [0]\n        end\n    end\n    if <(item (EnemyNo.) of [enemystate v]) = [1]> then\n        BasicYMovement\n        if <(item (EnemyNo.) of [enemyyvel v]) = [0]> then\n            replace item (EnemyNo.) of [enemystate v] with [2]\n            replace item (EnemyNo.) of [enemyextra v] with [0]\n        else\n            if <(x position) > ([x position v] of [player v])> then\n                point in direction (-90)\n            else\n                point in direction (90)\n            end\n            BasicXMovement [2]\n        end\n    end\n    if <(item (EnemyNo.) of [enemystate v]) = [0]> then\n        BasicYMovement\n        BasicXMovement [0]\n        if <(item (EnemyNo.) of [enemyextra v]) > [4]> then\n            replace item (EnemyNo.) of [enemystate v] with [1]\n            replace item (EnemyNo.) of [enemyextra v] with [0]\n            replace item (EnemyNo.) of [enemyyvel v] with [15]\n        end\n    end\nend\n\ndefine BoomBoomDamagePlayer\nif <<(item (EnemyNo.) of [enemystate v]) = [0]> or <(item (EnemyNo.) of [enemystate v]) = [2]>> then\n    if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [32]> and <<((y position) - ([y position v] of [player v])) < ((48) - ((Small) * (24)))> and <((y position) - ([y position v] of [player v])) > [-24]>>> then\n        AttemptToDamagePlayer\n    end\nend\nif <<(item (EnemyNo.) of [enemystate v]) = [1]> or <(item (EnemyNo.) of [enemystate v]) = [3]>> then\n    if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [32]> and <<((y position) - ([y position v] of [player v])) < ((48) - ((Small) * (24)))> and <((y position) - ([y position v] of [player v])) > [-4]>>> then\n        AttemptToDamagePlayer\n    end\n    if <<<([abs v] of ((x position) - ([x position v] of [player v])) ) < [32]> and <([abs v] of ((y position) - ([y position v] of [player v])) ) < [28]>> and <([y position v] of [player v]) > ((y position) + (4))>> then\n        start sound [Stomp v]\n        replace item (EnemyNo.) of [enemystate v] with [4]\n        replace item (EnemyNo.) of [enemyyvel v] with [1]\n        replace item (EnemyNo.) of [enemydir v] with ((item (EnemyNo.) of [enemydir v]) - (1))\n        replace item (EnemyNo.) of [enemyextra v] with [0]\n        set [yvel v] to [16]\n    end\nend\n\ndefine RealignKilledEnemiesList (no.killed)\nset [offset v] to [0]\nrepeat (length of [deleteenemylist v])\n    change [offset v] by (1)\n    if <(item (Offset) of [deleteenemylist v]) > (no.killed)> then\n        replace item (Offset) of [deleteenemylist v] with ((item (Offset) of [deleteenemylist v]) - (1))\n    end\nend\n\ndefine PTimer\nif <(PTimer) = [0]> then\n    set [ptimer v] to [10]\n    stop all sounds\nend\n\ndefine AttemptToDamagePlayer\nif <(StarTimer) = [0]> then\n    if <(Invincible) = [0]> then\n        broadcast (Powerdown v)\n    end\nelse\n    start sound [hit1 v]\n    add (((x position) - (MapX)) / (32)) to [particlemakex v]\n    add (((y position) - (MapY)) / (32)) to [particlemakey v]\n    add [Poof] to [particlemaketype v]\n    add [0] to [particlemakedir v]\n    add (EnemyNo.) to [deleteenemylist v]\n    delete this clone\nend\n\ndefine SpikeBallMovement\nif <(item (EnemyNo.) of [enemyextra v]) = [0]> then\n    if <(((y position) - (MapY)) / (32)) < (CurrentWaterLevel)> then\n        if <not <(item (EnemyNo.) of [enemytype v]) = [m]>> then\n            if <(item (EnemyNo.) of [enemyyvel v]) > [-2]> then\n                replace item (EnemyNo.) of [enemyyvel v] with ((item (EnemyNo.) of [enemyyvel v]) - ((EnemyGravity) / (2)))\n            end\n            if <(item (EnemyNo.) of [enemyyvel v]) < [-2]> then\n                replace item (EnemyNo.) of [enemyyvel v] with [-2]\n            end\n            if <(item (EnemyNo.) of [enemyyvel v]) > [10]> then\n                replace item (EnemyNo.) of [enemyyvel v] with [10]\n            end\n        end\n    else\n        if <(item (EnemyNo.) of [enemyyvel v]) > [-8]> then\n            replace item (EnemyNo.) of [enemyyvel v] with ((item (EnemyNo.) of [enemyyvel v]) - (EnemyGravity))\n        end\n        if <(item (EnemyNo.) of [enemyyvel v]) < [-8]> then\n            replace item (EnemyNo.) of [enemyyvel v] with [-8]\n        end\n    end\n    change y by (item (EnemyNo.) of [enemyyvel v])\n    if <(item (EnemyNo.) of [enemyyvel v]) > [0]> then\n    if <(item (EnemyNo.) of [enemyyvel v]) = [0]> then\n        replace item (EnemyNo.) of [enemyextra v] with [1]\n    end\nend\nif <<(item (EnemyNo.) of [enemyextra v]) > [0]> and <(item (EnemyNo.) of [enemyextra v]) < [2]>> then\n    replace item (EnemyNo.) of [enemyextra v] with ((item (EnemyNo.) of [enemyextra v]) + (0.1))\nend\nif <not <(item (EnemyNo.) of [enemyextra v]) < [2]>> then\n    move (4) steps\n    if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n        move (4) steps\n        set [breakx v] to (x position)\n        set [breaky v] to (y position)\n        broadcast (ShellBreakBlock v)\n        add (((x position) - (MapX)) / (32)) to [particlemakex v]\n        add (((y position) - (MapY)) / (32)) to [particlemakey v]\n        add [Explosion] to [particlemaketype v]\n        add (EnemyNo.) to [deleteenemylist v]\n        delete this clone\n    end\nend\n\ndefine SpikeMovement\nreplace item (EnemyNo.) of [enemyextra v] with ((item (EnemyNo.) of [enemyextra v]) + (0.1))\nBasicYMovement\nif <(item (EnemyNo.) of [enemyextra v]) < [2]> then\n    BasicXMovement [1.07]\nelse\n    if <<((item (EnemyNo.) of [enemyextra v]) - (0.1)) < [2.5]> and <not <(item (EnemyNo.) of [enemyextra v]) < [2.5]>>> then\n        SpawnSpikeBall\n    end\n    if <(item (EnemyNo.) of [enemyextra v]) > [5]> then\n        BasicXMovement [1.07]\n    else\n        BasicXMovement [0]\n    end\nend\nif <(item (EnemyNo.) of [enemyextra v]) > [12]> then\n    replace item (EnemyNo.) of [enemyextra v] with [0]\nend\n\ndefine SpawnSpikeBall\nadd (((x position) - (MapX)) / (32)) to [enemyx v]\nadd (((y position) - (MapY)) / (32)) to [enemyy v]\nadd [q] to [enemytype v]\nadd [0] to [enemystate v]\nadd [10] to [enemyyvel v]\nadd [0] to [enemyextra v]\nadd (direction) to [enemydir v]\nadd [0] to [enemykey v]\n\ndefine BulletBillMovement\nmove (3) steps\n\ndefine ThrowHammer\nadd (((x position) - (MapX)) / (32)) to [enemyx v]\nadd ((((y position) + (16)) - (MapY)) / (32)) to [enemyy v]\nadd [t] to [enemytype v]\nadd [0] to [enemystate v]\nif <([y position v] of [player v]) > ((y position) + (32))> then\n    add [13] to [enemyyvel v]\nelse\n    add ((10) + (([abs v] of (([x position v] of [player v]) - (x position)) ) * (0.02))) to [enemyyvel v]\nend\nadd [0] to [enemyextra v]\nadd (direction) to [enemydir v]\nadd [0] to [enemykey v]\n\ndefine HammerMovement\nswitch costume to (fireballhitbox v)\nif <(item (EnemyNo.) of [enemyyvel v]) > [-8]> then\n    replace item (EnemyNo.) of [enemyyvel v] with ((item (EnemyNo.) of [enemyyvel v]) - (EnemyGravity))\nend\nif <(item (EnemyNo.) of [enemyyvel v]) < [-8]> then\n    replace item (EnemyNo.) of [enemyyvel v] with [-8]\nend\nchange y by (item (EnemyNo.) of [enemyyvel v])\nchange x by ((direction) / ((42) + ((-12) - ((item (EnemyNo.) of [enemyyvel v]) * (1.7)))))\n\nwhen I receive [hammerhit v]\nif <<not <(EnemyNo.) = [0]>> and <not <(item (EnemyNo.) of [enemytype v]) = [u]>>> then\n    if <<([abs v] of (((x position) - ((16) * <<(item (EnemyNo.) of [enemytype v]) = [h]> or <(item (EnemyNo.) of [enemytype v]) = [i]>>)) - (FireballHitX)) ) < [28]> and <([abs v] of ((y position) - (FireballHitY)) ) < [24]>> then\n        if <not <<<<(item (EnemyNo.) of [enemytype v]) = [d]> or <(item (EnemyNo.) of [enemytype v]) = [o]>> or <<(item (EnemyNo.) of [enemytype v]) = [c]> or <(item (EnemyNo.) of [enemytype v]) = [l]>>> or <<(item (EnemyNo.) of [enemytype v]) = [j]> or <(item (EnemyNo.) of [enemytype v]) = [k]>>>> then\n            start sound [hit1 v]\n            EnemyDeathByOther\n        end\n    end\nend\n\nwhen I start as a clone\nshow\nif <<((((y position) + (8)) - (MapY)) / (32)) < (CurrentLavaLevel)> and <(AllowControl) = [1]>> then\n    add (((x position) - (MapX)) / (32)) to [particlemakex v]\n    add (((y position) - (MapY)) / (32)) to [particlemakey v]\n    add [Drift] to [particlemaketype v]\n    add (EnemyNo.) to [deleteenemylist v]\n    delete this clone\nend\npoint in direction (item (EnemyNo.) of [enemydir v])\nif <(AllowControl) = [0]> then\n    if <not <<(item (EnemyNo.) of [enemytype v]) = [h]> or <(item (EnemyNo.) of [enemytype v]) = [i]>>> then\n        change y by (-1)\n        stop [this script v]\n    end\nend\nif <(item (EnemyNo.) of [enemytype v]) = [a]> then\n    BasicYMovement\n    BasicXMovement [1.07]\nend\nif <<(item (EnemyNo.) of [enemytype v]) = [b]> or <(item (EnemyNo.) of [enemytype v]) = [e]>> then\n    if <(item (EnemyNo.) of [enemystate v]) = [0]> then\n        BasicYMovement\n        BasicXMovement [1.07]\n    end\n    if <(item (EnemyNo.) of [enemystate v]) = [1]> then\n        BasicYMovement\n        BasicXMovement [0]\n        hide\n    end\n    if <(item (EnemyNo.) of [enemystate v]) = [2]> then\n        BasicYMovement\n        BasicXMovement [6.5]\n        hide\n    end\nend\nif <(item (EnemyNo.) of [enemytype v]) = [c]> then\n    hide\nend\nif <(item (EnemyNo.) of [enemytype v]) = [d]> then\n    switch costume to (hitboxthwomp v)\n    ThwompMovement\n    switch costume to (thwompsupport v)\nend\nif <(item (EnemyNo.) of [enemytype v]) = [f]> then\n    if <(item (EnemyNo.) of [enemystate v]) = [0]> then\n        BasicYMovement\n        BasicXMovement [1.07]\n    end\n    if <(item (EnemyNo.) of [enemystate v]) > [0]> then\n        BasicYMovement\n        replace item (EnemyNo.) of [enemyextra v] with ((item (EnemyNo.) of [enemyextra v]) - (0.17))\n        if <(item (EnemyNo.) of [enemyextra v]) < [0]> then\n            replace item (EnemyNo.) of [enemyextra v] with [0]\n        end\n        BasicXMovement (item (EnemyNo.) of [enemyextra v])\n    end\nend\nif <(item (EnemyNo.) of [enemytype v]) = [g]> then\n    VinePlant\n    hide\nend\nif <<(item (EnemyNo.) of [enemytype v]) = [h]> or <(item (EnemyNo.) of [enemytype v]) = [i]>> then\n    PlantMovement\n    hide\n    if <<(item (EnemyNo.) of [enemytype v]) = [i]> and <(AllowControl) = [1]>> then\n        PlantFireball\n    end\nend\nif <(item (EnemyNo.) of [enemytype v]) = [j]> then\n    PlantFireballMovement\n    hide\nend\nif <(item (EnemyNo.) of [enemytype v]) = [k]> then\n    FireballMovement\n    hide\nend\nif <(item (EnemyNo.) of [enemytype v]) = [l]> then\n    hide\nend\nif <(item (EnemyNo.) of [enemytype v]) = [m]> then\n    CheepCheepMovement\nend\nif <(item (EnemyNo.) of [enemytype v]) = [n]> then\n    BoomBoomMovement\nend\nif <(item (EnemyNo.) of [enemytype v]) = [o]> then\n    BasicYMovement\n    if <(item (EnemyNo.) of [enemyextra v]) = [1]> then\n        BasicXMovement [5]\n        if <(item (EnemyNo.) of [enemyyvel v]) = [0]> then\n            replace item (EnemyNo.) of [enemyextra v] with [0]\n        end\n    else\n        BasicXMovement [0]\n    end\nend\nif <(item (EnemyNo.) of [enemytype v]) = [p]> then\n    SpikeMovement\nend\nif <(item (EnemyNo.) of [enemytype v]) = [q]> then\n    SpikeBallMovement\n    hide\nend\nif <(item (EnemyNo.) of [enemytype v]) = [r]> then\n    BulletBillMovement\nend\nif <(item (EnemyNo.) of [enemytype v]) = [s]> then\n    BasicYMovement\n    if <(item (EnemyNo.) of [enemyextra v]) > [0.5]> then\n        BasicXMovement [-1.07]\n        if <<(item (EnemyNo.) of [enemyyvel v]) = [0]> and <<(item (EnemyNo.) of [enemyextra v]) > [0.7]> and <(item (EnemyNo.) of [enemyextra v]) < [0.9]>>> then\n            if <((GameTimer) mod (1.2)) < [0.5]> then\n                replace item (EnemyNo.) of [enemyyvel v] with [12]\n            end\n        end\n    else\n        BasicXMovement [1.07]\n    end\n    if <([x position v] of [player v]) > (x position)> then\n        point in direction (90)\n    else\n        point in direction (-90)\n    end\nend\nif <(item (EnemyNo.) of [enemytype v]) = [t]> then\n    HammerMovement\n    hide\nend\nif <(item (EnemyNo.) of [enemytype v]) = [u]> then\n    HammerMovement\n    hide\nend\nif <(item (EnemyNo.) of [enemytype v]) = [v]> then\n    if <(item (EnemyNo.) of [enemystate v]) = [0]> then\n        BasicYMovement\n        BasicXMovement [1.07]\n    else\n        BasicYMovement\n        BasicXMovement [0]\n        hide\n    end\nend\nif <(item (EnemyNo.) of [enemytype v]) = [w]> then\n    SpikeTopMovement\nend\nif <not <<<(item (EnemyNo.) of [enemytype v]) = [h]> or <(item (EnemyNo.) of [enemytype v]) = [c]>> or <<(item (EnemyNo.) of [enemytype v]) = [i]> or <(item (EnemyNo.) of [enemytype v]) = [l]>>>> then\n    replace item (EnemyNo.) of [enemyx v] with (((x position) - (MapX)) / (32))\n    replace item (EnemyNo.) of [enemyy v] with (((y position) - (MapY)) / (32))\n    change y by (-1)\nend\nif <not <(item (EnemyNo.) of [enemytype v]) = [d]>> then\n    switch costume to (hitbox3 v)\nend\n\ndefine SpikeTopMovement\nif <(y position) < [-134.5]> then\n    delete this clone\nend\nset rotation style [all around v]\nif <(item (EnemyNo.) of [enemystate v]) = [0]> then\n    switch costume to (spiketopcheck v)\n    if <not <<touching (blocks v)?> or <touching (uniqueblocks v)?>>> then\n        set rotation style [left-right v]\n        switch costume to (hitbox v)\n        BasicYMovement\n        BasicXMovement [1.07]\n        replace item (EnemyNo.) of [enemyextra v] with [Fallen]\n        change y by (-1)\n        stop [this script v]\n    end\n    move (1.07) steps\n    if <not <<touching (blocks v)?> or <touching (uniqueblocks v)?>>> then\n        turn left (90) degrees\n        replace item (EnemyNo.) of [enemystate v] with [Left]\n        replace item (EnemyNo.) of [enemyextra v] with (direction)\n        turn right (90) degrees\n    end\n    switch costume to (spiketopcheck2 v)\n    if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n        turn right (90) degrees\n        replace item (EnemyNo.) of [enemystate v] with [Right]\n        replace item (EnemyNo.) of [enemyextra v] with (direction)\n        turn left (90) degrees\n    end\nelse\n    if <(item (EnemyNo.) of [enemystate v]) = [Left]> then\n        turn left (10) degrees\n        if <(round (direction)) = (item (EnemyNo.) of [enemyextra v])> then\n            replace item (EnemyNo.) of [enemystate v] with [0]\n        end\n    end\n    if <(item (EnemyNo.) of [enemystate v]) = [Right]> then\n        turn right (10) degrees\n        if <(round (direction)) = (item (EnemyNo.) of [enemyextra v])> then\n            replace item (EnemyNo.) of [enemystate v] with [0]\n        end\n    end\n    replace item (EnemyNo.) of [enemydir v] with (direction)\nend\n\n@HUD\n\nwhen flag clicked\nhide\ngo to x: (0) y: (-150)\nset size to (400) %\ngo to [front v] layer\nset [inventoryscroll v] to [0]\n\ndefine LoadHUD\nset [hotbar? v] to [1]\nset x to (-208)\nif <(ItemMenu) = [1]> then\n    set y to (-150)\n    set [cloneno. v] to [0]\n    repeat (9)\n        change [cloneno. v] by (1)\n        create clone of (_myself_ v)\n        change x by (52)\n    end\n    go to x: (-168) y: ((140) + (((InventoryScroll) * (50)) mod (50)))\n    set size to (340) %\n    set [hotbar? v] to [0]\n    set [cloneno. v] to (([floor v] of (InventoryScroll) ) * (10))\n    repeat ((length of [itemlist v]) - (CloneNo.))\n        change [cloneno. v] by (1)\n        if <<((CloneNo.) mod (10)) = [1]> and <not <((CloneNo.) - (([floor v] of (InventoryScroll) ) * (10))) = [1]>>> then\n            set x to (-168)\n            change y by (-48)\n        end\n        if <not <(y position) < [-110]>> then\n            if <(y position) > [148]> then\n                set [ghost v] effect to (((y position) - (148)) * (5))\n                change size by (((y position) - (148)) * (-1))\n            end\n            if <(y position) < [-88]> then\n                set [ghost v] effect to (((y position) - (-88)) * (-5))\n                change size by (((y position) - (-88)) * (1))\n            end\n            create clone of (_myself_ v)\n            clear graphic effects\n            change x by (((230) * (2)) / (11))\n            set size to (340) %\n        end\n    end\n    set size to (400) %\nelse\n    set y to (-150)\n    set [cloneno. v] to [0]\n    repeat (9)\n        change [cloneno. v] by (1)\n        create clone of (_myself_ v)\n        change x by (52)\n    end\nend\nset [cloneno. v] to [0]\n\nwhen I start as a clone\nshow\ngo to [front v] layer\ngo [backward v] (6) layers\nif <(Hotbar?) = [1]> then\n    if <(CloneNo.) = [9]> then\n        switch costume to (join [Extra] (([floor v] of (((GameTimer) * (15)) mod (6)) ) + (1)))\n        if <touching (mouse-pointer v)?> then\n            change size by (35)\n        end\n    else\n        switch costume to (item (CloneNo.) of [hotbar v])\n        if <<touching (mouse-pointer v)?> and <not <(CostumeSelected) = (item (CloneNo.) of [hotbar v])>>> then\n            change size by (35)\n        end\n        if <(ItemListSelected) = [0]> then\n            if <(CostumeSelected) = (item (CloneNo.) of [hotbar v])> then\n                change size by (35)\n            end\n        else\n            turn right (([sin v] of ((GameTimer) * (720)) ) * (8)) degrees\n            if <not <(([sin v] of (((GameTimer) + ((CloneNo.) * (0.025))) * (1080)) ) * (20)) < [0]>> then\n                set [brightness v] effect to (([sin v] of (((GameTimer) + ((CloneNo.) * (0.025))) * (1080)) ) * (25))\n            end\n        end\n    end\n    if <not <<<(PlacingPipes) = [1]> and <(letter (1) of (item (CloneNo.) of [hotbar v])) = [£]>> or <<(PlacingPipes) = [0]> or <<(Hotbar?) = [1]> and <(CloneNo.) = [9]>>>>> then\n        if <(ItemListSelected) = [0]> then\n            set [brightness v] effect to (-25)\n            set size to (400) %\n        end\n    end\nelse\n    go [backward v] (24) layers\n    switch costume to (item (CloneNo.) of [itemlist v])\n    if <touching (mouse-pointer v)?> then\n        change size by (75)\n    else\n        if <(distance to [mouse-pointer v]) < [64]> then\n            change size by (((distance to [mouse-pointer v]) - (64)) / (2))\n        end\n    end\n    if <(CloneNo.) = (ItemListSelected)> then\n        turn right (([sin v] of ((GameTimer) * (720)) ) * (8)) degrees\n        change size by (([sin v] of ((GameTimer) * (360)) ) * (24))\n    end\n    if <not <<<(PlacingPipes) = [1]> and <(letter (1) of (item (CloneNo.) of [itemlist v])) = [£]>> or <(PlacingPipes) = [0]>>> then\n        set [brightness v] effect to (-25)\n        set size to (300) %\n    end\nend\n\nwhen this sprite clicked\nif <(CloneNo.) > [0]> then\n    if <(Hotbar?) = [0]> then\n        set [editmode v] to [1]\n        if <<<(PlacingPipes) = [1]> and <(letter (1) of (item (CloneNo.) of [itemlist v])) = [£]>> or <(PlacingPipes) = [0]>> then\n            set [inventoryscroll v] to (([floor v] of (((CloneNo.) / (10)) - (1)) ) - (1.5))\n            if <(InventoryScroll) < [0]> then\n                set [inventoryscroll v] to [0]\n            end\n            if <(InventoryScroll) > [5]> then\n                set [inventoryscroll v] to [5]\n            end\n            if <(CloneNo.) = (ItemListSelected)> then\n                set [itemlistselected v] to [0]\n            else\n                set [gametimer v] to [0]\n                set [itemlistselected v] to (CloneNo.)\n                set [itemlistno. v] to (item # of (costume [name v]) in [itemlist v])\n                if <<(ItemListNo.) > (length of [itemlist v])> or <(ItemListNo.) < [1]>> then\n                    set [itemlistno. v] to [1]\n                end\n                set [costumeselected v] to (item (ItemListNo.) of [itemlist v])\n            end\n        end\n    else\n        if <(CloneNo.) = [9]> then\n            if <(ItemMenu) = [1]> then\n                set [itemmenu v] to [0.9]\n                set [itemlistselected v] to [0]\n            else\n                set [itemmenu v] to [1]\n            end\n        else\n            if <<<(PlacingPipes) = [1]> and <(letter (1) of (item (CloneNo.) of [hotbar v])) = [£]>> or <<(PlacingPipes) = [0]> or <not <(ItemListSelected) = [0]>>>> then\n                set [editmode v] to [1]\n                if <(ItemListSelected) = [0]> then\n                    set [itemlistno. v] to (item # of (costume [name v]) in [hotbar v])\n                    if <<(ItemListNo.) > (length of [hotbar v])> or <(ItemListNo.) < [1]>> then\n                        set [itemlistno. v] to [1]\n                    end\n                    set [costumeselected v] to (item (ItemListNo.) of [hotbar v])\n                else\n                    replace item (CloneNo.) of [hotbar v] with (item (ItemListSelected) of [itemlist v])\n                    set [itemlistselected v] to [0]\n                end\n            end\n        end\n    end\nend\n\nwhen I receive [costuming v]\nif <[1] = [1]> then\n    delete this clone\nend\nshow\nif <<not <(ItemMenu) = [1]>> and <(ItemMenu) > [0]>> then\n    change [itemmenu v] by (-0.1)\n    if <(ItemMenu) < [0.1]> then\n        set [itemmenu v] to [0]\n    end\nend\nif <not <(EditMode) = [0]>> then\n    LoadHUD\n    go to x: (0) y: (-150)\nend\nif <(CloneNo.) = [0]> then\n    if <(EditMode) = [0]> then\n        if <([abs v] of (XVel) ) > [7.19]> then\n            switch costume to (gamerun v)\n        else\n            switch costume to (gamewalk v)\n        end\n    else\n        switch costume to (hud v)\n        go [backward v] (8) layers\n        if <(ItemMenu) = [1]> then\n            hide\n        end\n    end\nend\n\nwhen I receive [menuupdate v]\nif <[1] = [1]> then\n    delete this clone\nend\nhide\n\n@HUD2\n\nwhen flag clicked\nset [showfullhud v] to [1]\nshow\ngo to x: (0) y: (-150)\nset size to (400) %\ngo to [front v] layer\ngo [backward v] (2) layers\n\nwhen I receive [costuming v]\nif <[1] = [1]> then\n    delete this clone\nend\nshow\nMakeClones\nset [touchingmenu v] to [0]\nif <(ItemMenu) = [1]> then\n    switch costume to (itemmenu v)\nelse\n    if <(EditMode) = [0]> then\n        switch costume to (game v)\n    else\n        if <(ShowFullHUD) = [0]> then\n            switch costume to (gameedit2 v)\n        else\n            switch costume to (gameedit v)\n        end\n        if <touching (mouse-pointer v)?> then\n            set [touchingmenu v] to [1]\n        end\n    end\nend\n\ndefine MakeClones\nset [cloneno. v] to [0]\nif <<not <(EditMode) = [0]>> and <not <(ItemMenu) = [1]>>> then\n    if <(ShowFullHUD) = [1]> then\n        repeat (7)\n            change [cloneno. v] by (1)\n            create clone of (_myself_ v)\n        end\n        if <not <<<(CurrentWaterLevel) = [$]> or <(CurrentWaterLevel) = [88.1]>> or <<(CostumeSelected) = [Water]> and <(EditMode) = [1]>>>> then\n            set [cloneno. v] to [10]\n            create clone of (_myself_ v)\n        end\n        if <not <<<(CurrentLavaLevel) = [$]> or <(CurrentLavaLevel) = [40]>> or <<(CostumeSelected) = [Lava]> and <(EditMode) = [1]>>>> then\n            set [cloneno. v] to [11]\n            create clone of (_myself_ v)\n        end\n    end\n    set [cloneno. v] to [12]\n    create clone of (_myself_ v)\nend\nif <(LeavingToMenu) > [0]> then\n    change [leavingtomenu v] by (-0.1)\n    if <(LeavingToMenu) < [0]> then\n        set [leavingtomenu v] to [0]\n    end\nend\nif <not <(ItemMenu) = [1]>> then\n    set [cloneno. v] to [13]\n    create clone of (_myself_ v)\nend\nif <(ItemMenu) = [1]> then\n    set [cloneno. v] to [14]\n    create clone of (_myself_ v)\nend\n\nwhen I start as a clone\ngo to [front v] layer\ngo [backward v] (3) layers\nif <(CloneNo.) = [1]> then\n    go to x: (-216) y: (-104)\n    switch costume to (floorchange v)\n    if <touching (mouse-pointer v)?> then\n        change size by (40)\n        say [Switches between the Sky, Ground and Underground Areas. \(Not themes\)]\n    end\nend\nif <(CloneNo.) = [2]> then\n    go to x: (-216) y: (-70)\n    switch costume to (backchange v)\n    if <touching (mouse-pointer v)?> then\n        change size by (40)\n        say [Switches the Theme of the current area.]\n    end\nend\nif <(CloneNo.) = [3]> then\n    go to x: (-216) y: (-2)\n    switch costume to (play v)\n    if <touching (mouse-pointer v)?> then\n        change size by (40)\n        say [Play the level from the beginning.]\n    end\nend\nif <(CloneNo.) = [4]> then\n    go to x: (216) y: (-36)\n    if <(EditMode) = [1]> then\n        switch costume to (pen v)\n        if <touching (mouse-pointer v)?> then\n            change size by (40)\n            say [Switch between placing, erasing and picking. \(Currently placing\) \[Q\]]\n        end\n    end\n    if <(EditMode) = [2]> then\n        switch costume to (eraser v)\n        if <touching (mouse-pointer v)?> then\n            change size by (40)\n            say [Switch between placing, erasing and picking. \(Currently erasing\) \[Q\]]\n        end\n    end\n    if <(EditMode) = [3]> then\n        switch costume to (picker v)\n        if <touching (mouse-pointer v)?> then\n            change size by (40)\n            say [Switch between placing, erasing and picking. \(Currently picking\) \[Q\]]\n        end\n    end\nend\nif <(CloneNo.) = [5]> then\n    go to x: (216) y: (-70)\n    if <(GroundLevel) = [1]> then\n        switch costume to (join [Camera] (1Camera))\n    end\n    if <(GroundLevel) = [0]> then\n        switch costume to (join [Camera] (0Camera))\n    end\n    if <(GroundLevel) = [-1]> then\n        switch costume to (join [Camera] (-1Camera))\n    end\n    if <touching (mouse-pointer v)?> then\n        change size by (40)\n        if <(costume [name v]) = [Camera1]> then\n            say [Changes how the camera moves in this area. \(Currently anywhere\) \(Will only take effect in Play mode\)]\n        end\n        if <(costume [name v]) = [Camera2]> then\n            say [Changes how the camera moves in this area. \(Currently anywhere past a wall to the left\) \(Will only take effect in Play mode\)]\n        end\n        if <(costume [name v]) = [Camera3]> then\n            say [Changes how the camera moves in this area. \(Currently will only move sideways\) \(Will only take effect in Play mode\)]\n        end\n        if <(costume [name v]) = [Camera4]> then\n            say [Changes how the camera moves in this area. \(Currently will only move up or down\) \(Will only take effect in Play mode\)]\n        end\n        if <(costume [name v]) = [Camera5]> then\n            say [Changes how the camera moves in this area. \(Currently will only move to the right\) \(Will only take effect in Play mode\)]\n        end\n        if <(costume [name v]) = [Camera6]> then\n            say [Changes how the camera moves in this area. \(Currently will only move upwards\) \(Will only take effect in Play mode\)]\n        end\n        if <(costume [name v]) = [Camera7]> then\n            say [Changes how the camera moves in this area. \(Currently will not move, but will move when you spawn or pipes or doors are used\) \(Will only take effect in Play mode\)]\n        end\n        if <(costume [name v]) = [Camera8]> then\n            say [Changes how the camera moves in this area. \(Currently will auto scroll to the right\) \(Will only take effect in Play mode\)]\n        end\n        if <(costume [name v]) = [Camera9]> then\n            say [Changes how the camera moves in this area. \(Currently will auto scroll upwards\) \(Will only take effect in Play mode\)]\n        end\n    end\nend\nif <(CloneNo.) = [6]> then\n    go to x: (-216) y: (-36)\n    switch costume to (timer v)\n    if <touching (mouse-pointer v)?> then\n        change size by (40)\n        say (join [Changes the time limit for the level. \(Min: 20 Max: 600\) \(Currently ] (join (FullLevelTimer) [\)]))\n    end\nend\nif <(CloneNo.) = [7]> then\n    go to x: (216) y: (-104)\n    switch costume to (save v)\n    if <touching (mouse-pointer v)?> then\n        change size by (40)\n        say [Saves your Level as a code, which can be copied and played, or edited later.]\n    end\nend\nif <(CloneNo.) = [10]> then\n    go to x: (182) y: (-104)\n    switch costume to (waterremove v)\n    if <touching (mouse-pointer v)?> then\n        change size by (40)\n        say [Removes water from the current area.]\n    end\nend\nif <(CloneNo.) = [11]> then\n    go to x: (150) y: (-104)\n    if <<<(CurrentWaterLevel) = [$]> or <(CurrentWaterLevel) = [40]>> or <<(CostumeSelected) = [Water]> and <(EditMode) = [1]>>> then\n        set x to (182)\n    end\n    switch costume to (lavaremove v)\n    if <touching (mouse-pointer v)?> then\n        change size by (40)\n        say [Removes lava from the current area.]\n    end\nend\nif <(CloneNo.) = [12]> then\n    go to x: (-224) y: (164)\n    switch costume to (showhud v)\n    if <(ShowFullHUD) = [0]> then\n        switch costume to (showhud2 v)\n    end\n    if <touching (mouse-pointer v)?> then\n        change size by (40)\n        if <(ShowFullHUD) = [1]> then\n            say [Toggles the HUD. \(currently showing\) \[R\]]\n        else\n            say [Toggles the HUD. \(currently hidden\) \[R\]]\n        end\n    end\nend\nif <(CloneNo.) = [13]> then\n    go to x: (224) y: (164)\n    switch costume to (exittomenu v)\n    if <touching (mouse-pointer v)?> then\n        change size by (40)\n        say [Return to the Main Menu \(Progress will be lost\) \(Double Click\)]\n    end\nend\nif <(CloneNo.) = [14]> then\n    if <not <mouse down?>> then\n        set [grabbedslider v] to [0]\n    end\n    switch costume to (scroller v)\n    go to x: (-214) y: ((31) + (((InventoryScroll) + (-2.5)) * (-50)))\n    if <touching (mouse-pointer v)?> then\n        change size by (40)\n        if <mouse down?> then\n            set [grabbedslider v] to [1]\n        end\n    end\n    if <(GrabbedSlider) = [1]> then\n        set y to (mouse y)\n        if <(y position) > [156]> then\n            set y to (156)\n        end\n        if <(y position) < [-94]> then\n            set y to (-94)\n        end\n        set [inventoryscroll v] to ((2.5) - (((y position) - (31)) / (50)))\n    end\nend\n\nwhen this sprite clicked\nif <(costume [name v]) = [FloorChange]> then\n    change [groundlevel v] by (-1)\n    if <(GroundLevel) < [-1]> then\n        set [groundlevel v] to [1]\n    end\n    if <(GroundLevel) = [1]> then\n        set [mapy v] to [-1256]\n    end\n    if <(GroundLevel) = [0]> then\n        set [mapy v] to [56]\n    end\n    if <(GroundLevel) = [-1]> then\n        set [mapy v] to [342]\n    end\nend\nif <(costume [name v]) = [BackChange]> then\n    if <(GroundLevel) = [1]> then\n        change [1theme v] by (1)\n        if <(1Theme) > [12]> then\n            set [1theme v] to [1]\n        end\n    end\n    if <(GroundLevel) = [0]> then\n        change [0theme v] by (1)\n        if <(0Theme) > [12]> then\n            set [0theme v] to [1]\n        end\n    end\n    if <(GroundLevel) = [-1]> then\n        change [-1theme v] by (1)\n        if <(-1Theme) > [12]> then\n            set [-1theme v] to [1]\n        end\n    end\nend\nif <(costume [name v]) = [Play]> then\n    broadcast (PlayButtonClicked v)\nend\nif <<(costume [name v]) = [Pen]> or <<(costume [name v]) = [Eraser]> or <(costume [name v]) = [Picker]>>> then\n    if <(PlacingPipes) = [0]> then\n        change [editmode v] by (1)\n        if <(EditMode) > [3]> then\n            set [editmode v] to [1]\n        end\n    end\nend\nif < (costume [name v]) contains [Camera]?> then\n    if <(GroundLevel) = [1]> then\n        change [1camera v] by (1)\n        if <(1Camera) > [9]> then\n            set [1camera v] to [1]\n        end\n    end\n    if <(GroundLevel) = [0]> then\n        change [0camera v] by (1)\n        if <(0Camera) > [9]> then\n            set [0camera v] to [1]\n        end\n    end\n    if <(GroundLevel) = [-1]> then\n        change [-1camera v] by (1)\n        if <(-1Camera) > [9]> then\n            set [-1camera v] to [1]\n        end\n    end\nend\nif <(costume [name v]) = [WaterRemove]> then\n    if <(GroundLevel) = [1]> then\n        set [1water v] to [-1]\n    end\n    if <(GroundLevel) = [0]> then\n        set [0water v] to [-1]\n    end\n    if <(GroundLevel) = [-1]> then\n        set [-1water v] to [-1]\n    end\n    set [itemmenu v] to [0.9]\nend\nif <(costume [name v]) = [LavaRemove]> then\n    if <(GroundLevel) = [1]> then\n        set [1lava v] to [-1]\n    end\n    if <(GroundLevel) = [0]> then\n        set [0lava v] to [-1]\n    end\n    if <(GroundLevel) = [-1]> then\n        set [-1lava v] to [-1]\n    end\n    set [itemmenu v] to [0.9]\nend\nif <(costume [name v]) = [Timer]> then\n    change [fullleveltimer v] by (20)\n    if <(FullLevelTimer) > [600]> then\n        set [fullleveltimer v] to [20]\n    end\nend\nif <(costume [name v]) = [Save]> then\n    broadcast (Save Code v)\nend\nif <<(costume [name v]) = [ShowHUD]> or <(costume [name v]) = [ShowHUD2]>> then\n    if <(ShowFullHUD) = [1]> then\n        set [showfullhud v] to [0]\n    else\n        set [showfullhud v] to [1]\n    end\nend\nif <(costume [name v]) = [ExitToMenu]> then\n    if <(LeavingToMenu) < [0.8]> then\n        set [leavingtomenu v] to [2]\n    else\n        broadcast (ReturnToMenu v)\n        stop all sounds\n    end\nend\n\nwhen I receive [playbuttonclicked v]\nbroadcast (FadeFast v)\nwait (0.3) seconds\nbroadcast (StartLevelFull v)\n\nwhen I receive [menuupdate v]\nif <[1] = [1]> then\n    delete this clone\nend\nhide\n\n@Particles\n\nwhen flag clicked\nset rotation style [don't rotate v]\nset [clone? v] to [0]\nset size to (400) %\nhide\ndelete all of [particlemaketype v]\ndelete all of [particlemakex v]\ndelete all of [particlemakey v]\ndelete all of [particlemakedir v]\n\nwhen I start as a clone\nset [clone? v] to [1]\npoint in direction (ParticleDir)\nhide\n\nwhen I receive [costuming v]\nif <not <(EditMode) = [0]>> then\n    delete this clone\nend\nif <(Clone?) = [0]> then\n    if <(length of [particlemakex v]) > [0]> then\n        AddParticles\n    end\n    if <(Holding) = [0]> then\n        hide\n    else\n        go to [back v] layer\n        go [forward v] (12) layers\n        change [holdingtimer v] by (0.1)\n        switch costume to (Holding)\n        if <(Holding) = [Bomb]> then\n            switch costume to (join [Bomb] (([floor v] of (((GameTimer) * (15)) mod (2)) ) + (1)))\n        end\n        if <(Holding) = [PSwitch]> then\n            if <(PTimer) = [0]> then\n                switch costume to (join [PSwitch] (([floor v] of (((GameTimer) * (15)) mod (4)) ) + (1)))\n            else\n                switch costume to (pswitch5 v)\n            end\n        end\n        if <<not <<(YVel) = [0]> or <(YVel) = (Gravity)>>> and <not <(Powerup) = [None]>>> then\n            go [forward v] (12) layers\n        end\n        go to (player v)\n        point in direction ([direction v] of [player v])\n        if <(Small) = [0]> then\n            change y by (12)\n        end\n        move (24) steps\n        show\n        if <<not <<key (space v) pressed?> and <(AllowControl) = [1]>>> or <<(Holding) = [Bomb]> and <(HoldingTimer) > [10]>>> then\n            set [kicked v] to [1]\n            SpawnThrownEnemy\n        end\n    end\nend\nif <(Clone?) = [1]> then\n    go to [front v] layer\n    go [backward v] (14) layers\n    show\n    go to x: (((ParticleX) * (32)) + (MapX)) y: (((ParticleY) * (32)) + (MapY))\n    if <(ParticleType) = [Brick]> then\n        if <([abs v] of (direction) ) < [150]> then\n            if <(direction) > [0]> then\n                turn right (6) degrees\n            else\n                turn left (6) degrees\n            end\n            set [particledir v] to (direction)\n        end\n        change x by (([sin v] of (direction) ) * (2))\n        change y by (([cos v] of (direction) ) * (12))\n        set [particlex v] to (((x position) - (MapX)) / (32))\n        set [particley v] to (((y position) - (MapY)) / (32))\n        switch costume to (join [Brick] (([floor v] of (((GameTimer) * (15)) mod (4)) ) + (1)))\n        if <(y position) < [-130]> then\n            delete this clone\n        end\n    else\n        if <(ParticleType) = [Drift]> then\n            turn right (1) degrees\n            switch costume to (join [Drift] ([ceiling v] of ((direction) / (3)) ))\n            change y by (0.4)\n            set [particley v] to (((y position) - (MapY)) / (32))\n            if <(direction) > [12]> then\n                delete this clone\n            end\n        else\n            if <(ParticleType) = [Key]> then\n                set rotation style [don't rotate v]\n                if <(ParticleYVel) = [0]> then\n                    set [particleyvel v] to [6]\n                end\n                if <(ParticleYVel) > [-8]> then\n                    change [particleyvel v] by (-0.4)\n                end\n                if <(ParticleYVel) < [-0.5]> then\n                    delete this clone\n                end\n                change y by (ParticleYVel)\n                set [particley v] to (((y position) - (MapY)) / (32))\n                switch costume to (join [Key] ((7) - ([ceiling v] of (ParticleYVel) )))\n            else\n                if <(ParticleType) = [Coin]> then\n                    set rotation style [don't rotate v]\n                    if <(ParticleYVel) = [0]> then\n                        set [particleyvel v] to [7]\n                    end\n                    if <(ParticleYVel) > [-8]> then\n                        change [particleyvel v] by (-0.5)\n                    end\n                    if <(ParticleYVel) < [0.5]> then\n                        delete this clone\n                    end\n                    change y by (ParticleYVel)\n                    set [particley v] to (((y position) - (MapY)) / (32))\n                    switch costume to (join [c] ((8) - ([ceiling v] of (ParticleYVel) )))\n                else\n                    if <(ParticleType) = [Poof]> then\n                        turn right (1) degrees\n                        switch costume to (join [Explosion] (([ceiling v] of ((direction) / (2)) ) + (4)))\n                        if <(direction) > [8]> then\n                            delete this clone\n                        end\n                    else\n                        if <(ParticleType) = [Explosion]> then\n                            turn right (1) degrees\n                            switch costume to (join [Explosion] (([ceiling v] of ((direction) / (2)) ) + (3)))\n                            if <(direction) > [10]> then\n                                delete this clone\n                            end\n                        else\n                            if <(ParticleType) = [GSquash]> then\n                                turn right (1) degrees\n                                switch costume to (ParticleType)\n                                if <(direction) > [16]> then\n                                    delete this clone\n                                end\n                            else\n                                set rotation style [left-right v]\n                                if <(ParticleYVel) = [0]> then\n                                    set [particleyvel v] to [8]\n                                end\n                                if <(ParticleYVel) > [-8]> then\n                                    change [particleyvel v] by (-0.61)\n                                end\n                                change y by (ParticleYVel)\n                                move (2) steps\n                                set [particlex v] to (((x position) - (MapX)) / (32))\n                                set [particley v] to (((y position) - (MapY)) / (32))\n                                switch costume to (ParticleType)\n                                if <(y position) < [-130]> then\n                                    delete this clone\n                                end\n                            end\n                        end\n                    end\n                end\n            end\n        end\n    end\nend\n\ndefine SpawnThrownEnemy\nstart sound [Kick v]\nadd (((x position) - (MapX)) / (32)) to [enemyx v]\nadd (((y position) - (MapY)) / (32)) to [enemyy v]\nif <(Holding) = [RKoopaShell]> then\n    add [e] to [enemytype v]\n    add [2] to [enemystate v]\n    add [6] to [enemyyvel v]\n    add [0] to [enemyextra v]\nend\nif <(Holding) = [GKoopaShell]> then\n    add [b] to [enemytype v]\n    add [2] to [enemystate v]\n    add [6] to [enemyyvel v]\n    add [0] to [enemyextra v]\nend\nif <(Holding) = [Bomb]> then\n    add [f] to [enemytype v]\n    add (HoldingTimer) to [enemystate v]\n    add [6] to [enemyyvel v]\n    add [6.5] to [enemyextra v]\nend\nif <(Holding) = [PSwitch]> then\n    add [o] to [enemytype v]\n    add [0] to [enemystate v]\n    add [6] to [enemyyvel v]\n    add [1] to [enemyextra v]\nend\nadd [0] to [enemykey v]\nadd ([direction v] of [player v]) to [enemydir v]\nset [holding v] to [0]\nset [kicking v] to [1]\n\nwhen I receive [menuupdate v]\nif <[1] = [1]> then\n    delete this clone\nend\nhide\n\ndefine AddParticles\nrepeat until <(length of [particlemakex v]) = [0]>\n    set [particletype v] to (item (1) of [particlemaketype v])\n    set [particlex v] to (item (1) of [particlemakex v])\n    set [particley v] to (item (1) of [particlemakey v])\n    set [particleyvel v] to [0]\n    if <(item (1) of [particlemaketype v]) = [Coin]> then\n        change [coins v] by (1)\n        if <(Coins) > [99]> then\n            set [coins v] to [0]\n        end\n    end\n    if <(item (1) of [particlemaketype v]) = [Brick]> then\n        set [particledir v] to [-30]\n        create clone of (_myself_ v)\n        set [particledir v] to [-15]\n        create clone of (_myself_ v)\n        set [particledir v] to [15]\n        create clone of (_myself_ v)\n        set [particledir v] to [30]\n        create clone of (_myself_ v)\n    else\n        if <(length of (ParticleType)) < [3]> then\n            set [particledir v] to (item (1) of [particlemakedir v])\n        else\n            set [particledir v] to [0]\n        end\n        create clone of (_myself_ v)\n    end\n    delete (1) of [particlemaketype v]\n    delete (1) of [particlemakex v]\n    delete (1) of [particlemakey v]\n    delete (1) of [particlemakedir v]\nend\n\n@Items\n\nwhen flag clicked\nset size to (400) %\nset rotation style [don't rotate v]\npoint in direction (90)\nhide\ndelete all of [itemdirection v]\ndelete all of [itemstate v]\ndelete all of [itemtype v]\ndelete all of [itemx v]\ndelete all of [itemy v]\ndelete all of [itemyvelocity v]\n\nwhen I receive [enemyupdate v]\nif <[1] = [1]> then\n    delete this clone\nend\nif <(length of [deleteitemlist v]) > [0]> then\n    DeleteItems\nend\nswitch costume to (hitbox v)\nhide\nLoad Enemies\n\ndefine Load Enemies\nif <[1] = [1]> then\n    delete this clone\nend\nset [itemno. v] to [0]\nif <(EditMode) = [0]> then\n    repeat (length of [itemx v])\n        change [itemno. v] by (1)\n        set [x v] to (((item (ItemNo.) of [itemx v]) * (32)) + (MapX))\n        set [y v] to (((item (ItemNo.) of [itemy v]) * (32)) + (MapY))\n        go to x: (X) y: (Y)\n        if <<([abs v] of (X) ) < [220]> and <<(Y) > [-140]> and <(Y) < [180]>>> then\n            create clone of (_myself_ v)\n        end\n    end\nend\nset [itemno. v] to [0]\n\nwhen I start as a clone\nshow\nif <((((y position) + (8)) - (MapY)) / (32)) < (CurrentLavaLevel)> then\n    add (((x position) - (MapX)) / (32)) to [particlemakex v]\n    add (((y position) - (MapY)) / (32)) to [particlemakey v]\n    add [Drift] to [particlemaketype v]\n    add (ItemNo.) to [deleteitemlist v]\n    delete this clone\nend\npoint in direction (item (ItemNo.) of [itemdirection v])\nif <(item (ItemNo.) of [itemtype v]) = [R]> then\n    if <(item (ItemNo.) of [itemstate v]) < [1]> then\n        change y by ((25) / (6))\n        replace item (ItemNo.) of [itemstate v] with ((item (ItemNo.) of [itemstate v]) + ((1) / (16)))\n        if <(item (ItemNo.) of [itemstate v]) > [1]> then\n            replace item (ItemNo.) of [itemstate v] with [1]\n        end\n    else\n        turn right (4) degrees\n        if <<(direction) < [0]> and <(direction) > [-180]>> then\n            change y by (([cos v] of (direction) ) * (1))\n        else\n            change y by (([cos v] of (direction) ) * (-1))\n        end\n        replace item (ItemNo.) of [itemdirection v] with (direction)\n        change x by (([sin v] of (direction) ) * (3))\n        change y by ((EnemyGravity) / (-2))\n    end\nend\nif <<(item (ItemNo.) of [itemtype v]) = [M]> or <(item (ItemNo.) of [itemtype v]) = [U]>> then\n    if <(item (ItemNo.) of [itemstate v]) < [1]> then\n        change y by ((25) / (16))\n        replace item (ItemNo.) of [itemstate v] with ((item (ItemNo.) of [itemstate v]) + ((1) / (16)))\n        if <(item (ItemNo.) of [itemstate v]) > [1]> then\n            replace item (ItemNo.) of [itemstate v] with [1]\n        end\n    else\n        BasicYMovement\n        BasicXMovement [2]\n    end\nend\nif <(item (ItemNo.) of [itemtype v]) = [F]> then\n    if <(item (ItemNo.) of [itemstate v]) < [1]> then\n        change y by ((25) / (16))\n        replace item (ItemNo.) of [itemstate v] with ((item (ItemNo.) of [itemstate v]) + ((1) / (16)))\n        if <(item (ItemNo.) of [itemstate v]) > [1]> then\n            replace item (ItemNo.) of [itemstate v] with [1]\n        end\n    else\n        BasicYMovement\n    end\nend\nif <(item (ItemNo.) of [itemtype v]) = [S]> then\n    if <(item (ItemNo.) of [itemstate v]) < [1]> then\n        change y by ((25) / (16))\n        replace item (ItemNo.) of [itemstate v] with ((item (ItemNo.) of [itemstate v]) + ((1) / (16)))\n        if <(item (ItemNo.) of [itemstate v]) > [1]> then\n            replace item (ItemNo.) of [itemstate v] with [1]\n        end\n    else\n        BasicYMovement\n        BasicXMovement [3]\n    end\nend\nif <<(item (ItemNo.) of [itemtype v]) = [J]> or <(item (ItemNo.) of [itemtype v]) = [H]>> then\n    if <(item (ItemNo.) of [itemstate v]) < [1]> then\n        change y by ((25) / (16))\n        replace item (ItemNo.) of [itemstate v] with ((item (ItemNo.) of [itemstate v]) + ((1) / (16)))\n        if <(item (ItemNo.) of [itemstate v]) > [1]> then\n            replace item (ItemNo.) of [itemstate v] with [1]\n        end\n    else\n        BasicYMovement\n        BasicXMovement [2]\n    end\nend\nreplace item (ItemNo.) of [itemx v] with (((x position) - (MapX)) / (32))\nreplace item (ItemNo.) of [itemy v] with (((y position) - (MapY)) / (32))\nchange y by (-2)\n\ndefine FindFloor\nset [offset v] to [0]\nif <touching (enemies + other v)?> then\n    replace item (ItemNo.) of [itemyvelocity v] with [0]\n    repeat until <not <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <<touching (semisolids v)?> or <touching (enemies + other v)?>>>>\n        change y by (1)\n        change [offset v] by (1)\n        if <(Offset) > [18]> then\n            set y to (Y)\n            stop [this script v]\n        end\n    end\nelse\n    repeat until <not <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <touching (semisolids v)?>>>\n        change y by (1)\n        change [offset v] by (1)\n        if <(Offset) > [20]> then\n            set y to ((Y) + (1))\n            stop [this script v]\n        end\n    end\nend\n\ndefine FindCeiling\nset [offset v] to [0]\nrepeat until <not <<touching (blocks v)?> or <touching (uniqueblocks v)?>>>\n    change [offset v] by (1)\n    change y by (-1)\n    if <(Offset) > [32]> then\n        set y to (Y)\n        stop [this script v]\n    end\nend\n\nwhen I receive [environment update v]\nif <(ItemNo.) > [0]> then\n    show\n    if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [28]> and <<((y position) - ([y position v] of [player v])) < ((48) - ((Small) * (24)))> and <((y position) - ([y position v] of [player v])) > [-24]>>> then\n        if <(item (ItemNo.) of [itemtype v]) = [U]> then\n            start sound [1up v]\n        else\n            if <(item (ItemNo.) of [itemtype v]) = [S]> then\n                stop all sounds\n                set [startimer v] to [10]\n            else\n                if <<(Powerup) = (item (ItemNo.) of [itemtype v])> or <<(item (ItemNo.) of [itemtype v]) = [M]> and <not <(Powerup) = [None]>>>> then\n                    start sound [Coin v]\n                else\n                    start sound [Powerup v]\n                    set [powerup v] to (item (ItemNo.) of [itemtype v])\n                end\n                broadcast (Powerup v)\n            end\n        end\n        add (((x position) - (MapX)) / (32)) to [particlemakex v]\n        add (((y position) - (MapY)) / (32)) to [particlemakey v]\n        add [Poof] to [particlemaketype v]\n        add [0] to [particlemakedir v]\n        add (ItemNo.) to [deleteitemlist v]\n    end\nend\n\ndefine XFix\nset [offset v] to [0]\nrepeat until <not <<touching (blocks v)?> or <touching (uniqueblocks v)?>>>\n    change [offset v] by (0.5)\n    set x to (X)\n    change x by (Offset)\n    if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n        set x to (X)\n        change x by ((Offset) * (-1))\n    end\n    if <(Offset) > [24]> then\n        set x to (X)\n        stop [this script v]\n    end\nend\n\nwhen I receive [bouncedblock v]\nif <(ItemNo.) > [0]> then\n    if <<([abs v] of ((x position) - (BlockBounceX)) ) < [28]> and <([abs v] of ((y position) - (BlockBounceY)) ) < [24]>> then\n        replace item (ItemNo.) of [itemyvelocity v] with [14.6]\n    end\nend\n\nwhen I receive [costuming v]\nif <(ItemNo.) > [0]> then\n    switch costume to (item (ItemNo.) of [itemtype v])\n    if <(item (ItemNo.) of [itemtype v]) = [R]> then\n        set rotation style [left-right v]\n        if <(item (ItemNo.) of [itemstate v]) > [0.99]> then\n            go [forward v] (20) layers\n        end\n    end\n    if <(item (ItemNo.) of [itemtype v]) = [S]> then\n        switch costume to (join [S] (([floor v] of (((GameTimer) * (30)) mod (3)) ) + (1)))\n    end\nend\n\ndefine BasicYMovement\nif <(((y position) - (MapY)) / (32)) < (CurrentWaterLevel)> then\n    if <(item (ItemNo.) of [itemyvelocity v]) > [-2]> then\n        replace item (ItemNo.) of [itemyvelocity v] with ((item (ItemNo.) of [itemyvelocity v]) - ((EnemyGravity) / (2)))\n    end\n    if <(item (ItemNo.) of [itemyvelocity v]) < [-2]> then\n        replace item (ItemNo.) of [itemyvelocity v] with [-2]\n    end\n    if <(item (ItemNo.) of [itemyvelocity v]) > [10]> then\n        replace item (ItemNo.) of [itemyvelocity v] with [10]\n    end\nelse\n    if <(item (ItemNo.) of [itemyvelocity v]) > [-8]> then\n        replace item (ItemNo.) of [itemyvelocity v] with ((item (ItemNo.) of [itemyvelocity v]) - (EnemyGravity))\n    end\n    if <(item (ItemNo.) of [itemyvelocity v]) < [-8]> then\n        replace item (ItemNo.) of [itemyvelocity v] with [-8]\n    end\nend\nchange y by (item (ItemNo.) of [itemyvelocity v])\nif <(item (ItemNo.) of [itemyvelocity v]) > [0]> then\n    if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n        replace item (ItemNo.) of [itemyvelocity v] with [0.5]\n        FindCeiling\n    end\nelse\n    switch costume to (bottom v)\n    if <<<touching (blocks v)?> or <touching (uniqueblocks v)?>> or <<touching (semisolids v)?> or <touching (enemies + other v)?>>> then\n        replace item (ItemNo.) of [itemyvelocity v] with [0]\n        if <<(item (ItemNo.) of [itemtype v]) = [S]> or <<(item (ItemNo.) of [itemtype v]) = [J]> or <(item (ItemNo.) of [itemtype v]) = [H]>>> then\n            replace item (ItemNo.) of [itemyvelocity v] with [12]\n        end\n        FindFloor\n    end\n    switch costume to (hitbox v)\nend\n\ndefine BasicXMovement (speed)\nswitch costume to (hitbox v)\nchange y by (1)\nchange x by ((direction) / ((90) / (speed)))\nif <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n    YSmoothing\nend\nif <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n    XFix\n    turn right (180) degrees\n    if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n        turn right (180) degrees\n    end\n    replace item (ItemNo.) of [itemdirection v] with (direction)\nend\nchange y by (-1)\n\nwhen I receive [enemy bumping update v]\nif <(ItemNo.) > [0]> then\n\nif <(costume [name v]) = [Hitbox3]> then\n    switch costume to (hitbox4 v)\n    if <touching (enemies + other v)?> then\n        turn right (180) degrees\n        replace item (ItemNo.) of [enemydir v] with (direction)\n        XFix\n    end\n    switch costume to (hitbox3 v)\nend\n\nwhen I receive [notebouncedblock v]\nif <(ItemNo.) > [0]> then\n    if <(length of [aboveblockx v]) > [0]> then\n        NoteBlockBounce/Conveyer\n    end\nend\n\ndefine NoteBlockBounce/Conveyer\nset [offset v] to [0]\nrepeat (length of [aboveblockx v])\n    change [offset v] by (1)\n    if <<([abs v] of ((x position) - (item (Offset) of [aboveblockx v])) ) < [28]> and <([abs v] of ((y position) - (item (Offset) of [aboveblocky v])) ) < [8]>> then\n        if <(item (Offset) of [aboveblocktype v]) = [Note]> then\n            replace item (ItemNo.) of [itemyvelocity v] with [14.6]\n        else\n            if <(item (Offset) of [aboveblocktype v]) = [Left]> then\n                replace item (ItemNo.) of [itemx v] with ((item (ItemNo.) of [itemx v]) - ((1) / (34.4)))\n            else\n                replace item (ItemNo.) of [itemx v] with ((item (ItemNo.) of [itemx v]) + ((1) / (34.4)))\n            end\n            stop [this script v]\n        end\n    end\nend\n\ndefine DeleteItems\nrepeat (length of [deleteitemlist v])\n    delete (item (1) of [deleteitemlist v]) of [itemdirection v]\n    delete (item (1) of [deleteitemlist v]) of [itemstate v]\n    delete (item (1) of [deleteitemlist v]) of [itemtype v]\n    delete (item (1) of [deleteitemlist v]) of [itemx v]\n    delete (item (1) of [deleteitemlist v]) of [itemy v]\n    delete (item (1) of [deleteitemlist v]) of [itemyvelocity v]\n    delete (1) of [deleteitemlist v]\nend\n\nwhen I receive [menuupdate v]\nif <[1] = [1]> then\n    delete this clone\nend\nhide\n\ndefine YSmoothing\nrepeat (10)\n    if <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n        change y by (0.5)\n    else\n        stop [this script v]\n    end\nend\nif <<touching (blocks v)?> or <touching (uniqueblocks v)?>> then\n    change y by (-5)\nend\n\n@Pipes\n\nwhen flag clicked\nset size to (400) %\nset rotation style [all around v]\npoint in direction (90)\nhide\n\nwhen I receive [enemyupdate v]\nif <[1] = [1]> then\n    delete this clone\nend\nswitch costume to (hitbox v)\nshow\nLoad Pipes\nhide\n\ndefine Load Pipes\nif <[1] = [1]> then\n    delete this clone\nend\nset [pipeno. v] to [0]\nrepeat (length of [pipex v])\n    change [pipeno. v] by (1)\n    set [x v] to (((item (PipeNo.) of [pipex v]) * (32)) + (MapX))\n    set [y v] to (((item (PipeNo.) of [pipey v]) * (32)) + (MapY))\n    go to x: (X) y: (Y)\n    if <<([abs v] of (X) ) < [240]> and <<(Y) > [-170]> and <(Y) < [180]>>> then\n        create clone of (_myself_ v)\n    end\nend\nset [pipeno. v] to [0]\n\nwhen I start as a clone\nset [color v] effect to (((round ((PipeNo.) / (2))) - (1)) * (16))\nif <(item (PipeNo.) of [pipedir v]) = [D1]> then\n    if <((PipeNo.) mod (2)) = [0]> then\n        switch costume to (d12 v)\n    else\n        switch costume to (d11 v)\n        DownPipeUsage\n    end\nend\nif <(item (PipeNo.) of [pipedir v]) = [D2]> then\n    switch costume to (d2 v)\n    DownPipeUsage\nend\nif <(item (PipeNo.) of [pipedir v]) = [U1]> then\n    if <((PipeNo.) mod (2)) = [0]> then\n        switch costume to (u12 v)\n    else\n        switch costume to (u11 v)\n        UpPipeUsage\n    end\nend\nif <(item (PipeNo.) of [pipedir v]) = [U2]> then\n    switch costume to (u2 v)\n    UpPipeUsage\nend\nif <(item (PipeNo.) of [pipedir v]) = [R1]> then\n    if <((PipeNo.) mod (2)) = [0]> then\n        switch costume to (r12 v)\n    else\n        switch costume to (r11 v)\n        RightPipeUsage\n    end\nend\nif <(item (PipeNo.) of [pipedir v]) = [R2]> then\n    switch costume to (r2 v)\n    RightPipeUsage\nend\nif <(item (PipeNo.) of [pipedir v]) = [L1]> then\n    if <((PipeNo.) mod (2)) = [0]> then\n        switch costume to (l12 v)\n    else\n        switch costume to (l11 v)\n        LeftPipeUsage\n    end\nend\nif <(item (PipeNo.) of [pipedir v]) = [L2]> then\n    switch costume to (l2 v)\n    LeftPipeUsage\nend\nif <(item (PipeNo.) of [pipedir v]) = [Door]> then\n    clear graphic effects\n    switch costume to (£9 v)\n    DoorUsage\n    if <(UsingDoor) > [0]> then\n        if <(PipeNo.) = (PipeUsingNo.)> then\n            if <(UsingDoor) > [0.8]> then\n                switch costume to (door1 v)\n            else\n                switch costume to (door2 v)\n            end\n        end\n    end\n    if <(UsingDoor) < [0]> then\n        if <(PipeNo.) = (PipeDestinationNo.)> then\n            if <(UsingDoor) > [-0.2]> then\n                switch costume to (door1 v)\n            else\n                switch costume to (door2 v)\n            end\n        end\n    end\nend\nif <(item (PipeNo.) of [pipedir v]) = [DoorL]> then\n    clear graphic effects\n    if <(item (PipeNo.) of [pipestate v]) = [1]> then\n        switch costume to (door3 v)\n        DoorUsage\n        if <(UsingDoor) > [0]> then\n            if <(PipeNo.) = (PipeUsingNo.)> then\n                if <(UsingDoor) > [0.8]> then\n                    switch costume to (door4 v)\n                else\n                    switch costume to (door5 v)\n                end\n            end\n        end\n        if <(UsingDoor) < [0]> then\n            if <(PipeNo.) = (PipeDestinationNo.)> then\n                if <(UsingDoor) > [-0.2]> then\n                    switch costume to (door4 v)\n                else\n                    switch costume to (door5 v)\n                end\n            end\n        end\n    else\n        switch costume to (£10 v)\n        if <(item (PipeNo.) of [pipestate v]) > [0]> then\n            set [playerx v] to ((item (PipeNo.) of [pipex v]) * (32))\n            switch costume to (door3 v)\n            replace item (PipeNo.) of [pipestate v] with ((item (PipeNo.) of [pipestate v]) + (0.05))\n            if <(item (PipeNo.) of [pipestate v]) > [1]> then\n                replace item (PipeNo.) of [pipestate v] with [1]\n                UsePipe\n            end\n        end\n        if <(item (PipeNo.) of [pipestate v]) = [0]> then\n            if <(Keys) > [0]> then\n                DoorUnlock\n            end\n        end\n    end\nend\nif <<not <(EditMode) = [0]>> or <<(item (PipeNo.) of [pipedir v]) = [Door]> or <(item (PipeNo.) of [pipedir v]) = [DoorL]>>> then\n    stamp\n    hide\nend\ndelete this clone\n\ndefine DownPipeUsage\nif <not <(EditMode) = [0]>> then\n    stop [this script v]\nend\nif <<<(YVel) = [0]> or <(YVel) = (Gravity)>> and <<<key (s v) pressed?> or <key (down arrow v) pressed?>> and <(AllowControl) = [1]>>> then\n    if <<([abs v] of (((x position) - (16)) - ([x position v] of [player v])) ) < [16]> and <([abs v] of ((y position) - ([y position v] of [player v])) ) < [8]>> then\n        start sound [PowerDown v]\n        UsePipe\n    end\nend\n\ndefine UpPipeUsage\nif <not <(EditMode) = [0]>> then\n    stop [this script v]\nend\nif <<(YVel) = [1.1]> and <<<key (w v) pressed?> or <key (up arrow v) pressed?>> and <(AllowControl) = [1]>>> then\n    if <<([abs v] of (((x position) - (16)) - ([x position v] of [player v])) ) < [16]> and <<((y position) - ([y position v] of [player v])) > [-8]> and <((y position) - ([y position v] of [player v])) < ((40) - ((Small) * (32)))>>> then\n        start sound [PowerDown v]\n        UsePipe\n    end\nend\n\ndefine UsePipe\nset [pipeusingno. v] to (PipeNo.)\nif <((PipeNo.) mod (2)) = [0]> then\n    set [pipedestinationno. v] to ((PipeNo.) - (1))\nelse\n    set [pipedestinationno. v] to ((PipeNo.) + (1))\nend\nif <(letter (2) of (item (PipeDestinationNo.) of [pipedir v])) = [o]> then\n    if <<(item (PipeDestinationNo.) of [pipedir v]) = [DoorL]> and <(item (PipeDestinationNo.) of [pipestate v]) = [0]>> then\n        stop [this script v]\n    else\n        set [pipedestinationx v] to ((item (PipeDestinationNo.) of [pipex v]) * (32))\n    end\nelse\n    set [pipedestinationx v] to (((item (PipeDestinationNo.) of [pipex v]) * (32)) - (16))\nend\nset [pipedestinationy v] to ((item (PipeDestinationNo.) of [pipey v]) * (32))\nbroadcast (UsePipe v)\n\ndefine RightPipeUsage\nif <not <(EditMode) = [0]>> then\n    stop [this script v]\nend\nif <<<(YVel) = [0]> or <(YVel) = (Gravity)>> and <<<key (d v) pressed?> or <key (right arrow v) pressed?>> and <(AllowControl) = [1]>>> then\n    if <<([abs v] of (((x position) - (-16)) - ([x position v] of [player v])) ) < [16]> and <([abs v] of ((y position) - ([y position v] of [player v])) ) < [8]>> then\n        start sound [PowerDown v]\n        UsePipe\n    end\nend\n\ndefine LeftPipeUsage\nif <not <(EditMode) = [0]>> then\n    stop [this script v]\nend\nif <<<(YVel) = [0]> or <(YVel) = (Gravity)>> and <<<key (a v) pressed?> or <key (left arrow v) pressed?>> and <(AllowControl) = [1]>>> then\n    if <<([abs v] of (((x position) - (16)) - ([x position v] of [player v])) ) < [16]> and <([abs v] of ((y position) - ([y position v] of [player v])) ) < [8]>> then\n        start sound [PowerDown v]\n        UsePipe\n    end\nend\n\nwhen I receive [menuupdate v]\nif <[1] = [1]> then\n    delete this clone\nend\nhide\n\nwhen I receive [costuming v]\nif <(PipeNo.) = [0]> then\n    LavaShow\nend\n\ndefine LavaShow\nif <(GroundLevel) = [1]> then\n    set [currentlavalevel v] to (((1Lava) / (32)) + (1))\n    Lava (1Lava)\nend\nif <(GroundLevel) = [0]> then\n    set [currentlavalevel v] to (((0Lava) / (32)) + (1))\n    Lava (0Lava)\nend\nif <(GroundLevel) = [-1]> then\n    set [currentlavalevel v] to (((-1Lava) / (32)) + (1))\n    Lava (-1Lava)\nend\n\ndefine Lava (y)\nif <<(y) = [-1]> and <not <<(CostumeSelected) = [Lava]> and <(EditMode) = [1]>>>> then\n    set [currentlavalevel v] to [$]\nelse\n    show\n    if <<(CostumeSelected) = [Lava]> and <(EditMode) = [1]>> then\n        switch costume to (costume1 v)\n        set size to (400) %\n        switch costume to (join [Lava] (([floor v] of (((GameTimer) * (15)) mod (4)) ) + (1)))\n        go to x: ((MapX) mod (32)) y: (((round (((mouse y) - (MapY)) / (32))) * (32)) + (MapY))\n        set [currentlavalevel v] to [$]\n    else\n        switch costume to (costume1 v)\n        set size to (400) %\n        switch costume to (join [Lava] (([floor v] of (((GameTimer) * (15)) mod (4)) ) + (1)))\n        go to x: ((MapX) mod (32)) y: ((y) + (MapY))\n        if <(y position) > [280]> then\n            switch costume to (costume1 v)\n            set size to (400) %\n            switch costume to (join [Lava] (([floor v] of (((GameTimer) * (15)) mod (4)) ) + (1)))\n            go to x: ((MapX) mod (32)) y: (288)\n        end\n        if <(y position) < [-180]> then\n            hide\n        end\n    end\nend\n\ndefine DoorUsage\nif <not <(EditMode) = [0]>> then\n    stop [this script v]\nend\nif <<<(YVel) = [0]> or <(YVel) = (Gravity)>> and <<<key (s v) pressed?> or <key (down arrow v) pressed?>> and <(AllowControl) = [1]>>> then\n    if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [12]> and <([abs v] of ((y position) - ([y position v] of [player v])) ) < [8]>> then\n        start sound [Door v]\n        UsePipe\n    end\nend\n\ndefine DoorUnlock\nif <not <(EditMode) = [0]>> then\n    stop [this script v]\nend\nif <<<(YVel) = [0]> or <(YVel) = (Gravity)>> and <<<key (s v) pressed?> or <key (down arrow v) pressed?>> and <(AllowControl) = [1]>>> then\n    if <<([abs v] of ((x position) - ([x position v] of [player v])) ) < [12]> and <([abs v] of ((y position) - ([y position v] of [player v])) ) < [8]>> then\n        change [keys v] by (-1)\n        add [Key] to [particlemaketype v]\n        add (((x position) - (MapX)) / (32)) to [particlemakex v]\n        add ((((y position) + (16)) - (MapY)) / (32)) to [particlemakey v]\n        add [0] to [particlemakedir v]\n        replace item (PipeNo.) of [pipestate v] with [0.5]\n        if <((PipeNo.) mod (2)) = [0]> then\n            replace item ((PipeNo.) - (1)) of [pipestate v] with [1]\n        else\n            replace item ((PipeNo.) + (1)) of [pipestate v] with [1]\n        end\n        set [allowcontrol v] to [0]\n        set [allowmovement v] to [0]\n    end\nend\n\n@Text\n\nwhen I receive [costuming v]\nif <[1] = [1]> then\n    delete this clone\nend\nif <(EditMode) = [0]> then\n    go to x: (120) y: (-142)\n    if <(Coins) < [10]> then\n        WriteWordHUD (join [0] (Coins))\n    else\n        WriteWordHUD (Coins)\n    end\n    go to x: (104) y: (-158)\n    if <<([ceiling v] of (Timer) ) < [100]> and <([ceiling v] of (Timer) ) > [9]>> then\n        WriteWordHUD (join [0] ([ceiling v] of (Timer) ))\n    else\n        if <(Timer) < [10]> then\n            WriteWordHUD (join [00] ([ceiling v] of (Timer) ))\n        else\n            WriteWordHUD ([ceiling v] of (Timer) )\n        end\n    end\n    if <(Keys) > [0]> then\n        ShowKeys\n    end\nend\n\nwhen flag clicked\nset [seenwarning v] to [0]\nset [codeinputshown v] to [0]\nset [codeloaded v] to [0]\nswitch costume to (  v)\ndelete all of [characters v]\nwait (2.5) seconds\nMakeCharacterList\nhide\nset size to (400) %\n\ndefine WriteWordHUD (word)\nshow\nset [letter v] to [0]\nrepeat (length of (word))\n    change [letter v] by (1)\n    switch costume to (join [1] (letter (Letter) of (word)))\n    create clone of (_myself_ v)\n    change x by (16)\nend\nhide\n\nwhen I start as a clone\ngo to [front v] layer\ngo [backward v] (1) layers\n\nwhen I receive [menuupdate v]\nif <[1] = [1]> then\n    delete this clone\nend\nhide\nclear graphic effects\nset size to (500) %\ngo to x: (2) y: (-98)\nif <([abs v] of ((mouse y) - (y position)) ) < [16]> then\n    change size by (50)\n    if <mouse down?> then\n        broadcast (TransitionToMaker v)\n    end\nend\nset [word v] to [Make Level]\nWriteWord\nset [brightness v] effect to (100)\ngo to x: (0) y: (-96)\nset [word v] to [Make Level]\nWriteWord\nset size to (500) %\nclear graphic effects\ngo to x: (2) y: (-130)\nif <([abs v] of ((mouse y) - (y position)) ) < [16]> then\n    change size by (50)\n    if <mouse down?> then\n        if <(CodeInputShown) = [0]> then\n            broadcast (AskForACode v)\n        end\n    end\nend\nset [word v] to [Load Level]\nWriteWord\nset [brightness v] effect to (100)\ngo to x: (0) y: (-128)\nset [word v] to [Load Level]\nWriteWord\nclear graphic effects\nset size to (400) %\ngo to x: (2) y: (168)\nset [word v] to [Made By BenjaminWins11]\nif <<([abs v] of ((mouse y) - (y position)) ) < [16]> and <(letter (11) of (Word)) = [n]>> then\n    change x by (-4)\nend\nWriteWord\nset [brightness v] effect to (100)\ngo to x: (0) y: (170)\nset [word v] to [Made By BenjaminWins11]\nWriteWord\nset size to (400) %\nclear graphic effects\n\ndefine ShowKeys\nshow\nswitch costume to (key1 v)\ngo to x: (170) y: (-150)\nrepeat (Keys)\n    create clone of (_myself_ v)\n    change x by (8)\n    if <(x position) > [220]> then\n        set x to (170)\n        change y by (-16)\n        if <(y position) < [-180]> then\n            stop [this script v]\n        end\n    end\nend\nhide\n\ndefine MakeCharacterList\ndelete all of [characters v]\nswitch costume to (a v)\nrepeat until <(costume [number v]) = [1]>\n    add (costume [name v]) to [characters v]\n    next costume\nend\n\ndefine WriteWord\nshow\nset [letter v] to [0]\nset [wordletter v] to [0]\nchange x by (((length of (Word)) - (1)) * (((-8) / (400)) * (size)))\nif <<(length of (Word)) > (((23) / (400)) * (size))> and <not <(Menu) = [1]>>> then\n    set x to (-176)\nend\nrepeat until <not <(Letter) < (length of (Word))>>\n    NextWord\n    if <<((x position) + ((length of (NewWord)) * (((16) / (400)) * (size)))) > [192]> and <(length of (NewWord)) < (((34) / (400)) * (size))>> then\n        if <(y position) < [-160]> then\n            stop [this script v]\n        else\n            set x to (-176)\n            change y by (((-16) / (400)) * (size))\n        end\n    end\n    repeat (length of (NewWord))\n        change [letter v] by (1)\n        switch costume to (item (item # of (letter (Letter) of (Word)) in [characters v]) of [characters v])\n        if <(Word) = [Made by BenjaminWins11]> then\n            change y by (([sin v] of (((GameTimer) + ((Letter) / (75))) * (720)) ) * (1))\n        end\n        create clone of (_myself_ v)\n        if <(Word) = [Made by BenjaminWins11]> then\n            change y by (([sin v] of (((GameTimer) + ((Letter) / (75))) * (720)) ) * (-1))\n        end\n        change x by (((16) / (400)) * (size))\n    end\n    change [letter v] by (1)\n    change x by (((16) / (400)) * (size))\nend\nhide\n\ndefine NextWord\nset [newword v] to []\nchange [wordletter v] by (1)\nrepeat until <<(letter (WordLetter) of (Word)) = [ ]> or <(letter (WordLetter) of (Word)) = []>>\n    set [newword v] to (join (NewWord) (letter (WordLetter) of (Word)))\n    change [wordletter v] by (1)\nend\n\nwhen I receive [askforacode v]\nset [codeinputshown v] to [1]\nif <(SeenWarning) = [0]> then\n    delete all of [save code v]\n    hide list [save code v]\n    add [To load a save code, you must either have your own from a level you saved,] to [save code v]\n    add [or you can take one from the forum linked in Notes.] to [save code v]\n    add [] to [save code v]\n    add [If you take one from the forum, you must copy both the bold and small text.] to [save code v]\n    add [This is done easily by just triple clicking the code, it should highlight the full] to [save code v]\n    add [code, allowing you to Right click and Copy, or do Ctrl + C.] to [save code v]\n    add [Link to Forum: https://scratch.mit.edu/discuss/topic/494544/] to [save code v]\n    add [] to [save code v]\n    add [Then paste the code into the box provided by doing Right click + Paste, or Ctrl + V.] to [save code v]\nend\nask [Enter a valid save code, either your own, or from the forum linked in Notes.] and wait\nset [seenwarning v] to [1]\nshow list [save code v]\nif <(length of (answer)) > [10]> then\n    set [save code v] to (answer)\n    broadcast (MenuFadeOut v)\n    wait (0.16) seconds\n    set [codeloaded v] to [0]\n    set [menu v] to [0.5]\n    set [levelbyme? v] to [0]\n    broadcast (Load Code v)\n    wait (2) seconds\n    if <(CodeLoaded) = [0]> then\n        set [failedcode v] to [1]\n        set [seenwarning v] to [0]\n    end\n    wait (5) seconds\n    if <(CodeLoaded) = [0]> then\n        broadcast (StopTryingToLoadCode v)\n        set [menu v] to [1]\n        broadcast (PipeFadeFast v)\n    end\nend\nset [codeinputshown v] to [0]\n\nwhen I receive [levelintroupdate v]\nif <[1] = [1]> then\n    delete this clone\nend\ngo to [front v] layer\nset [brightness v] effect to (100)\nset size to (400) %\nif <(FailedCode) = [1]> then\n    go to x: (0) y: (30)\n    set [word v] to [Invalid Code!]\n    WriteWord\n    go to x: (0) y: (0)\n    set [word v] to [The code you entered was invalid. Please read the instructions shown.]\n    WriteWord\nend\nif <(CodeLoaded) = [1]> then\n    go to x: (0) y: (30)\n    set [word v] to (Title)\n    WriteWord\n    go to x: (0) y: (-15)\n    set [word v] to (Description)\n    WriteWord\n    go to x: (0) y: (-150)\n    set [word v] to (join [Made By:] (Maker))\n    WriteWord\nend\nclear graphic effects\n\nwhen I receive [transitiontomaker v]\nbroadcast (ClearLevel v)\nstop all sounds\nbroadcast (Respawn v)\nset [levelbyme? v] to [1]\nset [itemmenu v] to [0.9]\nset [menu v] to [0]\nset [editmode v] to [1]\nbroadcast (PipeFadeFast v)\n\n@Transition\n\nwhen flag clicked\nset size to (100) %\ngo to x: (0) y: (0)\nhide\n\nwhen I receive [costuming v]\ngo to [front v] layer\n\nwhen I receive [fadefast v]\nswitch costume to (costume1 v)\nshow\nset [ghost v] effect to (100)\nrepeat (10)\n    change [ghost v] effect by (-10)\nend\nwait (0.2) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nclear graphic effects\nhide\n\nwhen I receive [pipefadefast v]\nswitch costume to (costume1 v)\nclear graphic effects\nshow\nwait (0.2) seconds\nrepeat (10)\n    change [ghost v] effect by (10)\nend\nclear graphic effects\nhide\n\nwhen I receive [menufadeout v]\nswitch costume to (costume1 v)\nshow\nset [ghost v] effect to (100)\nrepeat (5)\n    change [ghost v] effect by (-20)\nend\n\nwhen I receive [menuupdate v]\nswitch costume to (costume1 v)\ngo to [front v] layer\n\nwhen I receive [levelintroupdate v]\nswitch costume to (costume1 v)\ngo to [back v] layer\ngo [forward v] (3) layers\n\nwhen I receive [fadeoutinstant v]\nswitch costume to (costume1 v)\nclear graphic effects\nshow\nwait (0.2) seconds\nrepeat (5)\n    change [ghost v] effect by (20)\nend\nclear graphic effects\nhide\n\n@Logo\n\nwhen flag clicked\nwait (0) seconds\nshow\nclear graphic effects\nset size to (100) %\nswitch costume to (thumbnail3 v)\ngo to [front v] layer\ngo to x: (0) y: (-5)\nrepeat (5)\n    set y to (-5)\n    change [brightness v] effect by (-20)\nend\nclear graphic effects\nstop [other scripts in sprite v]\nswitch costume to (logo2 v)\nset size to (350) %\ngo to x: (0) y: (500)\nhide\nwait (0.34) seconds\ngo to x: (0) y: (258)\nshow\n\nwhen I receive [menuupdate v]\nset drag mode [draggable v]\nif <(y position) < [259]> then\n    show\n    set y to ((((y position) - (45)) / (1.12)) + (45))\n    set x to ((x position) / (1.12))\n    if <(GameTimer) > [0.75]> then\n        change y by (([sin v] of (((GameTimer) - (0.75)) * (480)) ) * (0.4))\n    end\nend\n\nwhen I receive [background update v]\nhide\n\nwhen I receive [levelintroupdate v]\nhide\n\nwhen [timer v] > (0.2)\nset size to (100) %\nswitch costume to (thumbnail3 v)\ngo to x: (0) y: (0)\nset drag mode [not draggable v]\nshow\ngo to [front v] layer\nset [brightness v] effect to (-100)\nrepeat (10)\n    change [brightness v] effect by (10)\nend\nclear graphic effects\nwait until <(timer) < [0.2]>\nhide\n\n@Save/Load\n\ndefine MakeCode\nset [save code v] to (join (join (join [\[b\]Title: ] (Title)) (join [ |   Description: ] (join (Description) [ |   Made by: ]))) (join (Maker) [ | \[/b\]\[small\] ]))\nset [offset v] to [0]\nrepeat (length of [blockx v])\n    change [offset v] by (1)\n    set [save code v] to (join (Save Code) (item (Offset) of [blockx v]))\n    set [save code v] to (join (Save Code) [|])\n    set [save code v] to (join (Save Code) (item (Offset) of [blocky v]))\n    set [save code v] to (join (Save Code) [|])\n    set [save code v] to (join (Save Code) (item (Offset) of [blocktype v]))\n    set [save code v] to (join (Save Code) [|])\nend\nset [save code v] to (join (Save Code) [S])\nset [offset v] to [0]\nrepeat (length of [semix v])\n    change [offset v] by (1)\n    set [save code v] to (join (Save Code) (item (Offset) of [semix v]))\n    set [save code v] to (join (Save Code) [|])\n    set [save code v] to (join (Save Code) (item (Offset) of [semiy v]))\n    set [save code v] to (join (Save Code) [|])\n    set [save code v] to (join (Save Code) (item (Offset) of [semitype v]))\n    set [save code v] to (join (Save Code) [|])\nend\nset [save code v] to (join (Save Code) [U])\nset [offset v] to [0]\nrepeat (length of [unx v])\n    change [offset v] by (1)\n    set [save code v] to (join (Save Code) (item (Offset) of [unx v]))\n    set [save code v] to (join (Save Code) [|])\n    set [save code v] to (join (Save Code) (item (Offset) of [uny v]))\n    set [save code v] to (join (Save Code) [|])\n    set [save code v] to (join (Save Code) (item (Offset) of [untype v]))\n    set [save code v] to (join (Save Code) [|])\nend\nset [save code v] to (join (Save Code) [E])\nset [offset v] to [0]\nrepeat (length of [enx v])\n    change [offset v] by (1)\n    set [save code v] to (join (Save Code) (item (Offset) of [enx v]))\n    set [save code v] to (join (Save Code) [|])\n    set [save code v] to (join (Save Code) (item (Offset) of [eny v]))\n    set [save code v] to (join (Save Code) [|])\n    set [save code v] to (join (Save Code) (item (Offset) of [entype v]))\n    set [save code v] to (join (Save Code) [|])\n    set [save code v] to (join (Save Code) (item (Offset) of [enkey v]))\n    set [save code v] to (join (Save Code) [|])\nend\nset [save code v] to (join (Save Code) [P])\nset [offset v] to [0]\nrepeat (length of [pipex v])\n    change [offset v] by (1)\n    set [save code v] to (join (Save Code) (item (Offset) of [pipex v]))\n    set [save code v] to (join (Save Code) [|])\n    set [save code v] to (join (Save Code) (item (Offset) of [pipey v]))\n    set [save code v] to (join (Save Code) [|])\n    set [save code v] to (join (Save Code) (item (Offset) of [pipetype v]))\n    set [save code v] to (join (Save Code) [|])\n    set [save code v] to (join (Save Code) (item (Offset) of [pipedir v]))\n    set [save code v] to (join (Save Code) [|])\nend\nset [save code v] to (join (Save Code) [E])\nset [save code v] to (join (Save Code) (-1Camera))\nset [save code v] to (join (Save Code) [|])\nset [save code v] to (join (Save Code) (-1Lava))\nset [save code v] to (join (Save Code) [|])\nset [save code v] to (join (Save Code) (-1Theme))\nset [save code v] to (join (Save Code) [|])\nset [save code v] to (join (Save Code) (-1Water))\nset [save code v] to (join (Save Code) [|])\nset [save code v] to (join (Save Code) (0Camera))\nset [save code v] to (join (Save Code) [|])\nset [save code v] to (join (Save Code) (0Lava))\nset [save code v] to (join (Save Code) [|])\nset [save code v] to (join (Save Code) (0Theme))\nset [save code v] to (join (Save Code) [|])\nset [save code v] to (join (Save Code) (0Water))\nset [save code v] to (join (Save Code) [|])\nset [save code v] to (join (Save Code) (1Camera))\nset [save code v] to (join (Save Code) [|])\nset [save code v] to (join (Save Code) (1Lava))\nset [save code v] to (join (Save Code) [|])\nset [save code v] to (join (Save Code) (1Theme))\nset [save code v] to (join (Save Code) [|])\nset [save code v] to (join (Save Code) (1Water))\nset [save code v] to (join (Save Code) [|])\nset [save code v] to (join (Save Code) (GoalX))\nset [save code v] to (join (Save Code) [|])\nset [save code v] to (join (Save Code) (GoalY))\nset [save code v] to (join (Save Code) [|])\nset [save code v] to (join (Save Code) (GoalLevel))\nset [save code v] to (join (Save Code) [|])\nset [save code v] to (join (Save Code) (OriginalSpawnX))\nset [save code v] to (join (Save Code) [|])\nset [save code v] to (join (Save Code) (OriginalSpawnY))\nset [save code v] to (join (Save Code) [|])\nset [save code v] to (join (Save Code) (FullLevelTimer))\nset [save code v] to (join (Save Code) [|])\nset [save code v] to (join (Save Code) [\[/small\]])\n\nwhen I receive [save code v]\nhide\nset [savingprocess v] to [1]\nask [Enter the Name of the Level. \(23 character limit.\)] and wait\nif <<(length of (answer)) < [1]> or <(length of (answer)) > [23]>> then\n    set [title v] to [None]\nelse\n    set [title v] to (answer)\nend\nask [Enter a Description of your Level. \(optional\) \(maybe include the difficulty, specific instructions...\) \(167 character limit.\)] and wait\nif <<(length of (answer)) < [1]> or <(length of (answer)) > [167]>> then\n    set [description v] to []\nelse\n    set [description v] to (answer)\nend\nset [maker v] to (username)\nhide list [save code v]\ndelete all of [save code v]\nadd [To save your code, you will need to repeatedly click on it until the entire code] to [save code v]\nadd [is highlighted, then right click it and click copy.] to [save code v]\nadd [] to [save code v]\nadd [You cannot drag your mouse over the code to copy it as not all will be copied.] to [save code v]\nadd [] to [save code v]\nadd [Once you have copied the code, you can share it in the forum linked in Notes.] to [save code v]\nadd [Do not post it in the comments, they will be deleted if you do.] to [save code v]\nadd [] to [save code v]\nadd [Click Space to confirm that you have read this.] to [save code v]\nadd [If Space isn't working, click the game behind this list and try again.] to [save code v]\nMakeCode\nwait until <key (space v) pressed?>\nrepeat until <(answer) = (Save Code)>\n    delete all of [save code v]\n    add [Repeatedly click on the code until it is fully highlighted, then right click it and copy.] to [save code v]\n    add [It works best if you repeatedly click on a word, try it on 'Title' at the start of the code.] to [save code v]\n    add [] to [save code v]\n    add [The save code is the line below this, starting with 'Title:'] to [save code v]\n    add (Save Code) to [save code v]\n    add [] to [save code v]\n    add [When copied, enter it into the box to check that it was copied correctly.] to [save code v]\n    ask [Enter the code you copied here:] and wait\n    if <not <(answer) = (Save Code)>> then\n        delete all of [save code v]\n        add [Code Copied Incorrectly! Please try again, follow the instructions. Reloading...] to [save code v]\n        wait (2) seconds\n    end\nend\ndelete all of [save code v]\nadd [Code Copied Correctly! Feel free to share it in the forum linked in Notes so others] to [save code v]\nadd [can play it. Do not share anything that violates the Community Guidelines.] to [save code v]\nadd [] to [save code v]\nadd [I hope you enjoyed!] to [save code v]\nadd [] to [save code v]\nadd [Link to the save code forum:] to [save code v]\nadd [https://scratch.mit.edu/discuss/topic/494544/] to [save code v]\nadd [Click Space to return to the editor.] to [save code v]\nwait until <key (space v) pressed?>\nset [savingprocess v] to [0]\nshow list [save code v]\n\ndefine ExtractNext\nset [itemextracted v] to []\nrepeat until <(letter (ExtractLetter) of (Save Code)) = [|]>\n    set [itemextracted v] to (join (ItemExtracted) (letter (ExtractLetter) of (Save Code)))\n    change [extractletter v] by (1)\nend\nchange [extractletter v] by (1)\n\ndefine LoadCode\nset [extractletter v] to [0]\nif <<(letter (1) of (Save Code)) = [-]> or <(letter (1) of (Save Code)) < [10]>> then\n    set [title v] to [Code copied incorrectly.]\n    set [description v] to [The bold text \(Title, Description etc...\) is part of the code. Loading anyway...]\n    set [maker v] to [Unknown]\nelse\n    ExtractTo :\n    change [extractletter v] by (1)\n    ExtractNext\n    set [title v] to (ItemExtracted)\n    ExtractTo :\n    change [extractletter v] by (1)\n    ExtractNext\n    set [description v] to (ItemExtracted)\n    ExtractTo :\n    change [extractletter v] by (1)\n    ExtractNext\n    set [maker v] to (ItemExtracted)\n    change [extractletter v] by (1)\n    if <(letter (ExtractLetter) of (Save Code)) = [\[]> then\n        change [extractletter v] by (11)\n    end\nend\nchange [extractletter v] by (1)\nrepeat until <(letter (ExtractLetter) of (Save Code)) = [S]>\n    ExtractNext\n    add (ItemExtracted) to [blockx v]\n    ExtractNext\n    add (ItemExtracted) to [blocky v]\n    ExtractNext\n    add (ItemExtracted) to [blocktype v]\nend\nchange [extractletter v] by (1)\nrepeat until <(letter (ExtractLetter) of (Save Code)) = [U]>\n    ExtractNext\n    add (ItemExtracted) to [semix v]\n    ExtractNext\n    add (ItemExtracted) to [semiy v]\n    ExtractNext\n    add (ItemExtracted) to [semitype v]\nend\nchange [extractletter v] by (1)\nrepeat until <(letter (ExtractLetter) of (Save Code)) = [E]>\n    ExtractNext\n    add (ItemExtracted) to [unx v]\n    ExtractNext\n    add (ItemExtracted) to [uny v]\n    ExtractNext\n    if <<(ItemExtracted) = [“]> or <(ItemExtracted) = [”]>> then\n        add ["] to [untype v]\n    else\n        add (ItemExtracted) to [untype v]\n    end\nend\nchange [extractletter v] by (1)\nrepeat until <(letter (ExtractLetter) of (Save Code)) = [P]>\n    ExtractNext\n    add (ItemExtracted) to [enx v]\n    ExtractNext\n    add (ItemExtracted) to [eny v]\n    ExtractNext\n    add (ItemExtracted) to [entype v]\n    ExtractNext\n    add (ItemExtracted) to [enkey v]\nend\nchange [extractletter v] by (1)\nrepeat until <(letter (ExtractLetter) of (Save Code)) = [E]>\n    ExtractNext\n    add (ItemExtracted) to [pipex v]\n    ExtractNext\n    add (ItemExtracted) to [pipey v]\n    ExtractNext\n    add (ItemExtracted) to [pipetype v]\n    ExtractNext\n    add (ItemExtracted) to [pipedir v]\nend\nchange [extractletter v] by (1)\nExtractNext\nset [-1camera v] to (ItemExtracted)\nExtractNext\nset [-1lava v] to (ItemExtracted)\nExtractNext\nset [-1theme v] to (ItemExtracted)\nExtractNext\nset [-1water v] to (ItemExtracted)\nExtractNext\nset [0camera v] to (ItemExtracted)\nExtractNext\nset [0lava v] to (ItemExtracted)\nExtractNext\nset [0theme v] to (ItemExtracted)\nExtractNext\nset [0water v] to (ItemExtracted)\nExtractNext\nset [1camera v] to (ItemExtracted)\nExtractNext\nset [1lava v] to (ItemExtracted)\nExtractNext\nset [1theme v] to (ItemExtracted)\nExtractNext\nset [1water v] to (ItemExtracted)\nExtractNext\nset [goalx v] to (ItemExtracted)\nExtractNext\nset [goaly v] to (ItemExtracted)\nExtractNext\nset [goallevel v] to (ItemExtracted)\nExtractNext\nset [originalspawnx v] to (ItemExtracted)\nExtractNext\nset [originalspawny v] to (ItemExtracted)\nExtractNext\nset [fullleveltimer v] to (ItemExtracted)\nset [codeloaded v] to [1]\nstop all sounds\n\ndefine ExtractTo :\nset [itemextracted v] to []\nrepeat until <(letter (ExtractLetter) of (Save Code)) = [:]>\n    set [itemextracted v] to (join (ItemExtracted) (letter (ExtractLetter) of (Save Code)))\n    change [extractletter v] by (1)\nend\nchange [extractletter v] by (1)\n\ndefine ClearLevel\ndelete all of [blocktype v]\ndelete all of [blockx v]\ndelete all of [blocky v]\ndelete all of [enemydir v]\ndelete all of [enemyextra v]\ndelete all of [enemystate v]\ndelete all of [enemytype v]\ndelete all of [enemyx v]\ndelete all of [enemyy v]\ndelete all of [enemyyvel v]\ndelete all of [entype v]\ndelete all of [enx v]\ndelete all of [eny v]\ndelete all of [itemdirection v]\ndelete all of [itemstate v]\ndelete all of [itemtype v]\ndelete all of [itemx v]\ndelete all of [itemy v]\ndelete all of [itemyvelocity v]\ndelete all of [pipedir v]\ndelete all of [pipetype v]\ndelete all of [pipex v]\ndelete all of [pipey v]\ndelete all of [semitype v]\ndelete all of [semix v]\ndelete all of [semiy v]\ndelete all of [uniquebounce v]\ndelete all of [uniquestate v]\ndelete all of [uniquetype v]\ndelete all of [uniquex v]\ndelete all of [uniquey v]\ndelete all of [untype v]\ndelete all of [unx v]\ndelete all of [uny v]\ndelete all of [enkey v]\ndelete all of [enemykey v]\ndelete all of [pipestate v]\nset [originalspawnx v] to [0]\nset [originalspawny v] to [-64]\nset [goalx v] to [0]\nset [goaly v] to [-1]\nset [spawnx v] to [0]\nset [spawny v] to [-64]\nset [editmode v] to [1]\nset [itemlistno. v] to [1]\nset [itemmenu v] to [0.9]\nset [itemlistselected v] to [0]\nset [invincible v] to [0]\nset [groundlevel v] to [0]\nset [-1theme v] to [2]\nset [0theme v] to [1]\nset [1theme v] to [3]\nset [-1camera v] to [1]\nset [0camera v] to [1]\nset [1camera v] to [1]\nset [-1water v] to [-1]\nset [0water v] to [-1]\nset [1water v] to [-1]\nset [-1lava v] to [-1]\nset [0lava v] to [-1]\nset [1lava v] to [-1]\nset [fullleveltimer v] to [300]\n\nwhen I receive [load code v]\nset [failedcode v] to [0]\nset [codeloaded v] to [0]\nClearLevel\nLoadCode\nwait ((3) + ((length of (Description)) / (128))) seconds\nset [menu v] to [0]\nset [editmode v] to [0]\nset [ptimer v] to [0]\nset [startimer v] to [0]\nbroadcast (FadeOutInstant v)\nwait (0.15) seconds\nbroadcast (StartLevelFull v)\n\nwhen I receive [stoptryingtoloadcode v]\nstop [other scripts in sprite v]\n\nwhen I receive [clearlevel v]\nClearLevel\n\n