Skip to content

Commit

Permalink
optimizations
Browse files Browse the repository at this point in the history
  • Loading branch information
Katsute committed May 4, 2024
1 parent 6583b8d commit 99aedfb
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions Spells.sp
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@

#pragma semicolon 1

#include <sourcemod>
#include <sdktools>
#include <tf2_stocks>

#define TFSPELL_FIREBALL 0
#define TFSPELL_SWARM_OF_BATS 1
Expand Down Expand Up @@ -52,7 +51,7 @@ public Plugin myinfo = {
name = "Spells",
author = "Katsute",
description = "Set spell probabilities",
version = "1.0",
version = "1.1",
url = "https://github.com/KatsuteTF/Spells"
}

Expand Down Expand Up @@ -159,7 +158,7 @@ public void OnEntityCreated(int ent, const char[] classname){
}

public void OnPlayerSpellbookTouch(const char[] output, const int ent, const int client, const float delay2){
if(0 < client <= MaxClients){
if(0 < client <= MaxClients && IsClientInGame(client) && !IsFakeClient(client)){
int sb = GetSpellbook(client);
if(sb != -1 && GetEntProp(sb, Prop_Send,"m_iSpellCharges") == 0){
bool rare = GetEntProp(ent, Prop_Data, "m_nTier") == 1;
Expand Down

0 comments on commit 99aedfb

Please sign in to comment.