mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-02-14 20:23:47 +00:00
try to load shapes during preload
it's half the point of the protocol
This commit is contained in:
parent
c138d838bb
commit
e8ccb3443a
18 changed files with 63 additions and 71 deletions
|
|
@ -390,16 +390,10 @@ bool TSStatic::_createShape()
|
|||
mAmbientThread = NULL;
|
||||
//mShape = NULL;
|
||||
|
||||
if (mShapeAsset.notNull())
|
||||
if (getShape())
|
||||
{
|
||||
if (!getShape())
|
||||
{
|
||||
Con::errorf("TSStatic::_createShape() - Shape Asset %s had no valid shape!", mShapeAsset.getAssetId());
|
||||
return false;
|
||||
}
|
||||
|
||||
if (isClientObject() &&
|
||||
!getShape()->preloadMaterialList(getShape().getPath()) &&
|
||||
!getShape()->preloadMaterialList(getShapeFile()) &&
|
||||
NetConnection::filesWereDownloaded())
|
||||
return false;
|
||||
|
||||
|
|
@ -440,6 +434,11 @@ bool TSStatic::_createShape()
|
|||
Sim::findObject(cubeDescId, reflectorDesc);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
Con::errorf("TSStatic::_createShape() - Shape Asset %s had no valid shape!", mShapeAsset.getAssetId());
|
||||
return false;
|
||||
}
|
||||
|
||||
//Set up the material slot vars for easy manipulation
|
||||
/*S32 materialCount = mShape->materialList->getMaterialNameList().size(); //mMeshAsset->getMaterialCount();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue