Panda3D
flee.h
1 ////////////////////////////////////////////////////////////////////////
2 // Filename : flee.h
3 // Created by : Deepak, John, Navin
4 // Date : 24 Oct 09
5 ////////////////////////////////////////////////////////////////////
6 //
7 // PANDA 3D SOFTWARE
8 // Copyright (c) Carnegie Mellon University. All rights reserved.
9 //
10 // All use of this software is subject to the terms of the revised BSD
11 // license. You should have received a copy of this license along
12 // with this source code in a file named "LICENSE."
13 //
14 ////////////////////////////////////////////////////////////////////
15 
16 #ifndef _FLEE_H
17 #define _FLEE_H
18 
19 #include "aiGlobals.h"
20 #include "aiCharacter.h"
21 
22 class AICharacter;
23 
24 class EXPCL_PANDAAI Flee {
25 
26 public:
27  AICharacter *_ai_char;
28 
29  LVecBase3 _flee_position;
30  float _flee_weight;
31  LVecBase3 _flee_direction;
32  double _flee_distance;
33  double _flee_relax_distance;
34  LVecBase3 _flee_present_pos;
35  bool _flee_done;
36  bool _flee_activate_done;
37 
38  Flee(AICharacter *ai_ch, NodePath target_object, double panic_distance = 10.0,
39  double relax_distance = 10.0, float flee_wt = 1.0);
40 
41  Flee(AICharacter *ai_ch, LVecBase3 pos, double panic_distance = 10.0,
42  double relax_distance = 10.0, float flee_wt = 1.0);
43 
44  ~Flee();
45  LVecBase3 do_flee();
46  void flee_activate();
47 };
48 
49 #endif
This is the base class for all three-component vectors and points.
Definition: lvecBase3.h:105
Definition: flee.h:24
NodePath is the fundamental system for disambiguating instances, and also provides a higher-level int...
Definition: nodePath.h:165