summary refs log tree commit diff stats
path: root/src/entityfactory.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/entityfactory.cpp')
-rw-r--r--src/entityfactory.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/entityfactory.cpp b/src/entityfactory.cpp index bad72cf..6fb86ca 100644 --- a/src/entityfactory.cpp +++ b/src/entityfactory.cpp
@@ -24,7 +24,7 @@ std::shared_ptr<Entity> EntityFactory::createNamedEntity(const std::string name)
24 EntityData data = factories[name]; 24 EntityData data = factories[name];
25 if (it == factories.end()) 25 if (it == factories.end())
26 { 26 {
27 xmlDocPtr doc = xmlParseFile(("../entities/" + name + ".xml").c_str()); 27 xmlDocPtr doc = xmlParseFile(("entities/" + name + ".xml").c_str());
28 if (doc == nullptr) 28 if (doc == nullptr)
29 { 29 {
30 fprintf(stderr, "Error reading entity %s\n", name.c_str()); 30 fprintf(stderr, "Error reading entity %s\n", name.c_str());
@@ -85,7 +85,7 @@ std::shared_ptr<Entity> EntityFactory::createNamedEntity(const std::string name)
85 if (!strcmp(data.action, "save")) 85 if (!strcmp(data.action, "save"))
86 { 86 {
87 auto component = std::make_shared<SimpleColliderComponent>([&] (Game& game, Entity&) { 87 auto component = std::make_shared<SimpleColliderComponent>([&] (Game& game, Entity&) {
88 playSound("../res/Pickup_Coin23.wav", 0.25); 88 playSound("res/Pickup_Coin23.wav", 0.25);
89 89
90 game.saveGame(); 90 game.saveGame();
91 }); 91 });