summaryrefslogtreecommitdiffstats
path: root/src/model/Map.cpp
diff options
context:
space:
mode:
authorMatthias Schiffer <mschiffer@universe-factory.net>2014-09-23 00:13:05 +0200
committerMatthias Schiffer <mschiffer@universe-factory.net>2014-09-23 00:13:05 +0200
commit11e77a9d65972c8e59aefd72419dfcf9036e9f6a (patch)
tree03288809e9a592849e881d6f3baae2eb41bee5cb /src/model/Map.cpp
parentc9b41bc1022c75ac6da84f4fa503dd8231a96cf2 (diff)
downloadrpgedit-11e77a9d65972c8e59aefd72419dfcf9036e9f6a.tar
rpgedit-11e77a9d65972c8e59aefd72419dfcf9036e9f6a.zip
Allow player movement
Diffstat (limited to 'src/model/Map.cpp')
-rw-r--r--src/model/Map.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/model/Map.cpp b/src/model/Map.cpp
index 9cbe880..48f5669 100644
--- a/src/model/Map.cpp
+++ b/src/model/Map.cpp
@@ -45,10 +45,10 @@ std::shared_ptr<Map> Map::load(__attribute__((unused)) const std::string &name)
}
}
- std::shared_ptr<Entity> square(new Entity("square"));
- square->move(6, 6);
+ map->playerEntity.reset(new Entity("square"));
+ map->playerEntity->moveTo(6, 6);
- map->entities.push_back(square);
+ map->entities.push_back(map->playerEntity);
return map;
}