Bounce 3 - Platformer #games
@Stage\n\nwhen flag clicked\nswitch backdrop to (1 v)\n\nwhen [u v] key pressed\nplay sound [Lil Globglogabgalab v] until done\n\n@character picker\n\nwhen I receive [color v]\nnext costume\n\nwhen flag clicked\nswitch costume to (green cherry v)\nshow\ngo to x: (0) y: (60)\nforever\n    glide (1) secs to x: (0) y: (57)\n    glide (1) secs to x: (0) y: (63)\nend\n\nwhen I receive [back v]\nswitch costume to ((costume [number v]) - (1))\n\nwhen I receive [play v]\nset [player v] to (costume [name v])\nhide\n\nbroadcast (next v)\n\n@right arrow\n\nwhen this sprite clicked\nstart sound [SELECT v]\nbroadcast (color v)\n\nwhen flag clicked\nshow\ngo to x: (75) y: (60)\n\nwhen I receive [play v]\nhide\n\n@left arrow\n\nwhen this sprite clicked\nstart sound [SELECT v]\nbroadcast (back v)\n\nwhen flag clicked\nshow\ngo to x: (75) y: (60)\n\nwhen I receive [play v]\nhide\n\n@plae\n\nwhen flag clicked\ngo to x: (0) y: (0)\nshow\n\nwhen this sprite clicked\nhide\nbroadcast (play v)\nplay sound [SELECT v] until done\n\n@background\n\nwhen flag clicked\nhide\ngo to x: (0) y: (0)\n\nwhen I receive [play v]\nshow\nswitch costume to (costume1 v)\nforever\n    go to [back v] layer\nend\n\nwhen I receive [next v]\nnext costume\n\nwhen flag clicked\ngo to x: (0) y: (0)\n\nwhen I receive [report v]\nwait (2.5) seconds\nhide\n\n@fade\n\nwhen flag clicked\nhide\ngo to x: (0) y: (0)\nset [ghost v] effect to (0)\nswitch costume to (costume1 v)\nset size to (100) %\n\nwhen I receive [play v]\nshow\ngo to [front v] layer\nrepeat (50)\n    change [ghost v] effect by (2)\nend\nbroadcast (walk v)\n\nwhen I receive [lights out v]\ngo to [front v] layer\nshow\nset [ghost v] effect to (0)\nswitch costume to (costume2 v)\nset size to (200) %\nswitch costume to (flashlight v)\nforever\n    go to (mouse-pointer v)\nend\n\nwhen I receive [report v]\nhide\n\nbroadcast (next v)\n\n@character\n\ndefine Define Gravity\nchange y by (fallspeed)\nif <touching (ground v)?> then\n    if <(fallspeed) < [0]> then\n        set [reversestep v] to [1]\n    else\n        set [reversestep v] to [-1]\n    end\n    repeat until <not <touching (ground v)?>>\n        change y by (reversestep)\n    end\n    set [fallspeed v] to [0]\nelse\n    change [fallspeed v] by (gravity)\nend\n\ndefine RUNControls\nif <<key (d v) pressed?> or <key (right arrow v) pressed?>> then\n    point in direction (90)\n    change x by (RUNSPEED)\n    if <touching (ground v)?> then\n        change x by ((0) - (RUNSPEED))\n    end\nend\nif <<key (a v) pressed?> or <key (left arrow v) pressed?>> then\n    point in direction (-90)\n    change x by ((0) - (RUNSPEED))\n    if <touching (ground v)?> then\n        change x by (RUNSPEED)\n    end\nend\n\ndefine starting position\nset [fallspeed v] to [0]\ngo to x: (-140) y: (-39)\n\nwhen flag clicked\nstarting position\nhide\nforever\n    switch costume to (player)\nend\n\ndefine Jump Control\nif <<key (w v) pressed?> or <key (up arrow v) pressed?>> then\n    change y by (-1)\n    if <touching (ground v)?> then\n        set [fallspeed v] to (takeoffspeed)\n    end\n    change y by (1)\nend\n\nbroadcast (\[arty v)\n\nbroadcast (\[arty v)\n\nwhen I receive [play v]\npoint in direction (90)\nset rotation style [left-right v]\nshow\nset [runspeed v] to [5]\nset [gravity v] to [-1]\nset [fallspeed v] to [0]\nset [takeoffspeed v] to [12]\nforever\n    RUNControls\n    Jump Control\n    Define Gravity\n    if <touching color (#0800a3)?> then\n        set [takeoffspeed v] to [18]\n        set [fallspeed v] to (takeoffspeed)\n        set [takeoffspeed v] to [10]\n    end\n    if <(x position) > [232]> then\n        starting position\n        broadcast (next v)\n    end\n    if <(y position) < [-170]> then\n        starting position\n    end\nend\n\nwhen I receive [walk v]\ngo to [front v] layer\n\nwhen flag clicked\nforever\n    if <<touching (ladder v)?> and <key (space v) pressed?>> then\n        if <(ladder point) = [1]> then\n            glide (0) secs to x: (65) y: (132)\n        end\n    end\n    if <<touching (ladder v)?> and <key (space v) pressed?>> then\n        if <(ladder point) = [4]> then\n            glide (0) secs to x: (-35) y: (93)\n        end\n    end\n    if <<touching (ladder v)?> and <key (space v) pressed?>> then\n        if <(ladder point) = [7]> then\n            glide (0) secs to x: (18) y: (143)\n        end\n    end\nend\n\nwhen flag clicked\nforever\n    if <<key (d v) pressed?> or <key (right arrow v) pressed?>> then\n        repeat until <not <<key (d v) pressed?> or <key (right arrow v) pressed?>>>\n            start sound [walkey v]\n            wait (1) seconds\n        end\n        stop all sounds\n    end\n    if <<key (a v) pressed?> or <key (left arrow v) pressed?>> then\n        repeat until <not <<key (a v) pressed?> or <key (left arrow v) pressed?>>>\n            start sound [walkey v]\n            wait (1) seconds\n        end\n        stop all sounds\n    end\nend\n\nwhen flag clicked\nforever\n    if <touching (egg v)?> then\n        starting position\n    end\nend\n\nstop [other scripts in sprite v]\n\nwhen I receive [report v]\nhide\n\n@ground\n\nwhen I receive [next v]\nnext costume\n\nwhen I receive [play v]\nswitch costume to (costume1 v)\nshow\n\nwhen flag clicked\nhide\n\nwhen I receive [report v]\nhide\n\nwhen I receive [play v]\ngo to [back v] layer\n\nwhen flag clicked\ngo to x: (0) y: (0)\n\n@ladder\n\nwhen flag clicked\nwait until <(ladder point) = [12]>\nbroadcast (lights out v)\n\nwhen flag clicked\nswitch costume to (1 v)\nhide\n\nwhen I receive [play v]\nshow\n\nwhen I receive [next v]\nnext costume\n\nwhen I receive [report v]\nhide\n\nwhen flag clicked\ngo to x: (0) y: (0)\n\nwhen flag clicked\nforever\n    set [ladder point v] to (costume [number v])\nend\n\n@egg\n\nwhen flag clicked\nhide\n\nwhen I receive [play v]\nshow\nswitch costume to (costume1 v)\n\nwhen I receive [next v]\nnext costume\n\nwhen I receive [report v]\nhide\n\nwhen flag clicked\ngo to x: (0) y: (0)\n\n@interactives\n\nwhen flag clicked\nhide\n\nwhen flag clicked\nwait until <(ladder point) = [15]>\nshow\nswitch costume to (costume1 v)\n\nwhen this sprite clicked\nbroadcast (report v)\nhide\n\n@report\n\nwhen flag clicked\nhide\ngo to x: (0) y: (0)\nswitch costume to (costume1 v)\n\nwhen I receive [report v]\nshow\nstart sound [Dead Body Reported v]\ngo to x: (20) y: (0)\nglide (2.3) secs to x: (0) y: (0)\nswitch costume to (costume2 v)\ngo to [back v] layer\n\nwhen I receive [black v]\nhide\n\nwhen I receive [cyan v]\nhide\n\nwhen I receive [red v]\nhide\n\n@cheat\n\nbroadcast (next v)\n\n@report2\n\nwhen flag clicked\nhide\ngo to x: (0) y: (0)\nswitch costume to (costume1 v)\n\nwhen this sprite clicked\nbroadcast (red v)\n\nwhen I receive [report v]\nwait (3) seconds\nshow\n\nwhen I receive [cyan v]\nhide\n\nwhen I receive [black v]\nhide\n\nwhen I receive [red v]\nhide\n\n@report3\n\nwhen flag clicked\nhide\ngo to x: (0) y: (0)\nswitch costume to (costume1 v)\n\nwhen this sprite clicked\nbroadcast (cyan v)\n\nwhen I receive [report v]\nwait (3) seconds\nshow\n\nwhen I receive [cyan v]\nhide\n\nwhen I receive [black v]\nhide\n\nwhen I receive [red v]\nhide\n\n@report4\n\nwhen flag clicked\nhide\ngo to x: (0) y: (0)\nswitch costume to (costume1 v)\n\nwhen this sprite clicked\nbroadcast (black v)\n\nwhen I receive [report v]\nwait (3) seconds\nshow\n\nwhen I receive [cyan v]\nhide\n\nwhen I receive [black v]\nhide\n\nwhen I receive [red v]\nhide\n\n@ejection\n\nwhen flag clicked\ngo to x: (0) y: (0)\nhide\n\nwhen I receive [cyan v]\nshow\nswitch costume to (cyan  v)\nglide (3) secs to x: (300) y: (0)\nwait (0.8) seconds\nhide\nbroadcast (victory v)\n\nwhen I receive [red v]\nshow\nswitch costume to (red v)\nglide (3) secs to x: (300) y: (0)\nwait (0.8) seconds\nhide\nbroadcast (defeat v)\n\nwhen I receive [black v]\nshow\nswitch costume to (black v)\nglide (3) secs to x: (300) y: (0)\nwait (0.8) seconds\nhide\nbroadcast (defeat v)\n\n@defeat/victory\n\nwhen flag clicked\nhide\n\nwhen I receive [defeat v]\nshow\nswitch costume to (costume1 v)\n\nwhen I receive [victory v]\nshow\nswitch costume to (costume2 v)\n\n@thumb\n\nwhen flag clicked\ngo to x: (0) y: (0)\nforever\n    set [ghost v] effect to (100)\n    show\n    go to [front v] layer\nend\n\n
PLANET PLATFORMER!\nTHANKS FOR FEATURE!\nPS: random people get world record because cloud variables broken so thanks scratch\nMovement - Arrow Keys\n\nLearn about the planet while playing a fun platformer!\n