practice mode integrated to the onboarding tutorial
This commit is contained in:
@@ -608,7 +608,28 @@ public class GameManager : NetworkBehaviour
|
||||
}
|
||||
}
|
||||
|
||||
bool turnTimerPaused;
|
||||
|
||||
public void SetTurnTimerPaused(bool paused)
|
||||
{
|
||||
if (!isServer)
|
||||
{
|
||||
CmdSetTurnTimerPaused(paused);
|
||||
return;
|
||||
}
|
||||
turnTimerPaused = paused;
|
||||
}
|
||||
|
||||
[Command(requiresAuthority = false)]
|
||||
void CmdSetTurnTimerPaused(bool paused)
|
||||
{
|
||||
turnTimerPaused = paused;
|
||||
}
|
||||
|
||||
void HandleTurnTimer(){
|
||||
if (turnTimerPaused)
|
||||
return;
|
||||
|
||||
if(turnTimerCounter < turnTimer){
|
||||
if(!isMoving && !switchingTeams && gameStarted){
|
||||
turnTimerCounter += Time.deltaTime;
|
||||
@@ -846,7 +867,7 @@ public class GameManager : NetworkBehaviour
|
||||
|
||||
public void StopClient(){
|
||||
try{
|
||||
NetworkManager.singleton.StopClient();
|
||||
NetManager.StopNetworkingForSceneChange();
|
||||
}catch(Exception e){
|
||||
Logger.Log("Error stopping client: " + e.Message);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user