summaryrefslogtreecommitdiff
path: root/src/content_cao.h
diff options
context:
space:
mode:
authorNils Dagsson Moskopp <nils@dieweltistgarnichtso.net>2011-07-20 22:04:24 +0200
committerNils Dagsson Moskopp <nils@dieweltistgarnichtso.net>2011-07-20 22:05:57 +0200
commit8129d16dd3f7e5575c444b4792e667a1e3df98e2 (patch)
tree1c3e56bba8c197275bc63b97d8a18620a3523560 /src/content_cao.h
parent4cbdf136fc70016f2721db311bda5ade7a3cdab8 (diff)
downloadminetest-8129d16dd3f7e5575c444b4792e667a1e3df98e2.tar.gz
minetest-8129d16dd3f7e5575c444b4792e667a1e3df98e2.tar.bz2
minetest-8129d16dd3f7e5575c444b4792e667a1e3df98e2.zip
+ fireflies
Diffstat (limited to 'src/content_cao.h')
-rw-r--r--src/content_cao.h42
1 files changed, 42 insertions, 0 deletions
diff --git a/src/content_cao.h b/src/content_cao.h
index 146e23b0c..b984be136 100644
--- a/src/content_cao.h
+++ b/src/content_cao.h
@@ -243,6 +243,48 @@ private:
bool m_damage_texture_enabled;
};
+/*
+ FireflyCAO
+*/
+
+class FireflyCAO : public ClientActiveObject
+{
+public:
+ FireflyCAO();
+ virtual ~FireflyCAO();
+
+ u8 getType() const
+ {
+ return ACTIVEOBJECT_TYPE_FIREFLY;
+ }
+
+ static ClientActiveObject* create();
+
+ void addToScene(scene::ISceneManager *smgr);
+ void removeFromScene();
+ void updateLight(u8 light_at_pos);
+ v3s16 getLightPosition();
+ void updateNodePos();
+
+ void step(float dtime, ClientEnvironment *env);
+
+ void processMessage(const std::string &data);
+
+ void initialize(const std::string &data);
+
+ core::aabbox3d<f32>* getSelectionBox()
+ {return &m_selection_box;}
+ v3f getPosition()
+ {return m_position;}
+
+private:
+ core::aabbox3d<f32> m_selection_box;
+ scene::IMeshSceneNode *m_node;
+ v3f m_position;
+ float m_yaw;
+ SmoothTranslator pos_translator;
+};
+
#endif