Flee Class Reference

#include <flee.h>

Collaboration diagram for Flee:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 Flee (AICharacter *ai_ch, NodePath target_object, double panic_distance=10.0, double relax_distance=10.0, float flee_wt=1.0)
 Flee (AICharacter *ai_ch, LVecBase3f pos, double panic_distance=10.0, double relax_distance=10.0, float flee_wt=1.0)
 ~Flee ()
LVecBase3f do_flee ()
void flee_activate ()

Public Attributes

AICharacter_ai_char
LVecBase3f _flee_position
float _flee_weight
LVecBase3f _flee_direction
double _flee_distance
double _flee_relax_distance
LVecBase3f _flee_present_pos
bool _flee_done
bool _flee_activate_done

Detailed Description

Definition at line 23 of file flee.h.


Constructor & Destructor Documentation

Flee::Flee ( AICharacter ai_ch,
NodePath  target_object,
double  panic_distance = 10.0,
double  relax_distance = 10.0,
float  flee_wt = 1.0 
)

Filename : flee.cxx Created by : Deepak, John, Navin Date : 24 Oct 09

PANDA3D SOFTWARE Copyright(c) Carnegie Mellon University. All rights reserved.

All use of this software is subjest to the terms of the revised BSD license. You should have received a copy of this license along with this source code in a file named "LICENSE"

Definition at line 17 of file flee.cxx.

Flee::Flee ( AICharacter ai_ch,
LVecBase3f  pos,
double  panic_distance = 10.0,
double  relax_distance = 10.0,
float  flee_wt = 1.0 
)

Definition at line 31 of file flee.cxx.

Flee::~Flee (  ) 

Definition at line 45 of file flee.cxx.


Member Function Documentation

LVecBase3f Flee::do_flee (  ) 

Function : do_flee Description : This function performs the flee and returns a flee force which is used in the calculate_prioritized function. In case the AICharacter is past the (panic + relax) distance, it resets to flee_activate. This function is not to be used by the user.

Definition at line 59 of file flee.cxx.

Here is the call graph for this function:

void Flee::flee_activate (  ) 

Function : flee_activate Description : This function checks for whether the target is within the panic distance. When this is true, it calls the do_flee function and sets the flee direction. This function is not to be used by the user.

Definition at line 91 of file flee.cxx.

Here is the call graph for this function:


Member Data Documentation

Definition at line 26 of file flee.h.

Definition at line 35 of file flee.h.

Definition at line 30 of file flee.h.

Definition at line 31 of file flee.h.

Definition at line 34 of file flee.h.

Definition at line 28 of file flee.h.

Definition at line 33 of file flee.h.

Definition at line 32 of file flee.h.

Definition at line 29 of file flee.h.


The documentation for this class was generated from the following files:
 All Classes Files Functions Variables Typedefs Enumerations Enumerator

Generated on Tue Nov 3 22:34:40 2009 for PandAI by  doxygen 1.6.1