mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-02-12 19:31:41 +00:00
Adds test shapes of Kork and SpaceOrc
Sidestep of memleak from CSF at the moment Minor fixes and corrections with asset importing and loose files WIP of updated options menu
This commit is contained in:
parent
98c4606b3c
commit
ae857faae2
40 changed files with 765 additions and 182 deletions
|
|
@ -121,12 +121,17 @@ void MaterialAsset::initializeAsset()
|
|||
|
||||
compileShader();
|
||||
|
||||
if (!Platform::isFullPath(mScriptFile))
|
||||
mScriptFile = getOwned() ? expandAssetFilePath(mScriptFile) : mScriptFile;
|
||||
|
||||
if (Platform::isFile(mScriptFile))
|
||||
Con::executeFile(mScriptFile, false, false);
|
||||
}
|
||||
|
||||
void MaterialAsset::onAssetRefresh()
|
||||
{
|
||||
mScriptFile = expandAssetFilePath(mScriptFile);
|
||||
|
||||
if (Platform::isFile(mScriptFile))
|
||||
Con::executeFile(mScriptFile, false, false);
|
||||
|
||||
|
|
@ -151,12 +156,8 @@ void MaterialAsset::setScriptFile(const char* pScriptFile)
|
|||
// Fetch image file.
|
||||
pScriptFile = StringTable->insert(pScriptFile);
|
||||
|
||||
// Ignore no change,
|
||||
if (pScriptFile == mScriptFile)
|
||||
return;
|
||||
|
||||
// Update.
|
||||
mScriptFile = getOwned() ? expandAssetFilePath(pScriptFile) : StringTable->insert(pScriptFile);
|
||||
mScriptFile = getOwned() ? expandAssetFilePath(pScriptFile) : pScriptFile;
|
||||
|
||||
// Refresh the asset.
|
||||
refreshAsset();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue