SetPlayerScriptDebugLevel: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
Fernando187 (talk | contribs) (Remove obsolete Requirements section) |
||
(2 intermediate revisions by 2 users not shown) | |||
Line 31: | Line 31: | ||
</syntaxhighlight> | </syntaxhighlight> | ||
</section> | </section> | ||
==See Also== | ==See Also== | ||
<!-- Change FunctionArea to the area that this function is in on the main function list page, e.g. Server, Player, Vehicle etc --> | <!-- Change FunctionArea to the area that this function is in on the main function list page, e.g. Server, Player, Vehicle etc --> | ||
{{ | {{Player functions|server}} |
Latest revision as of 17:18, 7 November 2024
This will set player's debug level, equivalent to debugscript <level>.
Syntax
bool setPlayerScriptDebugLevel ( player thePlayer, int level )
OOP Syntax Help! I don't understand this!
- Method: player:setScriptDebugLevel(...)
- Variable: .scriptDebugLevel
- Counterpart: getPlayerScriptDebugLevel
Required Arguments
- thePlayer: The player whose debug level you wish to change
- level: 0: close debug console, 1: only errors, 2: errors and warnings, 3: errors, warnings and info messages
Returns
Returns true if successful, false otherwise.
Example
Click to collapse [-]
ServerThis code will set joining players debug level to (3), (It is no recommended to use it in production, specially if you have sensitive data in your logs).
function setPlayerDebug (player) setPlayerScriptDebugLevel(player, 3) outputChatBox("You set debug script level to 3", player) end addCommandHandler("setdebug", setPlayerDebug)
See Also
- getAlivePlayers
- getDeadPlayers
- getPlayerACInfo
- getPlayerAnnounceValue
- getPlayerCount
- getPlayerIdleTime
- getPlayerIP
- getPlayerVersion
- getRandomPlayer
- isPlayerMuted
- redirectPlayer
- resendPlayerACInfo
- resendPlayerModInfo
- setPlayerAnnounceValue
- setPlayerMuted
- setPlayerScriptDebugLevel
- setPlayerTeam
- setPlayerVoiceBroadcastTo
- setPlayerVoiceIgnoreFrom
- setPlayerWantedLevel
- spawnPlayer
- takePlayerScreenShot
- Shared
- 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