Skip to content

Commit

Permalink
Spaces
Browse files Browse the repository at this point in the history
  • Loading branch information
Bara committed Mar 3, 2023
1 parent 6f0e298 commit f09ef02
Show file tree
Hide file tree
Showing 11 changed files with 273 additions and 273 deletions.
12 changes: 6 additions & 6 deletions addons/sourcemod/scripting/SurfTimer.sp
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ public void OnLibraryAdded(const char[] name)
return;
int iOffset = GameConfGetOffset(hGameData, "Teleport");
delete hGameData;

if (iOffset == -1)
return;

Expand Down Expand Up @@ -144,7 +144,7 @@ public void OnLibraryRemoved(const char[] name)
}

public void OnEntityCreated(int entity, const char[] classname) {
if( (classname[0] == 't' || classname[0] == 'l') ? (StrEqual(classname, "trigger_teleport", false) ) : false)
if ( (classname[0] == 't' || classname[0] == 'l') ? (StrEqual(classname, "trigger_teleport", false) ) : false)
{
SDKHook(entity, SDKHook_Use, IgnoreTriggers);
SDKHook(entity, SDKHook_StartTouch, IgnoreTriggers);
Expand Down Expand Up @@ -190,7 +190,7 @@ public void OnMapStart()
/// Start Loading Server Settings
ConVar cvHibernateWhenEmpty = FindConVar("sv_hibernate_when_empty");

if(g_tables_converted)
if (g_tables_converted)
{
if (!g_bRenaming && !g_bInTransactionChain && (IsServerProcessing() || !cvHibernateWhenEmpty.BoolValue))
{
Expand Down Expand Up @@ -599,9 +599,9 @@ public void OnClientDisconnect(int client)
sv_noclipspeed.FloatValue = g_iDefaultNoclipSpeed;

//PRINFO
if(IsValidClient(client) && !IsFakeClient(client)){
for(int zonegroup = 0; zonegroup < MAXZONEGROUPS; zonegroup++){
if(g_fTimeIncrement[client][zonegroup] != 0.0)
if (IsValidClient(client) && !IsFakeClient(client)) {
for(int zonegroup = 0; zonegroup < MAXZONEGROUPS; zonegroup++) {
if (g_fTimeIncrement[client][zonegroup] != 0.0)
g_fTimeinZone[client][zonegroup] += g_fTimeIncrement[client][zonegroup];
db_UpdatePRinfo(client, g_szSteamID[client], zonegroup);
}
Expand Down
14 changes: 7 additions & 7 deletions addons/sourcemod/scripting/surftimer/api.sp
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ public int Native_GetMapData(Handle plugin, int numParams)
SetNativeString(1, szname, sizeof(szname), true);
SetNativeString(2, sztime, sizeof(sztime), true);

if(g_fRecordMapTime >= 0)
if (g_fRecordMapTime >= 0)
time = g_fRecordMapTime;
else
time = -1.0;
Expand All @@ -152,13 +152,13 @@ public int Native_GetBonusData(Handle plugin, int numParams)
Format(szname, sizeof(szname), g_szBonusFastest[zonegroup]);
SetNativeString(2, szname, sizeof(szname), true);

if(g_fBonusFastest[zonegroup] > 0)
if (g_fBonusFastest[zonegroup] > 0)
WRtime = g_fBonusFastest[zonegroup];
else
WRtime = -1.0;
SetNativeCellRef(3, WRtime);

if(g_fPersonalRecordBonus[zonegroup][client] > 0)
if (g_fPersonalRecordBonus[zonegroup][client] > 0)
PBtime = g_fPersonalRecordBonus[zonegroup][client];
else
PBtime = -1.0;
Expand All @@ -181,13 +181,13 @@ public int Native_GetStageData(Handle plugin, int numParams)
Format(szname, sizeof(szname), g_szStageRecordPlayer[stage]);
SetNativeString(2, szname, sizeof(szname), true);

if(g_fStageRecord[stage] != 0.0)
if (g_fStageRecord[stage] != 0.0)
WRtime = g_fStageRecord[stage];
else
WRtime = -1.0;
SetNativeCellRef(3, WRtime);

if(g_fWrcpRecord[client][stage][g_iCurrentStyle[client]] != -1.0)
if (g_fWrcpRecord[client][stage][g_iCurrentStyle[client]] != -1.0)
PBtime = g_fWrcpRecord[client][stage][g_iCurrentStyle[client]];
else
PBtime = -1.0;
Expand Down Expand Up @@ -254,10 +254,10 @@ public int Native_GetClientStyle(Handle plugin, int numParams)
int style;
if (IsValidClient(client))
{
if(!IsFakeClient(client)) {
if (!IsFakeClient(client)) {
style = g_iCurrentStyle[client];
}
else{
else {
if (client == g_RecordBot)
style = g_iSelectedReplayStyle;
else if (client == g_BonusBot)
Expand Down
8 changes: 4 additions & 4 deletions addons/sourcemod/scripting/surftimer/buttonpress.sp
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ public void CL_OnEndTimerPress(int client)
if (style == 0)
{
//ADD LAST TIME TO CP DATA
if(g_bhasStages)
if (g_bhasStages)
g_fCheckpointTimesNew[zGroup][client][g_TotalStages-1] = g_fFinalTime[client];
else
g_fCheckpointTimesNew[zGroup][client][g_iTotalCheckpoints] = g_fFinalTime[client];
Expand Down Expand Up @@ -829,7 +829,7 @@ public void CL_OnStartWrcpTimerPress(int client)
if (!g_bSpectate[client] && !g_bNoClip[client] && ((GetGameTime() - g_fLastTimeNoClipUsed[client]) > 2.0))
{
int zGroup = g_iClientInZone[client][2];
if(zGroup != 0)
if (zGroup != 0)
{
return;
}
Expand Down Expand Up @@ -909,7 +909,7 @@ public void CL_OnStartWrcpTimerPress(int client)
continue;

int ObserverMode = GetEntProp(i, Prop_Send, "m_iObserverMode");
if(ObserverMode != 4 && ObserverMode != 5)
if (ObserverMode != 4 && ObserverMode != 5)
continue;

int ObserverTarget = GetEntPropEnt(i, Prop_Send, "m_hObserverTarget");
Expand Down Expand Up @@ -1044,7 +1044,7 @@ public void CL_OnStartPracSrcpTimerPress(int client)
int zGroup = g_iClientInZone[client][2];


if(zGroup != 0)
if (zGroup != 0)
{
return;
}
Expand Down
Loading

0 comments on commit f09ef02

Please sign in to comment.