OnPickupUse: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
No edit summary |
||
Line 2: | Line 2: | ||
__NOTOC__ | __NOTOC__ | ||
This event is | This event is triggered when a player stands on a pickup while not in a vehicle. | ||
==Syntax== | ==Syntax== | ||
<syntaxhighlight lang="lua"> | <syntaxhighlight lang="lua"> | ||
onPickupUse ( player player ) | |||
</syntaxhighlight> | </syntaxhighlight> | ||
==Example== | ==Example== | ||
<syntaxhighlight lang="lua"> | <syntaxhighlight lang="lua"> | ||
addEventHandler ( "onPickupUse", getRootElement(), "pickupUse" ) | |||
function pickupUse ( thePlayer ) | |||
outputChatBox ( getClientName ( thePlayer ) .. " picked up a pickup!" ) | |||
end | |||
</syntaxhighlight> | </syntaxhighlight> |
Revision as of 11:06, 11 September 2006
This event is triggered when a player stands on a pickup while not in a vehicle.
Syntax
onPickupUse ( player player )
Example
addEventHandler ( "onPickupUse", getRootElement(), "pickupUse" ) function pickupUse ( thePlayer ) outputChatBox ( getClientName ( thePlayer ) .. " picked up a pickup!" ) end