- Documentation
- Server functions
- textDisplayIsObserver
Function
textDisplayIsObserver
Checks whether a player sees a display.
Syntax
bool textDisplayIsObserver(textdisplay display, player thePlayer)Arguments
displaytextdisplay- The display.
thePlayerplayer- The player.
Returns
true when they see it.
Example
local display = textCreateDisplay()
addCommandHandler("hud", function(player)
if textDisplayIsObserver(display, player) then textDisplayRemoveObserver(display, player)
else textDisplayAddObserver(display, player) end
end)