-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Deploying to gh-pages from @ 91aba31 🚀
- Loading branch information
1 parent
1d7402a
commit bf514b7
Showing
13 changed files
with
536 additions
and
51 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
|
||
{"items":[{"name":"Introduction","href":"quickstart/introduction.html","topicHref":"quickstart/introduction.html","topicUid":"Guides.Introduction"},{"name":"Getting Started","href":"quickstart/getting-started.html","topicHref":"quickstart/getting-started.html","topicUid":"Guides.GettingStarted"}]} | ||
{"items":[{"name":"Quick Start","href":"quickstart/index.html","topicHref":"quickstart/index.html","items":[{"name":"Introduction","href":"quickstart/index.html","topicHref":"quickstart/index.html"},{"name":"Getting Started","href":"quickstart/getting-started.html","topicHref":"quickstart/getting-started.html"}]},{"name":"Tutorials","href":"tutorials/index.html","topicHref":"tutorials/index.html","items":[{"name":"Introduction","href":"tutorials/index.html","topicHref":"tutorials/index.html"},{"name":"Options","href":"tutorials/options.html","topicHref":"tutorials/options.html"},{"name":"State","href":"tutorials/state.html","topicHref":"tutorials/state.html"}]}]} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,118 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<meta charset="utf-8"> | ||
<title>Introduction | ConfigurableWarning Docs </title> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | ||
<meta name="title" content="Introduction | ConfigurableWarning Docs "> | ||
|
||
|
||
<link rel="icon" href="../../favicon.ico"> | ||
<link rel="stylesheet" href="../../public/docfx.min.css"> | ||
<link rel="stylesheet" href="../../public/main.css"> | ||
<meta name="docfx:navrel" content="../../toc.html"> | ||
<meta name="docfx:tocrel" content="../toc.html"> | ||
|
||
<meta name="docfx:rel" content="../../"> | ||
|
||
|
||
<meta name="docfx:docurl" content="https://github.com/RedstoneWizard08/ConfigurableWarning/blob/main/docs/guides/tutorials/index.md/#L1"> | ||
<meta name="loc:inThisArticle" content="In this article"> | ||
<meta name="loc:searchResultsCount" content="{count} results for "{query}""> | ||
<meta name="loc:searchNoResults" content="No results for "{query}""> | ||
<meta name="loc:tocFilter" content="Filter by title"> | ||
<meta name="loc:nextArticle" content="Next"> | ||
<meta name="loc:prevArticle" content="Previous"> | ||
<meta name="loc:themeLight" content="Light"> | ||
<meta name="loc:themeDark" content="Dark"> | ||
<meta name="loc:themeAuto" content="Auto"> | ||
<meta name="loc:changeTheme" content="Change theme"> | ||
<meta name="loc:copy" content="Copy"> | ||
<meta name="loc:downloadPdf" content="Download PDF"> | ||
|
||
<script type="module" src="./../../public/docfx.min.js"></script> | ||
|
||
<script> | ||
const theme = localStorage.getItem('theme') || 'auto' | ||
document.documentElement.setAttribute('data-bs-theme', theme === 'auto' ? (window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light') : theme) | ||
</script> | ||
|
||
</head> | ||
|
||
<body class="tex2jax_ignore" data-layout="" data-yaml-mime=""> | ||
<header class="bg-body border-bottom"> | ||
<nav id="autocollapse" class="navbar navbar-expand-md" role="navigation"> | ||
<div class="container-xxl flex-nowrap"> | ||
<a class="navbar-brand" href="../../index.html"> | ||
<img id="logo" class="svg" src="../../banner.svg" alt=""> | ||
|
||
</a> | ||
<button class="btn btn-lg d-md-none border-0" type="button" data-bs-toggle="collapse" data-bs-target="#navpanel" aria-controls="navpanel" aria-expanded="false" aria-label="Toggle navigation"> | ||
<i class="bi bi-three-dots"></i> | ||
</button> | ||
<div class="collapse navbar-collapse" id="navpanel"> | ||
<div id="navbar"> | ||
<form class="search" role="search" id="search"> | ||
<i class="bi bi-search"></i> | ||
<input class="form-control" id="search-query" type="search" disabled="" placeholder="Search" autocomplete="off" aria-label="Search"> | ||
</form> | ||
</div> | ||
</div> | ||
</div> | ||
</nav> | ||
</header> | ||
|
||
<main class="container-xxl"> | ||
<div class="toc-offcanvas"> | ||
<div class="offcanvas-md offcanvas-start" tabindex="-1" id="tocOffcanvas" aria-labelledby="tocOffcanvasLabel"> | ||
<div class="offcanvas-header"> | ||
<h5 class="offcanvas-title" id="tocOffcanvasLabel">Table of Contents</h5> | ||
<button type="button" class="btn-close" data-bs-dismiss="offcanvas" data-bs-target="#tocOffcanvas" aria-label="Close"></button> | ||
</div> | ||
<div class="offcanvas-body"> | ||
<nav class="toc" id="toc"></nav> | ||
</div> | ||
</div> | ||
</div> | ||
|
||
<div class="content"> | ||
<div class="actionbar"> | ||
<button class="btn btn-lg border-0 d-md-none" style="margin-top: -.65em; margin-left: -.8em" type="button" data-bs-toggle="offcanvas" data-bs-target="#tocOffcanvas" aria-controls="tocOffcanvas" aria-expanded="false" aria-label="Show table of contents"> | ||
<i class="bi bi-list"></i> | ||
</button> | ||
|
||
<nav id="breadcrumb"></nav> | ||
</div> | ||
|
||
<article data-uid="Tutorials.Intro"> | ||
<h1 id="tutorials">Tutorials</h1> | ||
|
||
<p>Welcome to the tutorials! | ||
You can find tutorials on how to use the API here!</p> | ||
|
||
</article> | ||
|
||
<div class="contribution d-print-none"> | ||
<a href="https://github.com/RedstoneWizard08/ConfigurableWarning/blob/main/docs/guides/tutorials/index.md/#L1" class="edit-link">Edit this page</a> | ||
</div> | ||
|
||
<div class="next-article d-print-none border-top" id="nextArticle"></div> | ||
|
||
</div> | ||
|
||
<div class="affix"> | ||
<nav id="affix"></nav> | ||
</div> | ||
</main> | ||
|
||
<div class="container-xxl search-results" id="search-results"></div> | ||
|
||
<footer class="border-top text-secondary"> | ||
<div class="container-xxl"> | ||
<div class="flex-fill"> | ||
<span>Made with <a href="https://dotnet.github.io/docfx">docfx</a></span> | ||
</div> | ||
</div> | ||
</footer> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,150 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<meta charset="utf-8"> | ||
<title>Options | ConfigurableWarning Docs </title> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | ||
<meta name="title" content="Options | ConfigurableWarning Docs "> | ||
|
||
|
||
<link rel="icon" href="../../favicon.ico"> | ||
<link rel="stylesheet" href="../../public/docfx.min.css"> | ||
<link rel="stylesheet" href="../../public/main.css"> | ||
<meta name="docfx:navrel" content="../../toc.html"> | ||
<meta name="docfx:tocrel" content="../toc.html"> | ||
|
||
<meta name="docfx:rel" content="../../"> | ||
|
||
|
||
<meta name="docfx:docurl" content="https://github.com/RedstoneWizard08/ConfigurableWarning/blob/main/docs/guides/tutorials/options.md/#L1"> | ||
<meta name="loc:inThisArticle" content="In this article"> | ||
<meta name="loc:searchResultsCount" content="{count} results for "{query}""> | ||
<meta name="loc:searchNoResults" content="No results for "{query}""> | ||
<meta name="loc:tocFilter" content="Filter by title"> | ||
<meta name="loc:nextArticle" content="Next"> | ||
<meta name="loc:prevArticle" content="Previous"> | ||
<meta name="loc:themeLight" content="Light"> | ||
<meta name="loc:themeDark" content="Dark"> | ||
<meta name="loc:themeAuto" content="Auto"> | ||
<meta name="loc:changeTheme" content="Change theme"> | ||
<meta name="loc:copy" content="Copy"> | ||
<meta name="loc:downloadPdf" content="Download PDF"> | ||
|
||
<script type="module" src="./../../public/docfx.min.js"></script> | ||
|
||
<script> | ||
const theme = localStorage.getItem('theme') || 'auto' | ||
document.documentElement.setAttribute('data-bs-theme', theme === 'auto' ? (window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light') : theme) | ||
</script> | ||
|
||
</head> | ||
|
||
<body class="tex2jax_ignore" data-layout="" data-yaml-mime=""> | ||
<header class="bg-body border-bottom"> | ||
<nav id="autocollapse" class="navbar navbar-expand-md" role="navigation"> | ||
<div class="container-xxl flex-nowrap"> | ||
<a class="navbar-brand" href="../../index.html"> | ||
<img id="logo" class="svg" src="../../banner.svg" alt=""> | ||
|
||
</a> | ||
<button class="btn btn-lg d-md-none border-0" type="button" data-bs-toggle="collapse" data-bs-target="#navpanel" aria-controls="navpanel" aria-expanded="false" aria-label="Toggle navigation"> | ||
<i class="bi bi-three-dots"></i> | ||
</button> | ||
<div class="collapse navbar-collapse" id="navpanel"> | ||
<div id="navbar"> | ||
<form class="search" role="search" id="search"> | ||
<i class="bi bi-search"></i> | ||
<input class="form-control" id="search-query" type="search" disabled="" placeholder="Search" autocomplete="off" aria-label="Search"> | ||
</form> | ||
</div> | ||
</div> | ||
</div> | ||
</nav> | ||
</header> | ||
|
||
<main class="container-xxl"> | ||
<div class="toc-offcanvas"> | ||
<div class="offcanvas-md offcanvas-start" tabindex="-1" id="tocOffcanvas" aria-labelledby="tocOffcanvasLabel"> | ||
<div class="offcanvas-header"> | ||
<h5 class="offcanvas-title" id="tocOffcanvasLabel">Table of Contents</h5> | ||
<button type="button" class="btn-close" data-bs-dismiss="offcanvas" data-bs-target="#tocOffcanvas" aria-label="Close"></button> | ||
</div> | ||
<div class="offcanvas-body"> | ||
<nav class="toc" id="toc"></nav> | ||
</div> | ||
</div> | ||
</div> | ||
|
||
<div class="content"> | ||
<div class="actionbar"> | ||
<button class="btn btn-lg border-0 d-md-none" style="margin-top: -.65em; margin-left: -.8em" type="button" data-bs-toggle="offcanvas" data-bs-target="#tocOffcanvas" aria-controls="tocOffcanvas" aria-expanded="false" aria-label="Show table of contents"> | ||
<i class="bi bi-list"></i> | ||
</button> | ||
|
||
<nav id="breadcrumb"></nav> | ||
</div> | ||
|
||
<article data-uid="Tutorials.Options"> | ||
<h1 id="options">Options</h1> | ||
|
||
<h2 id="creating-an-option">Creating an Option</h2> | ||
<p>To create an option, you'll need a few things.</p> | ||
<p>You'll start with the class:</p> | ||
<pre><code class="lang-cs">[RegisterOption] | ||
private class MyOptionThing() // Class name is different here to show that it doesn't matter in state | ||
: IntOption(Keys.MyOption, 50, "My Option!", 0, 100, "MY STUFF", "GENERAL"); | ||
</code></pre> | ||
<div class="NOTE"> | ||
<h5>Note</h5> | ||
<p>For information about the <code>Keys</code> class, see <a href="state.html">State</a>.</p> | ||
</div> | ||
<p>You'll notice a few things here. Let's break it down.</p> | ||
<p>The <code>[RegisterOption]</code> comes from <a class="xref" href="../../api/ConfigurableWarning.API.RegisterOption.html">RegisterOption</a>, and | ||
tells ConfigurableWarning to automatically register your option to the game, meaning that | ||
you don't have to do that!</p> | ||
<p>The inherited class, <a class="xref" href="../../api/ConfigurableWarning.API.Options.IntOption.html">IntOption</a>, defines this as an | ||
<a class="xref" href="../../api/ConfigurableWarning.API.Options.IOption-1.html">IOption<T></a> with the <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a> type for its | ||
value. This constructor takes a few arguments, namely:</p> | ||
<ol> | ||
<li>The option's name - Here it's <code>"MyOption"</code>. This is used in the state and registry, and the | ||
end-user will likely never see it.</li> | ||
<li>The default value - Here it's <code>50</code>.</li> | ||
<li>The option's display name - Here it's <code>"My Option!"</code>. This is what the user will see in the | ||
settings menu.</li> | ||
<li>The minimum value - Here it's <code>0</code>. This is the <u>minumum</u> value that the slider will go to.</li> | ||
<li>The maximum value - Here it's <code>100</code>. This is the <u>maximum</u> value that the slider will go to.</li> | ||
<li>The tab - Here it's <code>"MY STUFF"</code>. This will be the tab that the setting shows up in.</li> | ||
<li>The category - Here it's <code>"GENERAL"</code>. This will be the category that the setting appears under.</li> | ||
</ol> | ||
<div class="NOTE"> | ||
<h5>Note</h5> | ||
<p>Unfortunately, due to the nature of how Zorro's Settings API works, each option has | ||
to be its own class.</p> | ||
</div> | ||
|
||
</article> | ||
|
||
<div class="contribution d-print-none"> | ||
<a href="https://github.com/RedstoneWizard08/ConfigurableWarning/blob/main/docs/guides/tutorials/options.md/#L1" class="edit-link">Edit this page</a> | ||
</div> | ||
|
||
<div class="next-article d-print-none border-top" id="nextArticle"></div> | ||
|
||
</div> | ||
|
||
<div class="affix"> | ||
<nav id="affix"></nav> | ||
</div> | ||
</main> | ||
|
||
<div class="container-xxl search-results" id="search-results"></div> | ||
|
||
<footer class="border-top text-secondary"> | ||
<div class="container-xxl"> | ||
<div class="flex-fill"> | ||
<span>Made with <a href="https://dotnet.github.io/docfx">docfx</a></span> | ||
</div> | ||
</div> | ||
</footer> | ||
</body> | ||
</html> |
Oops, something went wrong.