Revert "Merge branch '33-basisownership-anhand-des-gkplayers' into 'development'"

This reverts merge request !54
This commit is contained in:
Marcel Schwarz 2020-05-10 16:48:04 +00:00 committed by Jakob Haag
parent bd5d142a43
commit 4189d0f634
30 changed files with 454 additions and 465 deletions

View File

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

View File

@ -18,27 +18,17 @@ class Modal: GKEntity{
switch modaltype{ switch modaltype{
case .BaseDetails: case .BaseDetails:
addComponent(ModalBackgroundComponent(anchorPoint: anchorPoint)) addComponent(ModalBackgroundComponent(anchorPoint: anchorPoint))
addComponent(ModalContentComponent( addComponent(ModalContentComponent(header: "Basis Information",
header: "Basis Information",
body: "Diese Basis enthält \(base.unitCount) Einheiten", body: "Diese Basis enthält \(base.unitCount) Einheiten",
footer: "", footer: "",
anchorPoint: anchorPoint anchorPoint: anchorPoint))
)
)
case .BaseAttack: case .BaseAttack:
addComponent(ModalBackgroundComponent(anchorPoint: anchorPoint)) addComponent(ModalBackgroundComponent(anchorPoint: anchorPoint))
addComponent(SliderComponent( addComponent(SliderComponent(width: 300, position: CGPoint(x: anchorPoint.x , y: anchorPoint.y - 80)))
width: 300, addComponent(ModalContentComponent(header: "Angriff",
position: CGPoint(x: anchorPoint.x , y: anchorPoint.y - 80)
)
)
addComponent(ModalContentComponent(
header: "Angriff",
body: "Schicke \(unitCount / 2) Einheiten", body: "Schicke \(unitCount / 2) Einheiten",
footer: "", footer: "",
anchorPoint: anchorPoint anchorPoint: anchorPoint))
)
)
} }
} }