ClientActiveObject(u16 id, Client *client, ClientEnvironment *env);
virtual ~ClientActiveObject();
- virtual void addToScene(scene::ISceneManager *smgr, ITextureSource *tsrc,
- IrrlichtDevice *irr){}
- virtual void removeFromScene(bool permanent){}
+ virtual void addToScene(scene::ISceneManager *smgr, ITextureSource *tsrc) {};
+ virtual void removeFromScene(bool permanent) {}
// 0 <= light_at_pos <= LIGHT_SUN
virtual void updateLight(u8 light_at_pos){}
virtual void updateLightNoCheck(u8 light_at_pos){}
static ClientActiveObject* create(Client *client, ClientEnvironment *env);
- void addToScene(scene::ISceneManager *smgr, ITextureSource *tsrc,
- IrrlichtDevice *irr);
+ void addToScene(scene::ISceneManager *smgr, ITextureSource *tsrc);
void removeFromScene(bool permanent);
void updateLight(u8 light_at_pos);
v3s16 getLightPosition();
return new TestCAO(client, env);
}
-void TestCAO::addToScene(scene::ISceneManager *smgr, ITextureSource *tsrc,
- IrrlichtDevice *irr)
+void TestCAO::addToScene(scene::ISceneManager *smgr, ITextureSource *tsrc)
{
if(m_node != NULL)
return;
static ClientActiveObject* create(Client *client, ClientEnvironment *env);
- void addToScene(scene::ISceneManager *smgr, ITextureSource *tsrc,
- IrrlichtDevice *irr);
+ void addToScene(scene::ISceneManager *smgr, ITextureSource *tsrc);
void removeFromScene(bool permanent);
void updateLight(u8 light_at_pos);
v3s16 getLightPosition();
return new ItemCAO(client, env);
}
-void ItemCAO::addToScene(scene::ISceneManager *smgr, ITextureSource *tsrc,
- IrrlichtDevice *irr)
+void ItemCAO::addToScene(scene::ISceneManager *smgr, ITextureSource *tsrc)
{
if(m_node != NULL)
return;
}
}
-void GenericCAO::addToScene(scene::ISceneManager *smgr,
- ITextureSource *tsrc, IrrlichtDevice *irr)
+void GenericCAO::addToScene(scene::ISceneManager *smgr, ITextureSource *tsrc)
{
m_smgr = smgr;
- m_irr = irr;
if (getSceneNode() != NULL) {
return;
}
}
- if(m_visuals_expired && m_smgr && m_irr){
+ if (m_visuals_expired && m_smgr) {
m_visuals_expired = false;
// Attachments, part 1: All attached objects must be unparented first,
}
removeFromScene(false);
- addToScene(m_smgr, m_client->tsrc(), m_irr);
+ addToScene(m_smgr, m_client->tsrc());
// Attachments, part 2: Now that the parent has been refreshed, put its attachments back
for (std::vector<u16>::size_type i = 0; i < m_children.size(); i++) {
ObjectProperties m_prop;
//
scene::ISceneManager *m_smgr = nullptr;
- IrrlichtDevice *m_irr = nullptr;
Client *m_client = nullptr;
aabb3f m_selection_box = aabb3f(-BS/3.,-BS/3.,-BS/3., BS/3.,BS/3.,BS/3.);
scene::IMeshSceneNode *m_meshnode = nullptr;
void removeFromScene(bool permanent);
- void addToScene(scene::ISceneManager *smgr, ITextureSource *tsrc,
- IrrlichtDevice *irr);
+ void addToScene(scene::ISceneManager *smgr, ITextureSource *tsrc);
inline void expireVisuals()
{