pokerogue/main/classes/test_utils_mocks_mockClock.MockClock.html
2024-09-28 20:42:37 +00:00

54 lines
37 KiB
HTML

<!DOCTYPE html><html class="default" lang="en"><head><meta charset="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>MockClock | pokemon-rogue-battle</title><meta name="description" content="Documentation for pokemon-rogue-battle"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><div class="table-cell" id="tsd-search" data-base=".."><div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-search"></use></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div><div class="field"><div id="tsd-toolbar-links"></div></div><ul class="results"><li class="state loading">Preparing search index...</li><li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">pokemon-rogue-battle</a></div><div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb"><li><a href="../index.html">pokemon-rogue-battle</a></li><li><a href="../modules/test_utils_mocks_mockClock.html">test/utils/mocks/mockClock</a></li><li><a href="test_utils_mocks_mockClock.MockClock.html">MockClock</a></li></ul><h1>Class MockClock</h1></div><section class="tsd-panel tsd-hierarchy"><h4>Hierarchy</h4><ul class="tsd-hierarchy"><li><span class="tsd-signature-type">Clock</span><ul class="tsd-hierarchy"><li><span class="target">MockClock</span></li></ul></li></ul></section><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/pagefaultgames/pokerogue/blob/a69da4bc06457882e183cacbd00f7de655fec519/src/test/utils/mocks/mockClock.ts#L4">src/test/utils/mocks/mockClock.ts:4</a></li></ul></aside><section class="tsd-panel-group tsd-index-group"><section class="tsd-panel tsd-index-panel"><details class="tsd-index-content tsd-accordion" open><summary class="tsd-accordion-summary tsd-index-summary"><h5 class="tsd-index-heading uppercase" role="button" aria-expanded="false" tabIndex="0"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-chevronSmall"></use></svg> Index</h5></summary><div class="tsd-accordion-details"><section class="tsd-index-section"><h3 class="tsd-index-heading">Constructors</h3><div class="tsd-index-list"><a href="test_utils_mocks_mockClock.MockClock.html#constructor" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-512"></use></svg><span>constructor</span></a>
</div></section><section class="tsd-index-section"><h3 class="tsd-index-heading">Properties</h3><div class="tsd-index-list"><a href="test_utils_mocks_mockClock.MockClock.html#now" class="tsd-index-link tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-1024"></use></svg><span>now</span></a>
<a href="test_utils_mocks_mockClock.MockClock.html#overrideDelay" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-1024"></use></svg><span>override<wbr/>Delay</span></a>
<a href="test_utils_mocks_mockClock.MockClock.html#paused" class="tsd-index-link tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-1024"></use></svg><span>paused</span></a>
<a href="test_utils_mocks_mockClock.MockClock.html#scene" class="tsd-index-link tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-1024"></use></svg><span>scene</span></a>
<a href="test_utils_mocks_mockClock.MockClock.html#startTime" class="tsd-index-link tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-1024"></use></svg><span>start<wbr/>Time</span></a>
<a href="test_utils_mocks_mockClock.MockClock.html#systems" class="tsd-index-link tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-1024"></use></svg><span>systems</span></a>
<a href="test_utils_mocks_mockClock.MockClock.html#timeScale" class="tsd-index-link tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-1024"></use></svg><span>time<wbr/>Scale</span></a>
</div></section><section class="tsd-index-section"><h3 class="tsd-index-heading">Methods</h3><div class="tsd-index-list"><a href="test_utils_mocks_mockClock.MockClock.html#addEvent" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-2048"></use></svg><span>add<wbr/>Event</span></a>
<a href="test_utils_mocks_mockClock.MockClock.html#clearPendingEvents" class="tsd-index-link tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-2048"></use></svg><span>clear<wbr/>Pending<wbr/>Events</span></a>
<a href="test_utils_mocks_mockClock.MockClock.html#delayedCall" class="tsd-index-link tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delayed<wbr/>Call</span></a>
<a href="test_utils_mocks_mockClock.MockClock.html#preUpdate" class="tsd-index-link tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-2048"></use></svg><span>pre<wbr/>Update</span></a>
<a href="test_utils_mocks_mockClock.MockClock.html#removeAllEvents" class="tsd-index-link tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-2048"></use></svg><span>remove<wbr/>All<wbr/>Events</span></a>
<a href="test_utils_mocks_mockClock.MockClock.html#removeEvent" class="tsd-index-link tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-2048"></use></svg><span>remove<wbr/>Event</span></a>
<a href="test_utils_mocks_mockClock.MockClock.html#update" class="tsd-index-link tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-2048"></use></svg><span>update</span></a>
</div></section></div></details></section></section><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Constructors"><h2><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="../assets/icons.svg#icon-chevronDown"></use></svg> Constructors</h2></summary><section><section class="tsd-panel tsd-member"><a id="constructor" class="tsd-anchor"></a><h3 class="tsd-anchor-link"><span>constructor</span><a href="#constructor" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class="tsd-signature tsd-anchor-link"><a id="constructor.new_MockClock" class="tsd-anchor"></a><span class="tsd-kind-constructor-signature">new <wbr/>Mock<wbr/>Clock</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">scene</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="test_utils_mocks_mockClock.MockClock.html" class="tsd-signature-type tsd-kind-class">MockClock</a><a href="#constructor.new_MockClock" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></li><li class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">scene</span>: <span class="tsd-signature-type">any</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <a href="test_utils_mocks_mockClock.MockClock.html" class="tsd-signature-type tsd-kind-class">MockClock</a></h4><aside class="tsd-sources"><p>Overrides Clock.constructor</p><ul><li>Defined in <a href="https://github.com/pagefaultgames/pokerogue/blob/a69da4bc06457882e183cacbd00f7de655fec519/src/test/utils/mocks/mockClock.ts#L6">src/test/utils/mocks/mockClock.ts:6</a></li></ul></aside></li></ul></section></section></details><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Properties"><h2><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="../assets/icons.svg#icon-chevronDown"></use></svg> Properties</h2></summary><section><section class="tsd-panel tsd-member tsd-is-inherited tsd-is-external"><a id="now" class="tsd-anchor"></a><h3 class="tsd-anchor-link"><span>now</span><a href="#now" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">now</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span></div><div class="tsd-comment tsd-typography"><p>The current time of the Clock, in milliseconds.</p>
<p>If accessed externally, this is equivalent to the <code>time</code> parameter normally passed to a Scene's <code>update</code> method.</p>
</div><div class="tsd-comment tsd-typography"></div><aside class="tsd-sources"><p>Inherited from Clock.now</p><ul><li>Defined in node_modules/phaser/types/phaser.d.ts:111451</li></ul></aside></section><section class="tsd-panel tsd-member"><a id="overrideDelay" class="tsd-anchor"></a><h3 class="tsd-anchor-link"><span>override<wbr/>Delay</span><a href="#overrideDelay" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">override<wbr/>Delay</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> = 1</span></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/pagefaultgames/pokerogue/blob/a69da4bc06457882e183cacbd00f7de655fec519/src/test/utils/mocks/mockClock.ts#L5">src/test/utils/mocks/mockClock.ts:5</a></li></ul></aside></section><section class="tsd-panel tsd-member tsd-is-inherited tsd-is-external"><a id="paused" class="tsd-anchor"></a><h3 class="tsd-anchor-link"><span>paused</span><a href="#paused" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">paused</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span></div><div class="tsd-comment tsd-typography"><p>Whether the Clock is paused (<code>true</code>) or active (<code>false</code>).</p>
<p>When paused, the Clock will not update any of its Timer Events, thus freezing time.</p>
</div><div class="tsd-comment tsd-typography"></div><aside class="tsd-sources"><p>Inherited from Clock.paused</p><ul><li>Defined in node_modules/phaser/types/phaser.d.ts:111472</li></ul></aside></section><section class="tsd-panel tsd-member tsd-is-inherited tsd-is-external"><a id="scene" class="tsd-anchor"></a><h3 class="tsd-anchor-link"><span>scene</span><a href="#scene" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">scene</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Scene</span></div><div class="tsd-comment tsd-typography"><p>The Scene which owns this Clock.</p>
</div><div class="tsd-comment tsd-typography"></div><aside class="tsd-sources"><p>Inherited from Clock.scene</p><ul><li>Defined in node_modules/phaser/types/phaser.d.ts:111439</li></ul></aside></section><section class="tsd-panel tsd-member tsd-is-inherited tsd-is-external"><a id="startTime" class="tsd-anchor"></a><h3 class="tsd-anchor-link"><span>start<wbr/>Time</span><a href="#startTime" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">start<wbr/>Time</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span></div><div class="tsd-comment tsd-typography"><p>The time the Clock (and Scene) started, in milliseconds.</p>
<p>This can be compared to the <code>time</code> parameter passed to a Scene's <code>update</code> method.</p>
</div><div class="tsd-comment tsd-typography"></div><aside class="tsd-sources"><p>Inherited from Clock.startTime</p><ul><li>Defined in node_modules/phaser/types/phaser.d.ts:111458</li></ul></aside></section><section class="tsd-panel tsd-member tsd-is-inherited tsd-is-external"><a id="systems" class="tsd-anchor"></a><h3 class="tsd-anchor-link"><span>systems</span><a href="#systems" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">systems</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Systems</span></div><div class="tsd-comment tsd-typography"><p>The Scene Systems object of the Scene which owns this Clock.</p>
</div><div class="tsd-comment tsd-typography"></div><aside class="tsd-sources"><p>Inherited from Clock.systems</p><ul><li>Defined in node_modules/phaser/types/phaser.d.ts:111444</li></ul></aside></section><section class="tsd-panel tsd-member tsd-is-inherited tsd-is-external"><a id="timeScale" class="tsd-anchor"></a><h3 class="tsd-anchor-link"><span>time<wbr/>Scale</span><a href="#timeScale" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">time<wbr/>Scale</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span></div><div class="tsd-comment tsd-typography"><p>The scale of the Clock's time delta.</p>
<p>The time delta is the time elapsed between two consecutive frames and influences the speed of time for this Clock and anything which uses it, such as its Timer Events. Values higher than 1 increase the speed of time, while values smaller than 1 decrease it. A value of 0 freezes time and is effectively equivalent to pausing the Clock.</p>
</div><div class="tsd-comment tsd-typography"></div><aside class="tsd-sources"><p>Inherited from Clock.timeScale</p><ul><li>Defined in node_modules/phaser/types/phaser.d.ts:111465</li></ul></aside></section></section></details><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Methods"><h2><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="../assets/icons.svg#icon-chevronDown"></use></svg> Methods</h2></summary><section><section class="tsd-panel tsd-member"><a id="addEvent" class="tsd-anchor"></a><h3 class="tsd-anchor-link"><span>add<wbr/>Event</span><a href="#addEvent" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class="tsd-signature tsd-anchor-link"><a id="addEvent.addEvent-1" class="tsd-anchor"></a><span class="tsd-kind-call-signature">add<wbr/>Event</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">config</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">TimerEvent</span><a href="#addEvent.addEvent-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></li><li class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates a Timer Event and adds it to this Clock at the start of the next frame.</p>
<p>You can pass in either a <code>TimerEventConfig</code> object, from with a new <code>TimerEvent</code> will
be created, or you can pass in a <code>TimerEvent</code> instance.</p>
<p>If passing an instance please make sure that this instance hasn't been used before.
If it has ever entered a 'completed' state then it will no longer be suitable to
run again.</p>
<p>Also, if the <code>TimerEvent</code> instance is being used by <em>another</em> Clock (in another Scene)
it will still be updated by that Clock as well, so be careful when using this feature.</p>
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">config</span>: <span class="tsd-signature-type">TimerEventConfig</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">TimerEvent</span></span><div class="tsd-comment tsd-typography"><p>The configuration for the Timer Event, or an existing Timer Event object.</p>
</div><div class="tsd-comment tsd-typography"></div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">TimerEvent</span></h4><div class="tsd-comment tsd-typography"></div><aside class="tsd-sources"><p>Overrides Clock.addEvent</p><ul><li>Defined in <a href="https://github.com/pagefaultgames/pokerogue/blob/a69da4bc06457882e183cacbd00f7de655fec519/src/test/utils/mocks/mockClock.ts#L19">src/test/utils/mocks/mockClock.ts:19</a></li></ul></aside></li></ul></section><section class="tsd-panel tsd-member tsd-is-inherited tsd-is-external"><a id="clearPendingEvents" class="tsd-anchor"></a><h3 class="tsd-anchor-link"><span>clear<wbr/>Pending<wbr/>Events</span><a href="#clearPendingEvents" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures tsd-is-inherited tsd-is-external"><li class="tsd-signature tsd-anchor-link"><a id="clearPendingEvents.clearPendingEvents-1" class="tsd-anchor"></a><span class="tsd-kind-call-signature">clear<wbr/>Pending<wbr/>Events</span><span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">this</span><a href="#clearPendingEvents.clearPendingEvents-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></li><li class="tsd-description"><div class="tsd-comment tsd-typography"><p>Clears and recreates the array of pending Timer Events.</p>
</div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">this</span></h4><div class="tsd-comment tsd-typography"></div><aside class="tsd-sources"><p>Inherited from Clock.clearPendingEvents</p><ul><li>Defined in node_modules/phaser/types/phaser.d.ts:111504</li></ul></aside></li></ul></section><section class="tsd-panel tsd-member tsd-is-inherited tsd-is-external"><a id="delayedCall" class="tsd-anchor"></a><h3 class="tsd-anchor-link"><span>delayed<wbr/>Call</span><a href="#delayedCall" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures tsd-is-inherited tsd-is-external"><li class="tsd-signature tsd-anchor-link"><a id="delayedCall.delayedCall-1" class="tsd-anchor"></a><span class="tsd-kind-call-signature">delayed<wbr/>Call</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">delay</span>, <span class="tsd-kind-parameter">callback</span>, <span class="tsd-kind-parameter">args</span><span class="tsd-signature-symbol">?</span>, <span class="tsd-kind-parameter">callbackScope</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">TimerEvent</span><a href="#delayedCall.delayedCall-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></li><li class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates a Timer Event and adds it to the Clock at the start of the frame.</p>
<p>This is a shortcut for #addEvent which can be shorter and is compatible with the syntax of the GreenSock Animation Platform (GSAP).</p>
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">delay</span>: <span class="tsd-signature-type">number</span></span><div class="tsd-comment tsd-typography"><p>The delay of the function call, in milliseconds.</p>
</div><div class="tsd-comment tsd-typography"></div></li><li><span><span class="tsd-kind-parameter">callback</span>: <span class="tsd-signature-type">Function</span></span><div class="tsd-comment tsd-typography"><p>The function to call after the delay expires.</p>
</div><div class="tsd-comment tsd-typography"></div></li><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">args</span>: <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>The arguments to call the function with.</p>
</div><div class="tsd-comment tsd-typography"></div></li><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">callbackScope</span>: <span class="tsd-signature-type">any</span></span><div class="tsd-comment tsd-typography"><p>The scope (<code>this</code> object) to call the function with.</p>
</div><div class="tsd-comment tsd-typography"></div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">TimerEvent</span></h4><div class="tsd-comment tsd-typography"></div><aside class="tsd-sources"><p>Inherited from Clock.delayedCall</p><ul><li>Defined in node_modules/phaser/types/phaser.d.ts:111499</li></ul></aside></li></ul></section><section class="tsd-panel tsd-member tsd-is-inherited tsd-is-external"><a id="preUpdate" class="tsd-anchor"></a><h3 class="tsd-anchor-link"><span>pre<wbr/>Update</span><a href="#preUpdate" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures tsd-is-inherited tsd-is-external"><li class="tsd-signature tsd-anchor-link"><a id="preUpdate.preUpdate-1" class="tsd-anchor"></a><span class="tsd-kind-call-signature">pre<wbr/>Update</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">time</span>, <span class="tsd-kind-parameter">delta</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span><a href="#preUpdate.preUpdate-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></li><li class="tsd-description"><div class="tsd-comment tsd-typography"><p>Updates the arrays of active and pending Timer Events. Called at the start of the frame.</p>
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">time</span>: <span class="tsd-signature-type">number</span></span><div class="tsd-comment tsd-typography"><p>The current time. Either a High Resolution Timer value if it comes from Request Animation Frame, or Date.now if using SetTimeout.</p>
</div><div class="tsd-comment tsd-typography"></div></li><li><span><span class="tsd-kind-parameter">delta</span>: <span class="tsd-signature-type">number</span></span><div class="tsd-comment tsd-typography"><p>The delta time in ms since the last frame. This is a smoothed and capped value based on the FPS rate.</p>
</div><div class="tsd-comment tsd-typography"></div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><div class="tsd-comment tsd-typography"></div><aside class="tsd-sources"><p>Inherited from Clock.preUpdate</p><ul><li>Defined in node_modules/phaser/types/phaser.d.ts:111525</li></ul></aside></li></ul></section><section class="tsd-panel tsd-member tsd-is-inherited tsd-is-external"><a id="removeAllEvents" class="tsd-anchor"></a><h3 class="tsd-anchor-link"><span>remove<wbr/>All<wbr/>Events</span><a href="#removeAllEvents" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures tsd-is-inherited tsd-is-external"><li class="tsd-signature tsd-anchor-link"><a id="removeAllEvents.removeAllEvents-1" class="tsd-anchor"></a><span class="tsd-kind-call-signature">remove<wbr/>All<wbr/>Events</span><span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">this</span><a href="#removeAllEvents.removeAllEvents-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></li><li class="tsd-description"><div class="tsd-comment tsd-typography"><p>Schedules all active Timer Events for removal at the start of the frame.</p>
</div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">this</span></h4><div class="tsd-comment tsd-typography"></div><aside class="tsd-sources"><p>Inherited from Clock.removeAllEvents</p><ul><li>Defined in node_modules/phaser/types/phaser.d.ts:111518</li></ul></aside></li></ul></section><section class="tsd-panel tsd-member tsd-is-inherited tsd-is-external"><a id="removeEvent" class="tsd-anchor"></a><h3 class="tsd-anchor-link"><span>remove<wbr/>Event</span><a href="#removeEvent" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures tsd-is-inherited tsd-is-external"><li class="tsd-signature tsd-anchor-link"><a id="removeEvent.removeEvent-1" class="tsd-anchor"></a><span class="tsd-kind-call-signature">remove<wbr/>Event</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">events</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">this</span><a href="#removeEvent.removeEvent-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></li><li class="tsd-description"><div class="tsd-comment tsd-typography"><p>Removes the given Timer Event, or an array of Timer Events, from this Clock.</p>
<p>The events are removed from all internal lists (active, pending and removal),
freeing the event up to be re-used.</p>
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">events</span>: <span class="tsd-signature-type">TimerEvent</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">TimerEvent</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>The Timer Event, or an array of Timer Events, to remove from this Clock.</p>
</div><div class="tsd-comment tsd-typography"></div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">this</span></h4><div class="tsd-comment tsd-typography"></div><aside class="tsd-sources"><p>Inherited from Clock.removeEvent</p><ul><li>Defined in node_modules/phaser/types/phaser.d.ts:111513</li></ul></aside></li></ul></section><section class="tsd-panel tsd-member tsd-is-inherited tsd-is-external"><a id="update" class="tsd-anchor"></a><h3 class="tsd-anchor-link"><span>update</span><a href="#update" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures tsd-is-inherited tsd-is-external"><li class="tsd-signature tsd-anchor-link"><a id="update.update-1" class="tsd-anchor"></a><span class="tsd-kind-call-signature">update</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">time</span>, <span class="tsd-kind-parameter">delta</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span><a href="#update.update-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></li><li class="tsd-description"><div class="tsd-comment tsd-typography"><p>Updates the Clock's internal time and all of its Timer Events.</p>
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">time</span>: <span class="tsd-signature-type">number</span></span><div class="tsd-comment tsd-typography"><p>The current time. Either a High Resolution Timer value if it comes from Request Animation Frame, or Date.now if using SetTimeout.</p>
</div><div class="tsd-comment tsd-typography"></div></li><li><span><span class="tsd-kind-parameter">delta</span>: <span class="tsd-signature-type">number</span></span><div class="tsd-comment tsd-typography"><p>The delta time in ms since the last frame. This is a smoothed and capped value based on the FPS rate.</p>
</div><div class="tsd-comment tsd-typography"></div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><div class="tsd-comment tsd-typography"></div><aside class="tsd-sources"><p>Inherited from Clock.update</p><ul><li>Defined in node_modules/phaser/types/phaser.d.ts:111532</li></ul></aside></li></ul></section></section></details></div><div class="col-sidebar"><div class="page-menu"><div class="tsd-navigation settings"><details class="tsd-accordion"><summary class="tsd-accordion-summary"><h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Settings</h3></summary><div class="tsd-accordion-details"><div class="tsd-filter-visibility"><span class="settings-label">Member Visibility</span><ul id="tsd-filter-options"><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-protected" name="protected"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Protected</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-external" name="external"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>External</span></label></li></ul></div><div class="tsd-theme-toggle"><label class="settings-label" for="tsd-theme">Theme</label><select id="tsd-theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div><details open class="tsd-accordion tsd-page-navigation"><summary class="tsd-accordion-summary"><h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>On This Page</h3></summary><div class="tsd-accordion-details"><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="tsd-otp-Constructors"><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Constructors</summary><div><a href="#constructor" class=""><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-512"></use></svg><span>constructor</span></a></div></details><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="tsd-otp-Properties"><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Properties</summary><div><a href="#now" class="tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-1024"></use></svg><span>now</span></a><a href="#overrideDelay" class=""><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-1024"></use></svg><span>override<wbr/>Delay</span></a><a href="#paused" class="tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-1024"></use></svg><span>paused</span></a><a href="#scene" class="tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-1024"></use></svg><span>scene</span></a><a href="#startTime" class="tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-1024"></use></svg><span>start<wbr/>Time</span></a><a href="#systems" class="tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-1024"></use></svg><span>systems</span></a><a href="#timeScale" class="tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-1024"></use></svg><span>time<wbr/>Scale</span></a></div></details><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="tsd-otp-Methods"><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Methods</summary><div><a href="#addEvent" class=""><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-2048"></use></svg><span>add<wbr/>Event</span></a><a href="#clearPendingEvents" class="tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-2048"></use></svg><span>clear<wbr/>Pending<wbr/>Events</span></a><a href="#delayedCall" class="tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delayed<wbr/>Call</span></a><a href="#preUpdate" class="tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-2048"></use></svg><span>pre<wbr/>Update</span></a><a href="#removeAllEvents" class="tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-2048"></use></svg><span>remove<wbr/>All<wbr/>Events</span></a><a href="#removeEvent" class="tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-2048"></use></svg><span>remove<wbr/>Event</span></a><a href="#update" class="tsd-is-inherited tsd-is-external"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-2048"></use></svg><span>update</span></a></div></details></div></details></div><div class="site-menu"><nav class="tsd-navigation"><a href="../index.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-1"></use></svg><span>pokemon-rogue-battle</span></a><ul class="tsd-small-nested-navigation" id="tsd-nav-container" data-base=".."><li>Loading...</li></ul></nav></div></div></div><footer><p class="tsd-generator">Generated using <a href="https://typedoc.org/" target="_blank">TypeDoc</a></p></footer><div class="overlay"></div></body></html>