| | |
| | | } |
| | | } |
| | | |
| | | public virtual void OnObjsDead(List<BattleDeadPack> deadPackList, RecordAction causingRecordAction = null) |
| | | public virtual DeathRecordAction OnObjsDead(List<BattleDeadPack> deadPackList, RecordAction _causingRecordAction = null) |
| | | { |
| | | DeathRecordAction deathRecordAction = null; |
| | | if (deadPackList.Count > 0) |
| | | { |
| | | // 过滤掉正在处理死亡的角色,避免重复处理 |
| | |
| | | // 只处理有效的死亡消息 |
| | | if (validDeadList.Count > 0) |
| | | { |
| | | DeathRecordAction recordAction = new DeathRecordAction(this, validDeadList, causingRecordAction); |
| | | // 如果有导致死亡的技能,将DeathRecordAction作为其子节点,并设置为WaitingPlay |
| | | if (causingRecordAction != null) |
| | | { |
| | | recordPlayer.ImmediatelyPlay(recordAction, causingRecordAction, true); |
| | | } |
| | | else |
| | | { |
| | | recordPlayer.ImmediatelyPlay(recordAction); |
| | | } |
| | | DeathRecordAction recordAction = new DeathRecordAction(this, validDeadList, _causingRecordAction); |
| | | deathRecordAction = recordAction; |
| | | } |
| | | |
| | | } |
| | | return deathRecordAction; |
| | | } |
| | | |
| | | public virtual void OnObjReborn(uint objId) |