Squirrel/Server/Functions/Weapons/GetWeaponIDFromName
From Liberty Unleashed Wiki
(Difference between revisions)
m |
|||
Line 1: | Line 1: | ||
− | + | {{Squirrel/Title|GetWeaponIDFromName}} | |
This function returns the ID of the weapon from its name. | This function returns the ID of the weapon from its name. | ||
Latest revision as of 11:15, 11 October 2010
This function returns the ID of the weapon from its name.
[edit] Syntax
int GetWeaponIDFromName( string weaponName )
[edit] Arguments
- weaponName - The name of the weapon
[edit] Example
function onPlayerCommand( player, command, text ) { if ( command == "wepid" ) GetWeaponIDFromName( text ); }
[edit] Notes
This function is used to get the weapon ID of the given text.
[edit] Related Functions
- GetWeaponData
- GetWeaponIDFromName
- GetWeaponName
- SetWeaponData