本文整理汇总了C#中ActorController.DoHeal方法的典型用法代码示例。如果您正苦于以下问题:C# ActorController.DoHeal方法的具体用法?C# ActorController.DoHeal怎么用?C# ActorController.DoHeal使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ActorController
的用法示例。
在下文中一共展示了ActorController.DoHeal方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: DoEffectOnTarget
//.........这里部分代码省略.........
}
num = num * (long)(10000 + this.damageMod) / 10000L;
num = num * (long)num5 / 10000L;
if (this.talentEnhanceDamage != null)
{
int num9 = (int)(target.CurHP * 10000L / target.MaxHP);
if (num9 <= this.talentEnhanceDamage.Value2)
{
num = num * (long)(10000 + this.talentEnhanceDamage.Value1) / 10000L;
}
}
if (!flag && info.TriggerDoubleDamage && this.doubleDamage != null && Time.time >= this.doubleDamage.Cooldown && UtilFunc.RangeRandom(0, 10000) < this.doubleDamage.Value1)
{
num = num * (long)this.doubleDamage.Value2 / 10000L;
this.doubleDamage.Cooldown = Time.time + (float)this.doubleDamage.Value3;
}
if (target.shareDamage > 0)
{
num = Globals.Instance.ActorMgr.DoShareDamage(target, num, target.shareDamage);
}
num2 = target.DoDamage(num, this, ActorController.CanHitBack(info));
if (num2 > 0 && target.damageReflect > 0)
{
long damage = (long)num2 * (long)target.damageReflect / 10000L;
this.DoReflectDamage(damage, target);
}
if (num2 > 0 && target.reflexDamage != null && Time.time >= target.reflexDamage.Cooldown && UtilFunc.RangeRandom(0, 10000) < target.reflexDamage.Value1)
{
long num10 = (long)num2 * (long)target.reflexDamage.Value2 / 10000L;
if (num10 > 0L)
{
target.reflexDamage.Cooldown = Time.time + (float)target.reflexDamage.Value3;
this.DoReflectDamage(num10, target);
}
}
if (target.uiText != null && num2 > 0)
{
if (target.factionType == ActorController.EFactionType.ERed)
{
if (flag)
{
GameUIManager.mInstance.HUDTextMgr.RequestShow(target, EShowType.EST_CriticalDamage, num2, null, 0);
}
else if (this.actorType == ActorController.EActorType.EPlayer && this.Skills[0] != null && this.Skills[0].Info != info)
{
GameUIManager.mInstance.HUDTextMgr.RequestShow(target, EShowType.EST_SkillDamage, num2, null, 0);
}
else
{
GameUIManager.mInstance.HUDTextMgr.RequestShow(target, EShowType.EST_Damage, num2, null, 0);
}
}
else
{
GameUIManager.mInstance.HUDTextMgr.RequestShow(target, EShowType.EST_Damage, -num2, null, 2);
}
}
num8 += (float)num2 * info.ThreatCoef;
if (this.suckPct > 0)
{
long value3 = (long)num2 * (long)this.suckPct / 10000L;
this.DoSuckHeal(value3, this, true);
}
if (num2 > 0 && this.damageToHeal != null && Time.time >= this.damageToHeal.Cooldown && UtilFunc.RangeRandom(0, 10000) < this.damageToHeal.Value1)
{
this.damageToHeal.Cooldown = Time.time + (float)this.damageToHeal.Value3;
long value4 = (long)num2 * (long)this.damageToHeal.Value2 / 10000L;
this.DoSuckHeal(value4, this, false);
}
if (this.attackToHeal != null && Time.time >= this.attackToHeal.Cooldown && UtilFunc.RangeRandom(0, 10000) < this.attackToHeal.Value1)
{
this.attackToHeal.Cooldown = Time.time + (float)this.attackToHeal.Value3;
long value5 = (long)this.GetAtt(EAttID.EAID_Attack) * (long)this.attackToHeal.Value2 / 10000L;
this.DoSuckHeal(value5, this, false);
}
}
if (num4 > 0L)
{
num4 = num4 * (long)(10000 + this.healMod) / 10000L;
num3 = target.DoHeal(num4, this);
if (num3 > 0 && target.uiText != null && this.factionType == ActorController.EFactionType.EBlue)
{
GameUIManager.mInstance.HUDTextMgr.RequestShow(target, EShowType.EST_Heal, num3, null, 0);
}
}
if (num8 > 0f && this.IsHostileTo(target))
{
target.AiCtrler.ThreatMgr.AddThreat(this, num8);
}
if ((this.actorType == ActorController.EActorType.EPlayer || this.actorType == ActorController.EActorType.EPet) && target.AiCtrler.ThreatMgr.TargetActor != null && target.AiCtrler.ThreatMgr.TargetActor.IsBuilding)
{
target.AiCtrler.ThreatMgr.Clear();
target.AiCtrler.SetInitTarget(this);
}
if (info.CastType == 0 || info.CastType == 1)
{
this.CastTriggerSkill(target);
}
this.CountSkillDamageHeal(info, (long)num2, (long)num3);
}