mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Scripting WIP
This commit is contained in:
parent
ee8b6d3444
commit
bfc68d3151
22 changed files with 1212 additions and 187 deletions
|
@ -21,8 +21,8 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
#include <fstream>
|
||||
#include "inventory.h"
|
||||
|
||||
ServerActiveObject::ServerActiveObject(ServerEnvironment *env, u16 id, v3f pos):
|
||||
ActiveObject(id),
|
||||
ServerActiveObject::ServerActiveObject(ServerEnvironment *env, v3f pos):
|
||||
ActiveObject(0),
|
||||
m_known_by_count(0),
|
||||
m_removed(false),
|
||||
m_pending_deactivation(false),
|
||||
|
@ -37,6 +37,11 @@ ServerActiveObject::~ServerActiveObject()
|
|||
{
|
||||
}
|
||||
|
||||
void ServerActiveObject::addedToEnvironment(u16 id)
|
||||
{
|
||||
setId(id);
|
||||
}
|
||||
|
||||
ServerActiveObject* ServerActiveObject::create(u8 type,
|
||||
ServerEnvironment *env, u16 id, v3f pos,
|
||||
const std::string &data)
|
||||
|
@ -53,7 +58,7 @@ ServerActiveObject* ServerActiveObject::create(u8 type,
|
|||
}
|
||||
|
||||
Factory f = n->getValue();
|
||||
ServerActiveObject *object = (*f)(env, id, pos, data);
|
||||
ServerActiveObject *object = (*f)(env, pos, data);
|
||||
return object;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue