public override void UpdateStatus(FightStatus fightStatus) { fightStatus.currentTurnPlayerId = 0; if (fightStatus != FightStatus.local || fightStatus.localPlayerId != concernedEntity) { return; } switch (FightCastManager.currentCastType) { case FightCastManager.CurrentCastType.Spell: FightCastManager.StopCastingSpell(cancelled: true); break; case FightCastManager.CurrentCastType.Companion: FightCastManager.StopInvokingCompanion(cancelled: true); break; default: throw new ArgumentOutOfRangeException(); case FightCastManager.CurrentCastType.None: break; } FightMap current = FightMap.current; if (null != current) { current.SetNoInteractionPhase(); } FightUIRework instance = FightUIRework.instance; if (null != instance) { instance.EndLocalPlayerTurn(); } if (fightStatus.TryGetEntity(concernedEntity, out PlayerStatus entityStatus)) { AbstractPlayerUIRework view = entityStatus.view; if (null != view) { view.SetUIInteractable(interactable: false); } } else { Log.Error(FightEventErrors.PlayerNotFound(concernedEntity), 60, "C:\\BuildAgents\\AgentB\\work\\cub_client_win64_develop\\client\\DofusCube.Unity\\Assets\\Core\\Code\\Fight\\Events\\TurnEndedEvent.cs"); } }
protected void EndTargetingPhase() { FightStatus local = FightStatus.local; if (local.currentTurnPlayerId == local.localPlayerId) { if (m_fightMap.IsInTargetingPhase()) { m_fightMap.SetMovementPhase(); } } else { m_fightMap.SetNoInteractionPhase(); } }