GetPlayerRespawnTime: Difference between revisions
From Onset Developer Wiki
Created page with "{{Info|Function|Server|1.0}} {{FuncDescription|__EDIT_ME__}} {{FuncSyntax|GetPlayerRespawnTime(player)}} {{FuncParameters}} {{FuncParam|player|__EDIT_ME__}} {{FuncReturnVa..." |
No edit summary |
||
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
{{Info|Function|Server|1.0}} | {{Info|Function|Server|1.0}} | ||
{{FuncDescription| | {{FuncDescription|Get the player's respawn time set with [[SetPlayerRespawnTime]].}} | ||
{{FuncSyntax|GetPlayerRespawnTime(player)}} | {{FuncSyntax|GetPlayerRespawnTime(player)}} | ||
{{FuncParameters}} | {{FuncParameters}} | ||
{{FuncParam|player| | {{FuncParam|player|The player identifier.}} | ||
{{FuncReturnValue| | {{FuncReturnValue|Returns the respawn time in milliseconds.}} | ||
== Example == | == Example == | ||
<syntaxhighlight lang="Lua"> | |||
AddCommand("respawntime", function(playerid) | |||
AddPlayerChat(playerid, "Your respawn time is: "..GetPlayerRespawnTime(playerid).." ms.") | |||
end) | |||
</syntaxhighlight> | |||
{{RelatedFunctions}} | {{RelatedFunctions}} | ||
* [[GetPlayerRespawnTime]] | |||
* [[SetPlayerRespawnTime]] |
Latest revision as of 14:14, 19 November 2019
Description
Get the player's respawn time set with SetPlayerRespawnTime.
Syntax
GetPlayerRespawnTime(player)
Parameters
- player
The player identifier.
Return Value
- Returns the respawn time in milliseconds.
Example
AddCommand("respawntime", function(playerid)
AddPlayerChat(playerid, "Your respawn time is: "..GetPlayerRespawnTime(playerid).." ms.")
end)