CanPlayerBeKnockedOffBike: Difference between revisions
Jump to navigation
Jump to search
m (→Example) |
mNo edit summary |
||
| Line 16: | Line 16: | ||
<syntaxhighlight lang="lua">function canBeKnockedOff ( command ) | <syntaxhighlight lang="lua">function canBeKnockedOff ( command ) | ||
-- The player should enter /knockstatus | -- The player should enter /knockstatus | ||
if canPlayerBeKnockedOffBike ( getLocalPlayer() ) then | |||
outputChatBox ( "You can be knocked off your bike." ) | |||
else | |||
outputChatBox ( "You can't be knocked off your bike." ) | |||
end | |||
end | end | ||
addCommandHandler ( "knockstatus", canBeKnockedOff ) | addCommandHandler ( "knockstatus", canBeKnockedOff ) | ||
Revision as of 00:22, 28 March 2008
| This article needs checking. | |
Reason(s): Can someone confirm this? |
This function checks if you can fall of your bike.
Syntax
bool canPlayerBeKnockedOffBike ( player thePlayer )
Required Arguments
- thePlayer: the player whose knockoffstatus being asked
Example
This example puts the knockoff status in the chatbox.
function canBeKnockedOff ( command )
-- The player should enter /knockstatus
if canPlayerBeKnockedOffBike ( getLocalPlayer() ) then
outputChatBox ( "You can be knocked off your bike." )
else
outputChatBox ( "You can't be knocked off your bike." )
end
end
addCommandHandler ( "knockstatus", canBeKnockedOff )
See Also
- getPlayerTeam
- getPlayerBlurLevel
- setPlayerBlurLevel
- getPlayerSerial
- forcePlayerMap
- getPlayerScriptDebugLevel
- getPlayerFromName
- getPlayerMoney
- getPlayerName
- getPlayerNametagColor
- getPlayerNametagText
- getPlayerPing
- getPlayerWantedLevel
- givePlayerMoney
- isPlayerMapForced
- isPlayerNametagShowing
- setPlayerHudComponentVisible
- setPlayerMoney
- setPlayerNametagColor
- setPlayerNametagShowing
- setPlayerNametagText
- takePlayerMoney
- countPlayersInTeam
- getPlayersInTeam
- isVoiceEnabled
- setControlState
- getControlState