make level dynamic from main

This commit is contained in:
2022-04-16 17:20:45 -04:00
committed by Gitea
parent f3656fe4b4
commit 97d84ef36a
3 changed files with 39 additions and 3 deletions

View File

@@ -5,6 +5,8 @@
#include <Node.hpp>
#include <OS.hpp>
#include <Input.hpp>
#include <PackedScene.hpp>
#include <Ref.hpp>
/**
* @brief This is the godot namespace for all the code included in the library.
@@ -57,6 +59,11 @@ namespace godot
*/
Input *_input;
/**
* @brief The first level to load
*
*/
Ref<PackedScene> level;
/**
* @brief If the window is full screen or not.
*
@@ -116,6 +123,20 @@ namespace godot
*/
void _physics_process(float delta);
/**
* @brief Set the level object.
*
* @param[in] level The new level to load when starting.
*/
void set_level(Ref<PackedScene> level);
/**
* @brief Get the level object.
*
* @return Ref<PackedScene> The level scene to load.
*/
Ref<PackedScene> get_level();
/**
* @brief Set the full screen object.
*