mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-02-12 19:31:41 +00:00
Increased stability Torqu3D: unit-tests running without a crash. See the console.log after ran unitTest_runTests( "", true ). @signmotion
This commit is contained in:
parent
29d7fe310d
commit
18ba0646c0
18 changed files with 113 additions and 19 deletions
|
|
@ -550,6 +550,7 @@ S32 ProjectileData::scaleValue( S32 value, bool down )
|
|||
//
|
||||
Projectile::Projectile()
|
||||
: mPhysicsWorld( NULL ),
|
||||
mDataBlock( NULL ),
|
||||
mCurrPosition( 0, 0, 0 ),
|
||||
mCurrVelocity( 0, 0, 1 ),
|
||||
mSourceObjectId( -1 ),
|
||||
|
|
@ -697,6 +698,12 @@ bool Projectile::onAdd()
|
|||
if(!Parent::onAdd())
|
||||
return false;
|
||||
|
||||
if( !mDataBlock )
|
||||
{
|
||||
Con::errorf("Projectile::onAdd - Fail - Not datablock");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (isServerObject())
|
||||
{
|
||||
ShapeBase* ptr;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue