summaryrefslogtreecommitdiffstats
path: root/src/motionhuman.h
diff options
context:
space:
mode:
authoradiblol <adiblol@1tbps.org>2012-03-08 19:32:05 +0100
committeradiblol <adiblol@1tbps.org>2012-03-08 19:32:05 +0100
commita4c804b49ec872b71bd5a0167c3ad45704a3cc30 (patch)
tree8c931235247d662ca46a99695beb328fdfc8e8a8 /src/motionhuman.h
downloadcolobot-a4c804b49ec872b71bd5a0167c3ad45704a3cc30.tar.gz
colobot-a4c804b49ec872b71bd5a0167c3ad45704a3cc30.tar.bz2
colobot-a4c804b49ec872b71bd5a0167c3ad45704a3cc30.zip
Initial commit, Copyright (C) 2001-2008, Daniel ROUX & EPSITEC SA, www.epsitec.ch
Diffstat (limited to 'src/motionhuman.h')
-rw-r--r--src/motionhuman.h82
1 files changed, 82 insertions, 0 deletions
diff --git a/src/motionhuman.h b/src/motionhuman.h
new file mode 100644
index 0000000..d312c97
--- /dev/null
+++ b/src/motionhuman.h
@@ -0,0 +1,82 @@
+// motionhuman.h
+
+#ifndef _MOTIONHUMAN_H_
+#define _MOTIONHUMAN_H_
+
+
+class CInstanceManager;
+class CEngine;
+class CLight;
+class CParticule;
+class CTerrain;
+class CCamera;
+class CBrain;
+class CPhysics;
+class CObject;
+
+
+#define MH_MARCH 0
+#define MH_MARCHTAKE 1
+#define MH_TURN 2
+#define MH_STOP 3
+#define MH_FLY 4
+#define MH_SWIM 5
+#define MH_SPEC 6
+
+#define MHS_FIRE 0
+#define MHS_GUN 1
+#define MHS_TAKE 2
+#define MHS_TAKEOTHER 3
+#define MHS_TAKEHIGH 4
+#define MHS_UPRIGHT 5
+#define MHS_WIN 6
+#define MHS_LOST 7
+#define MHS_DEADg 8
+#define MHS_DEADg1 9
+#define MHS_DEADg2 10
+#define MHS_DEADg3 11
+#define MHS_DEADg4 12
+#define MHS_DEADw 13
+#define MHS_FLAG 14
+#define MHS_SATCOM 15
+
+
+class CMotionHuman : public CMotion
+{
+public:
+ CMotionHuman(CInstanceManager* iMan, CObject* object);
+ ~CMotionHuman();
+
+ void DeleteObject(BOOL bAll=FALSE);
+ BOOL Create(D3DVECTOR pos, float angle, ObjectType type, float power);
+ BOOL EventProcess(const Event &event);
+ Error SetAction(int action, float time=0.2f);
+
+ void StartDisplayPerso();
+ void StopDisplayPerso();
+
+protected:
+ void CreatePhysics(ObjectType type);
+ BOOL EventFrame(const Event &event);
+
+protected:
+ int m_partiReactor;
+ float m_armMember;
+ float m_armTimeAbs;
+ float m_armTimeAction;
+ float m_armTimeSwim;
+ short m_armAngles[3*3*3*3*7 + 3*3*3*16];
+ int m_armTimeIndex;
+ int m_armPartIndex;
+ int m_armMemberIndex;
+ int m_armLastAction;
+ BOOL m_bArmStop;
+ float m_lastSoundMarch;
+ float m_lastSoundHhh;
+ float m_time;
+ float m_tired;
+ BOOL m_bDisplayPerso;
+};
+
+
+#endif //_MOTIONHUMAN_H_