TakeAllWeapons: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
No edit summary |
||
Line 3: | Line 3: | ||
==Syntax== | ==Syntax== | ||
<syntaxhighlight lang="lua"> | <syntaxhighlight lang="lua">takeAllWeapons ( thePlayer )</syntaxhighlight> | ||
===Required Arguments=== | ===Required Arguments=== | ||
Line 13: | Line 13: | ||
==Example== | ==Example== | ||
<syntaxhighlight lang="lua">player = getPlayerFromID ( 1 ) | <syntaxhighlight lang="lua">player = getPlayerFromID ( 1 ) | ||
takeAllWeapons ( player ) | |||
outputChatBox ( "All weapons removed from ", getPlayerName ( player ), "." )</syntaxhighlight> | outputChatBox ( "All weapons removed from ", getPlayerName ( player ), "." )</syntaxhighlight> | ||
==See Also== | ==See Also== | ||
{{Weapon functions}} | {{Weapon functions}} |
Revision as of 11:27, 14 August 2006
This function removes every weapons from a specified player, rendering him unarmed.
Syntax
takeAllWeapons ( thePlayer )
Required Arguments
- thePlayer: A player object referencing the specified player
Returns
Returns true if the function succeeded, false otherwise.
Example
player = getPlayerFromID ( 1 ) takeAllWeapons ( player ) outputChatBox ( "All weapons removed from ", getPlayerName ( player ), "." )
See Also
- getWeaponProperty
- getPickupWeapon
- getOriginalWeaponProperty
- getSlotFromWeapon
- getWeaponIDFromName
- getWeaponNameFromID
- setWeaponAmmo
- setWeaponProperty