diff --git a/src/CNLoginServer.hpp b/src/CNLoginServer.hpp index e694588..a2fae91 100644 --- a/src/CNLoginServer.hpp +++ b/src/CNLoginServer.hpp @@ -1,5 +1,4 @@ -#ifndef _CNLS_HPP -#define _CNLS_HPP +#pragma once #include "CNProtocol.hpp" #include "Defines.hpp" @@ -24,5 +23,3 @@ public: void newConnection(CNSocket* cns); void killConnection(CNSocket* cns); }; - -#endif diff --git a/src/CNProtocol.hpp b/src/CNProtocol.hpp index 3913a75..07620b7 100644 --- a/src/CNProtocol.hpp +++ b/src/CNProtocol.hpp @@ -1,5 +1,4 @@ -#ifndef _CNP_HPP -#define _CNP_HPP +#pragma once #define MAX_PACKETSIZE 8192 #define DEBUGLOG(x) x @@ -152,5 +151,3 @@ public: virtual void killConnection(CNSocket* cns); virtual void onTimer(); // called every 2 seconds }; - -#endif \ No newline at end of file diff --git a/src/CNShardServer.hpp b/src/CNShardServer.hpp index e9d9b56..4d5ca31 100644 --- a/src/CNShardServer.hpp +++ b/src/CNShardServer.hpp @@ -1,5 +1,4 @@ -#ifndef _CNSS_HPP -#define _CNSS_HPP +#pragma once #include "CNProtocol.hpp" #include "Defines.hpp" @@ -21,5 +20,3 @@ public: void killConnection(CNSocket* cns); void onTimer(); }; - -#endif diff --git a/src/CNShared.hpp b/src/CNShared.hpp index 5e0d240..f852191 100644 --- a/src/CNShared.hpp +++ b/src/CNShared.hpp @@ -3,8 +3,7 @@ There's some data shared between the Login Server and the Shard Server. Of course all of this needs to be thread-safe. No mucking about on this one! */ -#ifndef _CNSD_HPP -#define _CNSD_HPP +#pragma once #include #include @@ -19,5 +18,3 @@ namespace CNSharedData { Player getPlayer(int64_t sk); void erasePlayer(int64_t sk); } - -#endif \ No newline at end of file diff --git a/src/CNStructs.hpp b/src/CNStructs.hpp index 0b7de0b..584463a 100644 --- a/src/CNStructs.hpp +++ b/src/CNStructs.hpp @@ -2,8 +2,7 @@ CNStructs.hpp - defines some basic structs & useful methods for packets used by FusionFall based on the version defined */ -#ifndef _CNS_HPP -#define _CNS_HPP +#pragma once #ifdef _MSC_VER // codecvt_* is deprecated in C++17 and MSVC will throw an annoying warning because of that. @@ -45,5 +44,3 @@ uint64_t getTime(); #else #error Invalid PROTOCOL_VERSION #endif - -#endif diff --git a/src/ChatManager.hpp b/src/ChatManager.hpp index 241d47b..cfc827b 100644 --- a/src/ChatManager.hpp +++ b/src/ChatManager.hpp @@ -1,5 +1,4 @@ -#ifndef _CM_HPP -#define _CM_HPP +#pragma once #include "CNShardServer.hpp" @@ -10,5 +9,3 @@ namespace ChatManager { void emoteHandler(CNSocket* sock, CNPacketData* data); void menuChatHandler(CNSocket* sock, CNPacketData* data); } - -#endif diff --git a/src/ItemManager.hpp b/src/ItemManager.hpp index d6fc634..f87576b 100644 --- a/src/ItemManager.hpp +++ b/src/ItemManager.hpp @@ -1,5 +1,4 @@ -#ifndef _IM_HPP -#define _IM_HPP +#pragma once #include "CNShardServer.hpp" @@ -9,5 +8,3 @@ namespace ItemManager { void itemDeleteHandler(CNSocket* sock, CNPacketData* data); void itemGMGiveHandler(CNSocket* sock, CNPacketData* data); } - -#endif \ No newline at end of file diff --git a/src/NPCManager.hpp b/src/NPCManager.hpp index 8c3e369..b1897b1 100644 --- a/src/NPCManager.hpp +++ b/src/NPCManager.hpp @@ -1,5 +1,4 @@ -#ifndef _NPCMANAGER_HPP -#define _NPCMANAGER_HPP +#pragma once #include "CNProtocol.hpp" #include "PlayerManager.hpp" @@ -20,5 +19,3 @@ namespace NPCManager { void npcWarpManager(CNSocket* sock, CNPacketData* data); } - -#endif diff --git a/src/NanoManager.hpp b/src/NanoManager.hpp index d1f2646..0a28956 100644 --- a/src/NanoManager.hpp +++ b/src/NanoManager.hpp @@ -1,5 +1,4 @@ -#ifndef _NM_HPP -#define _NM_HPP +#pragma once #include "CNShardServer.hpp" @@ -17,5 +16,3 @@ namespace NanoManager { void setNanoSkill(CNSocket* sock, int16_t nanoId, int16_t skillId); void resetNanoSkill(CNSocket* sock, int16_t nanoId); } - -#endif \ No newline at end of file diff --git a/src/PlayerManager.hpp b/src/PlayerManager.hpp index 10fac5b..ae8fcdb 100644 --- a/src/PlayerManager.hpp +++ b/src/PlayerManager.hpp @@ -1,5 +1,4 @@ -#ifndef _PM_HPP -#define _PM_HPP +#pragma once #include "Player.hpp" #include "CNProtocol.hpp" @@ -44,5 +43,3 @@ namespace PlayerManager { void heartbeatPlayer(CNSocket* sock, CNPacketData* data); void exitGame(CNSocket* sock, CNPacketData* data); } - -#endif diff --git a/src/settings.hpp b/src/settings.hpp index 6ab94aa..82c4c75 100644 --- a/src/settings.hpp +++ b/src/settings.hpp @@ -1,5 +1,4 @@ -#ifndef _SETT_HPP -#define _SETT_HPP +#pragma once namespace settings { extern bool VERBOSE; @@ -17,5 +16,3 @@ namespace settings { void init(); } - -#endif