1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

Schematics: Refactor NodeResolver and add NodeResolveMethod

NodeResolver name lists now belong to the NodeResolver object instead of
the associated NodeDefManager.  In addition to minimizing unnecessary
abstraction and overhead, this move permits NodeResolvers to look up nodes
that they had previously set pending for resolution.  So far, this
functionality has been used in the case of schematics for
serialization/deserialization.
This commit is contained in:
kwolekr 2015-04-16 04:12:26 -04:00
parent 0c634a9719
commit 479f38973e
17 changed files with 493 additions and 458 deletions

View file

@ -388,7 +388,7 @@ void Client::step(float dtime)
if(counter <= 0.0) {
counter = 2.0;
Player *myplayer = m_env.getLocalPlayer();
Player *myplayer = m_env.getLocalPlayer();
FATAL_ERROR_IF(myplayer == NULL, "Local player not found in environment.");
// Send TOSERVER_INIT_LEGACY
@ -1631,7 +1631,7 @@ void Client::afterContentReceived(IrrlichtDevice *device)
draw_load_screen(text, device, guienv, 0, 72);
m_nodedef->updateAliases(m_itemdef);
m_nodedef->setNodeRegistrationStatus(true);
m_nodedef->runNodeResolverCallbacks();
m_nodedef->runNodeResolveCallbacks();
delete[] text;
// Update node textures and assign shaders to each tile