612 lines
46 KiB
HTML
612 lines
46 KiB
HTML
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
|
|
<head>
|
|
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
|
|
<meta name="generator" content="Doxygen 1.9.7"/>
|
|
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
|
<title>godot-cpp-utils: utils::GameRoot3D Class Reference</title>
|
|
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="jquery.js"></script>
|
|
<script type="text/javascript" src="dynsections.js"></script>
|
|
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="search/searchdata.js"></script>
|
|
<script type="text/javascript" src="search/search.js"></script>
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
|
$(document).ready(function() { init_search(); });
|
|
/* @license-end */
|
|
</script>
|
|
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
|
<link href="doxygen-awesome.css" rel="stylesheet" type="text/css"/>
|
|
</head>
|
|
<body>
|
|
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
|
<div id="titlearea">
|
|
<table cellspacing="0" cellpadding="0">
|
|
<tbody>
|
|
<tr id="projectrow">
|
|
<td id="projectalign">
|
|
<div id="projectname">godot-cpp-utils
|
|
</div>
|
|
<div id="projectbrief">A collection of utility classes, functions and macros for use with Godot and GDExtension.</div>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
<!-- end header part -->
|
|
<!-- Generated by Doxygen 1.9.7 -->
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
|
var searchBox = new SearchBox("searchBox", "search/",'.html');
|
|
/* @license-end */
|
|
</script>
|
|
<div id="navrow1" class="tabs">
|
|
<ul class="tablist">
|
|
<li><a href="index.html"><span>Main Page</span></a></li>
|
|
<li><a href="pages.html"><span>Related Pages</span></a></li>
|
|
<li class="current"><a href="annotated.html"><span>Classes</span></a></li>
|
|
<li><a href="files.html"><span>Files</span></a></li>
|
|
<li>
|
|
<div id="MSearchBox" class="MSearchBoxInactive">
|
|
<span class="left">
|
|
<span id="MSearchSelect" onmouseover="return searchBox.OnSearchSelectShow()" onmouseout="return searchBox.OnSearchSelectHide()"> </span>
|
|
<input type="text" id="MSearchField" value="" placeholder="Search" accesskey="S"
|
|
onfocus="searchBox.OnSearchFieldFocus(true)"
|
|
onblur="searchBox.OnSearchFieldFocus(false)"
|
|
onkeyup="searchBox.OnSearchFieldChange(event)"/>
|
|
</span><span class="right">
|
|
<a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.svg" alt=""/></a>
|
|
</span>
|
|
</div>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
<div id="navrow2" class="tabs2">
|
|
<ul class="tablist">
|
|
<li><a href="annotated.html"><span>Class List</span></a></li>
|
|
<li><a href="classes.html"><span>Class Index</span></a></li>
|
|
<li><a href="hierarchy.html"><span>Class Hierarchy</span></a></li>
|
|
<li><a href="functions.html"><span>Class Members</span></a></li>
|
|
</ul>
|
|
</div>
|
|
<!-- window showing the filter options -->
|
|
<div id="MSearchSelectWindow"
|
|
onmouseover="return searchBox.OnSearchSelectShow()"
|
|
onmouseout="return searchBox.OnSearchSelectHide()"
|
|
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
|
</div>
|
|
|
|
<!-- iframe showing the search results (closed by default) -->
|
|
<div id="MSearchResultsWindow">
|
|
<div id="MSearchResults">
|
|
<div class="SRPage">
|
|
<div id="SRIndex">
|
|
<div id="SRResults"></div>
|
|
<div class="SRStatus" id="Loading">Loading...</div>
|
|
<div class="SRStatus" id="Searching">Searching...</div>
|
|
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div id="nav-path" class="navpath">
|
|
<ul>
|
|
<li class="navelem"><b>utils</b></li><li class="navelem"><a class="el" href="classutils_1_1GameRoot3D.html">GameRoot3D</a></li> </ul>
|
|
</div>
|
|
</div><!-- top -->
|
|
<div class="header">
|
|
<div class="summary">
|
|
<a href="#pub-methods">Public Member Functions</a> |
|
|
<a href="#pub-static-methods">Static Public Member Functions</a> |
|
|
<a href="#pro-methods">Protected Member Functions</a> |
|
|
<a href="#pro-static-methods">Static Protected Member Functions</a> |
|
|
<a href="#pri-methods">Private Member Functions</a> |
|
|
<a href="#pri-static-methods">Static Private Member Functions</a> |
|
|
<a href="#pri-attribs">Private Attributes</a> |
|
|
<a href="#pri-static-attribs">Static Private Attributes</a> |
|
|
<a href="classutils_1_1GameRoot3D-members.html">List of all members</a> </div>
|
|
<div class="headertitle"><div class="title">utils::GameRoot3D Class Reference</div></div>
|
|
</div><!--header-->
|
|
<div class="contents">
|
|
|
|
<p>The root of a game.
|
|
<a href="classutils_1_1GameRoot3D.html#details">More...</a></p>
|
|
|
|
<p><code>#include <<a class="el" href="game__root_8hpp_source.html">game_root.hpp</a>></code></p>
|
|
<div class="dynheader">
|
|
Inheritance diagram for utils::GameRoot3D:</div>
|
|
<div class="dyncontent">
|
|
<div class="center">
|
|
<img src="classutils_1_1GameRoot3D.png" alt=""/>
|
|
</div></div>
|
|
<table class="memberdecls">
|
|
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pub-methods" name="pub-methods"></a>
|
|
Public Member Functions</h2></td></tr>
|
|
<tr class="memitem:acbe172accf6be3995fc6e09f82972f8d"><td class="memItemLeft" align="right" valign="top"><a id="acbe172accf6be3995fc6e09f82972f8d" name="acbe172accf6be3995fc6e09f82972f8d"></a>
|
|
virtual void </td><td class="memItemRight" valign="bottom"><b>_enter_tree</b> () override</td></tr>
|
|
<tr class="separator:acbe172accf6be3995fc6e09f82972f8d"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:ac2988192b6066c7497e8a9b8e2ab3aee"><td class="memItemLeft" align="right" valign="top"><a id="ac2988192b6066c7497e8a9b8e2ab3aee" name="ac2988192b6066c7497e8a9b8e2ab3aee"></a>
|
|
virtual void </td><td class="memItemRight" valign="bottom"><b>_ready</b> () override</td></tr>
|
|
<tr class="separator:ac2988192b6066c7497e8a9b8e2ab3aee"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a9990f4397e3e636f03b85cfaa9e32ff3"><td class="memItemLeft" align="right" valign="top"><a id="a9990f4397e3e636f03b85cfaa9e32ff3" name="a9990f4397e3e636f03b85cfaa9e32ff3"></a>
|
|
virtual void </td><td class="memItemRight" valign="bottom"><b>_exit_tree</b> () override</td></tr>
|
|
<tr class="separator:a9990f4397e3e636f03b85cfaa9e32ff3"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a85eee9cb258971abe9fe8577314b2556"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classutils_1_1GameRoot3D.html#a85eee9cb258971abe9fe8577314b2556">player_input_connected</a> ()</td></tr>
|
|
<tr class="memdesc:a85eee9cb258971abe9fe8577314b2556"><td class="mdescLeft"> </td><td class="mdescRight">Instantiate a new <a class="el" href="classutils_1_1PlayerInput.html" title="An event-driven input observer.">PlayerInput</a>. <br /></td></tr>
|
|
<tr class="separator:a85eee9cb258971abe9fe8577314b2556"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a89953130655a618aefa8f3ea0db63a53"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classutils_1_1GameRoot3D.html#a89953130655a618aefa8f3ea0db63a53">remove_player</a> (uint32_t player_id)</td></tr>
|
|
<tr class="memdesc:a89953130655a618aefa8f3ea0db63a53"><td class="mdescLeft"> </td><td class="mdescRight">Force-disconnect a player. <br /></td></tr>
|
|
<tr class="separator:a89953130655a618aefa8f3ea0db63a53"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a8609fc03b909a94a3c9da6f9e9d2307b"><td class="memItemLeft" align="right" valign="top"><a id="a8609fc03b909a94a3c9da6f9e9d2307b" name="a8609fc03b909a94a3c9da6f9e9d2307b"></a>
|
|
void </td><td class="memItemRight" valign="bottom"><b>remove_all_players</b> ()</td></tr>
|
|
<tr class="separator:a8609fc03b909a94a3c9da6f9e9d2307b"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a865e6d9fe4f9422c0fb974bd6b1222ce"><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classutils_1_1GameRoot3D.html#a865e6d9fe4f9422c0fb974bd6b1222ce">initialize_player</a> (<a class="el" href="classutils_1_1IPlayer.html">IPlayer</a> *player, uint32_t id)</td></tr>
|
|
<tr class="memdesc:a865e6d9fe4f9422c0fb974bd6b1222ce"><td class="mdescLeft"> </td><td class="mdescRight">Initialize and register a player instance. <br /></td></tr>
|
|
<tr class="separator:a865e6d9fe4f9422c0fb974bd6b1222ce"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:add087bf071383383e68e919173670c47"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classutils_1_1GameRoot3D.html#add087bf071383383e68e919173670c47">reset_game_mode</a> ()</td></tr>
|
|
<tr class="memdesc:add087bf071383383e68e919173670c47"><td class="mdescLeft"> </td><td class="mdescRight">Un-set game mode. <br /></td></tr>
|
|
<tr class="separator:add087bf071383383e68e919173670c47"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:acbec3f7b39c8c991a725e611dd8b869e"><td class="memItemLeft" align="right" valign="top"><a id="acbec3f7b39c8c991a725e611dd8b869e" name="acbec3f7b39c8c991a725e611dd8b869e"></a>
|
|
<a class="el" href="classutils_1_1Level3D.html">Level3D</a> * </td><td class="memItemRight" valign="bottom"><b>load_level</b> (gd::Ref< gd::PackedScene > level)</td></tr>
|
|
<tr class="memdesc:acbec3f7b39c8c991a725e611dd8b869e"><td class="mdescLeft"> </td><td class="mdescRight">shorthand for load_level(level, Transform3D()) <br /></td></tr>
|
|
<tr class="separator:acbec3f7b39c8c991a725e611dd8b869e"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:ad53d50b5b35e4c13bf84f2d9c0f45a0b"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classutils_1_1Level3D.html">Level3D</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="classutils_1_1GameRoot3D.html#ad53d50b5b35e4c13bf84f2d9c0f45a0b">load_level_at</a> (gd::Ref< gd::PackedScene > level, gd::Transform3D at)</td></tr>
|
|
<tr class="memdesc:ad53d50b5b35e4c13bf84f2d9c0f45a0b"><td class="mdescLeft"> </td><td class="mdescRight">Load a level, only works if 'level' is a valid scene where the root Node can cast to '<a class="el" href="classutils_1_1Level3D.html" title="3D level root to be used with GameRoot3D.">Level3D</a>'. <br /></td></tr>
|
|
<tr class="separator:ad53d50b5b35e4c13bf84f2d9c0f45a0b"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a4053b12af23cef53eb294729f1cb3aa8"><td class="memItemLeft" align="right" valign="top"><a id="a4053b12af23cef53eb294729f1cb3aa8" name="a4053b12af23cef53eb294729f1cb3aa8"></a>
|
|
void </td><td class="memItemRight" valign="bottom"><b>unload_all_levels</b> ()</td></tr>
|
|
<tr class="memdesc:a4053b12af23cef53eb294729f1cb3aa8"><td class="mdescLeft"> </td><td class="mdescRight">Unload all currently loaded levels. <br /></td></tr>
|
|
<tr class="separator:a4053b12af23cef53eb294729f1cb3aa8"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a453c8aa3920d7d0adaf2490c63a7d92c"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classutils_1_1GameRoot3D.html#a453c8aa3920d7d0adaf2490c63a7d92c">replace_levels</a> (gd::Ref< gd::PackedScene > level)</td></tr>
|
|
<tr class="memdesc:a453c8aa3920d7d0adaf2490c63a7d92c"><td class="mdescLeft"> </td><td class="mdescRight">Replace all currently loaded levels with a new level. <br /></td></tr>
|
|
<tr class="separator:a453c8aa3920d7d0adaf2490c63a7d92c"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a1937044fe05a903610308f8d382de975"><td class="memItemLeft" align="right" valign="top"><a id="a1937044fe05a903610308f8d382de975" name="a1937044fe05a903610308f8d382de975"></a>
|
|
void </td><td class="memItemRight" valign="bottom"><b>register_spawn_point</b> (<a class="el" href="classutils_1_1SpawnPoint3D.html">SpawnPoint3D</a> *spawn_point)</td></tr>
|
|
<tr class="memdesc:a1937044fe05a903610308f8d382de975"><td class="mdescLeft"> </td><td class="mdescRight">Register a spawnpoint for use when spawning players. <br /></td></tr>
|
|
<tr class="separator:a1937044fe05a903610308f8d382de975"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a8f0302998c72c1d402745e3d16cfbf7b"><td class="memItemLeft" align="right" valign="top"><a id="a8f0302998c72c1d402745e3d16cfbf7b" name="a8f0302998c72c1d402745e3d16cfbf7b"></a>
|
|
void </td><td class="memItemRight" valign="bottom"><b>unregister_spawn_point</b> (<a class="el" href="classutils_1_1SpawnPoint3D.html">SpawnPoint3D</a> *spawn_point)</td></tr>
|
|
<tr class="separator:a8f0302998c72c1d402745e3d16cfbf7b"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:aadefd1d1fd0b0493457c8288c87ccad6"><td class="memItemLeft" align="right" valign="top"><a id="aadefd1d1fd0b0493457c8288c87ccad6" name="aadefd1d1fd0b0493457c8288c87ccad6"></a>
|
|
void </td><td class="memItemRight" valign="bottom"><b>place_player_at_spawnpoint</b> (<a class="el" href="classutils_1_1IPlayer.html">IPlayer</a> *player)</td></tr>
|
|
<tr class="separator:aadefd1d1fd0b0493457c8288c87ccad6"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:ab5afd37ae4fca77439721fe9e5b578ed"><td class="memItemLeft" align="right" valign="top"><a id="ab5afd37ae4fca77439721fe9e5b578ed" name="ab5afd37ae4fca77439721fe9e5b578ed"></a>
|
|
void </td><td class="memItemRight" valign="bottom"><b>player_despawned</b> (uint32_t id)</td></tr>
|
|
<tr class="separator:ab5afd37ae4fca77439721fe9e5b578ed"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a6c2a1aa2c35808a1b003ae79eac348c2"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classutils_1_1GameRoot3D.html#a6c2a1aa2c35808a1b003ae79eac348c2">set_game_mode</a> (gd::Ref< <a class="el" href="classutils_1_1GameMode.html">GameMode</a> > prototype)</td></tr>
|
|
<tr class="memdesc:a6c2a1aa2c35808a1b003ae79eac348c2"><td class="mdescLeft"> </td><td class="mdescRight">Override the current gamemode. <br /></td></tr>
|
|
<tr class="separator:a6c2a1aa2c35808a1b003ae79eac348c2"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a896b4e4d3b9465a83a10249dbd559662"><td class="memItemLeft" align="right" valign="top"><a id="a896b4e4d3b9465a83a10249dbd559662" name="a896b4e4d3b9465a83a10249dbd559662"></a>
|
|
<a class="el" href="classutils_1_1GameMode.html">GameMode</a> * </td><td class="memItemRight" valign="bottom"><b>get_game_mode</b> () const</td></tr>
|
|
<tr class="memdesc:a896b4e4d3b9465a83a10249dbd559662"><td class="mdescLeft"> </td><td class="mdescRight">get the current active game mode. <br /></td></tr>
|
|
<tr class="separator:a896b4e4d3b9465a83a10249dbd559662"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a105011a591cf09368958d4be350ed352"><td class="memItemLeft" align="right" valign="top"><a id="a105011a591cf09368958d4be350ed352" name="a105011a591cf09368958d4be350ed352"></a>
|
|
<a class="el" href="classutils_1_1GameState.html">GameState</a> * </td><td class="memItemRight" valign="bottom"><b>get_game_state</b> () const</td></tr>
|
|
<tr class="memdesc:a105011a591cf09368958d4be350ed352"><td class="mdescLeft"> </td><td class="mdescRight">Get the current active game state. <br /></td></tr>
|
|
<tr class="separator:a105011a591cf09368958d4be350ed352"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:aa9ed453a0b416641dfa5154a0b69c79e"><td class="memItemLeft" align="right" valign="top">gd::HashMap< gd::StringName, <a class="el" href="classutils_1_1Level3D.html">Level3D</a> * > & </td><td class="memItemRight" valign="bottom"><a class="el" href="classutils_1_1GameRoot3D.html#aa9ed453a0b416641dfa5154a0b69c79e">get_levels</a> ()</td></tr>
|
|
<tr class="memdesc:aa9ed453a0b416641dfa5154a0b69c79e"><td class="mdescLeft"> </td><td class="mdescRight">Returns all currently active levels. <br /></td></tr>
|
|
<tr class="separator:aa9ed453a0b416641dfa5154a0b69c79e"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a27492f37140fa8af6c6955f2147f5521"><td class="memItemLeft" align="right" valign="top"><a id="a27492f37140fa8af6c6955f2147f5521" name="a27492f37140fa8af6c6955f2147f5521"></a>
|
|
<a class="el" href="classutils_1_1IPlayer.html">IPlayer</a> * </td><td class="memItemRight" valign="bottom"><b>get_player</b> (uint32_t id)</td></tr>
|
|
<tr class="memdesc:a27492f37140fa8af6c6955f2147f5521"><td class="mdescLeft"> </td><td class="mdescRight">Get the player instance associated with id. <br /></td></tr>
|
|
<tr class="separator:a27492f37140fa8af6c6955f2147f5521"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:af176a558f2a3b972c970087c2a1e3d7b"><td class="memItemLeft" align="right" valign="top"><a id="af176a558f2a3b972c970087c2a1e3d7b" name="af176a558f2a3b972c970087c2a1e3d7b"></a>
|
|
gd::Vector< <a class="el" href="classutils_1_1IPlayer.html">IPlayer</a> * > </td><td class="memItemRight" valign="bottom"><b>get_players</b> ()</td></tr>
|
|
<tr class="memdesc:af176a558f2a3b972c970087c2a1e3d7b"><td class="mdescLeft"> </td><td class="mdescRight">Get all players in a list. <br /></td></tr>
|
|
<tr class="separator:af176a558f2a3b972c970087c2a1e3d7b"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a15df4b8020de484ba142bc0ef61c60d4"><td class="memItemLeft" align="right" valign="top"><a id="a15df4b8020de484ba142bc0ef61c60d4" name="a15df4b8020de484ba142bc0ef61c60d4"></a>
|
|
void </td><td class="memItemRight" valign="bottom"><b>set_first_boot_level</b> (gd::Ref< gd::PackedScene > level)</td></tr>
|
|
<tr class="separator:a15df4b8020de484ba142bc0ef61c60d4"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a5305cfbb08abcabed07364e353c0017d"><td class="memItemLeft" align="right" valign="top"><a id="a5305cfbb08abcabed07364e353c0017d" name="a5305cfbb08abcabed07364e353c0017d"></a>
|
|
gd::Ref< gd::PackedScene > </td><td class="memItemRight" valign="bottom"><b>get_first_boot_level</b> () const</td></tr>
|
|
<tr class="separator:a5305cfbb08abcabed07364e353c0017d"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a80edbb785e0bc0b0b76a99572793cb87"><td class="memItemLeft" align="right" valign="top"><a id="a80edbb785e0bc0b0b76a99572793cb87" name="a80edbb785e0bc0b0b76a99572793cb87"></a>
|
|
void </td><td class="memItemRight" valign="bottom"><b>set_game_state_prototype</b> (gd::Ref< <a class="el" href="classutils_1_1GameState.html">GameState</a> > <a class="el" href="classutils_1_1GameRoot3D.html#af73d3a598b72fcdc7dce372ea3af6e44">game_state</a>)</td></tr>
|
|
<tr class="separator:a80edbb785e0bc0b0b76a99572793cb87"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a70389d0364230eaed0182c2fb9ded0ad"><td class="memItemLeft" align="right" valign="top"><a id="a70389d0364230eaed0182c2fb9ded0ad" name="a70389d0364230eaed0182c2fb9ded0ad"></a>
|
|
gd::Ref< <a class="el" href="classutils_1_1GameState.html">GameState</a> > </td><td class="memItemRight" valign="bottom"><b>get_game_state_prototype</b> () const</td></tr>
|
|
<tr class="separator:a70389d0364230eaed0182c2fb9ded0ad"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table><table class="memberdecls">
|
|
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pub-static-methods" name="pub-static-methods"></a>
|
|
Static Public Member Functions</h2></td></tr>
|
|
<tr class="memitem:ad1c9387dee7919a8ab5d60b19cba2140"><td class="memItemLeft" align="right" valign="top"><a id="ad1c9387dee7919a8ab5d60b19cba2140" name="ad1c9387dee7919a8ab5d60b19cba2140"></a>
|
|
static <a class="el" href="classutils_1_1GameRoot3D.html">GameRoot3D</a> * </td><td class="memItemRight" valign="bottom"><b>get_singleton</b> ()</td></tr>
|
|
<tr class="memdesc:ad1c9387dee7919a8ab5d60b19cba2140"><td class="mdescLeft"> </td><td class="mdescRight">get the current active singleton instance of GameRoot <br /></td></tr>
|
|
<tr class="separator:ad1c9387dee7919a8ab5d60b19cba2140"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a13e110d60dffd924248af9c3f6943706"><td class="memItemLeft" align="right" valign="top"><a id="a13e110d60dffd924248af9c3f6943706" name="a13e110d60dffd924248af9c3f6943706"></a>
|
|
static bool </td><td class="memItemRight" valign="bottom"><b>has_singleton</b> ()</td></tr>
|
|
<tr class="memdesc:a13e110d60dffd924248af9c3f6943706"><td class="mdescLeft"> </td><td class="mdescRight">returns true if there is currently a singleton active for GameRoot <br /></td></tr>
|
|
<tr class="separator:a13e110d60dffd924248af9c3f6943706"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table><table class="memberdecls">
|
|
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pro-methods" name="pro-methods"></a>
|
|
Protected Member Functions</h2></td></tr>
|
|
<tr class="memitem:a0fc164bad77a192ff2209eee18e5104b"><td class="memItemLeft" align="right" valign="top"><a id="a0fc164bad77a192ff2209eee18e5104b" name="a0fc164bad77a192ff2209eee18e5104b"></a>
|
|
void </td><td class="memItemRight" valign="bottom"><b>grab_singleton</b> ()</td></tr>
|
|
<tr class="memdesc:a0fc164bad77a192ff2209eee18e5104b"><td class="mdescLeft"> </td><td class="mdescRight">Attempt to make 'this' the current singleton instance. <br /></td></tr>
|
|
<tr class="separator:a0fc164bad77a192ff2209eee18e5104b"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:adc4455c11d39f8a267091f29ead441ee"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classutils_1_1GameRoot3D.html#adc4455c11d39f8a267091f29ead441ee">release_singleton</a> ()</td></tr>
|
|
<tr class="memdesc:adc4455c11d39f8a267091f29ead441ee"><td class="mdescLeft"> </td><td class="mdescRight">Attempt to stop being the active singleton instance. <br /></td></tr>
|
|
<tr class="separator:adc4455c11d39f8a267091f29ead441ee"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:ab3895b9b48c4646a876e188d226c5723"><td class="memItemLeft" align="right" valign="top"><a id="ab3895b9b48c4646a876e188d226c5723" name="ab3895b9b48c4646a876e188d226c5723"></a>
|
|
uint32_t </td><td class="memItemRight" valign="bottom"><b>find_empty_player_slot</b> () const</td></tr>
|
|
<tr class="memdesc:ab3895b9b48c4646a876e188d226c5723"><td class="mdescLeft"> </td><td class="mdescRight">Find a Player Input device not yet associated with a player. <br /></td></tr>
|
|
<tr class="separator:ab3895b9b48c4646a876e188d226c5723"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a3e74ac9841575d9a915cf7ac6735b42b"><td class="memItemLeft" align="right" valign="top"><a id="a3e74ac9841575d9a915cf7ac6735b42b" name="a3e74ac9841575d9a915cf7ac6735b42b"></a>
|
|
<a class="el" href="classutils_1_1IPlayer.html">IPlayer</a> * </td><td class="memItemRight" valign="bottom"><b>spawn_player</b> (uint32_t id)</td></tr>
|
|
<tr class="memdesc:a3e74ac9841575d9a915cf7ac6735b42b"><td class="mdescLeft"> </td><td class="mdescRight">Spawn a player to be associated with id. <br /></td></tr>
|
|
<tr class="separator:a3e74ac9841575d9a915cf7ac6735b42b"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:af34016620adcdc2654358b463769a85f"><td class="memItemLeft" align="right" valign="top"><a id="af34016620adcdc2654358b463769a85f" name="af34016620adcdc2654358b463769a85f"></a>
|
|
void </td><td class="memItemRight" valign="bottom"><b>level_unloaded</b> (gd::StringName scene_path)</td></tr>
|
|
<tr class="memdesc:af34016620adcdc2654358b463769a85f"><td class="mdescLeft"> </td><td class="mdescRight">Callback for a level exiting the tree. <br /></td></tr>
|
|
<tr class="separator:af34016620adcdc2654358b463769a85f"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table><table class="memberdecls">
|
|
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pro-static-methods" name="pro-static-methods"></a>
|
|
Static Protected Member Functions</h2></td></tr>
|
|
<tr class="memitem:a77e4726bb8fec522669cbb2c068e47d9"><td class="memItemLeft" align="right" valign="top"><a id="a77e4726bb8fec522669cbb2c068e47d9" name="a77e4726bb8fec522669cbb2c068e47d9"></a>
|
|
static bool </td><td class="memItemRight" valign="bottom"><b>is_valid_level</b> (gd::Ref< gd::PackedScene > &level)</td></tr>
|
|
<tr class="memdesc:a77e4726bb8fec522669cbb2c068e47d9"><td class="mdescLeft"> </td><td class="mdescRight">Check if a scene is a valid level. <br /></td></tr>
|
|
<tr class="separator:a77e4726bb8fec522669cbb2c068e47d9"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table><table class="memberdecls">
|
|
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pri-methods" name="pri-methods"></a>
|
|
Private Member Functions</h2></td></tr>
|
|
<tr class="memitem:a3e6425340b1db9e5472bbd1e26b664f3"><td class="memItemLeft" align="right" valign="top"><a id="a3e6425340b1db9e5472bbd1e26b664f3" name="a3e6425340b1db9e5472bbd1e26b664f3"></a>
|
|
 </td><td class="memItemRight" valign="bottom"><b>GDCLASS</b> (<a class="el" href="classutils_1_1GameRoot3D.html">GameRoot3D</a>, gd::Node)</td></tr>
|
|
<tr class="separator:a3e6425340b1db9e5472bbd1e26b664f3"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table><table class="memberdecls">
|
|
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pri-static-methods" name="pri-static-methods"></a>
|
|
Static Private Member Functions</h2></td></tr>
|
|
<tr class="memitem:a064191129e5e3447a5e883ad92d50a72"><td class="memItemLeft" align="right" valign="top"><a id="a064191129e5e3447a5e883ad92d50a72" name="a064191129e5e3447a5e883ad92d50a72"></a>
|
|
static void </td><td class="memItemRight" valign="bottom"><b>_bind_methods</b> ()</td></tr>
|
|
<tr class="separator:a064191129e5e3447a5e883ad92d50a72"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table><table class="memberdecls">
|
|
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pri-attribs" name="pri-attribs"></a>
|
|
Private Attributes</h2></td></tr>
|
|
<tr class="memitem:af508cc9852b123ea37b94651da0f3c19"><td class="memItemLeft" align="right" valign="top">uint32_t </td><td class="memItemRight" valign="bottom"><a class="el" href="classutils_1_1GameRoot3D.html#af508cc9852b123ea37b94651da0f3c19">next_player_id</a> {1}</td></tr>
|
|
<tr class="memdesc:af508cc9852b123ea37b94651da0f3c19"><td class="mdescLeft"> </td><td class="mdescRight">Next available player ID. <br /></td></tr>
|
|
<tr class="separator:af508cc9852b123ea37b94651da0f3c19"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:acf48cbe3b2b6dd064cd1665ea8df2b9a"><td class="memItemLeft" align="right" valign="top"><a id="acf48cbe3b2b6dd064cd1665ea8df2b9a" name="acf48cbe3b2b6dd064cd1665ea8df2b9a"></a>
|
|
gd::HashMap< uint32_t, gd::Pair< <a class="el" href="classutils_1_1PlayerInput.html">PlayerInput</a> *, <a class="el" href="classutils_1_1IPlayer.html">IPlayer</a> * > > </td><td class="memItemRight" valign="bottom"><b>players</b> {}</td></tr>
|
|
<tr class="memdesc:acf48cbe3b2b6dd064cd1665ea8df2b9a"><td class="mdescLeft"> </td><td class="mdescRight">all players by id by input device. <br /></td></tr>
|
|
<tr class="separator:acf48cbe3b2b6dd064cd1665ea8df2b9a"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a623230c72ced578d7be1b9141b54fbd4"><td class="memItemLeft" align="right" valign="top"><a id="a623230c72ced578d7be1b9141b54fbd4" name="a623230c72ced578d7be1b9141b54fbd4"></a>
|
|
gd::RandomNumberGenerator </td><td class="memItemRight" valign="bottom"><b>rng</b> {}</td></tr>
|
|
<tr class="memdesc:a623230c72ced578d7be1b9141b54fbd4"><td class="mdescLeft"> </td><td class="mdescRight">Global random number generator. <br /></td></tr>
|
|
<tr class="separator:a623230c72ced578d7be1b9141b54fbd4"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a800421c3b82947156eebcbf730a680db"><td class="memItemLeft" align="right" valign="top"><a id="a800421c3b82947156eebcbf730a680db" name="a800421c3b82947156eebcbf730a680db"></a>
|
|
gd::HashMap< gd::StringName, <a class="el" href="classutils_1_1Level3D.html">Level3D</a> * > </td><td class="memItemRight" valign="bottom"><b>levels</b> {}</td></tr>
|
|
<tr class="memdesc:a800421c3b82947156eebcbf730a680db"><td class="mdescLeft"> </td><td class="mdescRight">all currently active levels identified by their resource paths. <br /></td></tr>
|
|
<tr class="separator:a800421c3b82947156eebcbf730a680db"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a116245a9c4e7edf53ec03c6fe78c8462"><td class="memItemLeft" align="right" valign="top"><a id="a116245a9c4e7edf53ec03c6fe78c8462" name="a116245a9c4e7edf53ec03c6fe78c8462"></a>
|
|
gd::Vector< <a class="el" href="classutils_1_1SpawnPoint3D.html">SpawnPoint3D</a> * > </td><td class="memItemRight" valign="bottom"><b>spawn_points</b> {}</td></tr>
|
|
<tr class="memdesc:a116245a9c4e7edf53ec03c6fe78c8462"><td class="mdescLeft"> </td><td class="mdescRight">all currently available spawn points. <br /></td></tr>
|
|
<tr class="separator:a116245a9c4e7edf53ec03c6fe78c8462"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:abb25b7613e1c7cd4f056020e6990d8e1"><td class="memItemLeft" align="right" valign="top"><a id="abb25b7613e1c7cd4f056020e6990d8e1" name="abb25b7613e1c7cd4f056020e6990d8e1"></a>
|
|
gd::Ref< <a class="el" href="classutils_1_1GameMode.html">GameMode</a> > </td><td class="memItemRight" valign="bottom"><b>game_mode</b> {}</td></tr>
|
|
<tr class="memdesc:abb25b7613e1c7cd4f056020e6990d8e1"><td class="mdescLeft"> </td><td class="mdescRight">current active gamemode. <br /></td></tr>
|
|
<tr class="separator:abb25b7613e1c7cd4f056020e6990d8e1"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:af73d3a598b72fcdc7dce372ea3af6e44"><td class="memItemLeft" align="right" valign="top">gd::Ref< <a class="el" href="classutils_1_1GameState.html">GameState</a> > </td><td class="memItemRight" valign="bottom"><a class="el" href="classutils_1_1GameRoot3D.html#af73d3a598b72fcdc7dce372ea3af6e44">game_state</a> {}</td></tr>
|
|
<tr class="memdesc:af73d3a598b72fcdc7dce372ea3af6e44"><td class="mdescLeft"> </td><td class="mdescRight">Active game state. <br /></td></tr>
|
|
<tr class="separator:af73d3a598b72fcdc7dce372ea3af6e44"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:abf16d0f3b8030b758942397dcff1d46a"><td class="memItemLeft" align="right" valign="top"><a id="abf16d0f3b8030b758942397dcff1d46a" name="abf16d0f3b8030b758942397dcff1d46a"></a>
|
|
gd::Ref< gd::PackedScene > </td><td class="memItemRight" valign="bottom"><b>first_boot_level</b> {}</td></tr>
|
|
<tr class="memdesc:abf16d0f3b8030b758942397dcff1d46a"><td class="mdescLeft"> </td><td class="mdescRight">The level to boot into on startup. <br /></td></tr>
|
|
<tr class="separator:abf16d0f3b8030b758942397dcff1d46a"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:ad62b2be46770ba99aa6c2a7800c52aa8"><td class="memItemLeft" align="right" valign="top"><a id="ad62b2be46770ba99aa6c2a7800c52aa8" name="ad62b2be46770ba99aa6c2a7800c52aa8"></a>
|
|
gd::Ref< <a class="el" href="classutils_1_1GameState.html">GameState</a> > </td><td class="memItemRight" valign="bottom"><b>game_state_prototype</b> {}</td></tr>
|
|
<tr class="memdesc:ad62b2be46770ba99aa6c2a7800c52aa8"><td class="mdescLeft"> </td><td class="mdescRight">The default game state data used for game_state if no save data is available. <br /></td></tr>
|
|
<tr class="separator:ad62b2be46770ba99aa6c2a7800c52aa8"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table><table class="memberdecls">
|
|
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pri-static-attribs" name="pri-static-attribs"></a>
|
|
Static Private Attributes</h2></td></tr>
|
|
<tr class="memitem:a35961f730828273d502ff2311c7cd83d"><td class="memItemLeft" align="right" valign="top"><a id="a35961f730828273d502ff2311c7cd83d" name="a35961f730828273d502ff2311c7cd83d"></a>
|
|
static <a class="el" href="classutils_1_1GameRoot3D.html">GameRoot3D</a> * </td><td class="memItemRight" valign="bottom"><b>singleton_instance</b> {nullptr}</td></tr>
|
|
<tr class="separator:a35961f730828273d502ff2311c7cd83d"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table>
|
|
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
|
|
<div class="textblock"><p>The root of a game. </p>
|
|
<p>A game root node that manages levels and input devices. Can be loaded at any point in a game's life, but suggested is setting this as the root of the boot scene. </p>
|
|
</div><h2 class="groupheader">Member Function Documentation</h2>
|
|
<a id="aa9ed453a0b416641dfa5154a0b69c79e" name="aa9ed453a0b416641dfa5154a0b69c79e"></a>
|
|
<h2 class="memtitle"><span class="permalink"><a href="#aa9ed453a0b416641dfa5154a0b69c79e">◆ </a></span>get_levels()</h2>
|
|
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">gd::HashMap< gd::StringName, <a class="el" href="classutils_1_1Level3D.html">Level3D</a> * > & utils::GameRoot3D::get_levels </td>
|
|
<td>(</td>
|
|
<td class="paramname"></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Returns all currently active levels. </p>
|
|
<p>Levels are identified by their packed scene path. </p>
|
|
|
|
<p class="reference">References <a class="el" href="classutils_1_1GameRoot3D.html#a800421c3b82947156eebcbf730a680db">levels</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<a id="a865e6d9fe4f9422c0fb974bd6b1222ce" name="a865e6d9fe4f9422c0fb974bd6b1222ce"></a>
|
|
<h2 class="memtitle"><span class="permalink"><a href="#a865e6d9fe4f9422c0fb974bd6b1222ce">◆ </a></span>initialize_player()</h2>
|
|
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">bool utils::GameRoot3D::initialize_player </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="classutils_1_1IPlayer.html">IPlayer</a> * </td>
|
|
<td class="paramname"><em>player</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype">uint32_t </td>
|
|
<td class="paramname"><em>id</em> </td>
|
|
</tr>
|
|
<tr>
|
|
<td></td>
|
|
<td>)</td>
|
|
<td></td><td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Initialize and register a player instance. </p>
|
|
<p>The player will be added to the tree and AFTER setup_player_input will be called. This way the player can initialize before setting up input </p>
|
|
|
|
<p class="reference">References <a class="el" href="classutils_1_1GameRoot3D.html#acf48cbe3b2b6dd064cd1665ea8df2b9a">players</a>, <a class="el" href="classutils_1_1IPlayer.html#a0cafb35522002c12a00da6cb408e462c">utils::IPlayer::setup_player_input()</a>, and <a class="el" href="classutils_1_1IPlayer.html#aee51a05e36995e6523c3284b5cef1f42">utils::IPlayer::to_node()</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<a id="ad53d50b5b35e4c13bf84f2d9c0f45a0b" name="ad53d50b5b35e4c13bf84f2d9c0f45a0b"></a>
|
|
<h2 class="memtitle"><span class="permalink"><a href="#ad53d50b5b35e4c13bf84f2d9c0f45a0b">◆ </a></span>load_level_at()</h2>
|
|
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname"><a class="el" href="classutils_1_1Level3D.html">Level3D</a> * utils::GameRoot3D::load_level_at </td>
|
|
<td>(</td>
|
|
<td class="paramtype">gd::Ref< gd::PackedScene > </td>
|
|
<td class="paramname"><em>level</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype">gd::Transform3D </td>
|
|
<td class="paramname"><em>at</em> </td>
|
|
</tr>
|
|
<tr>
|
|
<td></td>
|
|
<td>)</td>
|
|
<td></td><td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Load a level, only works if 'level' is a valid scene where the root Node can cast to '<a class="el" href="classutils_1_1Level3D.html" title="3D level root to be used with GameRoot3D.">Level3D</a>'. </p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">at</td><td>Sets the root node's global transform. </td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
|
|
<p class="reference">References <a class="el" href="classutils_1_1GameRoot3D.html#abb25b7613e1c7cd4f056020e6990d8e1">game_mode</a>, <a class="el" href="classutils_1_1GameRoot3D.html#a77e4726bb8fec522669cbb2c068e47d9">is_valid_level()</a>, <a class="el" href="classutils_1_1GameRoot3D.html#af34016620adcdc2654358b463769a85f">level_unloaded()</a>, <a class="el" href="classutils_1_1GameRoot3D.html#a800421c3b82947156eebcbf730a680db">levels</a>, <a class="el" href="classutils_1_1GameRoot3D.html#acf48cbe3b2b6dd064cd1665ea8df2b9a">players</a>, and <a class="el" href="classutils_1_1GameRoot3D.html#a6c2a1aa2c35808a1b003ae79eac348c2">set_game_mode()</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<a id="a85eee9cb258971abe9fe8577314b2556" name="a85eee9cb258971abe9fe8577314b2556"></a>
|
|
<h2 class="memtitle"><span class="permalink"><a href="#a85eee9cb258971abe9fe8577314b2556">◆ </a></span>player_input_connected()</h2>
|
|
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void utils::GameRoot3D::player_input_connected </td>
|
|
<td>(</td>
|
|
<td class="paramname"></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Instantiate a new <a class="el" href="classutils_1_1PlayerInput.html" title="An event-driven input observer.">PlayerInput</a>. </p>
|
|
<p>Does not automatically spawn a new player, but does notify game mode. </p>
|
|
|
|
<p class="reference">References <a class="el" href="classutils_1_1GameRoot3D.html#af508cc9852b123ea37b94651da0f3c19">next_player_id</a>, and <a class="el" href="classutils_1_1GameRoot3D.html#acf48cbe3b2b6dd064cd1665ea8df2b9a">players</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<a id="adc4455c11d39f8a267091f29ead441ee" name="adc4455c11d39f8a267091f29ead441ee"></a>
|
|
<h2 class="memtitle"><span class="permalink"><a href="#adc4455c11d39f8a267091f29ead441ee">◆ </a></span>release_singleton()</h2>
|
|
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="mlabels">
|
|
<tr>
|
|
<td class="mlabels-left">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void utils::GameRoot3D::release_singleton </td>
|
|
<td>(</td>
|
|
<td class="paramname"></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</td>
|
|
<td class="mlabels-right">
|
|
<span class="mlabels"><span class="mlabel">protected</span></span> </td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Attempt to stop being the active singleton instance. </p>
|
|
<p>Only works if the current singleton is 'this'. </p>
|
|
|
|
</div>
|
|
</div>
|
|
<a id="a89953130655a618aefa8f3ea0db63a53" name="a89953130655a618aefa8f3ea0db63a53"></a>
|
|
<h2 class="memtitle"><span class="permalink"><a href="#a89953130655a618aefa8f3ea0db63a53">◆ </a></span>remove_player()</h2>
|
|
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void utils::GameRoot3D::remove_player </td>
|
|
<td>(</td>
|
|
<td class="paramtype">uint32_t </td>
|
|
<td class="paramname"><em>player_id</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Force-disconnect a player. </p>
|
|
<p>Calls queue_free on the <a class="el" href="classutils_1_1IPlayer.html" title="Interface required for player nodes.">IPlayer</a> instance </p>
|
|
|
|
<p class="reference">References <a class="el" href="classutils_1_1GameRoot3D.html#acf48cbe3b2b6dd064cd1665ea8df2b9a">players</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<a id="a453c8aa3920d7d0adaf2490c63a7d92c" name="a453c8aa3920d7d0adaf2490c63a7d92c"></a>
|
|
<h2 class="memtitle"><span class="permalink"><a href="#a453c8aa3920d7d0adaf2490c63a7d92c">◆ </a></span>replace_levels()</h2>
|
|
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void utils::GameRoot3D::replace_levels </td>
|
|
<td>(</td>
|
|
<td class="paramtype">gd::Ref< gd::PackedScene > </td>
|
|
<td class="paramname"><em>level</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Replace all currently loaded levels with a new level. </p>
|
|
<p>Shorthand for </p><div class="fragment"><div class="line"><a class="code hl_function" href="classutils_1_1GameRoot3D.html#a4053b12af23cef53eb294729f1cb3aa8">unload_all_levels</a>();</div>
|
|
<div class="line"><a class="code hl_function" href="classutils_1_1GameRoot3D.html#acbec3f7b39c8c991a725e611dd8b869e">load_level</a>(level);</div>
|
|
<div class="ttc" id="aclassutils_1_1GameRoot3D_html_a4053b12af23cef53eb294729f1cb3aa8"><div class="ttname"><a href="classutils_1_1GameRoot3D.html#a4053b12af23cef53eb294729f1cb3aa8">utils::GameRoot3D::unload_all_levels</a></div><div class="ttdeci">void unload_all_levels()</div><div class="ttdoc">Unload all currently loaded levels.</div><div class="ttdef"><b>Definition</b> game_root.cpp:133</div></div>
|
|
<div class="ttc" id="aclassutils_1_1GameRoot3D_html_acbec3f7b39c8c991a725e611dd8b869e"><div class="ttname"><a href="classutils_1_1GameRoot3D.html#acbec3f7b39c8c991a725e611dd8b869e">utils::GameRoot3D::load_level</a></div><div class="ttdeci">Level3D * load_level(gd::Ref< gd::PackedScene > level)</div><div class="ttdoc">shorthand for load_level(level, Transform3D())</div><div class="ttdef"><b>Definition</b> game_root.cpp:102</div></div>
|
|
</div><!-- fragment -->
|
|
<p class="reference">References <a class="el" href="classutils_1_1GameRoot3D.html#acbec3f7b39c8c991a725e611dd8b869e">load_level()</a>, and <a class="el" href="classutils_1_1GameRoot3D.html#a4053b12af23cef53eb294729f1cb3aa8">unload_all_levels()</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<a id="add087bf071383383e68e919173670c47" name="add087bf071383383e68e919173670c47"></a>
|
|
<h2 class="memtitle"><span class="permalink"><a href="#add087bf071383383e68e919173670c47">◆ </a></span>reset_game_mode()</h2>
|
|
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void utils::GameRoot3D::reset_game_mode </td>
|
|
<td>(</td>
|
|
<td class="paramname"></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Un-set game mode. </p>
|
|
<p>Shorthand for set_game_mode(Ref<GameMode>()) </p>
|
|
|
|
<p class="reference">References <a class="el" href="classutils_1_1GameRoot3D.html#a6c2a1aa2c35808a1b003ae79eac348c2">set_game_mode()</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<a id="a6c2a1aa2c35808a1b003ae79eac348c2" name="a6c2a1aa2c35808a1b003ae79eac348c2"></a>
|
|
<h2 class="memtitle"><span class="permalink"><a href="#a6c2a1aa2c35808a1b003ae79eac348c2">◆ </a></span>set_game_mode()</h2>
|
|
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void utils::GameRoot3D::set_game_mode </td>
|
|
<td>(</td>
|
|
<td class="paramtype">gd::Ref< <a class="el" href="classutils_1_1GameMode.html">GameMode</a> > </td>
|
|
<td class="paramname"><em>prototype</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Override the current gamemode. </p>
|
|
<p>Replaces game mode requires destroying and respawning all players </p>
|
|
|
|
<p class="reference">References <a class="el" href="classutils_1_1GameRoot3D.html#ab3895b9b48c4646a876e188d226c5723">find_empty_player_slot()</a>, <a class="el" href="classutils_1_1GameRoot3D.html#abb25b7613e1c7cd4f056020e6990d8e1">game_mode</a>, <a class="el" href="classutils_1_1GameRoot3D.html#a865e6d9fe4f9422c0fb974bd6b1222ce">initialize_player()</a>, and <a class="el" href="classutils_1_1GameRoot3D.html#a3e74ac9841575d9a915cf7ac6735b42b">spawn_player()</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<h2 class="groupheader">Member Data Documentation</h2>
|
|
<a id="af73d3a598b72fcdc7dce372ea3af6e44" name="af73d3a598b72fcdc7dce372ea3af6e44"></a>
|
|
<h2 class="memtitle"><span class="permalink"><a href="#af73d3a598b72fcdc7dce372ea3af6e44">◆ </a></span>game_state</h2>
|
|
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="mlabels">
|
|
<tr>
|
|
<td class="mlabels-left">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">gd::Ref<<a class="el" href="classutils_1_1GameState.html">GameState</a>> utils::GameRoot3D::game_state {}</td>
|
|
</tr>
|
|
</table>
|
|
</td>
|
|
<td class="mlabels-right">
|
|
<span class="mlabels"><span class="mlabel">private</span></span> </td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Active game state. </p>
|
|
<p>Will be assigned loaded save data, or game_state_prototype if no save data is found. </p>
|
|
|
|
</div>
|
|
</div>
|
|
<a id="af508cc9852b123ea37b94651da0f3c19" name="af508cc9852b123ea37b94651da0f3c19"></a>
|
|
<h2 class="memtitle"><span class="permalink"><a href="#af508cc9852b123ea37b94651da0f3c19">◆ </a></span>next_player_id</h2>
|
|
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="mlabels">
|
|
<tr>
|
|
<td class="mlabels-left">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">uint32_t utils::GameRoot3D::next_player_id {1}</td>
|
|
</tr>
|
|
</table>
|
|
</td>
|
|
<td class="mlabels-right">
|
|
<span class="mlabels"><span class="mlabel">private</span></span> </td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Next available player ID. </p>
|
|
<p>Default is 1 because 0 is the "invalid" player id. </p>
|
|
|
|
</div>
|
|
</div>
|
|
<hr/>The documentation for this class was generated from the following files:<ul>
|
|
<li><a class="el" href="game__root_8hpp_source.html">game_root.hpp</a></li>
|
|
<li>game_root.cpp</li>
|
|
</ul>
|
|
</div><!-- contents -->
|
|
<!-- start footer part -->
|
|
<hr class="footer"/><address class="footer"><small>
|
|
Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.7
|
|
</small></address>
|
|
</body>
|
|
</html>
|