Defense Strike #games #all #art #pen #animation #music #stories #tutorials #platformer

Instructions: Use left and right arrow keys to rotate and SPACEBAR to shoot. Your health is 3. Don't let the spaceships touch the ground. If you get the POWERUP, all of the enemy ships on the screen dissapear adding points to your score. Different enemy ships of different color have different health. Beat the highscore and enjoy!

@Stage\n\nwhen I receive [start v]\nforever\n    if <(mode) = [1]> then\n        switch backdrop to (backdrop1 v)\n    end\n    if <(mode) = [0]> then\n        switch backdrop to (backdrop3 v)\n    end\n    if <(mode) = [2]> then\n        switch backdrop to (backdrop2 v)\n    end\nend\n\n@strt\n\nwhen flag clicked\nbroadcast (start v)\nforever\n    if <(Score) > (☁ Hignscore)> then\n        set [☁ hignscore v] to (Score)\n    end\nend\n\n@Player\n\nwhen flag clicked\nset [score v] to [0]\nset [mode v] to [3]\nhide\n\nwhen I receive [start v]\nset volume to (30) %\nforever\n    play sound [Proxy \(Original Mix\) \[FREE DOWNLOAD\]_138111002_soundcloud.mp3 v] until done\nend\n\nwhen I receive [start v]\npoint in direction (90)\ngo to x: (0) y: (-156)\nset [mode v] to [0]\nset size to (75) %\nforever\n    if <(mode) = [1]> then\n        show\n        if <<<key (right arrow v) pressed?> or <key (d v) pressed?>> or <<mouse down?> and <(mouse x) > (x position)>>> then\n            turn right (5) degrees\n        end\n        if <<<key (left arrow v) pressed?> or <key (a v) pressed?>> or <<mouse down?> and <(x position) > (mouse x)>>> then\n            turn left (5) degrees\n        end\n        if <(Health) = [0]> then\n            set [mode v] to [0]\n            broadcast (dth v)\n            if <(Score) > (☁ Hignscore)> then\n                set [☁ hignscore v] to (Score)\n            end\n        end\n    else\n        hide\n    end\nend\n\n@Bullet\n\nwhen I start as a clone\nshow\nforever\n    move (13) steps\n    if <touching (_edge_ v)?> then\n        delete this clone\n    end\n    if <touching (enemy v)?> then\n        wait (0.01) seconds\n        delete this clone\n    end\nend\n\nwhen I receive [start v]\nhide\nset size to (75) %\nset [rof v] to [0.3]\nforever\n    if <(mode) = [1]> then\n        go to (player v)\n        point in direction (([direction v] of [player v]) - (90))\n        if <key (space v) pressed?> then\n            create clone of (_myself_ v)\n            wait (rof) seconds\n        end\n    else\n    end\nend\n\n@Enemy\n\nwhen I receive [delete v]\ndelete this clone\n\nwhen I receive [start v]\nset size to (75) %\nhide\nset [hardness v] to [3]\nforever\n    if <(mode) = [1]> then\n        wait (hardness) seconds\n        create clone of (_myself_ v)\n    else\n        broadcast (delete v)\n    end\nend\n\nwhen I start as a clone\nshow\ngo to x: (pick random (-230) to (230)) y: (190)\nswitch costume to (pick random (1) to (cap))\nif <(costume [number v]) = [1]> then\n    set [eh v] to [3]\n    set [sped v] to [1]\nend\nif <(costume [number v]) = [2]> then\n    set [eh v] to [5]\n    set [sped v] to [1]\nend\nif <(costume [number v]) = [3]> then\n    set [eh v] to [3]\n    set [sped v] to [2]\nend\nforever\n    change y by ((sped) * (-1))\n    if <touching (bullet v)?> then\n        change [eh v] by (-1)\n    end\n    if <(Eh) < [1]> then\n        change [score v] by (1)\n        delete this clone\n    end\n    if <(y position) < [-178]> then\n        change [health v] by (-1)\n        delete this clone\n    end\n    if <touching (shockwave v)?> then\n        change [score v] by (1)\n        delete this clone\n    end\n    if <(mode) = [0]> then\n        delete this clone\n    end\nend\n\nwhen flag clicked\nhide\n\nwhen I receive [start v]\nforever\n    if <(hardness) > [1]> then\n        change [hardness v] by (-0.0002)\n    end\nend\n\nwhen flag clicked\nforever\n    if <<(Score) > [0]> and <(Score) < [15]>> then\n        set [cap v] to [1]\n    end\n    if <<(Score) > [15]> and <(Score) < [50]>> then\n        set [cap v] to [2]\n    end\n    if <(Score) > [50]> then\n        set [cap v] to [3]\n    end\nend\n\n@Score board\n\nwhen flag clicked\ngo to x: (0) y: (0)\nhide\n\nwhen I receive [start v]\nforever\n    if <(mode) = [1]> then\n        show\n    else\n        hide\n    end\nend\n\n@Score\n\ndefine None\nset [i v] to [1]\ngo to x: (x) y: (y)\nrepeat (length of (text))\n    switch costume to (letter (I) of (text))\n    create clone of (_myself_ v)\n    change [i v] by (1)\n    change x by (14)\nend\n\nwhen I start as a clone\nshow\nwait (0.001) seconds\ndelete this clone\n\nwhen flag clicked\nhide\ngo to [front v] layer\nset size to (35) %\n\nwhen I receive [start v]\nforever\n    if <(mode) = [1]> then\n        draw (Score) (-165) (165)\n        draw (☁ Hignscore) (20) (165)\n        draw (Health) (191) (165)\n    else\n        if <(mode) = [0]> then\n            draw (Score) (150) (-163)\n        end\n    end\nend\n\n@Buttons\n\nwhen flag clicked\nhide\nswitch costume to (backdrop3 v)\nrepeat (3)\n    create clone of (_myself_ v)\n    next costume\nend\n\nwhen I start as a clone\nhide\nforever\n    if <<(costume [number v]) = [1]> or <(costume [number v]) = [2]>> then\n        if <(mode) = [0]> then\n            if <(costume [number v]) = [1]> then\n                set x to (0)\n                set y to (-60)\n                if <<touching (mouse-pointer v)?> and <mouse down?>> then\n                    set [mode v] to [1]\n                    set [score v] to [0]\n                    set [health v] to [3]\n                end\n                if <touching (mouse-pointer v)?> then\n                    set size to (120) %\n                    set [ghost v] effect to (10)\n                else\n                    set size to (100) %\n                    set [ghost v] effect to (0)\n                end\n            end\n            if <(costume [number v]) = [2]> then\n                set x to (0)\n                set y to (-110)\n                if <<touching (mouse-pointer v)?> and <mouse down?>> then\n                    set [mode v] to [2]\n                end\n            end\n            show\n        else\n            hide\n        end\n    else\n        go to x: (-180) y: (156)\n        if <(mode) = [2]> then\n            show\n            if <<touching (mouse-pointer v)?> and <mouse down?>> then\n                set [mode v] to [0]\n            end\n        else\n            hide\n        end\n    end\nend\n\n@Power up\n\nwhen flag clicked\nhide\n\nwhen I receive [start v]\nforever\n    if <(mode) = [1]> then\n        if <(Score) > [6]> then\n            wait (pick random (11) to (13)) seconds\n            create clone of (_myself_ v)\n        end\n    else\n    end\nend\n\nwhen I receive [delete v]\ndelete this clone\n\nwhen I start as a clone\ngo to x: (pick random (-220) to (220)) y: (190)\ngo [backward v] (3) layers\nshow\nrepeat until <(y position) < [-178]>\n    change y by (-3)\n    turn right (5) degrees\n    if <touching (bullet v)?> then\n        set [x v] to (x position)\n        set [y v] to (y position)\n        broadcast (shockwave v)\n        delete this clone\n    end\nend\ndelete this clone\n\n@Shockwave\n\nwhen I receive [shockwave v]\nclear graphic effects\nset size to (2) %\nshow\ngo to x: ([x v] of [power up v]) y: ([y v] of [power up v])\nrepeat (20)\n    change size by (20)\n    change [ghost v] effect by (4)\nend\nhide\n\nwhen flag clicked\nhide\n\n@Thumbnail\n\nwhen flag clicked\nhide\n\ngo to x: (0) y: (0)\n\n@tb\n\nwhen flag clicked\ngo to [front v] layer\nset [ghost v] effect to (100)\n\n@dth\n\nwhen I receive [dth v]\ngo to [front v] layer\nshow\n\nwhen flag clicked\nhide\n\nwhen I receive [hd v]\nhide\n\n@dth2\n\nwhen I receive [dth v]\ngo to [front v] layer\nshow\n\nwhen flag clicked\nhide\n\nwhen this sprite clicked\nwait (1) seconds\nset [mode v] to [1]\nbroadcast (hd v)\nhide\n\nforever\n    if <touching (mouse-pointer v)?> then\n        set size to (120) %\n        set [ghost v] effect to (10)\n    else\n        set [ghost v] effect to (0)\n        set size to (100) %\n    end\nend\n\n