using UnityEngine;
|
using System.Collections.Generic;
|
using System;
|
|
public class BuffMountAction : RecordAction
|
{
|
protected HB428_tagSCBuffRefresh hB428_TagSCBuffRefresh;
|
|
protected Action onComplete;
|
|
public BuffMountAction(BattleField _battleField, BattleObject _battleObj, HB428_tagSCBuffRefresh vNetData, Action _onComplete)
|
: base(RecordActionType.BuffMount, _battleField, _battleObj)
|
{
|
isFinish = false;
|
hB428_TagSCBuffRefresh = vNetData;
|
onComplete = _onComplete;
|
}
|
|
public override bool IsFinished()
|
{
|
return isFinish;
|
}
|
|
|
public override void Run()
|
{
|
base.Run();
|
|
if (!isRunOnce)
|
{
|
SkillConfig skillConfig = SkillConfig.Get((int)hB428_TagSCBuffRefresh.SkillID);
|
if (null != skillConfig)
|
{
|
// 飘字
|
battleObject.heroInfoBar.ShowTips(skillConfig.SkillName);
|
}
|
|
|
// 加buff(onComplete写了)
|
onComplete?.Invoke();
|
|
|
isFinish = true;
|
return;
|
}
|
|
}
|
|
public override void ForceFinish()
|
{
|
// 1帧就结束了 不管
|
base.ForceFinish();
|
}
|
}
|