This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# coding: utf-8 | |
from scene import * | |
import json | |
import sound | |
A = Action | |
standing_texture = Texture('plf:AlienBlue_front') | |
walk_textures = [Texture('plf:AlienBlue_walk1'), Texture('plf:AlienBlue_walk2')] | |
jump_texture = Texture('plf:AlienBlue_jump') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# coding: utf-8 | |
from scene import * | |
import json | |
import sound | |
A = Action | |
standing_texture = Texture('plf:AlienBlue_front') | |
walk_textures = [Texture('plf:AlienBlue_walk1'), Texture('plf:AlienBlue_walk2')] | |
jump_texture = Texture('plf:AlienBlue_jump') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# coding: utf-8 | |
from scene import * | |
import json | |
import sound | |
A = Action | |
standing_texture = Texture('plf:AlienBlue_front') | |
walk_textures = [Texture('plf:AlienBlue_walk1'), Texture('plf:AlienBlue_walk2')] | |
jump_texture = Texture('plf:AlienBlue_jump') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# coding: utf-8 | |
''' | |
Part 7 -- Space Lasers! ✳️ | |
The whole game has been somewhat defensive so far, so let's give the little alien something to attack -- lasers! | |
When a laser hits a meteor, it should be destroyed in an explosion, and as additional motivation to shoot them down, a destroyed meteor leaves behind a valuable star coin to collect. | |
A laser is shot when you tap anywhere on the screen, by implementing the `touch_began()` method. A maximum of 3 lasers can be on the screen at once; maybe the laser gun needs recharging -- in any case, it's supposed to discourage simply hammering on the screen the entire time. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# coding: utf-8 | |
from scene import * | |
import json | |
import sound | |
A = Action | |
standing_texture = Texture('plf:AlienBlue_front') | |
walk_textures = [Texture('plf:AlienBlue_walk1'), Texture('plf:AlienBlue_walk2')] | |
jump_texture = Texture('plf:AlienBlue_jump') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# coding: utf-8 | |
from scene import * | |
import json | |
import sound | |
A = Action | |
standing_texture = Texture('plf:AlienBlue_front') | |
walk_textures = [Texture('plf:AlienBlue_walk1'), Texture('plf:AlienBlue_walk2')] | |
jump_texture = Texture('plf:AlienBlue_jump') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# coding: utf-8 | |
from scene import * | |
import json | |
import sound | |
A = Action | |
standing_texture = Texture('plf:AlienBlue_front') | |
walk_textures = [Texture('plf:AlienBlue_walk1'), Texture('plf:AlienBlue_walk2')] | |
jump_texture = Texture('plf:AlienBlue_jump') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# coding: utf-8 | |
from scene import * | |
import json | |
import sound | |
A = Action | |
standing_texture = Texture('plf:AlienBlue_front') | |
walk_textures = [Texture('plf:AlienBlue_walk1'), Texture('plf:AlienBlue_walk2')] | |
jump_texture = Texture('plf:AlienBlue_jump') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from scene import * | |
import json | |
import sound | |
background_objects_json_str = ''' | |
[{"x": 500, "y": 62, "w": 50, "h": 80, "img": "plc:Dirt_Block"}, | |
{"x": 500, "y": 100, "w": 50, "h": 80, "img": "plc:Dirt_Block"}, | |
{"x": 500, "y": 150, "w": 50, "h": 50, "img": "plc:Grass_Block"}] | |
''' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from scene import * | |
import json | |
import sound | |
background_objects_json_str = '[{"x": 500, "y": 50, "w": 50, "h": 50, "img": "plc:Dirt_Block"}]' | |
class GameEnvironment(object): | |
def __init__(self): | |
self.background_speed = 0.3 |