mirror of
https://github.com/luanti-org/luanti.git
synced 2025-10-15 01:25:20 +02:00
ContentCAO: Fix broken attachments on join (#8701)
What happened: 1) Object data is received. Client begins to read the data 2) Client initializes all its children (gob_cmd_update_infant) 3) Children try to attach to parent (yet not added) 4) Parent initializes, is added to the environment And somewhere in between, Irrlicht wrecks up the attachments due to the missing matrix node. The solution here is to: 1) Use the same structure as ServerActiveObject 2) Attach all children after the parent is really initialized
This commit is contained in:
@@ -138,8 +138,6 @@ public:
|
||||
std::vector<PointedThing> &objects
|
||||
);
|
||||
|
||||
u16 attachement_parent_ids[USHRT_MAX + 1];
|
||||
|
||||
const std::list<std::string> &getPlayerNames() { return m_player_names; }
|
||||
void addPlayerName(const std::string &name) { m_player_names.push_back(name); }
|
||||
void removePlayerName(const std::string &name) { m_player_names.remove(name); }
|
||||
|
Reference in New Issue
Block a user