Jump! A scrolling platformer

Instructions:    —————MY SCRATCH CONVICTION—————\n    I have noticed some things on scratch that I think need to change… This is a fun platformer that also explains my convictions. Every time you jump you have a 1/5 chance of landing on your bottom, meaning times you mess up! The Animation is pretty funny!\nI made the classic spikes since I have never done something like that before…\nPLAY IN GOOGLE CHROME PLAY WITH SOUNDd\nCONTROLS\n-W jump\n-A left\n-D right\n-N skip

@Stage\n\nwhen flag clicked\nset volume to (50) %\nplay sound [videoplayback.mp3 v] until done\n\nwhen flag clicked\nforever\n    if <key (m v) pressed?> then\n        set volume to (0) %\n        wait (0.5) seconds\n        wait until <key (m v) pressed?>\n        set volume to (50) %\n    end\n    wait (0.5) seconds\nend\n\nwhen flag clicked\nswitch backdrop to (backdrop1 v)\n\nwhen I receive [start v]\nswitch backdrop to (backdrop2 v)\n\n@Ground\n\nwhen flag clicked\nswitch costume to (costume1 v)\ngo to x: (-13) y: (0)\nhide\n\nwhen I receive [start v]\nshow\n\nwhen I receive [next v]\nnext costume\n\nwhen flag clicked\nforever\n    if <(costume [number v]) = [23]> then\n        switch backdrop to (backdrop2 v)\n    end\nend\n\nwhen I receive [start v]\nswitch backdrop to (backdrop3 v)\nforever\n    if <(costume [number v]) = [16]> then\n        switch backdrop to (backdrop3 v)\n    end\nend\n\nset [dead v] to [1]\n\nwhen I receive [break v]\nplay sound [Light Bulb Breaking-SoundBible.com-53066515 v] until done\nswitch costume to (costume26 v)\n\nwhen I receive [start v]\nforever\n    if <(costume [number v]) = [29]> then\n    end\nend\n\nwhen I receive [fin. v]\nplay sound [thefatrat windfall 2.mp3 v] until done\n\nbroadcast (fin. v)\n\n@You\n\ndefine Walk (direction) (speed)\npoint in direction (direction)\nchange x by (speed)\nset [slope v] to [0]\nrepeat until <<(slope) = [8]> or <not <touching (ground v)?>>>\n    change y by (1)\n    change [slope v] by (1)\nend\nif <touching color (#003fff)?> then\n    go to x: (-204) y: (5)\nend\nif <(slope) = [8]> then\n    change x by ((0) - (speed))\n    change y by ((0) - (slope))\nend\n\ndefine Walk (direction) (speed)\npoint in direction (direction)\nchange x by (speed)\nset [slope v] to [0]\nrepeat until <<(slope) = [8]> or <not <touching (ground v)?>>>\n    change y by (1)\n    change [slope v] by (1)\nend\nif <(slope) = [8]> then\n    change x by ((0) - (speed))\n    change y by ((0) - (slope))\n    if <<key (w v) pressed?> and <([abs v] of (speed) ) > [3]>> then\n        if <(wall jump) = [0]> then\n            set [speed x v] to ((-1.2) * (speed))\n            set [speed y v] to [11]\n            set [falling? v] to [6]\n            set [wall jump v] to [15]\n        end\n    else\n        set [speed x v] to [0]\n    end\nend\nif <(speed) < [0]> then\n    change [frame v] by ((speed) / (-8))\nelse\n    change [frame v] by ((speed) / (8))\nend\n\ndefine Touch Ground <up?>\nchange [falling? v] by (1)\nrepeat until <not <touching (ground v)?>>\n    if <up?> then\n        change y by (-1)\n    else\n        change y by (1)\n        set [falling? v] to [0]\n    end\n    set [speed y v] to [0]\nend\n\nwhen I receive [start v]\nset size to (25) %\nset rotation style [left-right v]\ngo to x: (-204) y: (-122)\nshow\nset [speed y v] to [0]\nset [falling? v] to [10]\nforever\n    switch costume to (hitbox v)\n    if <<(speed y) < [4]> or <key (w v) pressed?>> then\n        change [speed y v] by (-1)\n    else\n        change [speed y v] by (-2)\n    end\n    change y by (speed y)\n    Touch Ground <(speed y) > [0]>\n    if <(wall jump) > [0]> then\n        change [wall jump v] by (-1)\n    else\n        set [speed x v] to ((speed x) * (0.7))\n        if <key (a v) pressed?> then\n            change [speed x v] by (-1.5)\n        end\n        if <key (d v) pressed?> then\n            change [speed x v] by (1.5)\n        end\n    end\n    if <(speed x) < [-0.5]> then\n        Walk (-90) (speed x)\n    else\n        if <(speed x) > [0.5]> then\n            Walk (90) (speed x)\n        else\n            set [frame v] to [0]\n        end\n    end\n    if <key (w v) pressed?> then\n        if <<(jump key) = [0]> and <(falling?) < [3]>> then\n            set [speed y v] to [14]\n            set [falling? v] to [6]\n            set [jump key v] to [1]\n        end\n    else\n        set [jump key v] to [0]\n    end\n    if <(y position) < [-180]> then\n        go to x: (0) y: (100)\n        set [speed y v] to [0]\n    end\nend\n\nwhen flag clicked\nforever\n    if <(x position) = [240]> then\n        go to x: (-204) y: (5)\n        broadcast (next v)\n    end\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [start v]\nforever\n    if <touching color (#003fff)?> then\n        set [dead v] to [1]\n        go to x: (-204) y: (5)\n    else\n        set [dead v] to [0]\n    end\nend\n\nwhen I receive [start v]\nforever\n    if <(Dead) = [1]> then\n        go to x: (-204) y: (5)\n    end\nend\n\nwhen [r v] key pressed\ngo to x: (-204) y: (5)\n\nwhen I receive [start v]\nforever\n    if <touching color (#99b2ff)?> then\n        broadcast (next v)\n    end\nend\n\nwhen I receive [start v]\nforever\n    if <touching color (#003fff)?> then\n        go to x: (-204) y: (5)\n    end\nend\n\nwhen I receive [start v]\nforever\n    if <([costume # v] of [ground v]) = [23]> then\n        repeat until <not <([costume # v] of [ground v]) = [23]>>\n            think [Now I just need to go home.] for (2) seconds\n        end\n    end\nend\n\ngo to x: (-204) y: (5)\n\nrepeat until <not <([costume # v] of [ground v]) = [23]>>\n    think [Now I just need to go home.] for (2) seconds\nend\n\nwhen I receive [start v]\nforever\n    if <([costume # v] of [ground v]) = [24]> then\n        if <(x position) > [-57]> then\n            stop [other scripts in sprite v]\n            broadcast (oh no! v)\n            hide\n            stop [this script v]\n        end\n    end\nend\n\nwhen I receive [oh no! v]\nwait (3) seconds\nshow\ngo to x: (53) y: (-125)\nwait (5) seconds\nrepeat until <touching (_edge_ v)?>\n    change y by (-1)\n    turn right (2) degrees\nend\nhide\nbroadcast (next v)\ngo to x: (32) y: (-138)\npoint in direction (-90)\nshow\nwait (0.4) seconds\nsay [Help! Help, I'm stuck!] for (3) seconds\nwait (0.2) seconds\nbroadcast (i'm chilling in a hole. v)\n\nwhen I receive [it's time to climb baby. v]\nglide (0.7) secs to x: (-34) y: (-125)\nglide (1) secs to x: (-72) y: (100)\nglide (0.3) secs to x: (-99) y: (100)\nbroadcast (okay. let's go home i'm so lazy of making another scene of this game so let's make it fade out and fade back in. v)\n\nwhen I receive [finally this game is done hooray now people will stop commenting that i'm lazy and haven't finished this. time to go to sleep and watch youtube. the moment everyone has been waiting for. v]\ngo to x: (-11) y: (-74)\n\nwhen I receive [y'all need a friend v]\nsay [Sure! How does Tuesday at my place sound?] for (3) seconds\n\nwhen I receive [it's finished. time to sleep :\) v]\npoint in direction (90)\ngo to x: (-86) y: (-75)\nwait (4.6) seconds\nthink [Finally. Time for sleep.] for (2) seconds\nthink [I think I'll go on an adventure tomorrow too.] for (3) seconds\nhide\nbroadcast (next v)\nwait (1) seconds\nbroadcast (fin. v)\n\ngo to [front v] layer\n\nbroadcast (fin. v)\n\nbroadcast (next v)\n\n@Sprite2\n\nwhen flag clicked\ngo to x: (0) y: (0)\nshow\nset [divide v] to [0]\nrepeat (40)\n    change [divide v] by (((1500) - (divide)) / (5))\nend\n\nwhen flag clicked\nreset timer\nset [size v] to [10]\nforever\n    set [size v] to (([sin v] of ((timer) * (100)) ) * (10))\n    point in direction ((Size) + (90))\nend\n\nwhen flag clicked\nforever\n    if <touching (mouse-pointer v)?> then\n        set [brightness v] effect to (10)\n    else\n        set [brightness v] effect to (0)\n    end\nend\n\nwhen this sprite clicked\nbroadcast (start v)\nhide\n\nwhen I receive [start v]\nforever\n    if <color (#003fff) is touching ([direction v] of [you v])?> then\n        set [dead v] to [1]\n    end\nend\n\n@Sprite3\n\nwhen flag clicked\nset [ghost v] effect to (100)\ngo to x: (-189) y: (172)\nforever\n    set x to (pick random (-227) to (227))\n    wait (1) seconds\n    create clone of (_myself_ v)\nend\n\nwhen I start as a clone\ngo [backward v] (5) layers\nset [ghost v] effect to (0)\nrepeat until <touching (_edge_ v)?>\n    change y by (-1)\nend\ndelete this clone\n\n@Penguin Traveler\n\nwhen flag clicked\nhide\n\nwhen flag clicked\nforever\n    point towards (you v)\nend\n\nwhen I receive [start v]\nforever\n    if <([costume # v] of [ground v]) = [4]> then\n        show variable [coins v]\n        show\n        go to x: (141) y: (-126)\n        repeat until <not <([costume # v] of [ground v]) = [4]>>\n            if <([x position v] of [you v]) > [61]> then\n                think [\(Click to Talk\)] for (1) seconds\n            end\n        end\n    else\n        if <([costume # v] of [ground v]) = [8]> then\n            if <(Coins) = [3]> then\n                hide variable [coins v]\n            end\n            show\n            go to x: (141) y: (-126)\n            repeat until <not <([costume # v] of [ground v]) = [9]>>\n                if <([x position v] of [you v]) > [61]> then\n                    think [\(Click to Talk\)] for (1) seconds\n                end\n            end\n        else\n            hide\n        end\n    end\nend\n\nwhen this sprite clicked\nif <([costume # v] of [ground v]) = [4]> then\n    broadcast (Speak v)\nelse\n    if <([costume # v] of [ground v]) = [8]> then\n        broadcast (Speak2 v)\n    end\nend\n\n@Traveler Dioluague\n\nwhen flag clicked\nhide\n\nwhen I receive [speak v]\ngo to [front v] layer\nshow\nswitch costume to (costume1 v)\nrepeat until <(costume [number v]) = [5]>\n    if <key (space v) pressed?> then\n        next costume\n        wait (1) seconds\n    end\nend\nwait (0.5) seconds\nwait until <key (space v) pressed?>\nhide\n\nwhen I receive [speak2 v]\ngo to [front v] layer\nshow\nswitch costume to (costume1 v)\nif <(Coins) < [3]> then\n    switch costume to (costume6 v)\n    wait until <key (space v) pressed?>\n    broadcast (Game Over v)\nend\nswitch costume to (costume7 v)\nrepeat until <(costume [number v]) = [10]>\n    if <key (space v) pressed?> then\n        next costume\n        wait (1) seconds\n    end\nend\nwait (0.5) seconds\nwait until <key (space v) pressed?>\nhide\n\n@Sprite1\n\nwhen flag clicked\nset [coins v] to [0]\nhide variable [coins v]\ngo to x: (216) y: (131)\nhide\n\nwhen I receive [start v]\nforever\n    if <([costume # v] of [ground v]) = [5]> then\n        go to x: (216) y: (131)\n        show\n        repeat until <([costume # v] of [ground v]) = [6]>\n            if <touching (you v)?> then\n                change [coins v] by (1)\n                hide\n                play sound [Mario-coin-sound.mp3 v] until done\n            end\n        end\n        go to x: (-25) y: (132)\n        show\n    else\n        if <([costume # v] of [ground v]) = [6]> then\n            go to x: (-25) y: (132)\n            show\n            repeat until <([costume # v] of [ground v]) = [7]>\n                if <touching (you v)?> then\n                    change [coins v] by (1)\n                    hide\n                    play sound [Mario-coin-sound.mp3 v] until done\n                end\n            end\n        else\n            if <([costume # v] of [ground v]) = [7]> then\n                go to x: (195) y: (141)\n                show\n                repeat until <([costume # v] of [ground v]) = [8]>\n                    if <touching (you v)?> then\n                        change [coins v] by (1)\n                        hide\n                        play sound [Mario-coin-sound.mp3 v] until done\n                    end\n                end\n            else\n                hide\n            end\n        end\n    end\nend\n\nwhen I receive [start v]\nforever\n    if <<([costume # v] of [ground v]) = [5]> or <<([costume # v] of [ground v]) = [6]> or <([costume # v] of [ground v]) = [7]>>> then\n        forever\n            repeat (5)\n                change y by (1)\n                wait (0.1) seconds\n            end\n            wait (0.1) seconds\n            repeat (5)\n                change y by (-1)\n                wait (0.1) seconds\n            end\n            wait (0.1) seconds\n        end\n    else\n        hide\n    end\nend\n\n@Sprite4\n\nwhen flag clicked\nhide\ngo to x: (0) y: (0)\n\nwhen I receive [game over v]\nshow\ngo to [front v] layer\nstop all sounds\nplay sound [medieval1 v] until done\n\n@Penguin Mom\n\nwhen flag clicked\nhide\n\nwhen flag clicked\nforever\n    point towards (you v)\nend\n\nwhen I receive [start v]\nforever\n    if <([costume # v] of [ground v]) = [10]> then\n        show\n        go to x: (141) y: (-126)\n        repeat until <not <([costume # v] of [ground v]) = [10]>>\n            if <([x position v] of [you v]) > [61]> then\n                think [\(Click to Talk\)] for (1) seconds\n            end\n        end\n    else\n        if <([costume # v] of [ground v]) = [14]> then\n            show\n            go to x: (141) y: (-126)\n            repeat until <not <([costume # v] of [ground v]) = [14]>>\n                if <([x position v] of [you v]) > [61]> then\n                    think [\(Click to Talk\)] for (1) seconds\n                end\n            end\n        else\n            if <([costume # v] of [ground v]) = [27]> then\n                show\n            else\n                hide\n            end\n        end\n    end\nend\n\nwhen this sprite clicked\nif <([costume # v] of [ground v]) = [10]> then\n    broadcast (Help v)\nelse\n    if <([costume # v] of [ground v]) = [14]> then\n        broadcast (Yay v)\n    end\nend\n\nwhen I receive [i'm chilling in a hole. v]\ngo to x: (-206) y: (100)\nwait (8) seconds\nforever\n    show\nend\n\ngo to x: (-157) y: (99)\n\nwhen I receive [i'm chilling in a hole. v]\nwait (8) seconds\nsay [Oh dear! You're the penguin who saved my daughter!] for (6) seconds\nsay [Hold on, we'll help you! Thanks for helping us!] for (5) seconds\nwait (0.5) seconds\nbroadcast (Oh no! #2 v)\n\nwhen I receive [ladder v]\nwait (11) seconds\nsay [Be careful! The ladder is made out of ice.] for (3) seconds\nbroadcast (It's time to climb baby. v)\n\nwhen I receive [finally this game is done hooray now people will stop commenting that i'm lazy and haven't finished this. time to go to sleep and watch youtube. the moment everyone has been waiting for. v]\ngo to x: (-175) y: (-73)\nwait (2) seconds\nsay [Well, I'm glad I could help.] for (2) seconds\nsay [I need to go home now. My daughter is waiting.] for (3) seconds\nsay [Stay safe!] for (1) seconds\nforever\n    hide\nend\n\n@Mom Dioluague\n\nwhen flag clicked\nhide\n\nwhen I receive [help v]\ngo to x: (2) y: (-127)\ngo to [front v] layer\nshow\nswitch costume to (costume1 v)\nrepeat until <(costume [number v]) = [4]>\n    if <key (space v) pressed?> then\n        next costume\n        wait (1) seconds\n    end\nend\nwait (0.5) seconds\nwait until <key (space v) pressed?>\nhide\n\nwhen I receive [yay v]\ngo to x: (2) y: (-127)\ngo to [front v] layer\nshow\nif <(Follow) = [1]> then\n    switch costume to (costume6 v)\n    repeat until <(costume [number v]) = [7]>\n        if <key (space v) pressed?> then\n            next costume\n            wait (1) seconds\n        end\n    end\n    wait (0.5) seconds\n    wait until <key (space v) pressed?>\n    hide\nelse\n    switch costume to (costume5 v)\n    wait until <key (space v) pressed?>\n    hide\n    broadcast (Game Over v)\nend\n\n@Sprite5\n\nwhen flag clicked\ngo to x: (0) y: (0)\nhide\ngo to [front v] layer\n\n@Penguin Daughter\n\nwhen flag clicked\nhide\n\nwhen flag clicked\nforever\n    point towards (you v)\nend\n\nwhen this sprite clicked\nif <([costume # v] of [ground v]) = [13]> then\n    broadcast (Thank you! v)\nelse\nend\n\nwhen I receive [start v]\nforever\n    if <([costume # v] of [ground v]) = [13]> then\n        show\n        go to x: (150) y: (-126)\n        repeat until <not <([costume # v] of [ground v]) = [13]>>\n            if <([x position v] of [you v]) > [61]> then\n                think [\(Click to Talk\)] for (1) seconds\n            end\n        end\n    else\n        if <([costume # v] of [ground v]) = [14]> then\n            if <(Follow) = [1]> then\n                show\n            end\n        else\n            hide\n        end\n    end\nend\n\nwhen I receive [follow v]\nrepeat until <([costume # v] of [ground v]) = [14]>\n    glide (0.4) secs to x: ([x position v] of [you v]) y: ([y position v] of [you v])\nend\ngo to x: (150) y: (-126)\n\n@Daughter Dioluague\n\nwhen flag clicked\nset [follow v] to [0]\nhide variable [follow v]\nhide\n\nwhen I receive [thank you! v]\ngo to x: (2) y: (-127)\nshow\ngo to [front v] layer\nswitch costume to (costume1 v)\nwait until <key (space v) pressed?>\nhide\nbroadcast (Follow v)\nset [follow v] to [1]\n\n@Trapped Penguin\n\nwhen flag clicked\nhide\n\nwhen flag clicked\nforever\n    point towards (you v)\nend\n\nwhen I receive [start v]\nforever\n    if <([costume # v] of [ground v]) = [17]> then\n        show\n        go to x: (141) y: (-126)\n        repeat until <not <([costume # v] of [ground v]) = [17]>>\n            if <([x position v] of [you v]) > []> then\n                think [\(Click to Talk\)] for (1) seconds\n            end\n        end\n    else\n        if <([costume # v] of [ground v]) = [21]> then\n            show\n            go to x: (141) y: (-126)\n            repeat until <not <([costume # v] of [ground v]) = [21]>>\n                if <([x position v] of [you v]) > []> then\n                    think [\(Click to Talk\)] for (1) seconds\n                end\n            end\n        else\n            if <([costume # v] of [ground v]) = [22]> then\n                show\n                go to x: (141) y: (-126)\n                repeat until <not <([costume # v] of [ground v]) = [22]>>\n                    if <([x position v] of [you v]) > [61]> then\n                        think [\(Click to Talk\)] for (1) seconds\n                    end\n                end\n            else\n                hide\n            end\n        end\n    end\nend\n\nwhen this sprite clicked\nif <([costume # v] of [ground v]) = [17]> then\n    broadcast (Get me out! v)\nelse\n    if <([costume # v] of [ground v]) = [21]> then\n        broadcast (You Found Me! v)\n    else\n        if <([costume # v] of [ground v]) = [22]> then\n            broadcast (Hooray!! v)\n        end\n    end\nend\n\nwhen I receive [i'm chilling in a hole. v]\ngo to x: (-149) y: (100)\nforever\n    show\nend\n\nwhen I receive [i'm chilling in a hole. v]\nsay [Hey! It's tuxedo guy!] for (3) seconds\nsay [We need to get you out of there.] for (5) seconds\n\nwhen I receive [ladder v]\nwait (1) seconds\nsay [There, we built you a ladder! I don't know how we did it so fast...] for (5) seconds\nsay [Oh well, this a game, right? Not reality. Building stuff takes a few seconds.] for (6) seconds\n\nwhen I receive [finally this game is done hooray now people will stop commenting that i'm lazy and haven't finished this. time to go to sleep and watch youtube. the moment everyone has been waiting for. v]\ngo to x: (-121) y: (-73)\nwait (7.8) seconds\nsay [Hey, you're one cool penguin.] for (2) seconds\nsay [Maybe we could hang out sometime?] for (2) seconds\nbroadcast (y'all need a friend v)\nwait (3) seconds\nsay [R-Really?? I've never actually hung out with someone before...everyone turned me down!] for (4) seconds\nsay [Alrighty! It's a deal! But you should get some rest. You must be exhausted. ] for (4) seconds\nsay [See you on Tuesday!] for (2) seconds\nbroadcast (it's finished. Time to sleep :\) v)\nforever\n    hide\nend\n\nwait until <([costume # v] of [ground v]) = [27]>\n\nbroadcast (finally this game is done hooray now people will stop commenting that I'm lazy and haven't finished this. Time to go to sleep and watch YouTube. the moment everyone has been waiting for. v)\n\n@Trapped Penguin Dialouge\n\nwhen flag clicked\nhide\n\nwhen I receive [get me out! v]\ngo to x: (2) y: (-127)\ngo to [front v] layer\nshow\nif <([costume # v] of [ground v]) = [17]> then\n    switch costume to (costume1 v)\n    repeat until <(costume [number v]) = [5]>\n        if <key (space v) pressed?> then\n            next costume\n            wait (1) seconds\n        end\n    end\n    wait (0.5) seconds\n    wait until <key (space v) pressed?>\n    hide\nelse\nend\n\nwhen I receive [you found me! v]\ngo to x: (2) y: (-127)\ngo to [front v] layer\nshow\nif <([costume # v] of [ground v]) = [21]> then\n    if <(Hammer) = [1]> then\n        switch costume to (costume6 v)\n        repeat until <(costume [number v]) = [8]>\n            if <key (space v) pressed?> then\n                next costume\n                wait (1) seconds\n            end\n        end\n        wait (0.5) seconds\n        wait until <key (space v) pressed?>\n        hide\n    else\n        switch costume to (costume8 v)\n        wait until <key (space v) pressed?>\n        hide\n        broadcast (Game Over v)\n    end\nelse\nend\n\nwhen I receive [hooray!! v]\ngo to x: (2) y: (-127)\ngo to [front v] layer\nshow\nif <([costume # v] of [ground v]) = [22]> then\n    switch costume to (costume9 v)\n    repeat until <(costume [number v]) = [11]>\n        if <key (space v) pressed?> then\n            next costume\n            wait (1) seconds\n        end\n    end\n    wait (0.5) seconds\n    wait until <key (space v) pressed?>\n    hide\nelse\nend\n\nswitch costume to (costume8 v)\nwait until <key (space v) pressed?>\nhide\nbroadcast (Game Over v)\n\n@Sprite6\n\nwhen flag clicked\ngo to x: (35) y: (98)\nhide\nforever\n    if <([costume # v] of [ground v]) = [19]> then\n        show\n        repeat until <not <([costume # v] of [ground v]) = [19]>>\n            change y by (-6)\n            if <touching color (#003fff)?> then\n                start sound [water drop v]\n                go to x: (35) y: (98)\n            end\n        end\n    else\n        hide\n    end\nend\n\n@Hammer\n\nwhen flag clicked\ngo to x: (-36) y: (-100)\nhide variable [hits until ice breaks v]\nset [hits until ice breaks v] to [5]\nset [hammer v] to [0]\npoint in direction (90)\nswitch costume to (costume1 v)\nhide\nrepeat until <touching (you v)?>\n    if <([costume # v] of [ground v]) = [20]> then\n        show\n        repeat until <touching (you v)?>\n            repeat (5)\n                change y by (1)\n                wait (0.1) seconds\n            end\n            wait (0.1) seconds\n            repeat (5)\n                change y by (-1)\n                wait (0.1) seconds\n            end\n            wait (0.1) seconds\n        end\n        hide\n        broadcast (Hammer v)\n        set [hammer v] to [1]\n    else\n        hide\n    end\nend\nhide\nbroadcast (Hammer v)\n\nwhen I receive [hammer v]\nswitch costume to (costume2 v)\nshow\nforever\n    go to (you v)\nend\n\nwhen I receive [hammer v]\nshow\nforever\n    point towards (mouse-pointer v)\nend\n\nwhen I receive [hammer v]\nswitch costume to (costume2 v)\nshow\nforever\n    if <([costume # v] of [ground v]) = [21]> then\n        show variable [hits until ice breaks v]\n        if <(Hits Until Ice Breaks) = [0]> then\n            broadcast (Next v)\n            stop [other scripts in sprite v]\n            hide\n            hide variable [hits until ice breaks v]\n        else\n            if <<mouse down?> and <touching color (#ccffff)?>> then\n                play sound [zoop v] until done\n                change [hits until ice breaks v] by (-1)\n            end\n        end\n    end\nend\n\nif <<mouse down?> and <touching color (#ccffff)?>> then\n    play sound [zoop v] until done\nend\n\ngo to [front v] layer\n\nstop [this script v]\n\n@Sprite7\n\nwhen flag clicked\ngo to [front v] layer\ngo to x: (0) y: (0)\nhide\nset [ghost v] effect to (100)\n\nwhen I receive [oh no! v]\nshow\nrepeat (100)\n    change [ghost v] effect by (-3)\nend\nstop all sounds\nwait (0.3) seconds\nrepeat (100)\n    change [ghost v] effect by (3)\nend\nbroadcast (Break v)\n\nwhen I receive [oh no! #2 v]\nshow\nrepeat (100)\n    change [ghost v] effect by (-3)\nend\nwait (0.3) seconds\nrepeat (100)\n    change [ghost v] effect by (3)\nend\nbroadcast (Ladder v)\n\nwhen I receive [okay. let's go home i'm so lazy of making another scene of this game so let's make it fade out and fade back in. v]\nshow\nrepeat (100)\n    change [ghost v] effect by (-3)\nend\nstop all sounds\nbroadcast (Next v)\nwait (0.3) seconds\nbroadcast (finally this game is done hooray now people will stop commenting that I'm lazy and haven't finished this. Time to go to sleep and watch YouTube. the moment everyone has been waiting for. v)\nrepeat (100)\n    change [ghost v] effect by (3)\nend\n\nwhen I receive [it's finished. time to sleep :\) v]\nshow\nrepeat (100)\n    change [ghost v] effect by (-3)\nend\nstop all sounds\nbroadcast (Next v)\nwait (0.3) seconds\nrepeat (100)\n    change [ghost v] effect by (3)\nend\n\nwhen flag clicked\nforever\n    go to [front v] layer\nend\n\n@Sprite8\n\nwhen flag clicked\ngo to x: (-52) y: (-48)\nhide\n\nwhen I receive [ladder v]\nrepeat until <([costume # v] of [ground v]) = [27]>\n    show\nend\nhide\n\n@Sprite9\n\nwhen flag clicked\nswitch costume to (costume1 v)\nhide\nset [ghost v] effect to (100)\nset size to (40) %\n\nwhen I receive [fin. v]\ngo to [front v] layer\nswitch costume to (costume1 v)\nrepeat (6)\n    set size to (40) %\n    show\n    show\n    go to x: (-275) y: (-40)\n    glide (1) secs to x: (-111) y: (0)\n    glide (3) secs to x: (115) y: (0)\n    glide (1) secs to x: (275) y: (-40)\n    set [ghost v] effect to (100)\n    next costume\nend\n\nchange [ghost v] effect by (-4)\n\nwhen I receive [fin. v]\nrepeat (6)\n    repeat until <(size) = [100]>\n        change size by (2)\n    end\n    wait (3) seconds\n    repeat until <(size) = [40]>\n        change size by (-2)\n    end\nend\n\nchange [ghost v] effect by (-4)\n\nrepeat (30)\nend\n\ngo to [front v] layer\n\nwait (1) seconds\n\nbroadcast (fin. v)\n\nwhen I receive [fin. v]\nrepeat (6)\n    repeat (25)\n        change [ghost v] effect by (-4)\n    end\n    set [ghost v] effect to (0)\n    show\n    wait (4) seconds\nend\n\n