1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-25 07:44:38 +01:00

clang-format: change IndentPPDirectives to BeforeHash (#23287)

This commit is contained in:
Aaron van Geffen
2024-11-29 12:04:56 +09:00
committed by GitHub
parent c8388002d9
commit 3685d1a24b
173 changed files with 1636 additions and 1636 deletions

View File

@@ -9,21 +9,21 @@
#ifndef DISABLE_NETWORK
# include "NetworkConnection.h"
#include "NetworkConnection.h"
# include "../core/String.hpp"
# include "../localisation/Formatting.h"
# include "../platform/Platform.h"
# include "Socket.h"
# include "network.h"
#include "../core/String.hpp"
#include "../localisation/Formatting.h"
#include "../platform/Platform.h"
#include "Socket.h"
#include "network.h"
using namespace OpenRCT2;
static constexpr size_t kNetworkDisconnectReasonBufSize = 256;
static constexpr size_t kNetworkBufferSize = 1024 * 64; // 64 KiB, maximum packet size.
# ifndef DEBUG
#ifndef DEBUG
static constexpr size_t kNetworkNoDataTimeout = 20; // Seconds.
# endif
#endif
NetworkConnection::NetworkConnection() noexcept
{
@@ -181,13 +181,13 @@ void NetworkConnection::ResetLastPacketTime() noexcept
bool NetworkConnection::ReceivedPacketRecently() const noexcept
{
# ifndef DEBUG
#ifndef DEBUG
constexpr auto kTimeoutMs = kNetworkNoDataTimeout * 1000;
if (Platform::GetTicks() > _lastPacketTime + kTimeoutMs)
{
return false;
}
# endif
#endif
return true;
}