Merge branch 'Preview4_0' of https://github.com/TorqueGameEngines/Torque3D into Preview4_0

This commit is contained in:
Areloch 2021-09-19 02:28:19 -05:00
commit 9a809dfb6b
10 changed files with 102 additions and 57 deletions

View file

@ -1,10 +1,6 @@
$Core::windowIcon = "data/icon.png";
$Core::splashWindowImage = "data/splash.png";
// Display a splash window immediately to improve app responsiveness before
// engine is initialized and main window created.
displaySplashWindow($Core::splashWindowImage);
// Console does something.
setLogMode(6);
@ -20,6 +16,13 @@ ModuleDatabase.setModuleExtension("module");
ModuleDatabase.scanModules( "core", false );
ModuleDatabase.LoadExplicit( "CoreModule" );
// Display a splash window immediately to improve app responsiveness before
// engine is initialized and main window created.
if ($Server::Dedicated == false)
displaySplashWindow($Core::splashWindowImage);
else
$Video::forceDisplayAdapter = -1;
//-----------------------------------------------------------------------------
// Load any gameplay modules
ModuleDatabase.scanModules( "data", false );
@ -42,6 +45,7 @@ else
}
}
closeSplashWindow();
if ($Server::Dedicated == false)
closeSplashWindow();
echo("Engine initialized...");

View file

@ -919,7 +919,7 @@ T3Dpre4ProjectImporter::genProcessor("DebrisData", "shape shapeAsset shapeFile s
T3Dpre4ProjectImporter::genProcessor("DecalData", "material materialAsset");
T3Dpre4ProjectImporter::genProcessor("ExplosionData", "explosionShape explosionShapeAsset");
T3Dpre4ProjectImporter::genProcessor("ParticleData", "texture textureAsset textureName textureAsset textureExt textureExtAsset textureExtName textureExtAsset");
T3Dpre4ProjectImporter::genProcessor("PrecipitationData", "drop dropAsset dropTexture dropAsset splash splashAsset splashTexture splashAsset");
T3Dpre4ProjectImporter::genProcessor("PrecipitationData", "drop dropAsset dropTexture dropAsset splash splashAsset splashTexture splashAsset soundProfile soundAsset");
T3Dpre4ProjectImporter::genProcessor("SplashData", "texture textureAsset");
T3Dpre4ProjectImporter::genProcessor("LightFlareData", "flareTexture flareTextureAsset");
T3Dpre4ProjectImporter::genProcessor("PhysicsDebrisData", "shape shapeAsset shapeFile shapeAsset");

View file

@ -556,23 +556,49 @@ function processLegacyField(%line, %originalFieldName, %newFieldName)
%targetFilename = sanitizeFilename(%value);
if(isObject(%targetFilename))
{
if(%originalFieldName $= "soundProfile")
{
//likely a material name, so handle it that way
%assetId = MaterialAsset::getAssetIdByMaterialName(%targetFilename);
$ProjectImporter::assetQuery.clear();
%foundAssets = AssetDatabase.findAssetName($ProjectImporter::assetQuery, %targetFilename);
if(%foundAssets != 0)
{
%assetId = $ProjectImporter::assetQuery.getAsset(0);
}
}
else
{
//likely a material name, so handle it that way
%assetId = MaterialAsset::getAssetIdByMaterialName(%targetFilename);
}
}
else
{
if(!isFile(%targetFilename))
{
error("Legacy Project Importer - file described in line could not be found/is not valid");
return %line;
}
$ProjectImporter::assetQuery.clear();
%foundAssets = AssetDatabase.findAssetLooseFile($ProjectImporter::assetQuery, %targetFilename);
if(%foundAssets != 0)
{
%assetId = $ProjectImporter::assetQuery.getAsset(0);
{
if(%originalFieldName $= "soundProfile")
{
$ProjectImporter::assetQuery.clear();
%foundAssets = AssetDatabase.findAssetName($ProjectImporter::assetQuery, %targetFilename);
if(%foundAssets != 0)
{
%assetId = $ProjectImporter::assetQuery.getAsset(0);
}
}
else
{
error("Legacy Project Importer - file described in line could not be found/is not valid");
return %line;
}
}
else
{
$ProjectImporter::assetQuery.clear();
%foundAssets = AssetDatabase.findAssetLooseFile($ProjectImporter::assetQuery, %targetFilename);
if(%foundAssets != 0)
{
%assetId = $ProjectImporter::assetQuery.getAsset(0);
}
}
}