Added 'server ready' broadcast to UCS server so clients will reconnect after crash

This commit is contained in:
Uleat
2018-02-26 20:02:27 -05:00
parent c469571f62
commit e547a1e778
11 changed files with 122 additions and 20 deletions
+1
View File
@@ -52,6 +52,7 @@ void UCSConnection::ProcessPacket(uint16 opcode, EQ::Net::Packet &p)
Log(Logs::Detail, Logs::UCS_Server, "Got authentication from UCS when they are already authenticated.");
break;
}
case ServerOP_UCSBroadcastServerReady:
case ServerOP_UCSClientVersionRequest:
{
zoneserver_list.SendPacket(pack);
-17
View File
@@ -516,23 +516,6 @@ void WorldDatabase::GetLauncherList(std::vector<std::string> &rl) {
}
void WorldDatabase::SetMailKey(int CharID, int IPAddress, int MailKey)
{
char MailKeyString[17];
if(RuleB(Chat, EnableMailKeyIPVerification) == true)
sprintf(MailKeyString, "%08X%08X", IPAddress, MailKey);
else
sprintf(MailKeyString, "%08X", MailKey);
std::string query = StringFormat("UPDATE character_data SET mailkey = '%s' WHERE id = '%i'",
MailKeyString, CharID);
auto results = QueryDatabase(query);
if (!results.Success())
Log(Logs::General, Logs::Error, "WorldDatabase::SetMailKey(%i, %s) : %s", CharID, MailKeyString, results.ErrorMessage().c_str());
}
bool WorldDatabase::GetCharacterLevel(const char *name, int &level)
{
std::string query = StringFormat("SELECT level FROM character_data WHERE name = '%s'", name);
-1
View File
@@ -34,7 +34,6 @@ public:
int MoveCharacterToBind(int CharID, uint8 bindnum = 0);
void GetLauncherList(std::vector<std::string> &result);
void SetMailKey(int CharID, int IPAddress, int MailKey);
bool GetCharacterLevel(const char *name, int &level);
bool LoadCharacterCreateAllocations();