Advertisement
Guest User

Untitled

a guest
Apr 29th, 2017
61
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 1.00 KB | None | 0 0
  1. using DragonFiesta.Utils.ServerTask;
  2. using DragonFiesta.World.InternNetwork;
  3. using DragonFiesta.World.Network;
  4. using System;
  5. using System.Collections.Generic;
  6. using System.Linq;
  7. using System.Text;
  8. using System.Threading.Tasks;
  9.  
  10. namespace DragonFiesta.World.ServerTask.Intern
  11. {
  12.     [ServerTaskClass(ServerTaskTimes.SERVER_INTERN_SESSION_ALIVE)]
  13.     public class TASK_UPDATE_WORLD_SERVER : mServerTask
  14.     {
  15.    
  16.         public override void Dispose()
  17.         {
  18.    
  19.         }
  20.  
  21.         public override bool Update(GameTime Now)
  22.         {
  23.             if (ServerMain.InternalInstance.ServerIsReady)
  24.             {
  25.                 InternLoginSession.Instance.SendMessage(new UpdateWorldServer
  26.                 {
  27.                     Id = Guid.NewGuid(),
  28.                     NowPlayerCount = WorldSessionManager.Instance.CountOfSessions,
  29.                      WorldReady = ServerMain.InternalInstance.ServerIsReady,
  30.                 });
  31.             }
  32.  
  33.             return true;
  34.         }
  35.     }
  36. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement