public virtual void CompleteToAll(DungeonScene _this, FubenResult result, int seconds = 20) { _this.PushActionToAllPlayer(player => { if (player != null) { _this.Complete(player.ObjId, result); } }); _this.EnterAutoClose(seconds); }
public void NotifyDungeonTime(DungeonScene _this, eDungeonTimerType type) { var trigger = _this.Trggers[(int)type]; if (trigger != null && trigger.T != null) { _this.PushActionToAllPlayer( player => { player.Proxy.NotifyDungeonTime((int)_this.State, (ulong)trigger.Time.ToBinary()); }); } }
public void OnNpcDie(DungeonScene _this, ObjNPC npc, ulong characterId) { var idx = _this.MapNpcRecords.FindIndex(r => r.NpcID == npc.TypeId); if (idx == -1) { return; } var info = _this.MapNpcInfo.Data[idx]; info.Alive = false; var data = new MapNpcInfos(); data.Data.Add(info); _this.PushActionToAllPlayer(p => { if (p.Proxy == null) { return; } p.Proxy.NotifyNpcStatus(data); }); }