mirror of
https://github.com/Jackzmc/sourcemod-plugins.git
synced 2025-05-08 14:53:21 +00:00
Hopefully fix witch crash
This commit is contained in:
parent
8338263ccb
commit
ac1897d5fa
4 changed files with 3 additions and 4 deletions
Binary file not shown.
|
@ -352,11 +352,11 @@ void ApplyTroll(int victim, const char[] name, int activator, trollModifier modi
|
|||
}
|
||||
}
|
||||
|
||||
bool isActive = IsTrollActive(victim, troll.name);
|
||||
bool isActive = Trolls[trollIndex].activeFlagClients[victim] > -1;
|
||||
|
||||
// Toggle on flags for client, if it's not a single run.
|
||||
if(modifier & TrollMod_Constant) {
|
||||
Trolls[troll.id].activeFlagClients[victim] = isActive ? -1 : flags;
|
||||
Trolls[trollIndex].activeFlagClients[victim] = isActive ? -1 : flags;
|
||||
}
|
||||
|
||||
// Applies any custom logic needed for a troll, mostly only used for TrollMod_Instant
|
||||
|
|
|
@ -21,7 +21,7 @@ bool SetWitchTarget(int witch, int target) {
|
|||
#if defined _actions_included
|
||||
g_iWitchAttackVictim = target;
|
||||
BehaviorAction action = ActionsManager.GetAction(witch, "WitchBehavior");
|
||||
if(action == INVALID_ACTION) {
|
||||
if(action == INVALID_ACTION || action.Child == INVALID_ACTION) {
|
||||
return false;
|
||||
}
|
||||
action = action.Child;
|
||||
|
|
|
@ -85,7 +85,6 @@ public void OnPluginStart() {
|
|||
RegAdminCmd("sm_insta", Command_InstaSpecial, ADMFLAG_KICK, "Spawns a special that targets them, close to them.");
|
||||
RegAdminCmd("sm_stagger", Command_Stagger, ADMFLAG_KICK, "Stagger a player");
|
||||
RegAdminCmd("sm_inface", Command_InstaSpecialFace, ADMFLAG_KICK, "Spawns a special that targets them, right in their face.");
|
||||
// TODO: Merge as trolls
|
||||
RegAdminCmd("sm_bots_attack", Command_BotsAttack, ADMFLAG_CHEATS, "Instructs all bots to attack a player until they have X health.");
|
||||
RegAdminCmd("sm_scharge", Command_SmartCharge, ADMFLAG_CHEATS, "Auto Smart charge");
|
||||
RegAdminCmd("sm_healbots", Command_HealTarget, ADMFLAG_CHEATS, "Make bots heal a player");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue