summary refs log tree commit diff stats
path: root/src/entityfactory.cpp
diff options
context:
space:
mode:
authorKelly Rauchenberger <fefferburbia@gmail.com>2015-03-14 17:58:50 -0400
committerKelly Rauchenberger <fefferburbia@gmail.com>2015-03-14 17:58:50 -0400
commitd9349f10d6d1972e87aea76d502703fae128a0e5 (patch)
tree93d545f8da6865ed81329426a510c81e7c3d44fd /src/entityfactory.cpp
parent2ca593c5f09ee59a39733856cdb1f7191dc87216 (diff)
downloadtherapy-d9349f10d6d1972e87aea76d502703fae128a0e5.tar.gz
therapy-d9349f10d6d1972e87aea76d502703fae128a0e5.tar.bz2
therapy-d9349f10d6d1972e87aea76d502703fae128a0e5.zip
Removed some unnecessary parameters from methods
Diffstat (limited to 'src/entityfactory.cpp')
-rw-r--r--src/entityfactory.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/entityfactory.cpp b/src/entityfactory.cpp index bf137e2..47a1463 100644 --- a/src/entityfactory.cpp +++ b/src/entityfactory.cpp
@@ -15,7 +15,7 @@ struct EntityData {
15 15
16static std::map<std::string, EntityData> factories; 16static std::map<std::string, EntityData> factories;
17 17
18std::shared_ptr<Entity> EntityFactory::createNamedEntity(const std::string name, const Map& map) 18std::shared_ptr<Entity> EntityFactory::createNamedEntity(const std::string name)
19{ 19{
20 auto it = factories.find(name); 20 auto it = factories.find(name);
21 EntityData data = factories[name]; 21 EntityData data = factories[name];
@@ -81,10 +81,10 @@ std::shared_ptr<Entity> EntityFactory::createNamedEntity(const std::string name,
81 { 81 {
82 if (!strcmp(data.action, "save")) 82 if (!strcmp(data.action, "save"))
83 { 83 {
84 auto component = std::make_shared<SimpleColliderComponent>([&] (Game& game, Entity& collider) { 84 auto component = std::make_shared<SimpleColliderComponent>([&] (Game& game, Entity&) {
85 playSound("../res/Pickup_Coin23.wav", 0.25); 85 playSound("../res/Pickup_Coin23.wav", 0.25);
86 86
87 game.saveGame(map, collider.position); 87 game.saveGame();
88 }); 88 });
89 entity->addComponent(component); 89 entity->addComponent(component);
90 } 90 }