Open main menu
Home
Random
Log in
Settings
About AddOn Studio
Disclaimers
AddOn Studio
Search
Editing
WoW:API PartialPlayTime
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
{{wowapi}} This function is not in any way related to the rested state per character and resting in inns or cities. This function is to limit people from playing the game for too long, acting as a global account API that returns the same value no matter what character you logon. PartialPlayTime(); ---- ;''Arguments'' : none ---- ;''Returns'' : Returns true if you have played more than 3 hours and is in a half-tired state. This is a global account function that affects all characters. Otherwise it returns nil. This function is only working in continents like Asia where you have the rested system enabled, US and EU are not under such limitations. ---- ;''Example'' Based on the official function, changed a bit to output the text in the chat rather than the tooltip on your avatar: if ( PartialPlayTime() ) then DEFAULT_CHAT_FRAME:AddMessage(format(PLAYTIME_TIRED, REQUIRED_REST_HOURS - floor(GetBillingTimeRested()/60))); elseif ( NoPlayTime() ) then DEFAULT_CHAT_FRAME:AddMessage(format(PLAYTIME_UNHEALTHY, REQUIRED_REST_HOURS - floor(GetBillingTimeRested()/60))); else DEFAULT_CHAT_FRAME:AddMessage("You are not limited by PartialPlayTime nor NoPlayTime."); end ;''Related'' Take a look on the [[API NoPlayTime|NoPlayTime]]() API and the [[API GetBillingTimeRested|GetBillingTimeRested]]() API.
Summary:
Please note that all contributions to AddOn Studio are considered to be released under the Creative Commons Attribution-NonCommercial-ShareAlike (see
AddOn Studio Wiki:Copyrights
for details).
Submissions must be written by you, or copied from a public domain or similar free resource (see
AddOn Studio Wiki:Copyrights
for details).
Cancel
Editing help
(opens in new window)
Templates used on this page:
Template:Apinav
(
edit
)
Template:Editlink
(
edit
)
Template:Tocright
(
edit
)
Template:Wowapi
(
edit
)