|
@@ -28,10 +28,10 @@ public:
|
|
return mNumPilesPerAxis == 1? "RagdollSinglePile" : "Ragdoll";
|
|
return mNumPilesPerAxis == 1? "RagdollSinglePile" : "Ragdoll";
|
|
}
|
|
}
|
|
|
|
|
|
- virtual bool Load() override
|
|
|
|
|
|
+ virtual bool Load(const String &inAssetPath) override
|
|
{
|
|
{
|
|
// Load ragdoll
|
|
// Load ragdoll
|
|
- if (!ObjectStreamIn::sReadObject("Assets/Human.tof", mRagdollSettings))
|
|
|
|
|
|
+ if (!ObjectStreamIn::sReadObject((inAssetPath + "Human.tof").c_str(), mRagdollSettings))
|
|
{
|
|
{
|
|
cerr << "Unable to load ragdoll" << endl;
|
|
cerr << "Unable to load ragdoll" << endl;
|
|
return false;
|
|
return false;
|
|
@@ -46,7 +46,7 @@ public:
|
|
mRagdollSettings->CalculateConstraintIndexToBodyIdxPair();
|
|
mRagdollSettings->CalculateConstraintIndexToBodyIdxPair();
|
|
|
|
|
|
// Load animation
|
|
// Load animation
|
|
- if (!ObjectStreamIn::sReadObject("Assets/Human/dead_pose1.tof", mAnimation))
|
|
|
|
|
|
+ if (!ObjectStreamIn::sReadObject((inAssetPath + "Human/dead_pose1.tof").c_str(), mAnimation))
|
|
{
|
|
{
|
|
cerr << "Unable to load animation" << endl;
|
|
cerr << "Unable to load animation" << endl;
|
|
return false;
|
|
return false;
|
|
@@ -57,7 +57,7 @@ public:
|
|
mAnimation->Sample(0.0f, mPose);
|
|
mAnimation->Sample(0.0f, mPose);
|
|
|
|
|
|
// Read the background scene
|
|
// Read the background scene
|
|
- if (!ObjectStreamIn::sReadObject("Assets/terrain2.bof", mBackground))
|
|
|
|
|
|
+ if (!ObjectStreamIn::sReadObject((inAssetPath + "terrain2.bof").c_str(), mBackground))
|
|
{
|
|
{
|
|
cerr << "Unable to load terrain" << endl;
|
|
cerr << "Unable to load terrain" << endl;
|
|
return false;
|
|
return false;
|