Exemplo n.º 1
0
        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;
        }
Exemplo n.º 2
0
        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;
        }
Exemplo n.º 3
0
 public void AddAIConfig(AIConfig config)
 {
     aiConfigs.Add(config.id, config);
 }