]> Dogcows Code - chaz/yoink/blobdiff - src/Character.hh
minor refactoring and state progress
[chaz/yoink] / src / Character.hh
index 19559f38b0f54be1643f31fc29f2949323be977b..5dfde01922860cbbbe6759f00eacc5a13b1f2bee 100644 (file)
 
 #include <boost/shared_ptr.hpp>
 
+#include <Moof/Aabb.hh>
 #include <Moof/Entity.hh>
 #include <Moof/Math.hh>
-#include <Moof/RK4.hh>
+#include <Moof/Octree.hh>
+#include <Moof/RigidBody.hh>
+#include <Moof/Sphere.hh>
 
 #include "Animation.hh"
 #include "Tilemap.hh"
@@ -49,12 +52,8 @@ typedef boost::shared_ptr<Character> CharacterP;
  * includes the heroine herself and the bad guys.
  */
 
-struct Character : public Mf::Entity
+class Character : public Mf::RigidBody2, public Mf::OctreeInsertable
 {
-protected:
-
-       Mf::Vector2 userForce;
-
 public:
 
        Character(const std::string& name);
@@ -63,9 +62,14 @@ public:
        virtual void update(Mf::Scalar t, Mf::Scalar dt);
        virtual void draw(Mf::Scalar alpha) const;
 
+       virtual int getOctant(const Mf::Aabb& aabb) const;
 
        Tilemap         tilemap;
        Animation       animation;
+
+private:
+
+       static const Mf::Scalar z = 96.0;
 };
 
 
This page took 0.019917 seconds and 4 git commands to generate.