diff --git a/GoldWars/GoldWars/Entities/EntityManager.swift b/GoldWars/GoldWars/Entities/EntityManager.swift index 7a49701..48aef0d 100644 --- a/GoldWars/GoldWars/Entities/EntityManager.swift +++ b/GoldWars/GoldWars/Entities/EntityManager.swift @@ -111,7 +111,7 @@ class EntityManager { if base.changeOwnership { //FIX-ME: Find a way to update the Component without deleting it upfront //TODO: outsource component handling to a generic function - base.removeComponent(ofType: TeamComponent.self) + //base.removeComponent(ofType: TeamComponent.self) base.addComponent(TeamComponent( team: (entities[0] as! Base).component(ofType: TeamComponent.self)!.team, player: (entities[0] as! Base).component(ofType: TeamComponent.self)!.player, @@ -142,7 +142,7 @@ class EntityManager { base.ownershipPlayer = getOwnerBySnapBase //FIX-ME: Find a way to update the Component without deleting it upfront //TODO: outsource component handling to a generic function - entity.removeComponent(ofType: TeamComponent.self) + //entity.removeComponent(ofType: TeamComponent.self) entity.addComponent(TeamComponent( team: getTeamByPlayer(playerName: snapBase.ownership!), player: getOwnerBySnapBase!,