protected override void OnStart() { base.OnStart(); if (legionData.aiConfig == null || legionData.aiConfig.uplevelLevel == AIUplevelLevel.Level_0_Lazy) { enabled = false; return; } legionId = legionData.legionId; aiConfig = legionData.aiConfig; intervalMax = aiConfig.uplevelInterval; intervalMin = Mathf.Max(intervalMax - aiConfig.uplevelIntervalRandom, 0f); _updateTime = Time.time + Random.Range(intervalMin, intervalMax) + War.sceneData.begionDelayTime; }
protected override void OnStart() { base.OnStart(); if (legionData.aiConfig == null) { enabled = false; return; } legionId = legionData.legionId; aiConfig = legionData.aiConfig; distanceScoreRate_Attack = aiConfig.distanceScoreRate_Attack; distanceScoreRate_Rescue = aiConfig.distanceScoreRate_Rescue; intervalMax = aiConfig.interval; intervalMin = Mathf.Max(intervalMax - aiConfig.intervalRandom, 0f); _updateTime = Time.time + Random.Range(intervalMin, intervalMax) + War.sceneData.begionDelayTime; }
public void AddAIConfig(AIConfig config) { aiConfigs.Add(config.id, config); }