Do some polishing
This commit is contained in:
parent
0dbcbe5eb0
commit
7fc4a5145f
@ -15,7 +15,7 @@ class Base : GKEntity {
|
|||||||
|
|
||||||
init(position: CGPoint, team: Team! = nil) {
|
init(position: CGPoint, team: Team! = nil) {
|
||||||
self.unitCount = 0
|
self.unitCount = 0
|
||||||
self.adjacencyList = Array<Base>()
|
self.adjacencyList = [Base]()
|
||||||
|
|
||||||
super.init()
|
super.init()
|
||||||
|
|
||||||
|
@ -69,7 +69,7 @@ class TwoPlayerDefaultTestMap: MapProtocol {
|
|||||||
|
|
||||||
basePlayerTwo.adjacencyList.append(contentsOf: column3)
|
basePlayerTwo.adjacencyList.append(contentsOf: column3)
|
||||||
|
|
||||||
// Add Bases to GameScene
|
// Register bases with the EntityManager
|
||||||
entityManager.add(basePlayerOne)
|
entityManager.add(basePlayerOne)
|
||||||
|
|
||||||
column1.forEach({base in entityManager.add(base)})
|
column1.forEach({base in entityManager.add(base)})
|
||||||
|
@ -33,7 +33,6 @@ class GameScene: SKScene{
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: Issue #24 create Map generation Service
|
|
||||||
func initMap() {
|
func initMap() {
|
||||||
MapFactory(scene: self, entityManager: self.entityManager).loadMap(playerCount: 2)
|
MapFactory(scene: self, entityManager: self.entityManager).loadMap(playerCount: 2)
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user