Skip to content

Commit

Permalink
Fixed wrong classname in GetClassWeaponClassname (#167) [M]
Browse files Browse the repository at this point in the history
If the class is heavy, return it to "tf_weapon_fireaxe" instead of
"tf_weapon_fists". I don't know when it changed.
  • Loading branch information
M60TM authored Feb 4, 2024
1 parent cf268c9 commit 8a84e8e
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 18 deletions.
17 changes: 8 additions & 9 deletions addons/sourcemod/scripting/ff2r_default_abilities.sp
Original file line number Diff line number Diff line change
Expand Up @@ -3469,15 +3469,14 @@ void GetClassWeaponClassname(TFClassType class, char[] name, int length)
{
switch(class)
{
case TFClass_Scout: strcopy(name, length, "tf_weapon_bat");
case TFClass_Pyro: strcopy(name, length, "tf_weapon_fireaxe");
case TFClass_DemoMan: strcopy(name, length, "tf_weapon_bottle");
case TFClass_Heavy: strcopy(name, length, "tf_weapon_fists");
case TFClass_Engineer: strcopy(name, length, "tf_weapon_wrench");
case TFClass_Medic: strcopy(name, length, "tf_weapon_bonesaw");
case TFClass_Sniper: strcopy(name, length, "tf_weapon_club");
case TFClass_Spy: strcopy(name, length, "tf_weapon_knife");
default: strcopy(name, length, "tf_weapon_shovel");
case TFClass_Scout: strcopy(name, length, "tf_weapon_bat");
case TFClass_Pyro, TFClass_Heavy: strcopy(name, length, "tf_weapon_fireaxe");
case TFClass_DemoMan: strcopy(name, length, "tf_weapon_bottle");
case TFClass_Engineer: strcopy(name, length, "tf_weapon_wrench");
case TFClass_Medic: strcopy(name, length, "tf_weapon_bonesaw");
case TFClass_Sniper: strcopy(name, length, "tf_weapon_club");
case TFClass_Spy: strcopy(name, length, "tf_weapon_knife");
default: strcopy(name, length, "tf_weapon_shovel");
}
}
else if(StrEqual(name, "tf_weapon_shotgun"))
Expand Down
17 changes: 8 additions & 9 deletions addons/sourcemod/scripting/freak_fortress_2/stocks.sp
Original file line number Diff line number Diff line change
Expand Up @@ -110,15 +110,14 @@ void GetClassWeaponClassname(TFClassType class, char[] name, int length)
{
switch(class)
{
case TFClass_Scout: strcopy(name, length, "tf_weapon_bat");
case TFClass_Pyro: strcopy(name, length, "tf_weapon_fireaxe");
case TFClass_DemoMan: strcopy(name, length, "tf_weapon_bottle");
case TFClass_Heavy: strcopy(name, length, "tf_weapon_fists");
case TFClass_Engineer: strcopy(name, length, "tf_weapon_wrench");
case TFClass_Medic: strcopy(name, length, "tf_weapon_bonesaw");
case TFClass_Sniper: strcopy(name, length, "tf_weapon_club");
case TFClass_Spy: strcopy(name, length, "tf_weapon_knife");
default: strcopy(name, length, "tf_weapon_shovel");
case TFClass_Scout: strcopy(name, length, "tf_weapon_bat");
case TFClass_Pyro, TFClass_Heavy: strcopy(name, length, "tf_weapon_fireaxe");
case TFClass_DemoMan: strcopy(name, length, "tf_weapon_bottle");
case TFClass_Engineer: strcopy(name, length, "tf_weapon_wrench");
case TFClass_Medic: strcopy(name, length, "tf_weapon_bonesaw");
case TFClass_Sniper: strcopy(name, length, "tf_weapon_club");
case TFClass_Spy: strcopy(name, length, "tf_weapon_knife");
default: strcopy(name, length, "tf_weapon_shovel");
}
}
else if(StrEqual(name, "tf_weapon_shotgun"))
Expand Down

0 comments on commit 8a84e8e

Please sign in to comment.