Difference between revisions of "Player onuse"
From Fortress Forever Wiki
Jump to navigationJump to search (Created page with "This callback is called whenever the player presses the ''USE'' button. ==Usage== <pre> function player_onuse( player ) local MyName = player:GetName() -- Says the p...") |
(No difference)
|
Revision as of 16:10, 30 March 2015
This callback is called whenever the player presses the USE button.
Usage
function player_onuse( player )
local MyName = player:GetName()
-- Says the players name on use.
ChatToPlayer(player, "My Name is "..MyName.."!")
end
Return false to prevent the use from happening.