chore: miscellaneous code, formatting, and syntax cleanup (#1351)

* miscellaneous code, formatting, and syntax cleanup

* update

* update again

* updated to account for feedback
This commit is contained in:
jadebenn
2023-12-23 18:11:00 -06:00
committed by GitHub
parent 5e9355b1ff
commit 6de224a2fa
13 changed files with 169 additions and 141 deletions

View File

@@ -217,7 +217,7 @@ int main(int argc, char** argv) {
uint32_t chatPort = 1501;
if (Game::config->GetValue("chat_server_port") != "") chatPort = std::atoi(Game::config->GetValue("chat_server_port").c_str());
auto chatSock = SocketDescriptor(uint16_t(ourPort + 2), 0);
auto chatSock = SocketDescriptor(static_cast<uint16_t>(ourPort + 2), 0);
Game::chatServer = RakNetworkFactory::GetRakPeerInterface();
Game::chatServer->Startup(1, 30, &chatSock, 1);
Game::chatServer->Connect(masterIP.c_str(), chatPort, "3.25 ND1", 8);
@@ -1246,7 +1246,7 @@ void HandlePacket(Packet* packet) {
default:
const auto messageId = *reinterpret_cast<eWorldMessageType*>(&packet->data[3]);
const std::string_view messageIdString = StringifiedEnum::ToString(messageId);
const std::string_view messageIdString = StringifiedEnum::ToString(messageId);
LOG("Unknown world packet received: %4i, %s", messageId, messageIdString.data());
}
}