profectus-docs/assets/api_modules_data_projEntry.md.f786acc9.js

1 line
4.9 KiB
JavaScript
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import{_ as e,c as t,o as a,N as r}from"./chunks/framework.0799945b.js";const y=JSON.parse('{"title":"Module: data/projEntry","description":"","frontmatter":{"editLink":false},"headers":[],"relativePath":"api/modules/data/projEntry.md","lastUpdated":null}'),o={name:"api/modules/data/projEntry.md"},n=r('<h1 id="module-data-projentry" tabindex="-1">Module: data/projEntry <a class="header-anchor" href="#module-data-projentry" aria-label="Permalink to &quot;Module: data/projEntry&quot;"></a></h1><h2 id="variables" tabindex="-1">Variables <a class="header-anchor" href="#variables" aria-label="Permalink to &quot;Variables&quot;"></a></h2><h3 id="haswon" tabindex="-1">hasWon <a class="header-anchor" href="#haswon" aria-label="Permalink to &quot;hasWon&quot;"></a></h3><p>• <code>Const</code> <strong>hasWon</strong>: <code>ComputedRef</code>&lt;<code>boolean</code>&gt;</p><p>A computed ref whose value is true whenever the game is over.</p><h4 id="defined-in" tabindex="-1">Defined in <a class="header-anchor" href="#defined-in" aria-label="Permalink to &quot;Defined in&quot;"></a></h4><p><a href="https://github.com/profectus-engine/Profectus/blob/b5e7e77/src/data/projEntry.tsx#L88" target="_blank" rel="noreferrer">profectus/src/data/projEntry.tsx:88</a></p><h2 id="functions" tabindex="-1">Functions <a class="header-anchor" href="#functions" aria-label="Permalink to &quot;Functions&quot;"></a></h2><h3 id="fixoldsave" tabindex="-1">fixOldSave <a class="header-anchor" href="#fixoldsave" aria-label="Permalink to &quot;fixOldSave&quot;"></a></h3><p>▸ <strong>fixOldSave</strong>(<code>oldVersion</code>, <code>player</code>): <code>void</code></p><p>Given a player save data object being loaded with a different version, update the save data object to match the structure of the current version.</p><h5 id="parameters" tabindex="-1">Parameters <a class="header-anchor" href="#parameters" aria-label="Permalink to &quot;Parameters&quot;"></a></h5><table><thead><tr><th style="text-align:left;">Name</th><th style="text-align:left;">Type</th><th style="text-align:left;">Description</th></tr></thead><tbody><tr><td style="text-align:left;"><code>oldVersion</code></td><td style="text-align:left;"><code>undefined</code> | <code>string</code></td><td style="text-align:left;">The version of the save being loaded in</td></tr><tr><td style="text-align:left;"><code>player</code></td><td style="text-align:left;"><a href="https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype" target="_blank" rel="noreferrer"><code>Partial</code></a>&lt;<a href="./../game/player#player"><code>Player</code></a>&gt;</td><td style="text-align:left;">The save data being loaded in</td></tr></tbody></table><h5 id="returns" tabindex="-1">Returns <a class="header-anchor" href="#returns" aria-label="Permalink to &quot;Returns&quot;"></a></h5><p><code>void</code></p><h4 id="defined-in-1" tabindex="-1">Defined in <a class="header-anchor" href="#defined-in-1" aria-label="Permalink to &quot;Defined in&quot;"></a></h4><p><a href="https://github.com/profectus-engine/Profectus/blob/b5e7e77/src/data/projEntry.tsx#L98" target="_blank" rel="noreferrer">profectus/src/data/projEntry.tsx:98</a></p><hr><h3 id="getinitiallayers" tabindex="-1">getInitialLayers <a class="header-anchor" href="#getinitiallayers" aria-label="Permalink to &quot;getInitialLayers&quot;"></a></h3><p>▸ <strong>getInitialLayers</strong>(<code>player</code>): <a href="./../game/layers#genericlayer"><code>GenericLayer</code></a>[]</p><p>Given a player save data object being loaded, return a list of layers that should currently be enabled. If your project does not use dynamic layers, this should just return all layers.</p><h5 id="parameters-1" tabindex="-1">Parameters <a class="header-anchor" href="#parameters-1" aria-label="Permalink to &quot;Parameters&quot;"></a></h5><table><thead><tr><th style="text-align:left;">Name</th><th style="text-align:left;">Type</th></tr></thead><tbody><tr><td style="text-align:left;"><code>player</code></td><td style="text-align:left;"><a href="https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype" target="_blank" rel="noreferrer"><code>Partial</code></a>&lt;<a href="./../game/player#player"><code>Player</code></a>&gt;</td></tr></tbody></table><h5 id="returns-1" tabindex="-1">Returns <a class="header-anchor" href="#returns-1" aria-label="Permalink to &quot;Returns&quot;"></a></h5><p><a href="./../game/layers#genericlayer"><code>GenericLayer</code></a>[]</p><h4 id="defined-in-2" tabindex="-1">Defined in <a class="header-anchor" href="#defined-in-2" aria-label="Permalink to &quot;Defined in&quot;"></a></h4><p><a href="https://github.com/profectus-engine/Profectus/blob/b5e7e77/src/data/projEntry.tsx#L80" target="_blank" rel="noreferrer">profectus/src/data/projEntry.tsx:80</a></p>',27),d=[n];function l(i,s,h,c,p,f){return a(),t("div",null,d)}const b=e(o,[["render",l]]);export{y as __pageData,b as default};