'ifnot' template property + hpp

This commit is contained in:
MihailRis
2024-05-06 00:45:43 +03:00
parent 8b1c102cfe
commit 9ea67deb13
59 changed files with 204 additions and 201 deletions
+6 -5
View File
@@ -1,11 +1,12 @@
#include "LuaState.h"
#include "LuaState.hpp"
#include "lua_util.hpp"
#include "api_lua.hpp"
#include "../../../debug/Logger.hpp"
#include "../../../util/stringutil.h"
#include <iomanip>
#include <iostream>
#include "lua_util.h"
#include "api_lua.h"
#include "../../../debug/Logger.hpp"
#include "../../../util/stringutil.h"
inline std::string LAMBDAS_TABLE = "$L";
@@ -1,9 +1,7 @@
#ifndef LOGIC_SCRIPTING_LUA_STATE_H_
#define LOGIC_SCRIPTING_LUA_STATE_H_
#ifndef LOGIC_SCRIPTING_LUA_STATE_HPP_
#define LOGIC_SCRIPTING_LUA_STATE_HPP_
#include "lua_commons.h"
#include <string>
#include <stdexcept>
#include "lua_commons.hpp"
#include "../../../data/dynamic.h"
#include "../../../delegates.h"
@@ -12,6 +10,9 @@
#error LuaJIT required
#endif
#include <string>
#include <stdexcept>
namespace lua {
class luaerror : public std::runtime_error {
public:
@@ -76,4 +77,4 @@ namespace lua {
};
}
#endif // LOGIC_SCRIPTING_LUA_STATE_H_
#endif // LOGIC_SCRIPTING_LUA_STATE_HPP_
@@ -1,8 +1,9 @@
#ifndef LOGIC_SCRIPTING_API_LUA_H_
#define LOGIC_SCRIPTING_API_LUA_H_
#ifndef LOGIC_SCRIPTING_API_LUA_HPP_
#define LOGIC_SCRIPTING_API_LUA_HPP_
#include "lua_commons.hpp"
#include <exception>
#include "lua_commons.h"
// Libraries
extern const luaL_Reg audiolib [];
@@ -23,4 +24,4 @@ extern const luaL_Reg inputlib [];
// Lua Overrides
extern int l_print(lua_State* L);
#endif // LOGIC_SCRIPTING_API_LUA_H_
#endif // LOGIC_SCRIPTING_API_LUA_HPP_
+4 -4
View File
@@ -1,8 +1,8 @@
#include "api_lua.h"
#include "lua_commons.h"
#include "lua_util.h"
#include "api_lua.hpp"
#include "lua_commons.hpp"
#include "lua_util.hpp"
#include "../../../audio/audio.h"
#include "../../../audio/audio.hpp"
#include "../../../engine.h"
#include "../scripting.h"
+3 -3
View File
@@ -1,6 +1,6 @@
#include "lua_commons.h"
#include "api_lua.h"
#include "lua_util.h"
#include "lua_commons.hpp"
#include "api_lua.hpp"
#include "lua_util.hpp"
#include "../scripting.h"
#include "../../../world/Level.h"
#include "../../../voxels/Chunks.h"
+3 -3
View File
@@ -1,6 +1,6 @@
#include "lua_commons.h"
#include "api_lua.h"
#include "LuaState.h"
#include "lua_commons.hpp"
#include "api_lua.hpp"
#include "LuaState.hpp"
#include "../../../engine.h"
#include "../../../files/settings_io.hpp"
+2 -2
View File
@@ -1,5 +1,5 @@
#include "lua_commons.h"
#include "api_lua.h"
#include "lua_commons.hpp"
#include "api_lua.hpp"
#include "../scripting.h"
#include "../../../engine.h"
#include "../../../files/files.h"
+5 -7
View File
@@ -1,11 +1,9 @@
#include "lua_commons.h"
#include "api_lua.h"
#include "lua_commons.hpp"
#include "api_lua.hpp"
#include "lua_util.hpp"
#include "LuaState.hpp"
#include <iostream>
#include "../scripting.h"
#include "lua_util.h"
#include "LuaState.h"
#include "../../../engine.h"
#include "../../../assets/Assets.h"
#include "../../../items/Inventories.h"
@@ -18,7 +16,7 @@
#include "../../../graphics/ui/elements/Panel.hpp"
#include "../../../graphics/ui/elements/Menu.hpp"
#include "../../../graphics/ui/elements/InventoryView.hpp"
#include "../../../frontend/UiDocument.h"
#include "../../../frontend/UiDocument.hpp"
#include "../../../frontend/locale/langs.h"
#include "../../../util/stringutil.h"
#include "../../../world/Level.h"
+6 -5
View File
@@ -1,11 +1,12 @@
#include "lua_commons.h"
#include "api_lua.h"
#include "LuaState.h"
#include "lua_commons.hpp"
#include "api_lua.hpp"
#include "LuaState.hpp"
#include "../../../assets/Assets.h"
#include "../../../content/Content.h"
#include "../../../engine.h"
#include "../../../frontend/hud.h"
#include "../../../frontend/UiDocument.h"
#include "../../../frontend/hud.hpp"
#include "../../../frontend/UiDocument.hpp"
#include "../../../graphics/ui/elements/InventoryView.hpp"
#include "../../../items/Inventories.h"
#include "../../../logic/BlocksController.h"
+4 -5
View File
@@ -1,15 +1,14 @@
#include "api_lua.h"
#include "lua_commons.h"
#include "api_lua.hpp"
#include "lua_commons.hpp"
#include "LuaState.hpp"
#include "../scripting.h"
#include "../../../window/input.hpp"
#include "../../../window/Events.hpp"
#include "../../../frontend/screens/Screen.hpp"
#include "../../../frontend/hud.h"
#include "../../../frontend/hud.hpp"
#include "../../../engine.h"
#include "LuaState.h"
namespace scripting {
extern lua::LuaState* state;
extern Hud* hud;
+3 -4
View File
@@ -1,7 +1,6 @@
#include "lua_commons.h"
#include "api_lua.h"
#include "lua_util.h"
#include "lua_commons.hpp"
#include "api_lua.hpp"
#include "lua_util.hpp"
#include "../scripting.h"
#include "../../../content/Content.h"
#include "../../../world/Level.h"
+2 -2
View File
@@ -1,5 +1,5 @@
#include "lua_commons.h"
#include "api_lua.h"
#include "lua_commons.hpp"
#include "api_lua.hpp"
#include "../scripting.h"
#include "../../../content/Content.h"
#include "../../../items/ItemDef.h"
+3 -4
View File
@@ -1,7 +1,6 @@
#include "api_lua.h"
#include "lua_commons.h"
#include "LuaState.h"
#include "api_lua.hpp"
#include "lua_commons.hpp"
#include "LuaState.hpp"
#include "../../../coders/json.h"
#include "../../../data/dynamic.h"
+2 -2
View File
@@ -1,5 +1,5 @@
#include "api_lua.h"
#include "lua_commons.h"
#include "api_lua.hpp"
#include "lua_commons.hpp"
#include "../scripting.h"
#include "../../../engine.h"
#include "../../../assets/AssetsLoader.h"
+2 -2
View File
@@ -1,5 +1,5 @@
#include "lua_commons.h"
#include "api_lua.h"
#include "lua_commons.hpp"
#include "api_lua.hpp"
#include "../scripting.h"
#include "../../../world/Level.h"
#include "../../../objects/Player.h"
+2 -2
View File
@@ -1,5 +1,5 @@
#include "api_lua.h"
#include "lua_commons.h"
#include "api_lua.hpp"
#include "lua_commons.hpp"
#include "../scripting.h"
#include "../../../engine.h"
#include "../../../window/Window.hpp"
+2 -2
View File
@@ -1,5 +1,5 @@
#include "lua_commons.h"
#include "api_lua.h"
#include "lua_commons.hpp"
#include "api_lua.hpp"
#include "../scripting.h"
#include "../../../assets/Assets.h"
#include "../../../assets/AssetsLoader.h"
@@ -1,5 +1,5 @@
#ifndef LOGIC_SCRIPTING_LUA_H_
#define LOGIC_SCRIPTING_LUA_H_
#ifndef LOGIC_SCRIPTING_LUA_HPP_
#define LOGIC_SCRIPTING_LUA_HPP_
#ifdef __linux__
#include <luajit-2.1/luaconf.h>
@@ -30,4 +30,4 @@ template <lua_CFunction func> int lua_wrap_errors(lua_State *L) {
return result;
}
#endif // LOGIC_SCRIPTING_LUA_H_
#endif // LOGIC_SCRIPTING_LUA_HPP_
+2 -2
View File
@@ -1,5 +1,5 @@
#include "api_lua.h"
#include "lua_commons.h"
#include "api_lua.hpp"
#include "lua_commons.hpp"
#include <iostream>
@@ -1,6 +1,8 @@
#ifndef LOGIC_SCRIPTING_LUA_UTIL_H_
#define LOGIC_SCRIPTING_LUA_UTIL_H_
#include "LuaState.hpp"
#ifdef __linux__
#include <luajit-2.1/luaconf.h>
#include <luajit-2.1/lua.hpp>
@@ -8,7 +10,6 @@
#include <lua.hpp>
#endif
#include <glm/glm.hpp>
#include "LuaState.h"
namespace lua {
inline int pushivec3(lua_State* L, luaint x, luaint y, luaint z) {