Physic rebuild start
This commit is contained in:
@@ -3,6 +3,13 @@
|
||||
#include <WICTextureLoader.h>
|
||||
#include <SimpleMath.h>
|
||||
|
||||
enum class ObjectType
|
||||
{
|
||||
Sphere,
|
||||
Cube,
|
||||
Unknown
|
||||
};
|
||||
|
||||
class Object : public ModelClass
|
||||
{
|
||||
public:
|
||||
@@ -30,7 +37,7 @@ public:
|
||||
XMVECTOR GetScale();
|
||||
|
||||
void SetVelocity(XMVECTOR);
|
||||
void AddVelocity(float);
|
||||
void AddVelocity(float deltaTime);
|
||||
XMVECTOR GetVelocity() const;
|
||||
void SetAcceleration(XMVECTOR);
|
||||
XMVECTOR GetAcceleration() const;
|
||||
@@ -54,6 +61,8 @@ public:
|
||||
void SetName(std::string name);
|
||||
int SetId(int id);
|
||||
int GetId() const;
|
||||
void SetType(ObjectType type) { m_type = type; };
|
||||
ObjectType GetType() const { return m_type; };
|
||||
|
||||
bool LoadTexture(ID3D11Device* device, ID3D11DeviceContext* deviceContext, const std::wstring& filename);
|
||||
|
||||
@@ -88,9 +97,10 @@ private:
|
||||
XMVECTOR m_acceleration;
|
||||
float m_mass;
|
||||
bool m_isGrounded;
|
||||
bool m_isPhysicsEnabled;
|
||||
bool m_isPhysicsEnabled = false;
|
||||
|
||||
std::string m_name;
|
||||
ObjectType m_type = ObjectType::Unknown;
|
||||
|
||||
ShaderType m_activeShader = LIGHTING;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user