private float fCurrentThinkCooldown = 0f; // fCurrentThinkCooldown: The current think cooldown of the brain - restricts the brain from thinking too much // Private Functions // Start(): Use this for initialisation void Start() { fAggressiveToDefensive = Settings.s_fAggressiveToDefensive; fThinkCooldown = Settings.s_fThinkCooldown; m_PlayerSquadFSM = PlayerSquadFSM.Instance; }
public static void LoadScene(int _sceneId) { Application.LoadLevel(2); // Call All Reset Statics PlayerChildFSM.ResetStatics(); PlayerMain.ResetStatics(); player_control.ResetStatics(); GameManager.ResetStatics(); EndGamePanel.ResetStatics(); PlayerSquadFSM.ResetStatics(); SquadChildFSM.ResetStatics(); Wall.ResetStatics(); WallRenderer.ResetStatics(); Nutrients.ResetStatics(); ECPoolManager.ResetStatics(); ECIdleState.ResetStatics(); DirectionDatabase.ResetStatics(); FormationDatabase.ResetStatics(); PathQuery.ResetStatics(); PointDatabase.ResetStatics(); PositionQuery.ResetStatics(); ECTracker.ResetStatics(); EnemyMainFSM.ResetStatics(); Application.LoadLevel(_sceneId); }
// Private Functions // Awake(): Called when the object is instantiated void Awake() { // Singleton Implementation if (s_m_Instance == null) { s_m_Instance = this; } else { Destroy(this.gameObject); } fMinimumCooldown = Settings.s_fMinimumCooldown; fMaximumCooldown = Settings.s_fMaximumCooldown; }
public static void ResetStatics() { s_m_Instance = null; }
// Constructor public PS_FindResourceState(PlayerSquadFSM para_playerSquadFSM) { m_psFSM = para_playerSquadFSM; }
// Constructor public PS_DefendState(PlayerSquadFSM para_playerSquadFSM) { m_psFSM = para_playerSquadFSM; }
public PS_AvoidState(PlayerSquadFSM para_PlayerSquadFSM) { m_psFSM = para_PlayerSquadFSM; }
// Constructor public PS_IdleState(PlayerSquadFSM para_playerSquadFSM, PS_Logicaliser para_Brain) { m_psFSM = para_playerSquadFSM; m_Brain = para_Brain; }
// Constructor public PS_DeadState(PlayerSquadFSM para_playerSquadFSM) { m_psFSM = para_playerSquadFSM; }
// Constructor public PS_AttackState(PlayerSquadFSM para_playerSquadFSM) { m_psFSM = para_playerSquadFSM; }
// Constructor public PS_ProduceState(PlayerSquadFSM para_playerSquadFSM) { m_psFSM = para_playerSquadFSM; }
// Private Functions // Awake(): Called when the object is instantiated void Awake() { // Singleton Implementation if (s_m_Instance == null) s_m_Instance = this; else Destroy(this.gameObject); fMinimumCooldown = Settings.s_fMinimumCooldown; fMaximumCooldown = Settings.s_fMaximumCooldown; }
// Private Functions // Start(): Use this for initialisation void Start() { fAggressiveToDefensive = Settings.s_fAggressiveToDefensive; fThinkCooldown = Settings.s_fThinkCooldown; m_PlayerSquadFSM = PlayerSquadFSM.Instance; }