add player to init method

This commit is contained in:
Jakob Haag 2020-05-12 18:27:21 +02:00
parent 339be93865
commit 1f5a9f2365

View File

@ -17,7 +17,7 @@ class Base: GKEntity {
var changeOwnership: Bool var changeOwnership: Bool
var ownershipPlayer: GKPlayer? var ownershipPlayer: GKPlayer?
init(position: CGPoint, team: Team! = nil) { init(position: CGPoint, player: GKPlayer! = nil, team: Team! = nil) {
self.unitCount = 0 self.unitCount = 0
self.adjacencyList = [Base]() self.adjacencyList = [Base]()
self.changeOwnership = false self.changeOwnership = false