Drawn 4(Platformer) Mobile Friendly #games

Instructions:                               Instructions\n>Use The W,A,S,D or Arrow Keys To Move.\n>The Rest In The Game\n>Part 1: https://scratch.mit.edu/projects/419661760/\n>Part 2: https://scratch.mit.edu/projects/421336908/\n>Part 3: https://scratch.mit.edu/projects/430970611/\n>You Have Only 5 Skips Use It Wisely \n>This Is The Final Part Of Drawn \n>Music  @-Xaf-

@Stage\n\nwhen flag clicked\nbroadcast (Start v)\nforever\n    play sound [Popsicle v] until done\nend\n\nwhen flag clicked\nforever\n    if <(Volume) = [2]> then\n        set volume to (50) %\n    else\n        set volume to (0) %\n    end\nend\n\nwhen flag clicked\nforever\n    if <(Level) = [21]> then\n        switch backdrop to (backdrop2 v)\n    else\n        switch backdrop to (backdrop1 v)\n    end\nend\n\n@Blank\n\n@Player\n\ndefine Game On\nset [sx v] to [0]\nset [x v] to [-222]\nset [y v] to [-125]\nset [sy v] to [0]\nset [in air v] to [0]\nset [finish v] to []\npoint in direction (90)\nclear graphic effects\nshow\n\ndefine Movement\nif <<<key (a v) pressed?> or <key (left arrow v) pressed?>> or <<mouse down?> and <(mouse x) < (x position)>>> then\n    change [sx v] by (-1.5)\nend\nif <<<key (d v) pressed?> or <key (right arrow v) pressed?>> or <<mouse down?> and <(x position) < (mouse x)>>> then\n    change [sx v] by (1.5)\nend\nset [sx v] to ((sx) * (0.8))\nif <([abs v] of (sx) ) > [0.9]> then\n    Change Player x by (round (sx))\nend\nif <<<key (w v) pressed?> or <key (up arrow v) pressed?>> or <<mouse down?> and <(mouse y) > (y position)>>> then\n    if <(in air) < [4]> then\n        set [sy v] to [14]\n    end\nend\nif <(sy) > [-20]> then\n    change [sy v] by (-2)\nend\nChange Player y by (sy)\nDie\nPosition\nif <(Level) = [21]> then\n    switch costume to (2 v)\nelse\n    switch costume to (1 v)\nend\nif <(y position) < [-180]> then\n    set [finish v] to [No]\nend\n\nwhen I receive [start v]\ngo to [front v] layer\nset [level v] to [1]\nforever\n    broadcast (Reset v) and wait\n    broadcast (Setup v) and wait\n    Game On\n    repeat until <(Finish) > []>\n        Movement\n    end\n    if <(Finish) = [Yes]> then\n        Game Con\n    else\n        Game End\n    end\nend\n\ndefine Change Player y by (sy)\nchange [y v] by (sy)\nchange [in air v] by (1)\nPosition\nrepeat until <not <<touching (platform v)?> or <touching (blocks v)?>>>\n    if <(sy) > [0]> then\n        change [y v] by (-1)\n    else\n        change [y v] by (1)\n        set [in air v] to [0]\n    end\n    Position\n    set [sy v] to [0]\nend\n\ndefine Position\ngo to x: (x) y: (y)\n\ndefine Change Player x by (sx)\nchange [x v] by (sx)\nPosition\nif <<touching (platform v)?> or <touching (blocks v)?>> then\n    repeat (12)\n        change [y v] by (1)\n        Position\n        if <not <<touching (platform v)?> or <touching (blocks v)?>>> then\n            stop [this script v]\n        end\n    end\n    change [y v] by (-12)\n    if <<<key (w v) pressed?> or <key (up arrow v) pressed?>> or <<mouse down?> and <(mouse y) > (y position)>>> then\n        if <(sx) > [0]> then\n            if <(Volume) = [2]> then\n                start sound [Wall Jump v]\n            end\n            set [sx v] to [-15]\n        else\n            if <(Volume) = [2]> then\n                start sound [Wall Jump v]\n            end\n            set [sx v] to [15]\n        end\n        set [in air v] to [0]\n    else\n        set [sx v] to [0]\n    end\n    repeat until <not <<touching (platform v)?> or <touching (blocks v)?>>>\n        if <(sx) > [0]> then\n            change [x v] by (-1)\n        else\n            change [x v] by (1)\n        end\n        Position\n    end\nend\n\ndefine Game End\nif <(Volume) = [2]> then\n    start sound [Die v]\nend\ngo to [front v] layer\nset [sx v] to [0]\nset [sy v] to [8]\nrepeat (12)\n    turn right (15) degrees\n    change y by (sy)\n    change [sy v] by (-1)\nend\nrepeat until <[-180] > (y position)>\n    change y by (sy)\n    change [sy v] by (-1)\nend\nset [finish v] to []\n\ndefine Die\nif <<touching (danger v)?> or <touching (disappearingspikes v)?>> then\n    set [finish v] to [No]\nend\n\ndefine Game Con\nchange [level v] by (1)\n\nwhen flag clicked\nforever\n    if <(x) < [-225]> then\n        set [x v] to [-225]\n    end\n    if <(x) > [228]> then\n        set [x v] to [228]\n    end\nend\n\nwhen I receive [bounce v]\nset [sy v] to [14]\n\n@Platform\n\nwhen flag clicked\nhide\n\nwhen I receive [start v]\nshow\nforever\n    go to x: (0) y: (0)\n    switch costume to (Level)\nend\n\n@Flag\n\nwhen I receive [start v]\nforever\n    if <(Level) = [1]> then\n        go to x: (214) y: (-105)\n    end\n    if <(Level) = [2]> then\n        go to x: (214) y: (9)\n    end\n    if <(Level) = [3]> then\n        go to x: (214) y: (-105)\n    end\n    if <(Level) = [4]> then\n        go to x: (214) y: (-105)\n    end\n    if <(Level) = [5]> then\n        go to x: (214) y: (-105)\n    end\n    if <(Level) = [6]> then\n        go to x: (214) y: (-105)\n    end\n    if <(Level) = [7]> then\n        go to x: (214) y: (-105)\n    end\n    if <(Level) = [8]> then\n        go to x: (214) y: (-105)\n    end\n    if <(Level) = [9]> then\n        go to x: (214) y: (-105)\n    end\n    if <(Level) = [10]> then\n        go to x: (214) y: (-105)\n    end\n    if <(Level) = [11]> then\n        go to x: (214) y: (138)\n    end\n    if <(Level) = [12]> then\n        go to x: (214) y: (48)\n    end\n    if <(Level) = [13]> then\n        go to x: (214) y: (86)\n    end\n    if <(Level) = [14]> then\n        go to x: (214) y: (-105)\n    end\n    if <(Level) = [15]> then\n        go to x: (214) y: (148)\n    end\n    if <(Level) = [16]> then\n        go to x: (214) y: (101)\n    end\n    if <(Level) = [17]> then\n        go to x: (214) y: (-18)\n    end\n    if <(Level) = [18]> then\n        go to x: (214) y: (-105)\n    end\n    if <(Level) = [19]> then\n        go to x: (214) y: (-105)\n    end\n    if <(Level) = [20]> then\n        go to x: (214) y: (100)\n    end\nend\n\nwhen I receive [start v]\nshow\nforever\n    if <not <(Level) = [21]>> then\n        show\n    else\n        hide\n    end\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [start v]\nforever\n    set size to (90) %\n    if <touching (player v)?> then\n        wait (0.05) seconds\n        set [finish v] to [Yes]\n        if <(Volume) = [2]> then\n            play sound [star v] until done\n        end\n    end\nend\n\n@Danger\n\nwhen I receive [start v]\nshow\nforever\n    switch costume to (Level)\n    go to [back v] layer\n    go to x: (-1) y: (-21)\nend\n\nwhen flag clicked\nhide\n\n@Text\n\nwhen flag clicked\nhide\n\nwhen I receive [start v]\nshow\nforever\n    go to x: (0) y: (0)\n    switch costume to (Level)\nend\n\n@Blocks\n\nwhen flag clicked\nhide\n\nwhen I receive [setup v]\nif <(Level) = [2]> then\n    switch costume to (block1 v)\n    Create A Clone At x: [-1] y: [-50] Time: (pick random (2) to (3))\nend\nif <(Level) = [3]> then\n    switch costume to (block2 v)\n    Create A Clone At x: [86] y: [-103] Time: (pick random (2) to (3))\n    switch costume to (block2 v)\n    Create A Clone At x: [-40] y: [-51] Time: (pick random (2) to (3))\nend\nif <(Level) = [5]> then\n    switch costume to (block3 v)\n    Create A Clone At x: [-10] y: [-40] Time: (pick random (2) to (3))\nend\nif <(Level) = [7]> then\n    switch costume to (block4 v)\n    Create A Clone At x: [5] y: [-40] Time: (pick random (1) to (2))\nend\nif <(Level) = [11]> then\n    switch costume to (block5 v)\n    Create A Clone At x: [-28] y: [-51] Time: (pick random (1) to (2))\n    Create A Clone At x: [61] y: [26] Time: (pick random (1) to (2))\nend\nif <(Level) = [12]> then\n    switch costume to (block5 v)\n    Create A Clone At x: [2] y: [-51] Time: (pick random (1) to (2))\nend\nif <(Level) = [13]> then\n    switch costume to (block2 v)\n    Create A Clone At x: [-152] y: [-53] Time: (pick random (1) to (2))\nend\nif <(Level) = [14]> then\n    switch costume to (block6 v)\n    Create A Clone At x: [-82] y: [-50] Time: (pick random (1) to (2))\nend\nif <(Level) = [15]> then\n    switch costume to (block5 v)\n    Create A Clone At x: [11] y: [-50] Time: (pick random (2) to (3))\n    Create A Clone At x: [13] y: [54] Time: (pick random (2) to (3))\nend\nif <(Level) = [16]> then\n    switch costume to (block7 v)\n    Create A Clone At x: [-73] y: [-75] Time: (pick random (1) to (2))\n    Create A Clone At x: [-11] y: [-23] Time: (pick random (1) to (2))\n    Create A Clone At x: [50] y: [29] Time: (pick random (1) to (2))\nend\nif <(Level) = [17]> then\n    switch costume to (block7 v)\n    Create A Clone At x: [-30] y: [-102] Time: (pick random (0.5) to (0.8))\nend\nif <(Level) = [18]> then\n    switch costume to (block7 v)\n    Create A Clone At x: [23] y: [-154] Time: [0.5]\nend\nif <(Level) = [20]> then\n    switch costume to (block1 v)\n    Create A Clone At x: [1] y: [-50] Time: [0.5]\nend\n\nwhen I receive [reset v]\ndelete this clone\n\ndefine Create A Clone At x: (x) y: (y) Time: (time)\ngo to x: (x) y: (y)\nset [time v] to (time)\ncreate clone of (_myself_ v)\n\nwhen I start as a clone\nshow\nset [ghost v] effect to (100)\nrepeat (10)\n    change [ghost v] effect by (-10)\nend\nwait (time) seconds\nforever\n    repeat (10)\n        change [ghost v] effect by (10)\n    end\n    set [ghost v] effect to (100)\n    hide\n    wait (time) seconds\n    show\n    set [ghost v] effect to (100)\n    repeat (10)\n        change [ghost v] effect by (-10)\n    end\n    set [ghost v] effect to (0)\n    wait (time) seconds\nend\n\n@Enemy\n\nwhen I start as a clone\nset [die v] to [No]\nset [x v] to [0]\nset [y v] to [0]\ngo to [front v] layer\nset size to (55) %\nshow\nforever\n    if <(die) = [No]> then\n        change [y v] by (-1)\n        if <([x position v] of [player v]) < ((x position) - (10))> then\n            change [x v] by (-.5)\n            point in direction (-90)\n        end\n        if <((x position) - (-10)) < ([x position v] of [player v])> then\n            change [x v] by (.5)\n            point in direction (90)\n        end\n        set [x v] to ((x) * (0.9))\n        change x by (x)\n        if <touching (platform v)?> then\n            change y by (1)\n            if <touching (platform v)?> then\n                change y by (1)\n                if <touching (platform v)?> then\n                    change y by (1)\n                    if <touching (platform v)?> then\n                        change y by (1)\n                        if <touching (platform v)?> then\n                            change y by (-3)\n                            change x by ((x) * (-1))\n                            if <<(y position) < ([y position v] of [player v])> or <(y position) < ([x position v] of [player v])>> then\n                                if <(x) > [0]> then\n                                    set [x v] to [-5]\n                                else\n                                    set [x v] to [5]\n                                end\n                                set [y v] to [12]\n                            else\n                                set [x v] to [0]\n                            end\n                        end\n                    end\n                end\n            end\n        end\n        change y by (y)\n        if <touching (platform v)?> then\n            change y by ((y) - ((y) * (2)))\n            set [y v] to [0]\n        end\n        change y by (-1)\n    end\nend\n\nwhen flag clicked\nhide\n\ndefine Create A Clone at x: (x) y: (y)\ngo to x: (x) y: (y)\ncreate clone of (_myself_ v)\n\nwhen I receive [reset v]\ndelete this clone\n\nwhen I receive [setup v]\nif <(Level) = [10]> then\n    Create A Clone at x: [215] y: [-128]\nend\nif <(Level) = [13]> then\n    Create A Clone at x: [215] y: [-128]\n    Create A Clone at x: [135] y: [-128]\nend\nif <(Level) = [15]> then\n    Create A Clone at x: [215] y: [-128]\nend\nif <(Level) = [20]> then\n    Create A Clone at x: [-223] y: [80]\n    Create A Clone at x: [223] y: [80]\n    Create A Clone at x: [215] y: [-128]\nend\n\nwhen I start as a clone\nforever\n    if <<touching (danger v)?> or <touching (disappearingspikes v)?>> then\n        wait (0.05) seconds\n        delete this clone\n    end\n    if <<touching (player v)?> and <(Finish) = []>> then\n        if <<([y position v] of [player v]) > (y position)> and <([sy v] of [player v]) < [-1]>> then\n            set [die v] to [Yes]\n            broadcast (Bounce v)\n            if <(Volume) = [2]> then\n                start sound [Die v]\n            end\n            stop [other scripts in sprite v]\n            repeat (5)\n                change [ghost v] effect by (20)\n            end\n            delete this clone\n        else\n            set [finish v] to [No]\n        end\n    end\nend\n\n@DisappearingSpikes\n\nwhen flag clicked\nhide\n\ndefine Create A Clone At x: (x) y: (y) Time: (time)\ngo to x: (x) y: (y)\nset [time v] to (time)\nswitch costume to (Level)\ncreate clone of (_myself_ v)\n\nwhen I receive [setup v]\nif <(Level) = [1]> then\n    Create A Clone At x: [0] y: [0] Time: (pick random (2) to (3))\nend\nif <(Level) = [2]> then\n    Create A Clone At x: [0] y: [0] Time: (pick random (2) to (3))\nend\nif <(Level) = [3]> then\n    Create A Clone At x: [0] y: [0] Time: (pick random (2) to (3))\nend\nif <(Level) = [4]> then\n    Create A Clone At x: [0] y: [0] Time: (pick random (2) to (3))\nend\nif <(Level) = [6]> then\n    Create A Clone At x: [-115] y: [-134] Time: (pick random (2) to (3))\n    Create A Clone At x: [-47] y: [-134] Time: (pick random (1) to (2))\n    Create A Clone At x: [35] y: [-134] Time: (pick random (2) to (3))\n    Create A Clone At x: [111] y: [-134] Time: (pick random (1) to (2))\nend\nif <(Level) = [8]> then\n    Create A Clone At x: [2] y: [-32] Time: (pick random (2) to (2.5))\nend\nif <(Level) = [9]> then\n    point in direction (-90)\n    Create A Clone At x: [52] y: [135] Time: (pick random (1) to (2))\n    point in direction (90)\n    Create A Clone At x: [-38] y: [-134] Time: (pick random (1) to (2))\nend\nif <(Level) = [13]> then\n    Create A Clone At x: [46] y: [58] Time: (pick random (1) to (2))\nend\n\nwhen I receive [reset v]\ndelete this clone\n\nwhen I start as a clone\nif <not <<(Level) = [15]> or <(Level) = [20]>>> then\n    show\n    set [ghost v] effect to (100)\n    repeat (10)\n        change [ghost v] effect by (-10)\n    end\n    wait (time) seconds\n    forever\n        repeat (10)\n            change [ghost v] effect by (10)\n        end\n        set [ghost v] effect to (100)\n        hide\n        wait (time) seconds\n        show\n        set [ghost v] effect to (100)\n        repeat (10)\n            change [ghost v] effect by (-10)\n        end\n        set [ghost v] effect to (0)\n        wait (time) seconds\n    end\nelse\n    if <(Level) = [15]> then\n        go to x: (214) y: (2)\n        switch costume to (15 v)\n        go to [back v] layer\n        show\n        repeat until <(x position) < [-236]>\n            change x by (-10)\n        end\n        delete this clone\n    else\n        go to x: (-2) y: (150)\n        switch costume to (20 v)\n        go to [back v] layer\n        show\n        repeat until <<(y position) < [-175]> or <touching (blocks v)?>>\n            change y by (-15)\n        end\n        delete this clone\n    end\nend\n\nwhen I receive [reset v]\ndelete this clone\n\nwhen I receive [start v]\nforever\n    if <<(Level) = [15]> or <(Level) = [20]>> then\n        create clone of (_myself_ v)\n        if <(Level) = [15]> then\n            wait (1) seconds\n        else\n            wait (0.5) seconds\n        end\n    end\nend\n\n@Skip\n\nwhen flag clicked\nshow\nforever\n    if <not <(Level) = [21]>> then\n        show\n    else\n        hide\n        stop [other scripts in sprite v]\n        stop [this script v]\n    end\nend\n\nwhen I receive [start v]\nshow\nset [volume v] to [2]\nset [skip v] to [5]\nset size to (80) %\nforever\n    switch costume to (Skip)\n    go to x: (190) y: (-158)\n    if <touching (mouse-pointer v)?> then\n        if <(size) < [90]> then\n            change size by (2)\n        end\n        if <<mouse down?> and <(Skip) > [0]>> then\n            change [skip v] by (-1)\n            set [finish v] to [Yes]\n            wait until <not <mouse down?>>\n        end\n    else\n        if <(size) > [80]> then\n            change size by (-2)\n        end\n    end\nend\n\n@Volume\n\nwhen flag clicked\nset [volume v] to [2]\nset size to (80) %\nforever\n    go to x: (-215) y: (158)\n    if <(Volume) = [0]> then\n        switch costume to (2 v)\n    end\n    if <(Volume) = [2]> then\n        switch costume to (1 v)\n    end\n    if <touching (mouse-pointer v)?> then\n        if <(size) < [90]> then\n            change size by (2)\n        end\n        if <<mouse down?> and <(Volume) = [0]>> then\n            set [volume v] to [2]\n            wait until <not <mouse down?>>\n        end\n        if <<mouse down?> and <(Volume) = [2]>> then\n            set [volume v] to [0]\n            wait until <not <mouse down?>>\n        end\n    else\n        if <(size) > [80]> then\n            change size by (-2)\n        end\n    end\nend\n\n@Thumbnail\n\nwhen flag clicked\nforever\n    go to [front v] layer\n    set [ghost v] effect to (100)\n    go to x: (0) y: (0)\n    show\nend\n\n