altEngine
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Public Member Functions | Public Attributes | List of all members
RigidBody Class Reference

#include <rigidbody.h>

Inheritance diagram for RigidBody:
Inheritance graph
[legend]
Collaboration diagram for RigidBody:
Collaboration graph
[legend]

Public Member Functions

 RigidBody (Entity *entity)
 
void recalc ()
 
virtual void integrate (float time)
 
bool collision_detect (vec3 &v)
 
bool collision_detect (Plane &p)
 
bool collision_detect_simple (RigidBody &body)
 
bool collision_detect (RigidBody &body)
 
bool collision_distance (RigidBody &body)
 
void impulse (Plane &plane, vec3 &vertex)
 
void impulse (RigidBody &rigid, vec3 &point)
 
void impulse (RigidBody &rigid, vec3 &point, Plane &plane)
 
void frame2ent (Frame *camera_frame, input_t &input)
 
void frame2ent_yaw (Frame *camera_frame, input_t &input)
 
void save_config (cfg_t &config)
 
void load_config (cfg_t &config)
 
void get_frame (Frame &frame)
 
void seek (const vec3 &position)
 
void flee (const vec3 &position)
 
void arrive (const vec3 &position)
 
void pursue ()
 
void evade ()
 
void wander (float radius, float distance, float jitter)
 
void set_target (Entity &target)
 
bool move (input_t &input, float speed_scale)
 
void move_forward (float speed_scale)
 
void move_backward (float speed_scale)
 
void move_left (float speed_scale)
 
void move_right (float speed_scale)
 
void move_up (float speed_scale)
 
void move_down (float speed_scale)
 
void lookat (vec3 &target)
 
void lookat_yaw (vec3 &target)
 
void pid_follow_path (vec3 *path_list, int num_path, float max_velocity, float distance, int wait)
 
int train_follow_path (vec3 *target, float max_velocity, float distance, int wait)
 
float get_volume ()
 
float get_height ()
 
float * get_matrix (float *matrix)
 
- Public Member Functions inherited from Model
 Model (Entity *entity)
 
 Model ()
 
virtual ~Model ()
 
void calc_frustum (matrix4 &clip)
 
void load (Graphics &gfx, char *file)
 
void create_box (Graphics &gfx, vec3 *aabb)
 
void render (Graphics &gfx)
 
void render_box (Graphics &gfx)
 
void clone (Model &model)
 
void getForwardVector (vec3 &forward)
 
void make_aabb ()
 

Public Attributes

unsigned int impact_index
 
bool on_ground
 
bool hard_impact
 
float impact_velocity
 
bool pursue_flag
 
bool step_flag
 
Entitytarget
 
vec3 sphere_target
 
int jump_timer
 
unsigned int bounce
 
float restitution
 
bool sleep
 
int y_offset
 
bool gravity
 
bool noclip
 
bool flight
 
bool water
 
bool last_water
 
bool lava
 
bool slime
 
int step_type
 
int bsp_trigger_volume
 
int bsp_model_platform
 
bool rotational_friction_flag
 
bool translational_friction_flag
 
bool ground_friction_flag
 
float rotational_friction
 
float translational_friction
 
float water_depth
 
float mass
 
matrix3 inverse_tensor
 
matrix3 world_tensor
 
vec3 velocity
 
vec3 angular_velocity
 
vec3 net_force
 
vec3 net_torque
 
vec3 old_position
 
matrix3 old_orientation
 
vec3 wishdir
 
train_t train
 
func_path_t path
 
pid_state_t pid
 
- Public Attributes inherited from Model
Entityentity
 
int num_vertex
 
int num_index
 
vertex_tmodel_vertex_array
 
unsigned int * model_index_array
 
char * model_file
 
char * index_file
 
int model_vertex
 
int model_index
 
int model_tex
 
int normal_tex
 
matrix3 morientation
 
vec3 aabb [8]
 
int box_vertex
 
int box_index
 
vec3 center
 
vec4 frustum [6]
 
char name [128]
 
bool blend
 
bool cull_none
 
bool rail_trail
 
bool lightning_trail
 

Additional Inherited Members

- Static Public Member Functions inherited from Model
static void CreateObjects (Graphics &gfx)
 
- Static Public Attributes inherited from Model
static int quad_vertex = 0
 
static int quad_index = 0
 
static int cube_vertex = 0
 
static int cube_index = 0
 
static int skybox_vertex
 
static int skybox_index
 

Constructor & Destructor Documentation

RigidBody::RigidBody ( Entity entity)

Here is the call graph for this function:

Member Function Documentation

void RigidBody::arrive ( const vec3 position)

Here is the call graph for this function:

bool RigidBody::collision_detect ( vec3 v)

Here is the caller graph for this function:

bool RigidBody::collision_detect ( Plane p)

Here is the call graph for this function:

bool RigidBody::collision_detect ( RigidBody body)

Here is the call graph for this function:

bool RigidBody::collision_detect_simple ( RigidBody body)

Here is the call graph for this function:

bool RigidBody::collision_distance ( RigidBody body)

Here is the call graph for this function:

Here is the caller graph for this function:

void RigidBody::evade ( )

Here is the call graph for this function:

Here is the caller graph for this function:

void RigidBody::flee ( const vec3 position)

Here is the call graph for this function:

Here is the caller graph for this function:

void RigidBody::frame2ent ( Frame camera_frame,
input_t input 
)

Here is the call graph for this function:

void RigidBody::frame2ent_yaw ( Frame camera_frame,
input_t input 
)

Here is the call graph for this function:

void RigidBody::get_frame ( Frame frame)
virtual

Reimplemented from Model.

Here is the call graph for this function:

Here is the caller graph for this function:

float RigidBody::get_height ( )

Here is the call graph for this function:

Here is the caller graph for this function:

float * RigidBody::get_matrix ( float *  matrix)
virtual

Reimplemented from Model.

Here is the caller graph for this function:

float RigidBody::get_volume ( )

Here is the call graph for this function:

void RigidBody::impulse ( Plane plane,
vec3 vertex 
)

Here is the call graph for this function:

Here is the caller graph for this function:

void RigidBody::impulse ( RigidBody rigid,
vec3 point 
)

Here is the call graph for this function:

void RigidBody::impulse ( RigidBody rigid,
vec3 point,
Plane plane 
)

Here is the call graph for this function:

void RigidBody::integrate ( float  time)
virtual

Here is the call graph for this function:

Here is the caller graph for this function:

void RigidBody::load_config ( cfg_t config)

Here is the caller graph for this function:

void RigidBody::lookat ( vec3 target)

Here is the call graph for this function:

Here is the caller graph for this function:

void RigidBody::lookat_yaw ( vec3 target)

Here is the call graph for this function:

Here is the caller graph for this function:

bool RigidBody::move ( input_t input,
float  speed_scale 
)

Here is the call graph for this function:

Here is the caller graph for this function:

void RigidBody::move_backward ( float  speed_scale)

Here is the call graph for this function:

void RigidBody::move_down ( float  speed_scale)

Here is the call graph for this function:

void RigidBody::move_forward ( float  speed_scale)

Here is the call graph for this function:

Here is the caller graph for this function:

void RigidBody::move_left ( float  speed_scale)

Here is the call graph for this function:

Here is the caller graph for this function:

void RigidBody::move_right ( float  speed_scale)

Here is the call graph for this function:

Here is the caller graph for this function:

void RigidBody::move_up ( float  speed_scale)

Here is the call graph for this function:

void RigidBody::pid_follow_path ( vec3 path_list,
int  num_path,
float  max_velocity,
float  distance,
int  wait 
)

Here is the call graph for this function:

Here is the caller graph for this function:

void RigidBody::pursue ( )

Here is the call graph for this function:

Here is the caller graph for this function:

void RigidBody::recalc ( )

Here is the call graph for this function:

Here is the caller graph for this function:

void RigidBody::save_config ( cfg_t config)

Here is the caller graph for this function:

void RigidBody::seek ( const vec3 position)

Here is the call graph for this function:

Here is the caller graph for this function:

void RigidBody::set_target ( Entity target)
int RigidBody::train_follow_path ( vec3 target,
float  max_velocity,
float  distance,
int  wait 
)

Here is the call graph for this function:

void RigidBody::wander ( float  radius,
float  distance,
float  jitter 
)

Here is the call graph for this function:

Member Data Documentation

vec3 RigidBody::angular_velocity
unsigned int RigidBody::bounce
int RigidBody::bsp_model_platform
int RigidBody::bsp_trigger_volume
bool RigidBody::flight
bool RigidBody::gravity
bool RigidBody::ground_friction_flag
bool RigidBody::hard_impact
unsigned int RigidBody::impact_index
float RigidBody::impact_velocity
matrix3 RigidBody::inverse_tensor
int RigidBody::jump_timer
bool RigidBody::last_water
bool RigidBody::lava
float RigidBody::mass
vec3 RigidBody::net_force
vec3 RigidBody::net_torque
bool RigidBody::noclip
matrix3 RigidBody::old_orientation
vec3 RigidBody::old_position
bool RigidBody::on_ground
func_path_t RigidBody::path
pid_state_t RigidBody::pid
bool RigidBody::pursue_flag
float RigidBody::restitution
float RigidBody::rotational_friction
bool RigidBody::rotational_friction_flag
bool RigidBody::sleep
bool RigidBody::slime
vec3 RigidBody::sphere_target
bool RigidBody::step_flag
int RigidBody::step_type
Entity* RigidBody::target
train_t RigidBody::train
float RigidBody::translational_friction
bool RigidBody::translational_friction_flag
vec3 RigidBody::velocity
bool RigidBody::water
float RigidBody::water_depth
vec3 RigidBody::wishdir
matrix3 RigidBody::world_tensor
int RigidBody::y_offset

The documentation for this class was generated from the following files: