mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Move scriptapi to separate folder (by sapier)
On the lua side, notably minetest.env:<function>(<args>) should now be replaced by minetest.<function>(<args>). The old way is and will stay supported for a long time. Also: Update and clean up lua_api.txt (by celeron55) Move EnvRef to lua and remove add_rat and add_firefly (by kahrl) Add separate src/util/CMakeLists.txt, other minor fixes (by kahrl)
This commit is contained in:
parent
865f380c91
commit
ab43377577
87 changed files with 6401 additions and 5584 deletions
|
@ -50,6 +50,7 @@ class IGameDef;
|
|||
class Map;
|
||||
class ServerMap;
|
||||
class ClientMap;
|
||||
class ScriptApi;
|
||||
|
||||
class Environment
|
||||
{
|
||||
|
@ -190,7 +191,7 @@ public:
|
|||
class ServerEnvironment : public Environment
|
||||
{
|
||||
public:
|
||||
ServerEnvironment(ServerMap *map, lua_State *L, IGameDef *gamedef,
|
||||
ServerEnvironment(ServerMap *map, ScriptApi *iface, IGameDef *gamedef,
|
||||
IBackgroundBlockEmerger *emerger);
|
||||
~ServerEnvironment();
|
||||
|
||||
|
@ -198,8 +199,9 @@ public:
|
|||
|
||||
ServerMap & getServerMap();
|
||||
|
||||
lua_State* getLua()
|
||||
{ return m_lua; }
|
||||
//TODO find way to remove this fct!
|
||||
ScriptApi* getScriptIface()
|
||||
{ return m_script; }
|
||||
|
||||
IGameDef *getGameDef()
|
||||
{ return m_gamedef; }
|
||||
|
@ -348,7 +350,7 @@ private:
|
|||
// The map
|
||||
ServerMap *m_map;
|
||||
// Lua state
|
||||
lua_State *m_lua;
|
||||
ScriptApi* m_script;
|
||||
// Game definition
|
||||
IGameDef *m_gamedef;
|
||||
// Background block emerger (the server, in practice)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue