From 0e681d9bd43fd8d264602bce49c92def78334f2e Mon Sep 17 00:00:00 2001 From: Lukasz Wlasinksi Date: Mon, 25 Oct 2004 11:16:02 +0000 Subject: [PATCH] replaced get_weaponname with xmod_get_wpnname --- plugins/cstrike/miscstats.sma | 5 +++-- plugins/cstrike/stats_logging.sma | 3 +-- plugins/cstrike/statsx.sma | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/plugins/cstrike/miscstats.sma b/plugins/cstrike/miscstats.sma index a5af3c5b..cf83bada 100755 --- a/plugins/cstrike/miscstats.sma +++ b/plugins/cstrike/miscstats.sma @@ -33,6 +33,7 @@ */ #include +#include public MultiKill public MultiKillSound @@ -328,7 +329,7 @@ public client_death(killer,victim,wpnindex,hitplace,TK) { if ( headshot && (HeadShotKill || HeadShotKillSound) ) { if ( HeadShotKill ) { new killer_name[32], victim_name[32], weapon_name[32], message[128], players[32], pnum - get_weaponname(wpnindex,weapon_name,31) + xmod_get_wpnname(wpnindex,weapon_name,31) get_user_name(killer,killer_name,31) get_user_name(victim,victim_name,31) @@ -385,7 +386,7 @@ public showStatus(id) { if (g_friend[id]==1) { // friend new clip, ammo, wpnid = get_user_weapon(pid,clip,ammo) new wpnname[32] - get_weaponname(wpnid,wpnname,31) + xmod_get_wpnname(wpnid,wpnname,31) set_hudmessage(color1,50,color2,-1.0,0.60,1, 0.01, 3.0, 0.01, 0.01, 4) show_hudmessage(id,"%s -- %d HP / %d AP / %s",name, get_user_health(pid),get_user_armor(pid),wpnname) diff --git a/plugins/cstrike/stats_logging.sma b/plugins/cstrike/stats_logging.sma index 7d98d23b..8418eb64 100755 --- a/plugins/cstrike/stats_logging.sma +++ b/plugins/cstrike/stats_logging.sma @@ -54,8 +54,7 @@ public client_disconnect(id) { get_user_authid(id, szAuthid , 31 ) for (new i = 1 ; i < 31 ; ++i ) { if ( get_user_wstats( id , i ,iStats , iHits ) ) { - get_weaponname( i , szWeapon , 23 ) - + xmod_get_wpnname( i , szWeapon , 23 ) log_message("^"%s<%d><%s><%s>^" triggered ^"weaponstats^" (weapon ^"%s^") (shots ^"%d^") (hits ^"%d^") (kills ^"%d^") (headshots ^"%d^") (tks ^"%d^") (damage ^"%d^") (deaths ^"%d^")", szName,iUserid,szAuthid,szTeam,szWeapon,iStats[4],iStats[5],iStats[0], iStats[2],iStats[3],iStats[6],iStats[1]) log_message("^"%s<%d><%s><%s>^" triggered ^"weaponstats2^" (weapon ^"%s^") (head ^"%d^") (chest ^"%d^") (stomach ^"%d^") (leftarm ^"%d^") (rightarm ^"%d^") (leftleg ^"%d^") (rightleg ^"%d^")", diff --git a/plugins/cstrike/statsx.sma b/plugins/cstrike/statsx.sma index 6e9b6ff9..497cbda6 100755 --- a/plugins/cstrike/statsx.sma +++ b/plugins/cstrike/statsx.sma @@ -800,7 +800,7 @@ format_stats( id, sBuffer[MAX_BUFFER_LENGTH+1] ) { lWeapon, lKills, lDeaths, lHits, lShots, lDamage, lAcc ) for ( iWeapon = 1; iWeapon < xmod_get_maxweapons() && MAX_BUFFER_LENGTH - iLen > 0 ; iWeapon++ ) { if ( get_user_wstats( id, iWeapon, izStats, izBody ) ) { - get_weaponname( iWeapon, t_sWpn, MAX_WEAPON_LENGTH ) + xmod_get_wpnname( iWeapon, t_sWpn, MAX_WEAPON_LENGTH ) iLen += format( sBuffer[iLen], MAX_BUFFER_LENGTH - iLen, "%-12.12s %6d %6d %6d %6d %6d %3.0f%%^n", t_sWpn, izStats[STATS_KILLS], izStats[STATS_DEATHS], @@ -999,7 +999,7 @@ public cmdReport( id ) { } new iWeapon, iClip, iAmmo, iHealth, iArmor iWeapon = get_user_weapon( id, iClip, iAmmo ) - get_weaponname( iWeapon, t_sWpn, MAX_WEAPON_LENGTH ) + xmod_get_wpnname( iWeapon, t_sWpn, MAX_WEAPON_LENGTH ) iHealth = get_user_health( id ) iArmor = get_user_armor( id ) new lWeapon[16]