protected void SendFailure(string text) { client.SendPacket(new FailurePacket { ErrorId = 0, ErrorDescription = text }); }
protected void SendFailure(string text, int type = 0) { client.SendPacket(new FailurePacket { Message = text, ErrorId = type }); }
public static bool TryConnect(Client client) { var acc = client.Account; if (client.ConnectedBuild != client.clientVer) { client.SendPacket(new TextPacket() { Name = "", BubbleTime = 0, Stars = -1, Text = "You are running an outdated client version." }); return false; } if (acc.Banned) return false; if (Clients.Count >= MAX_CLIENT) return false; else return Clients.TryAdd(client.Account.AccountId, client); }
protected void SendNotification(Client cli, string text, int type = 0) { cli.SendPacket(new GlobalNotificationPacket { Text = text, Type = type }); }
protected void SendFailure(Client cli, string text) { cli.SendPacket(new svrPackets.FailurePacket { Message = text }); }