public override void Start() { base.Start(); BattleInfoArg battleInfo = new BattleInfoArg(); if (skillType != SkillType.NotReleaseSkill) { battleInfo.Message = GenMessage(); } GameControler.singleton.eventManager.FireEvent(this, battleInfo); lostBanlanceValue = 0; CountTime(m_SkillStruct.releaseTime); }
public void GetHurt(int value) { if (value < 0) { Debug.LogWarning("WrongHurtValue"); return; } if (m_Propty.GetIsEgnoreEffectMarked(EgnoreEffect.Hurt)) { return; } OnNewProgresss("受到" + value + "点伤害"); BattleInfoArg arg = new BattleInfoArg(); arg.Message = m_Propty.name + "受到" + value + "点伤害"; GameControler.singleton.eventManager.FireEvent <BattleInfoArg>(this, arg); if (DeductLife(value) <= 0) { arg.Message = m_Propty.name + "死亡"; GameControler.singleton.eventManager.FireEvent <BattleInfoArg>(this, arg); OnChampionFallDown(this); } }
public void OnGetMessage(object sender, FrameWorkEventArg arg) { BattleInfoArg battleArg = arg as BattleInfoArg; battleInfo.text = battleArg.Message + "\n\n" + battleInfo.text; }