SetPlayerCanBeKnockedOffBike
From Multi Theft Auto: Wiki
This function is deprecated. This means that its use is discouraged and that it might not exist in future versions. | |
Please use setPedCanBeKnockedOffBike instead. |
This function controls if you can fall of your bike by accident - namely by banging into a wall.
Syntax
bool setPlayerCanBeKnockedOffBike ( player thePlayer, bool canBeKnockedOffBike )
Required Arguments
- thePlayer: the player whose knockoffstatus being changed
- state: the true or false state
Example
This example allows the local player to toggle whether or not he can fall of bikes.
function changeCanBeKnockedOff ( command ) -- The player should enter /knock if canPedBeKnockedOffBike ( getLocalPlayer() ) then setPlayerCanBeKnockedOffBike ( getLocalPlayer(), false ) outputChatBox ( "Now you can't be knocked off your bike." ) else setPlayerCanBeKnockedOffBike ( getLocalPlayer(), true ) outputChatBox ( "Now you can be knocked off your bike." ) end end addCommandHandler ( "knock", changeCanBeKnockedOff )
See Also
- forcePlayerMap
- getAlivePlayers
- getDeadPlayers
- getPlayerACInfo
- getPlayerAnnounceValue
- getPlayerBlurLevel
- getPlayerCount
- getPlayerFromName
- getPlayerIdleTime
- getPlayerIP
- getPlayerMoney
- getPlayerName
- getPlayerNametagColor
- getPlayerNametagText
- getPlayerPing
FROM VERSION 1.5.7 r19626 ONWARDS
- getPlayerSerial
- getPlayerTeam
- getPlayerVersion
- getPlayerWantedLevel
- getRandomPlayer
- givePlayerMoney
- isPlayerMapForced
- isPlayerMuted
- isPlayerNametagShowing
- isVoiceEnabled
- redirectPlayer
- resendPlayerACInfo
- resendPlayerModInfo
- setPlayerAnnounceValue
- setPlayerBlurLevel
- setPlayerHudComponentVisible
- setPlayerMoney
- setPlayerMuted
- setPlayerName
- setPlayerNametagColor
- setPlayerNametagShowing
- setPlayerNametagText
FROM VERSION 1.5.7 r19626 ONWARDS
- setPlayerTeam
- setPlayerVoiceBroadcastTo
- setPlayerVoiceIgnoreFrom
- setPlayerWantedLevel
- spawnPlayer
- takePlayerMoney
- takePlayerScreenShot