Quote:
Originally Posted by Lee
Calling a native such as format eliminates the purpose of using string slicing instead of replace().
|
Replace searches, format don't. So it would be less expensive.
In this case the best way would be:
PHP Code:
public get_user_weapon2( id )
{
new szWeapon[20];
get_weaponname(get_user_weapon(id), szWeapon, charsmax(szWeapon));
return szWeapon[7];
}
But i didn't know that
PHP Code:
return szWeapon[7];
was possible
__________________