28 lines
No EOL
606 B
C++
28 lines
No EOL
606 B
C++
#ifndef _GAME_H
|
|
#define _GAME_H
|
|
|
|
#include <Components/TopLevel/GameObject.hpp>
|
|
#include <Components/TopLevel/Game.hpp>
|
|
|
|
#include <vendor/LuaBridge3/Source/LuaBridge/LuaBridge.h> // Pain
|
|
|
|
struct Game : public GameObject {
|
|
Game() : GameObject("game") {
|
|
std::cout << "Game: created\n";
|
|
}
|
|
|
|
bool isGame() {
|
|
return true;
|
|
}
|
|
};
|
|
|
|
void registerGame(lua_State* L) {
|
|
luabridge::getGlobalNamespace (L)
|
|
.beginNamespace ("Core")
|
|
.deriveClass <Game, GameObject> ("Game")
|
|
.addFunction ("isGame", &Game::isGame)
|
|
.endClass ()
|
|
.endNamespace ();
|
|
}
|
|
|
|
#endif |