18 #ifndef __PSMOVEMENT_H__ 19 #define __PSMOVEMENT_H__ 21 #include <csutil/parray.h> 22 #include <csutil/csstring.h> 23 #include <csgeom/vector3.h> 100 void SetupControls();
106 void UpdateVelocity();
150 bool HandleEvent(iEvent& event);
158 const psCharMode* FindCharMode(
const char* name)
const;
159 const psMovement* FindMovement(
const char* name)
const;
163 void LockMoves(
bool v);
173 void StopAllMovement();
176 void StopControlledMovement();
183 void LoadMouseSettings();
185 void MouseLookCanAct(
bool v);
188 void MouseLook(
bool v);
190 void MouseLook(iEvent& ev);
191 void UpdateMouseLook();
195 void MouseZoom(iEvent& ev);
199 void SetRunToPos(
psPoint& mouse);
203 void ToggleAutoMove();
217 bool SetRun(
bool runState);
psVelocity & operator-=(const psVelocity &v)
Manages main character movements.
uint32 id
ID of this movement type from server DB.
csString idle_anim
Base animation for this mode.
This is a player or another 'alive' entity on the client.
const psCharMode * defaultmode
Default actor mode.
bool IsReady()
Ready to receive events?
Manages button functions and triggers.
csVector3 rotate
Angular velocity.
csPDelArray< psMovement > moves
All available movement types.
const psCharMode * actormode
Current active mode.
const psMovement * backward
bool onGround
Is actor on ground or airborne?
void SetMouseSensY(float v)
A character movement and its properties.
The structure of 1 queue entry (pointer to a message)
uint activeMoves
Bit mask for active moves.
psVelocity modifier
Velocity multiplier for this mode.
uint32 id
ID of this character mode from server DB.
csString name
Name of this movement.
Used to save movement state to detect changes.
GEMClientActor * ControlledActor()
psVelocity move_total
Current total of all active move velocities.
psVelocity & operator=(const psVelocity &v)
bool ready
Have movements been setup?
csVector3 move
Translational velocity.
csString name
Name of this mode.
psVelocity & operator/=(const psVelocity &v)
bool locked
Is this player allowed to move?
csEventID event_mousemove
void SetMouseMove(bool v)
void SetMouseSensX(float v)
const psMovement * forward
psVelocity(csVector3 m, csVector3 r)
bool MoveStateChanged(psMoveState &state)
An entity's translational and angular velocity.
A character mode and its properties.
psVelocity & operator*=(const psVelocity &v)
void SaveMoveState(psMoveState &state)
csPDelArray< psCharMode > modes
All available character modes.
psVelocity & operator+=(const psVelocity &v)
psMoveModMsg::ModType activeModType
psVelocity motion
Motion aplied for this movement.
const char * GetModeIdleAnim(size_t id) const
const psCharMode * FindCharMode(size_t id) const
void SetInvertedMouse(bool v)
psControlManager * controls
GEMClientActor * actor
Actor we're moving here.