| | |
| | | using System.Collections.Generic; |
| | | using UnityEngine; |
| | | using TowerDefense.Agents; |
| | | |
| | | /** |
| | | * 魔法护盾 |
| | |
| | | /// </summary> |
| | | public override void ReleaseSkill() |
| | | { |
| | | base.ReleaseSkill(); |
| | | List<int> tunelIdList = GetTunelList(); |
| | | |
| | | if (tunelIdList.Count > 0) |
| | | { |
| | | for (int i = 0; i < tunelIdList.Count; ++i) |
| | | { |
| | | List<Agent> agents = AgentInsManager.instance.GetAgentsByTunel(tunelIdList[i]); |
| | | |
| | | if (agents == null) continue; |
| | | |
| | | for (int j = 0; j < agents.Count; ++j) |
| | | { |
| | | float shieldValue = agents[j].configuration.currentHealth * SkillData.effect[0]; |
| | | agents[j].configuration.AddShieldWall(shieldValue, SkillData.effect[1]); |
| | | } |
| | | } |
| | | } |
| | | } |
| | | |
| | | public override void Init() |
| | | { |
| | | base.Init(); |
| | | Debug.Log("--------------------- 魔法护盾技能初始化 ---------------------"); |
| | | } |
| | | |
| | | public override void Update(float deltaTime) |
| | | { |
| | | IsCDCompleted = false; |
| | | } |
| | | } |
| | | } |