diff options
author | Paweł Redman <pawel.redman@gmail.com> | 2017-12-12 15:44:19 +0100 |
---|---|---|
committer | Paweł Redman <pawel.redman@gmail.com> | 2017-12-12 15:44:19 +0100 |
commit | c33d0fa9c43fb316a9c6bbb2be81446dce7f49da (patch) | |
tree | a4ded215d9dd7c5098b395925f0c19956c46670c /src/game/assets.cpp | |
parent | 5667984053536d855ba0917deac326d429f2c5b4 (diff) |
Move tile data to src/game.
Diffstat (limited to 'src/game/assets.cpp')
-rw-r--r-- | src/game/assets.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/game/assets.cpp b/src/game/assets.cpp index 32eff81..c20d77b 100644 --- a/src/game/assets.cpp +++ b/src/game/assets.cpp @@ -1,6 +1,6 @@ #include "game.hpp" -namespace assets { +namespace game::assets { human_assets_t human; sf::Texture tile_dirt; @@ -13,8 +13,10 @@ void load(void) human.legs_idle.load("assets/units/human/legs_idle", 2, 2); human.legs_walking.load("assets/units/human/legs_walking", 2, 2); - tile_dirt.loadFromFile("assets/tiles/dirt.png"); - tile_wall.loadFromFile("assets/tiles/wall.png"); + world::register_tile(TILE_DIRT, 0); + world::register_tile(TILE_WALL, 1); + render::register_tile(TILE_DIRT, "assets/tiles/dirt.png"); + render::register_tile(TILE_WALL, "assets/tiles/wall.png"); } -} // namespace assets +} // namespace game::assets |