Code: Select all
1>BulletCollision.lib(btBoxShape.obj) : error LNK2005: "public: __thiscall btBoxShape::btBoxShape(class btVector3 const &)" (??0btBoxShape@@QAE@ABVbtVector3@@@Z) already defined in BoxBody.obj
1>..\..\Skeleton\DXTEST.exe : fatal error LNK1169: one or more multiply defined symbols found
Code: Select all
#pragma once
#include "PhysicalBody.h"
class BoxBody : public PhysicalBody
{
public:
BoxBody(float extent, float _mass, D3DXVECTOR3 origin);
BoxBody(D3DXVECTOR3 extents, float _mass, D3DXVECTOR3 origin);
};
Code: Select all
#pragma once
#include "BulletToDX.h"
class PhysicalBody
{
public:
PhysicalBody(void);
~PhysicalBody(void);
D3DXVECTOR3 GetOrigin();
D3DXMATRIX GetRotationMatrix();
D3DXMATRIX GetTransformMatrix();
btRigidBody* rigidBody;
protected:
float mass;
btCollisionShape* collisionShape;
btMotionState* motionState;
btVector3 origin;
};
Code: Select all
#pragma once
#include <d3dx9.h>
#include <btBulletDynamicsCommon.h>
D3DXVECTOR3 BT2DX_VECTOR3(const btVector3 &v);
btVector3 DX2BT_VECTOR3(const D3DXVECTOR3& v);
D3DXQUATERNION BT2DX_QUATERNION(const btQuaternion &q);
D3DXMATRIX BT2DX_MATRIX(const btTransform &ms);