Physics4K  2013-06-04
Physics4K is the next great evolution in 2D physics engines. built upon the C++ Game Framework, it is going to take the next generation gaming world by storm.
 All Classes Namespaces Files Functions Variables Enumerations Enumerator Friends Macros
Shape.h
Go to the documentation of this file.
1 // Filename: Shape.h
4 
5 //Preprocessor directive designed to cause the current source file to be included only once in a single compilation
6 #pragma once
7 
8 //Includes
9 #include "PKInclude.h"
10 #include "Vector2f.h"
11 #include <float.h>
12 
13 namespace PK
14 {
15  //Enum containing all supported shape types
16  enum ShapeType
17  {
21  };
22 
23  class PK_API Shape
24  {
25  friend class World;
26 
27  protected: //Abstract class. no destructor needed?
28  Shape();
29  Shape(float xPos, float yPos, float rotation, float friction, float mas, float intertiaTensor);
30 
31  void ZeroForce();
32 
33  public:
34  void SetForce(Vector2f force);
35  ShapeType GetType();
36 
37  public:
39  float Rotation;
41  float Friction;
43  float Mass;
44  float InvMass;
45  float InertiaTensor;
52  protected:
54  };
55 }