Added new monster sprites.

This commit is contained in:
Cameron Smart
2020-04-19 00:14:21 -07:00
parent 3b81bcfc65
commit 9c81afa345
12 changed files with 23 additions and 4 deletions

View File

@@ -54,11 +54,11 @@ class Game(arcade.Window):
Player.setup(self)
# Create the level
self.floor_list, self.wall_list = Level.load_file('resources/levels/box.json')
self.floor_list, self.wall_list = Level.load_file('resources/levels/test1.json')
# Create monsters
self.enemy_list.append(Enemy(image_source, 100, 100).get_enemy())
self.enemy_list.append(Enemy(image_source, Config.SCREEN_WIDTH / 2 + 10, Config.SCREEN_HEIGHT / 2 + 10).get_enemy())
self.enemy_list.append(Enemy("resources/images/monsters/ghost/ghost1.png", 200, 200).get_enemy())
self.enemy_list.append(Enemy("resources/images/monsters/frog/frog1.png", 200, 1000).get_enemy())
# Create the 'physics engine'
self.physics_engine = arcade.PhysicsEngineSimple(self.player_sprite, self.wall_list)
@@ -68,7 +68,7 @@ class Game(arcade.Window):
# Clear the screen to the background color
arcade.start_render()
# Draw our sprites
self.floor_list.draw()
self.player_sprite.draw()

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 294 B

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 303 B

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 305 B

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 276 B

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 276 B

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 276 B

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 321 B

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 317 B

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 331 B

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 317 B

View File

@@ -0,0 +1,19 @@
{
"elements" : {
"w" : "resources/images/tiles/wall_tile.png",
" " : "resources/images/tiles/floor_tile.png",
"e" : ""
},
"structure" : [
["w", "w", "w", "w", "w", "w", "w", "w", "w", "w"],
["w", " ", " ", "w", " ", " ", "w", " ", " ", "w"],
["w", " ", " ", "w", " ", " ", "w", " ", " ", "w"],
["w", " ", " ", "w", " ", " ", "w", " ", " ", "w"],
["w", " ", " ", " ", " ", " ", " ", " ", " ", "w"],
["w", " ", " ", " ", " ", " ", " ", " ", " ", "w"],
["w", " ", " ", "w", " ", " ", "w", " ", " ", "w"],
["w", " ", " ", "w", " ", " ", "w", " ", " ", "w"],
["w", " ", " ", "w", " ", " ", "w", " ", " ", "w"],
["w", "w", "w", "w", "w", "w", "w", "w", "w", "w"]
]
}