WoW:API GetBattleFieldInstanceRunTime: Difference between revisions

From AddOn Studio
Jump to navigation Jump to search
(Added description)
 
mNo edit summary
Line 1: Line 1:
{{wowapi}} __NOTOC__
{{wowapi|removed=3.2.0}}


Returns the time in ms since the current battlefield has opened.
Returns the time in ms since the current battlefield has opened.


  battlefieldRunTime = GetBattleFieldInstanceRunTime();
  local battlefieldRunTime = GetBattleFieldInstanceRunTime()


== Parameters ==
== Parameters ==
=== Returns ===
=== Returns ===
* battlefieldRunTime (number) - the time in ms since the current battlefield has opened or zero if you are not in any battleground.


:; battlefieldRunTime
== Details ==
::: Integer - the time in ms since the current battlefield has opened or zero if you are not in any battleground.
; Internal Implementation in WoW Version 3.2.0


== Internal Implementation ==
Whenever you enter a battleground, WoW retrieves the start-time from the server and saves a DWORD-value at 0x1129334 containing the time between system startup of the user and battleground start.
=== WoW Version 3.2.0 ===


Whenever you enter a battleground, WoW retrieves the start-time from the server and saves a DWORD-value at 0x1129334 containing the time between system startup of the user and battleground start.
This function simply gets the time between system startup and now and substracts that saved value from it.  
This function simply gets the time between system startup and now and substracts that saved value from it.  
The windows client calls GetTickCount() to get those times, see: [http://msdn.microsoft.com/en-us/library/ms724408%28VS.85%29.aspx MSDN WinAPI reference]
The windows client calls GetTickCount() to get those times, see: [http://msdn.microsoft.com/en-us/library/ms724408%28VS.85%29.aspx MSDN Windows API reference]
 
== Notes ==
* Removed in patch 3.2.0

Revision as of 21:00, 12 February 2021

WoW API < GetBattleFieldInstanceRunTime

Returns the time in ms since the current battlefield has opened.

local battlefieldRunTime = GetBattleFieldInstanceRunTime()

Parameters

Returns

  • battlefieldRunTime (number) - the time in ms since the current battlefield has opened or zero if you are not in any battleground.

Details

Internal Implementation in WoW Version 3.2.0

Whenever you enter a battleground, WoW retrieves the start-time from the server and saves a DWORD-value at 0x1129334 containing the time between system startup of the user and battleground start.

This function simply gets the time between system startup and now and substracts that saved value from it. The windows client calls GetTickCount() to get those times, see: MSDN Windows API reference

Notes

  • Removed in patch 3.2.0