Last change
on this file since 5823 was
5257,
checked in by bensch, 19 years ago
|
orxonox/trunk: bouncy effect with physically based animations… or something like it at least.
|
File size:
1.2 KB
|
Line | |
---|
1 | /*! |
---|
2 | * @file physics_connection.h |
---|
3 | * Definition of The Physical Connection Class. |
---|
4 | * @todo |
---|
5 | */ |
---|
6 | |
---|
7 | #ifndef _PHYSICS_CONNECTION_H |
---|
8 | #define _PHYSICS_CONNECTION_H |
---|
9 | |
---|
10 | #include "base_object.h" |
---|
11 | // Forward Declaration |
---|
12 | class PhysicsInterface; |
---|
13 | class ParticleSystem; |
---|
14 | class Field; |
---|
15 | |
---|
16 | //! An enumerator for different ConnectionTypes |
---|
17 | typedef enum PCON_Type |
---|
18 | { |
---|
19 | PCON_PhysIPhysI = 1, |
---|
20 | PCON_PhysIField = 2 |
---|
21 | }; |
---|
22 | |
---|
23 | |
---|
24 | // Forward Declaration |
---|
25 | |
---|
26 | //! A class that Handles Physical Connection between different subjects |
---|
27 | class PhysicsConnection : public BaseObject |
---|
28 | { |
---|
29 | |
---|
30 | public: |
---|
31 | PhysicsConnection(PhysicsInterface* subject, Field* field); |
---|
32 | // PhysicsConnection(PhysicsInterface* partnerOne, PhysicsInterface* partnerTwo); |
---|
33 | PhysicsConnection(const TiXmlElement* root); |
---|
34 | |
---|
35 | virtual ~PhysicsConnection(); |
---|
36 | |
---|
37 | void setSubject(const char* subjectName); |
---|
38 | void setField(const char* fieldName); |
---|
39 | |
---|
40 | void apply() const; |
---|
41 | |
---|
42 | private: |
---|
43 | PCON_Type type; //!< What kind of connection this is. |
---|
44 | |
---|
45 | PhysicsInterface* subject; //!< The main Subject of this Connection. |
---|
46 | PhysicsInterface* partner2; //!< The second partner of this Connection. |
---|
47 | |
---|
48 | Field* field; //!< The field to connect either subject of ParticleSystem to. |
---|
49 | }; |
---|
50 | |
---|
51 | #endif /* _PHYSICS_CONNECTION_H */ |
---|
Note: See
TracBrowser
for help on using the repository browser.