Change battle actions to use battle decisions instead.
This commit is contained in:
@@ -46,8 +46,7 @@ func startBattle(params) -> void:
|
||||
|
||||
# Initial cutscene elements. In future I may need to make this editable
|
||||
# somehow?
|
||||
for fighter:BattleFighter in params['fighters'].values():
|
||||
battleCutscene.addCallable(BattleCutsceneAction.getPlayerDecisionCallable(fighter))
|
||||
battleCutscene.addCallable(BattleCutsceneAction.getPlayerDecisionCallable())
|
||||
|
||||
# Emit signals
|
||||
active = true
|
||||
@@ -56,7 +55,15 @@ func startBattle(params) -> void:
|
||||
|
||||
# Start running the battle cutscene.
|
||||
if !battleCutscene.running:
|
||||
battleCutscene.start()
|
||||
battleCutscene.start()# Should this await?
|
||||
|
||||
func getFighterAtPosition(battlePos:BattlePosition) -> BattleFighter:
|
||||
return fighterMap.get(battlePos, null)
|
||||
|
||||
func getPositionOfFighter(fighter:BattleFighter) -> BattlePosition:
|
||||
for pos in fighterMap.keys():
|
||||
if fighterMap[pos] == fighter:
|
||||
return pos
|
||||
|
||||
assert(false)
|
||||
return BattlePosition.LEFT_TOP_BACK
|
||||
|
||||
Reference in New Issue
Block a user