From a1a150db9fed4356474c8c2bfe6f08c8f781d83d Mon Sep 17 00:00:00 2001 From: zaCade Date: Sun, 24 Feb 2019 11:34:17 +0100 Subject: [PATCH] RevEmuAPI: Fix formatting --- configure.py | 2 +- extension.cpp | 6 +++--- include/RevEmuAPI.inc | 28 ++++++++++++++-------------- revemu.h | 12 ++++++------ 4 files changed, 24 insertions(+), 24 deletions(-) diff --git a/configure.py b/configure.py index 57910e8..3d07dc1 100644 --- a/configure.py +++ b/configure.py @@ -7,7 +7,7 @@ from ambuild2 import run builder = run.PrepareBuild(sourcePath = sys.path[0]) builder.options.add_option('--hl2sdk-root', type=str, dest='hl2sdk_root', default=None, - help='Root search folder for HL2SDKs') + help='Root search folder for HL2SDKs') builder.options.add_option('--mms-path', type=str, dest='mms_path', default=None, help='Path to Metamod:Source') builder.options.add_option('--sm-path', type=str, dest='sm_path', default=None, diff --git a/extension.cpp b/extension.cpp index 1d11af6..3681668 100644 --- a/extension.cpp +++ b/extension.cpp @@ -37,7 +37,7 @@ * @brief Implement extension code here. */ -RevEmuAPI g_RevEmuAPI; /**< Global singleton for extension's main interface */ +RevEmuAPI g_RevEmuAPI; /**< Global singleton for extension's main interface */ SMEXT_LINK(&g_RevEmuAPI); @@ -68,7 +68,7 @@ static cell_t IsPlayerSteam(IPluginContext *pContext, const cell_t *params) { if (!Rev_BGetPlayerInfoByUserID(pPlayer->GetUserId(), &PlayerInfo)) { - PlayerInfo.m_ePlayerType = k_eUnknown; + PlayerInfo.m_ePlayerType = k_eInvalid; } } @@ -99,7 +99,7 @@ static cell_t GetPlayerType(IPluginContext *pContext, const cell_t *params) { if (!Rev_BGetPlayerInfoByUserID(pPlayer->GetUserId(), &PlayerInfo)) { - PlayerInfo.m_ePlayerType = k_eUnknown; + PlayerInfo.m_ePlayerType = k_eInvalid; } } diff --git a/include/RevEmuAPI.inc b/include/RevEmuAPI.inc index 22f40e8..7af822e 100644 --- a/include/RevEmuAPI.inc +++ b/include/RevEmuAPI.inc @@ -3,8 +3,8 @@ enum RevEmu_UserType { - Unknown = -1, - SteamLegitUser = 0, + Invalid = -1, + SteamLegitUser = 0, SteamCrackedUser, RevEmuUser, RevEmuUserOld, @@ -19,9 +19,9 @@ enum RevEmu_UserType /** * Check if clients usertype is legit. * - * @param clients The client index. + * @param clients The client index. * - * @return True if valid, false otherwise. + * @return True if valid, false otherwise. * @error Invalid client index, not connected or fake client. */ native bool RevEmu_IsPlayerSteam(int client); @@ -29,9 +29,9 @@ native bool RevEmu_IsPlayerSteam(int client); /** * Retrieve clients usertype. * - * @param clients The client index. + * @param clients The client index. * - * @return The clients usertype. + * @return The clients usertype. * @error Invalid client index, not connected or fake client. */ native RevEmu_UserType RevEmu_GetPlayerType(int client); @@ -39,25 +39,25 @@ native RevEmu_UserType RevEmu_GetPlayerType(int client); public Extension __ext_RevEmuAPI = { - name = "RevEmuAPI", - file = "RevEmuAPI.ext", + name = "RevEmuAPI", + file = "RevEmuAPI.ext", #if defined AUTOLOAD_EXTENSIONS - autoload = 1, + autoload = 1, #else - autoload = 0, + autoload = 0, #endif #if defined REQUIRE_EXTENSIONS - required = 1, + required = 1, #else - required = 0, + required = 0, #endif }; #if !defined REQUIRE_EXTENSIONS public __ext_RevEmuAPI_SetNTVOptional() { - MarkNativeAsOptional("RevEmu_IsPlayerSteam"); - MarkNativeAsOptional("RevEmu_GetPlayerType"); + MarkNativeAsOptional("RevEmu_IsPlayerSteam"); + MarkNativeAsOptional("RevEmu_GetPlayerType"); } #endif diff --git a/revemu.h b/revemu.h index d715b77..6e2a293 100644 --- a/revemu.h +++ b/revemu.h @@ -5,8 +5,8 @@ typedef uint64_t CSteamID; enum EUserType { - k_eUnknown = -1, - k_eSteamLegitUser = 0, + k_eInvalid = -1, + k_eSteamLegitUser = 0, k_eSteamCrackedUser, k_eRevEmuUser, k_eRevEmuUserOld, @@ -20,10 +20,10 @@ enum EUserType struct PlayerInfo_t { - unsigned int m_unUserID; - CSteamID m_steamIDPlayer; - EUserType m_ePlayerType; - unsigned int m_unIP; + unsigned int m_unUserID; + CSteamID m_steamIDPlayer; + EUserType m_ePlayerType; + unsigned int m_unIP; }; typedef bool (*pRev_BGetPlayerInfoByUserID) ( unsigned int unUserID, PlayerInfo_t* pPlayerInfo );