diff --git a/Engine/source/gfx/D3D11/gfxD3D11Cubemap.cpp b/Engine/source/gfx/D3D11/gfxD3D11Cubemap.cpp index abf26218d..562ab7b63 100644 --- a/Engine/source/gfx/D3D11/gfxD3D11Cubemap.cpp +++ b/Engine/source/gfx/D3D11/gfxD3D11Cubemap.cpp @@ -223,7 +223,6 @@ void GFXD3D11Cubemap::initDynamic(U32 texSize, GFXFormat faceFormat, U32 mipLeve mMipMapLevels = mipLevels; - bool compressed = ImageUtil::isCompressedFormat(mFaceFormat); UINT bindFlags = D3D11_BIND_SHADER_RESOURCE; @@ -397,10 +396,19 @@ void GFXD3D11CubemapArray::init(GFXCubemapHandle *cubemaps, const U32 cubemapCou AssertFatal(cubemaps, "GFXD3D11CubemapArray::initStatic - Got null GFXCubemapHandle!"); AssertFatal(*cubemaps, "GFXD3D11CubemapArray::initStatic - Got empty cubemap!"); + U32 downscalePower = GFXTextureManager::smTextureReductionLevel; + U32 scaledSize = cubemaps[0]->getSize(); + + if (downscalePower != 0) + { + // Otherwise apply the appropriate scale... + scaledSize >>= downscalePower; + } + //all cubemaps must be the same size,format and number of mipmaps. Grab the details from the first cubemap - mSize = cubemaps[0]->getSize(); + mSize = scaledSize; mFormat = cubemaps[0]->getFormat(); - mMipMapLevels = cubemaps[0]->getMipMapLevels(); + mMipMapLevels = cubemaps[0]->getMipMapLevels() - downscalePower; mNumCubemaps = cubemapCount; //create texture object @@ -467,8 +475,16 @@ void GFXD3D11CubemapArray::init(GFXCubemapHandle *cubemaps, const U32 cubemapCou //Just allocate the cubemap array but we don't upload any data void GFXD3D11CubemapArray::init(const U32 cubemapCount, const U32 cubemapFaceSize, const GFXFormat format) { - mSize = cubemapFaceSize; - mMipMapLevels = ImageUtil::getMaxMipCount(cubemapFaceSize, cubemapFaceSize); + U32 downscalePower = GFXTextureManager::smTextureReductionLevel; + U32 scaledSize = cubemapFaceSize; + + if (downscalePower != 0) + { + scaledSize >>= downscalePower; + } + + mSize = scaledSize; + mMipMapLevels = ImageUtil::getMaxMipCount(cubemapFaceSize, cubemapFaceSize) - downscalePower; mNumCubemaps = cubemapCount; mFormat = format; @@ -512,6 +528,9 @@ void GFXD3D11CubemapArray::init(const U32 cubemapCount, const U32 cubemapFaceSiz void GFXD3D11CubemapArray::updateTexture(const GFXCubemapHandle &cubemap, const U32 slot) { + U32 cubeMapSz = cubemap->getSize(); + U32 cubeMapSize = cubemap->getMipMapLevels(); + AssertFatal(slot <= mNumCubemaps, "GFXD3D11CubemapArray::updateTexture - trying to update a cubemap texture that is out of bounds!"); AssertFatal(mFormat == cubemap->getFormat(), "GFXD3D11CubemapArray::updateTexture - Destination format doesn't match"); AssertFatal(mSize == cubemap->getSize(), "GFXD3D11CubemapArray::updateTexture - Destination size doesn't match"); diff --git a/Engine/source/gfx/gfxTextureManager.h b/Engine/source/gfx/gfxTextureManager.h index d706d14f0..f5bf7c38e 100644 --- a/Engine/source/gfx/gfxTextureManager.h +++ b/Engine/source/gfx/gfxTextureManager.h @@ -194,8 +194,7 @@ public: /// Used to remove a cubemap from the cache. void releaseCubemap( GFXCubemap *cubemap ); -protected: - +public: /// The amount of texture mipmaps to skip when loading a /// texture that allows downscaling. /// @@ -205,6 +204,8 @@ protected: /// static S32 smTextureReductionLevel; +protected: + /// File path to the missing texture static String smMissingTexturePath; diff --git a/Templates/BaseGame/game/core/clientServer/scripts/client/connectionToServer.cs b/Templates/BaseGame/game/core/clientServer/scripts/client/connectionToServer.cs index 11df6afd6..e5dff5e78 100644 --- a/Templates/BaseGame/game/core/clientServer/scripts/client/connectionToServer.cs +++ b/Templates/BaseGame/game/core/clientServer/scripts/client/connectionToServer.cs @@ -30,7 +30,20 @@ function GameConnection::onConnectionAccepted(%this) { // Startup the physX world on the client before any // datablocks and objects are ghosted over. - physicsInitWorld( "client" ); + physicsInitWorld( "client" ); + + //Get our modules so we can exec any specific client-side loading/handling + %modulesList = ModuleDatabase.findModules(true); + for(%i=0; %i < getWordCount(%modulesList); %i++) + { + %module = getWord(%modulesList, %i); + %moduleID = %module.ModuleId; + + if(%module.scopeSet.isMethod("onCreateClient")) + { + eval(%module.scopeSet @ ".onCreateClient();"); + } + } } function GameConnection::initialControlSet(%this) @@ -126,5 +139,16 @@ function disconnectedCleanup() } // We can now delete the client physics simulation. - physicsDestroyWorld( "client" ); + physicsDestroyWorld( "client" ); + + //Get our modules so we can exec any specific client-side loading/handling + %modulesList = ModuleDatabase.findModules(true); + for(%i=0; %i < getWordCount(%modulesList); %i++) + { + %module = getWord(%modulesList, %i); + if(%module.scopeSet.isMethod("onDestroyClient")) + { + eval(%module.scopeSet @ ".onDestroyClient();"); + } + } } diff --git a/Templates/BaseGame/game/core/clientServer/scripts/server/server.cs b/Templates/BaseGame/game/core/clientServer/scripts/server/server.cs index 9a40f5ab3..6d82746bd 100644 --- a/Templates/BaseGame/game/core/clientServer/scripts/server/server.cs +++ b/Templates/BaseGame/game/core/clientServer/scripts/server/server.cs @@ -155,6 +155,17 @@ function createServer(%serverType, %level) if ($pref::Net::DisplayOnMaster !$= "Never" ) schedule(0,0,startHeartbeat); } + + //Get our modules so we can exec any specific server-side loading/handling + %modulesList = ModuleDatabase.findModules(true); + for(%i=0; %i < getWordCount(%modulesList); %i++) + { + %module = getWord(%modulesList, %i); + if(%module.scopeSet.isMethod("onCreateServer")) + { + eval(%module.scopeSet @ ".onCreateServer();"); + } + } // Let the game initialize some things now that the // the server has been created @@ -229,6 +240,17 @@ function destroyServer() // Delete all the data blocks... deleteDataBlocks(); + //Get our modules so we can exec any specific server-side loading/handling + %modulesList = ModuleDatabase.findModules(true); + for(%i=0; %i < getWordCount(%modulesList); %i++) + { + %module = getWord(%modulesList, %i); + if(%module.scopeSet.isMethod("onDestroyServer")) + { + eval(%module.scopeSet @ ".onDestroyServer();"); + } + } + // Save any server settings %prefPath = getPrefpath(); echo( "Exporting server prefs..." ); diff --git a/Templates/BaseGame/game/core/rendering/scripts/renderManager.cs b/Templates/BaseGame/game/core/rendering/scripts/renderManager.cs index 1dcc62f69..8a0a8adea 100644 --- a/Templates/BaseGame/game/core/rendering/scripts/renderManager.cs +++ b/Templates/BaseGame/game/core/rendering/scripts/renderManager.cs @@ -50,7 +50,6 @@ function initRenderManager() DiffuseRenderPassManager.addManager( new RenderProbeMgr(ProbeBin) { bintype = "Probes"; renderOrder = 0.019; processAddOrder = 0.019; } ); - //DiffuseRenderPassManager.addManager( new RenderVistaMgr() { bintype = "Vista"; renderOrder = 0.15; processAddOrder = 0.15; } ); DiffuseRenderPassManager.addManager( new RenderObjectMgr(BeginBin) { bintype = "Begin"; renderOrder = 0.2; processAddOrder = 0.2; } ); // Normal mesh rendering. diff --git a/Templates/BaseGame/game/data/ImportTesting/ImportTesting.cs b/Templates/BaseGame/game/data/ImportTesting/ImportTesting.cs new file mode 100644 index 000000000..42e89148e --- /dev/null +++ b/Templates/BaseGame/game/data/ImportTesting/ImportTesting.cs @@ -0,0 +1,10 @@ +function ImportTesting::onCreate(%this) +{ + +} + +function ImportTesting::onDestroy(%this) +{ + +} + diff --git a/Templates/BaseGame/game/data/ImportTesting/ImportTesting.module b/Templates/BaseGame/game/data/ImportTesting/ImportTesting.module new file mode 100644 index 000000000..44441516c --- /dev/null +++ b/Templates/BaseGame/game/data/ImportTesting/ImportTesting.module @@ -0,0 +1,25 @@ + + + + + diff --git a/Templates/BaseGame/game/tools/assetBrowser/assetImportConfigs.xml b/Templates/BaseGame/game/tools/assetBrowser/assetImportConfigs.xml index 72050b04f..4bc243e71 100644 --- a/Templates/BaseGame/game/tools/assetBrowser/assetImportConfigs.xml +++ b/Templates/BaseGame/game/tools/assetBrowser/assetImportConfigs.xml @@ -1,34 +1,3 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + diff --git a/Templates/BaseGame/game/tools/assetBrowser/guis/assetImport.gui b/Templates/BaseGame/game/tools/assetBrowser/guis/assetImport.gui index d7e82723c..f3d432a3a 100644 --- a/Templates/BaseGame/game/tools/assetBrowser/guis/assetImport.gui +++ b/Templates/BaseGame/game/tools/assetBrowser/guis/assetImport.gui @@ -609,5 +609,107 @@ }; }; }; + new GuiWindowCtrl(ImportAssetNewConfigEditorWindow) { + text = "Import Options Config"; + resizeWidth = "1"; + resizeHeight = "1"; + canMove = "1"; + canClose = "0"; + canMinimize = "0"; + canMaximize = "0"; + canCollapse = "0"; + edgeSnap = "1"; + margin = "0 0 0 0"; + padding = "0 0 0 0"; + anchorTop = "1"; + anchorBottom = "0"; + anchorLeft = "1"; + anchorRight = "0"; + position = "524 332"; + extent = "376 50"; + minExtent = "48 92"; + horizSizing = "center"; + vertSizing = "center"; + profile = "ToolsGuiWindowProfile"; + visible = "0"; + active = "1"; + tooltipProfile = "ToolsGuiToolTipProfile"; + hovertime = "1000"; + isContainer = "1"; + hidden = "1"; + canSave = "1"; + canSaveDynamicFields = "0"; + + new GuiTextCtrl() { + text = "Configuration Name:"; + maxLength = "1024"; + margin = "0 0 0 0"; + padding = "0 0 0 0"; + anchorTop = "1"; + anchorBottom = "0"; + anchorLeft = "1"; + anchorRight = "0"; + position = "10 26"; + extent = "100 17"; + minExtent = "8 2"; + horizSizing = "right"; + vertSizing = "bottom"; + profile = "GuiTextProfile"; + visible = "1"; + active = "1"; + tooltipProfile = "GuiToolTipProfile"; + hovertime = "1000"; + isContainer = "1"; + canSave = "1"; + canSaveDynamicFields = "0"; + }; + new GuiTextEditCtrl(AssetImportNewConfigName) { + historySize = "0"; + tabComplete = "0"; + sinkAllKeyEvents = "0"; + password = "0"; + passwordMask = "*"; + maxLength = "1024"; + margin = "0 0 0 0"; + padding = "0 0 0 0"; + anchorTop = "1"; + anchorBottom = "0"; + anchorLeft = "1"; + anchorRight = "0"; + position = "113 25"; + extent = "250 18"; + minExtent = "8 2"; + horizSizing = "width"; + vertSizing = "bottom"; + profile = "GuiTextEditProfile"; + visible = "1"; + active = "1"; + tooltipProfile = "GuiToolTipProfile"; + hovertime = "1000"; + isContainer = "1"; + canSave = "1"; + canSaveDynamicFields = "0"; + }; + new GuiButtonCtrl() { + text = "Done"; + groupNum = "-1"; + buttonType = "PushButton"; + useMouseEvents = "0"; + position = "301 27"; + extent = "64 22"; + minExtent = "8 2"; + horizSizing = "left"; + vertSizing = "top"; + profile = "ToolsGuiButtonProfile"; + visible = "1"; + active = "1"; + command = "ImportAssetConfigEditorWindow.saveAssetOptionsConfig();"; + tooltipProfile = "ToolsGuiToolTipProfile"; + hovertime = "1000"; + isContainer = "0"; + canSave = "1"; + canSaveDynamicFields = "0"; + }; + }; }; //--- OBJECT WRITE END --- diff --git a/Templates/BaseGame/game/tools/assetBrowser/scripts/assetImport.cs b/Templates/BaseGame/game/tools/assetBrowser/scripts/assetImport.cs index 299ecd030..d7d5a0282 100644 --- a/Templates/BaseGame/game/tools/assetBrowser/scripts/assetImport.cs +++ b/Templates/BaseGame/game/tools/assetBrowser/scripts/assetImport.cs @@ -513,79 +513,18 @@ function ImportAssetWindow::reloadImportOptionConfigs(%this) if(%xmlDoc.loadFile($AssetBrowser::importConfigsFile)) { //StateMachine element - %xmlDoc.pushFirstChildElement("AssetImportSettings"); + if(!%xmlDoc.pushFirstChildElement("AssetImportConfigs")) + { + error("Invalid Import Configs file"); + return; + } //Config Groups %configCount = 0; while(%xmlDoc.pushChildElement(%configCount)) { - %configName = %xmlDoc.attribute("name"); - - /*%xmlDoc.pushFirstChildElement("Mesh"); - %configObj.ImportMesh = %xmlDoc.attribute("ImportMesh"); - %configObj.DoUpAxisOverride = %xmlDoc.attribute("DoUpAxisOverride"); - %configObj.UpAxisOverride = %xmlDoc.attribute("UpAxisOverride"); - %configObj.DoScaleOverride = %xmlDoc.attribute("DoScaleOverride"); - %configObj.ScaleOverride = %xmlDoc.attribute("ScaleOverride"); - %configObj.IgnoreNodeScale = %xmlDoc.attribute("IgnoreNodeScale"); - %configObj.AdjustCenter = %xmlDoc.attribute("AdjustCenter"); - %configObj.AdjustFloor = %xmlDoc.attribute("AdjustFloor"); - %configObj.CollapseSubmeshes = %xmlDoc.attribute("CollapseSubmeshes"); - %configObj.LODType = %xmlDoc.attribute("LODType"); - %configObj.ImportedNodes = %xmlDoc.attribute("ImportedNodes"); - %configObj.IgnoreNodes = %xmlDoc.attribute("IgnoreNodes"); - %configObj.ImportMeshes = %xmlDoc.attribute("ImportMeshes"); - %configObj.IgnoreMeshes = %xmlDoc.attribute("IgnoreMeshes"); - %xmlDoc.popElement(); - - %xmlDoc.pushFirstChildElement("Materials"); - %configObj.ImportMaterials = %xmlDoc.attribute("ImportMaterials"); - %configObj.IgnoreMaterials = %xmlDoc.attribute("IgnoreMaterials"); - %configObj.CreateComposites = %xmlDoc.attribute("CreateComposites"); - %configObj.UseDiffuseSuffixOnOriginImg = %xmlDoc.attribute("UseDiffuseSuffixOnOriginImg"); - %configObj.UseExistingMaterials = %xmlDoc.attribute("UseExistingMaterials"); - %xmlDoc.popElement(); - - %xmlDoc.pushFirstChildElement("Animations"); - %configObj.ImportAnimations = %xmlDoc.attribute("ImportAnimations"); - %configObj.SeparateAnimations = %xmlDoc.attribute("SeparateAnimations"); - %configObj.SeparateAnimationPrefix = %xmlDoc.attribute("SeparateAnimationPrefix"); - %xmlDoc.popElement(); - - %xmlDoc.pushFirstChildElement("Collisions"); - %configObj.GenerateCollisions = %xmlDoc.attribute("GenerateCollisions"); - %configObj.GenCollisionType = %xmlDoc.attribute("GenCollisionType"); - %configObj.CollisionMeshPrefix = %xmlDoc.attribute("CollisionMeshPrefix"); - %configObj.GenerateLOSCollisions = %xmlDoc.attribute("GenerateLOSCollisions"); - %configObj.GenLOSCollisionType = %xmlDoc.attribute("GenLOSCollisionType"); - %configObj.LOSCollisionMeshPrefix = %xmlDoc.attribute("LOSCollisionMeshPrefix"); - %xmlDoc.popElement(); - - %xmlDoc.pushFirstChildElement("Images"); - %configObj.ImageType = %xmlDoc.attribute("ImageType"); - %configObj.DiffuseTypeSuffixes = %xmlDoc.attribute("DiffuseTypeSuffixes"); - %configObj.NormalTypeSuffixes = %xmlDoc.attribute("NormalTypeSuffixes"); - %configObj.SpecularTypeSuffixes = %xmlDoc.attribute("SpecularTypeSuffixes"); - %configObj.MetalnessTypeSuffixes = %xmlDoc.attribute("MetalnessTypeSuffixes"); - %configObj.RoughnessTypeSuffixes = %xmlDoc.attribute("RoughnessTypeSuffixes"); - %configObj.SmoothnessTypeSuffixes = %xmlDoc.attribute("SmoothnessTypeSuffixes"); - %configObj.AOTypeSuffixes = %xmlDoc.attribute("AOTypeSuffixes"); - %configObj.CompositeTypeSuffixes = %xmlDoc.attribute("CompositeTypeSuffixes"); - %configObj.TextureFilteringMode = %xmlDoc.attribute("TextureFilteringMode"); - %configObj.UseMips = %xmlDoc.attribute("UseMips"); - %configObj.IsHDR = %xmlDoc.attribute("IsHDR"); - %configObj.Scaling = %xmlDoc.attribute("Scaling"); - %configObj.Compressed = %xmlDoc.attribute("Compressed"); - %configObj.GenerateMaterialOnImport = %xmlDoc.attribute("GenerateMaterialOnImport"); - %configObj.PopulateMaterialMaps = %xmlDoc.attribute("PopulateMaterialMaps"); - %xmlDoc.popElement(); - - %xmlDoc.pushFirstChildElement("Sounds"); - %configObj.VolumeAdjust = %xmlDoc.attribute("VolumeAdjust"); - %configObj.PitchAdjust = %xmlDoc.attribute("PitchAdjust"); - %configObj.Compressed = %xmlDoc.attribute("Compressed"); - %xmlDoc.popElement();*/ - + %configName = %xmlDoc.attribute("Name"); + %xmlDoc.popElement(); %configCount++; @@ -595,6 +534,8 @@ function ImportAssetWindow::reloadImportOptionConfigs(%this) %xmlDoc.popElement(); } + ImportAssetWindow.importConfigsList.add(%configName); + for(%i = 0; %i < ImportAssetWindow.importConfigsList.count(); %i++) { %configName = ImportAssetWindow.importConfigsList.getKey(%i); @@ -773,10 +714,10 @@ function ImportAssetWindow::_findImportingAssetByName(%this, %id, %assetName) function ImportAssetWindow::parseImageSuffixes(%this, %assetItem) { //diffuse - %suffixCount = getTokenCount(ImportAssetWindow.activeImportConfig.DiffuseTypeSuffixes, ",;"); + %suffixCount = getTokenCount(getAssetImportConfigValue("Image/DiffuseTypeSuffixes", ""), ",;"); for(%sfx = 0; %sfx < %suffixCount; %sfx++) { - %suffixToken = getToken(ImportAssetWindow.activeImportConfig.DiffuseTypeSuffixes, ",;", %sfx); + %suffixToken = getToken(getAssetImportConfigValue("Image/DiffuseTypeSuffixes", ""), ",;", %sfx); if(strIsMatchExpr("*"@%suffixToken, %assetItem.AssetName)) { %assetItem.imageSuffixType = %suffixToken; @@ -785,10 +726,10 @@ function ImportAssetWindow::parseImageSuffixes(%this, %assetItem) } //normal - %suffixCount = getTokenCount(ImportAssetWindow.activeImportConfig.NormalTypeSuffixes, ",;"); + %suffixCount = getTokenCount(getAssetImportConfigValue("Image/NormalTypeSuffixes", ""), ",;"); for(%sfx = 0; %sfx < %suffixCount; %sfx++) { - %suffixToken = getToken(ImportAssetWindow.activeImportConfig.NormalTypeSuffixes, ",;", %sfx); + %suffixToken = getToken(getAssetImportConfigValue("Image/NormalTypeSuffixes", ""), ",;", %sfx); if(strIsMatchExpr("*"@%suffixToken, %assetItem.AssetName)) { %assetItem.imageSuffixType = %suffixToken; @@ -797,10 +738,10 @@ function ImportAssetWindow::parseImageSuffixes(%this, %assetItem) } //roughness - %suffixCount = getTokenCount(ImportAssetWindow.activeImportConfig.RoughnessTypeSuffixes, ",;"); + %suffixCount = getTokenCount(getAssetImportConfigValue("Image/RoughnessTypeSuffixes", ""), ",;"); for(%sfx = 0; %sfx < %suffixCount; %sfx++) { - %suffixToken = getToken(ImportAssetWindow.activeImportConfig.RoughnessTypeSuffixes, ",;", %sfx); + %suffixToken = getToken(getAssetImportConfigValue("Image/RoughnessTypeSuffixes", ""), ",;", %sfx); if(strIsMatchExpr("*"@%suffixToken, %assetItem.AssetName)) { %assetItem.imageSuffixType = %suffixToken; @@ -809,10 +750,10 @@ function ImportAssetWindow::parseImageSuffixes(%this, %assetItem) } //Ambient Occlusion - %suffixCount = getTokenCount(ImportAssetWindow.activeImportConfig.AOTypeSuffixes, ",;"); + %suffixCount = getTokenCount(getAssetImportConfigValue("Image/AOTypeSuffixes", ""), ",;"); for(%sfx = 0; %sfx < %suffixCount; %sfx++) { - %suffixToken = getToken(ImportAssetWindow.activeImportConfig.AOTypeSuffixes, ",;", %sfx); + %suffixToken = getToken(getAssetImportConfigValue("Image/AOTypeSuffixes", ""), ",;", %sfx); if(strIsMatchExpr("*"@%suffixToken, %assetItem.AssetName)) { %assetItem.imageSuffixType = %suffixToken; @@ -821,10 +762,10 @@ function ImportAssetWindow::parseImageSuffixes(%this, %assetItem) } //metalness - %suffixCount = getTokenCount(ImportAssetWindow.activeImportConfig.MetalnessTypeSuffixes, ",;"); + %suffixCount = getTokenCount(getAssetImportConfigValue("Image/MetalnessTypeSuffixes", ""), ",;"); for(%sfx = 0; %sfx < %suffixCount; %sfx++) { - %suffixToken = getToken(ImportAssetWindow.activeImportConfig.MetalnessTypeSuffixes, ",;", %sfx); + %suffixToken = getToken(getAssetImportConfigValue("Image/MetalnessTypeSuffixes", ""), ",;", %sfx); if(strIsMatchExpr("*"@%suffixToken, %assetItem.AssetName)) { %assetItem.imageSuffixType = %suffixToken; @@ -833,10 +774,10 @@ function ImportAssetWindow::parseImageSuffixes(%this, %assetItem) } //composite - %suffixCount = getTokenCount(ImportAssetWindow.activeImportConfig.CompositeTypeSuffixes, ",;"); + %suffixCount = getTokenCount(getAssetImportConfigValue("Image/CompositeTypeSuffixes", ""), ",;"); for(%sfx = 0; %sfx < %suffixCount; %sfx++) { - %suffixToken = getToken(ImportAssetWindow.activeImportConfig.CompositeTypeSuffixes, ",;", %sfx); + %suffixToken = getToken(getAssetImportConfigValue("Image/CompositeTypeSuffixes", ""), ",;", %sfx); if(strIsMatchExpr("*"@%suffixToken, %assetItem.AssetName)) { %assetItem.imageSuffixType = %suffixToken; @@ -845,7 +786,7 @@ function ImportAssetWindow::parseImageSuffixes(%this, %assetItem) } //specular - %suffixCount = getTokenCount(ImportAssetWindow.activeImportConfig.SpecularTypeSuffixes, ",;"); + /*%suffixCount = getTokenCount(ImportAssetWindow.activeImportConfig.SpecularTypeSuffixes, ",;"); for(%sfx = 0; %sfx < %suffixCount; %sfx++) { %suffixToken = getToken(ImportAssetWindow.activeImportConfig.SpecularTypeSuffixes, ",;", %sfx); @@ -854,7 +795,7 @@ function ImportAssetWindow::parseImageSuffixes(%this, %assetItem) %assetItem.imageSuffixType = %suffixToken; return "specular"; } - } + }*/ return ""; } diff --git a/Templates/BaseGame/game/tools/assetBrowser/scripts/assetImportConfig.cs b/Templates/BaseGame/game/tools/assetBrowser/scripts/assetImportConfig.cs index aa9d96377..e84725b6e 100644 --- a/Templates/BaseGame/game/tools/assetBrowser/scripts/assetImportConfig.cs +++ b/Templates/BaseGame/game/tools/assetBrowser/scripts/assetImportConfig.cs @@ -8,7 +8,6 @@ function ImportAssetConfigList::onSelect( %this, %id, %text ) ImportAssetWindow.activeImportConfigIndex = %id; ImportAssetWindow.activeImportConfig = ImportAssetWindow.importConfigsList.getKey(%id); - //ImportAssetWindow.refresh(); AssetBrowser.reloadImportingFiles(); } @@ -187,14 +186,25 @@ function ImportOptionsList::ImportMaterialsChanged(%this, %fieldName, %newValue, echo("CHANGED IF OUR IMPORTED MATERIALS WERE HAPPENING!"); } +function getAssetImportConfigValue(%fieldName, %defaultValue) +{ + if(ImportAssetWindow.activeImportConfig $= "") + return ""; + + return AssetImportSettings.value(ImportAssetWindow.activeImportConfig @ "/" @ %fieldName, %defaultValue); +} + function ImportAssetConfigEditorWindow::populateConfigList(%this, %optionsObj) { AssetImportConfigName.setText(%optionsObj.Name); - ImportOptionsConfigList.clear(); + ImportOptionsConfigList.clearFields(); ImportOptionsConfigList.startGroup("Mesh"); - ImportOptionsConfigList.addCallbackField("ImportMesh", "Import Mesh", "bool", "", "1", "", "ToggleImportMesh", %optionsObj); + ImportOptionsConfigList.addSettingsField("Mesh/ImportMesh", "Import Mesh", "bool", "Should meshes be imported", ""); + ImportOptionsConfigList.endGroup(); + + /*ImportOptionsConfigList.addCallbackField("ImportMesh", "Import Mesh", "bool", "", "1", "", "ToggleImportMesh", %optionsObj); ImportOptionsConfigList.addField("DoUpAxisOverride", "Do Up-axis Override", "bool", "", "0", "", %optionsObj); ImportOptionsConfigList.addField("UpAxisOverride", "Up-axis Override", "list", "", "Z_AXIS", "X_AXIS,Y_AXIS,Z_AXIS", %optionsObj); ImportOptionsConfigList.addField("DoScaleOverride", "Do Scale Override", "bool", "", "0", "", %optionsObj); @@ -270,80 +280,80 @@ function ImportAssetConfigEditorWindow::populateConfigList(%this, %optionsObj) ImportOptionsConfigList.addField("VolumeAdjust", "Volume Adjustment", "float", "", "1.0", "", %optionsObj); ImportOptionsConfigList.addField("PitchAdjust", "Pitch Adjustment", "float", "", "1.0", "", %optionsObj); ImportOptionsConfigList.addField("Compressed", "Is Compressed", "bool", "", "0", "", %optionsObj); - ImportOptionsConfigList.endGroup(); + ImportOptionsConfigList.endGroup();*/ } function ImportAssetConfigEditorWindow::addNewConfig(%this) { - ImportAssetConfigEditorWindow.setVisible(1); - ImportAssetConfigEditorWindow.selectWindow(); + ImportAssetNewConfigEditorWindow.setVisible(1); + ImportAssetNewConfigEditorWindow.selectWindow(); - %optionsObj = new ScriptObject(){}; + %configName = AssetImportConfigName.getText(); - ImportAssetWindow.importConfigsList.add(%optionsObj); + AssetImportSettings.beginGroup(%configName); - //Initial, blank configuration - %optionsObj.ImportMesh = true; - %optionsObj.DoUpAxisOverride = false; - %optionsObj.UpAxisOverride = "Z_AXIS"; - %optionsObj.DoScaleOverride = false; - %optionsObj.ScaleOverride = 1.0; - %optionsObj.IgnoreNodeScale = false; - %optionsObj.AdjustCenter = false; - %optionsObj.AdjustFloor = false; - %optionsObj.CollapseSubmeshes = false; - %optionsObj.LODType = "TrailingNumber"; - //%optionsObj.TrailingNumber = 2; - %optionsObj.ImportedNodes = ""; - %optionsObj.IgnoreNodes = ""; - %optionsObj.ImportMeshes = ""; - %optionsObj.IgnoreMeshes = ""; + //Meshes + AssetImportSettings.setValue("Meshes/ImportMesh", "1"); + AssetImportSettings.setValue("Meshes/DoUpAxisOverride", "0"); + AssetImportSettings.setValue("Meshes/UpAxisOverride", "Z_AXIS"); + AssetImportSettings.setValue("Meshes/DoScaleOverride", "0"); + AssetImportSettings.setValue("Meshes/ScaleOverride", "1.0"); + AssetImportSettings.setValue("Meshes/IgnoreNodeScale", "0"); + AssetImportSettings.setValue("Meshes/AdjustCenter", "0"); + AssetImportSettings.setValue("Meshes/AdjustFloor", "0"); + AssetImportSettings.setValue("Meshes/CollapseSubmeshes", "0"); + AssetImportSettings.setValue("Meshes/LODType", "TrailingNumber"); + AssetImportSettings.setValue("Meshes/ImportedNodes", ""); + AssetImportSettings.setValue("Meshes/IgnoreNodes", ""); + AssetImportSettings.setValue("Meshes/ImportMeshes", ""); + AssetImportSettings.setValue("Meshes/IgnoreMeshes", ""); //Materials - %optionsObj.ImportMaterials = true; - %optionsObj.IgnoreMaterials = ""; - %optionsObj.CreateComposites = true; - %optionsObj.UseDiffuseSuffixOnOriginImg = true; - %optionsObj.UseExistingMaterials = true; + AssetImportSettings.setValue("Materials/ImportMaterials", "1"); + AssetImportSettings.setValue("Materials/IgnoreMaterials", ""); + AssetImportSettings.setValue("Materials/CreateComposites", "1"); + AssetImportSettings.setValue("Materials/UseDiffuseSuffixOnOriginImage", "1"); + AssetImportSettings.setValue("Materials/UseExistingMaterials", "1"); //Animations - %optionsObj.ImportAnimations = true; - %optionsObj.SeparateAnimations = true; - %optionsObj.SeparateAnimationPrefix = ""; + AssetImportSettings.setValue("Animations/ImportAnimations", "1"); + AssetImportSettings.setValue("Animations/SeparateAnimations", "1"); + AssetImportSettings.setValue("Animations/SeparateAnimationPrefix", ""); //Collision - %optionsObj.GenerateCollisions = true; - %optionsObj.GenCollisionType = "CollisionMesh"; - %optionsObj.CollisionMeshPrefix = "Col"; - %optionsObj.GenerateLOSCollisions = true; - %optionsObj.GenLOSCollisionType = "CollisionMesh"; - %optionsObj.LOSCollisionMeshPrefix = "LOS"; + AssetImportSettings.setValue("Collision/GenerateCollisions", "1"); + AssetImportSettings.setValue("Collision/GenCollisionType", "CollisionMesh"); + AssetImportSettings.setValue("Collision/CollisionMeshPrefix", "Col"); + AssetImportSettings.setValue("Collision/GenerateLOSCollisions", "1"); + AssetImportSettings.setValue("Collision/GenLOSCollisionType", "CollisionMesh"); + AssetImportSettings.setValue("Collision/LOSCollisionMeshPrefix", "LOS"); //Images - %optionsObj.ImageType = "N/A"; - %optionsObj.DiffuseTypeSuffixes = "_ALBEDO;_DIFFUSE;_ALB;_DIF;_COLOR;_COL;_BASECOLOR;_BASE_COLOR"; - %optionsObj.NormalTypeSuffixes = "_NORMAL;_NORM"; - %optionsObj.SpecularTypeSuffixes = "_SPECULAR;_SPEC"; - %optionsObj.MetalnessTypeSuffixes = "_METAL;_MET;_METALNESS;_METALLIC"; - %optionsObj.RoughnessTypeSuffixes = "_ROUGH;_ROUGHNESS"; - %optionsObj.SmoothnessTypeSuffixes = "_SMOOTH;_SMOOTHNESS"; - %optionsObj.AOTypeSuffixes = "_AO;_AMBIENT;_AMBIENTOCCLUSION"; - %optionsObj.CompositeTypeSuffixes = "_COMP;_COMPOSITE"; - %optionsObj.TextureFilteringMode = "Bilinear"; - %optionsObj.UseMips = true; - %optionsObj.IsHDR = false; - %optionsObj.Scaling = 1.0; - %optionsObj.Compressed = true; - %optionsObj.GenerateMaterialOnImport = true; - %optionsObj.PopulateMaterialMaps = true; + AssetImportSettings.setValue("Images/ImageType", "N/A"); + AssetImportSettings.setValue("Images/DiffuseTypeSuffixes", "_ALBEDO;_DIFFUSE;_ALB;_DIF;_COLOR;_COL;_BASECOLOR;_BASE_COLOR"); + AssetImportSettings.setValue("Images/NormalTypeSuffixes", "_NORMAL;_NORM"); + AssetImportSettings.setValue("Images/MetalnessTypeSuffixes", "_METAL;_MET;_METALNESS;_METALLIC"); + AssetImportSettings.setValue("Images/RoughnessTypeSuffixes", "_ROUGH;_ROUGHNESS"); + AssetImportSettings.setValue("Images/SmoothnessTypeSuffixes", "_SMOOTH;_SMOOTHNESS"); + AssetImportSettings.setValue("Images/AOTypeSuffixes", "_AO;_AMBIENT;_AMBIENTOCCLUSION"); + AssetImportSettings.setValue("Images/CompositeTypeSuffixes", "_COMP;_COMPOSITE"); + AssetImportSettings.setValue("Images/TextureFilteringMode", "Bilinear"); + AssetImportSettings.setValue("Images/UseMips", "1"); + AssetImportSettings.setValue("Images/IsHDR", "0"); + AssetImportSettings.setValue("Images/Scaling", "1.0"); + AssetImportSettings.setValue("Images/Compressed", "1"); + AssetImportSettings.setValue("Images/GenerateMaterialOnImport", "1"); + AssetImportSettings.setValue("Images/PopulateMaterialMaps", "1"); //Sounds - %optionsObj.VolumeAdjust = 1.0; - %optionsObj.PitchAdjust = 1.0; - %optionsObj.Compressed = false; + AssetImportSettings.setValue("Sounds/VolumeAdjust", "1.0"); + AssetImportSettings.setValue("Sounds/PitchAdjust", "1.0"); + AssetImportSettings.setValue("Sounds/Compressed", "0"); + + AssetImportSettings.endGroup(); //Hook in the UI - %this.populateConfigList(%optionsObj); + //%this.populateConfigList(%optionsObj); } function ImportAssetConfigEditorWindow::editConfig(%this) @@ -364,97 +374,30 @@ function ImportAssetConfigEditorWindow::deleteConfig(%this) function ImportAssetConfigEditorWindow::saveAssetOptionsConfig(%this) { - %xmlDoc = new SimXMLDocument(); - - %xmlDoc.pushNewElement("AssetImportConfigs"); - - for(%i = 0; %i < ImportAssetWindow.importConfigsList.count(); %i++) - { - %configObj = ImportAssetWindow.importConfigsList.getKey(%i); - - %xmlDoc.pushNewElement("Config"); - - if(%configObj.Name $= "") - %configObj.Name = AssetImportConfigName.getText(); - - %xmlDoc.setAttribute("Name", %configObj.Name); - - %xmlDoc.pushNewElement("Mesh"); - %xmlDoc.setAttribute("ImportMesh", %configObj.ImportMesh); - %xmlDoc.setAttribute("DoUpAxisOverride", %configObj.DoUpAxisOverride); - %xmlDoc.setAttribute("UpAxisOverride", %configObj.UpAxisOverride); - %xmlDoc.setAttribute("DoScaleOverride", %configObj.DoScaleOverride); - %xmlDoc.setAttribute("ScaleOverride", %configObj.ScaleOverride); - %xmlDoc.setAttribute("IgnoreNodeScale", %configObj.IgnoreNodeScale); - %xmlDoc.setAttribute("AdjustCenter", %configObj.AdjustCenter); - %xmlDoc.setAttribute("AdjustFloor", %configObj.AdjustFloor); - %xmlDoc.setAttribute("CollapseSubmeshes", %configObj.CollapseSubmeshes); - %xmlDoc.setAttribute("LODType", %configObj.LODType); - %xmlDoc.setAttribute("ImportedNodes", %configObj.ImportedNodes); - %xmlDoc.setAttribute("IgnoreNodes", %configObj.IgnoreNodes); - %xmlDoc.setAttribute("ImportMeshes", %configObj.ImportMeshes); - %xmlDoc.setAttribute("IgnoreMeshes", %configObj.IgnoreMeshes); - %xmlDoc.popElement(); - - %xmlDoc.pushNewElement("Materials"); - %xmlDoc.setAttribute("ImportMaterials", %configObj.ImportMaterials); - %xmlDoc.setAttribute("IgnoreMaterials", %configObj.IgnoreMaterials); - %xmlDoc.setAttribute("CreateComposites", %configObj.CreateComposites); - %xmlDoc.setAttribute("UseDiffuseSuffixOnOriginImg", %configObj.UseDiffuseSuffixOnOriginImg); - %xmlDoc.setAttribute("UseExistingMaterials", %configObj.UseExistingMaterials); - %xmlDoc.popElement(); - - %xmlDoc.pushNewElement("Animations"); - %xmlDoc.setAttribute("ImportAnimations", %configObj.ImportAnimations); - %xmlDoc.setAttribute("SeparateAnimations", %configObj.SeparateAnimations); - %xmlDoc.setAttribute("SeparateAnimationPrefix", %configObj.SeparateAnimationPrefix); - %xmlDoc.popElement(); - - %xmlDoc.pushNewElement("Collisions"); - %xmlDoc.setAttribute("GenerateCollisions", %configObj.GenerateCollisions); - %xmlDoc.setAttribute("GenCollisionType", %configObj.GenCollisionType); - %xmlDoc.setAttribute("CollisionMeshPrefix", %configObj.CollisionMeshPrefix); - %xmlDoc.setAttribute("GenerateLOSCollisions", %configObj.GenerateLOSCollisions); - %xmlDoc.setAttribute("GenLOSCollisionType", %configObj.GenLOSCollisionType); - %xmlDoc.setAttribute("LOSCollisionMeshPrefix", %configObj.LOSCollisionMeshPrefix); - %xmlDoc.popElement(); - - %xmlDoc.pushNewElement("Images"); - %xmlDoc.setAttribute("ImageType", %configObj.ImageType); - %xmlDoc.setAttribute("DiffuseTypeSuffixes", %configObj.DiffuseTypeSuffixes); - %xmlDoc.setAttribute("NormalTypeSuffixes", %configObj.NormalTypeSuffixes); - %xmlDoc.setAttribute("SpecularTypeSuffixes", %configObj.SpecularTypeSuffixes); - %xmlDoc.setAttribute("MetalnessTypeSuffixes", %configObj.MetalnessTypeSuffixes); - %xmlDoc.setAttribute("RoughnessTypeSuffixes", %configObj.RoughnessTypeSuffixes); - %xmlDoc.setAttribute("SmoothnessTypeSuffixes", %configObj.SmoothnessTypeSuffixes); - %xmlDoc.setAttribute("AOTypeSuffixes", %configObj.AOTypeSuffixes); - %xmlDoc.setAttribute("CompositeTypeSuffixes", %configObj.CompositeTypeSuffixes); - %xmlDoc.setAttribute("TextureFilteringMode", %configObj.TextureFilteringMode); - %xmlDoc.setAttribute("UseMips", %configObj.UseMips); - %xmlDoc.setAttribute("IsHDR", %configObj.IsHDR); - %xmlDoc.setAttribute("Scaling", %configObj.Scaling); - %xmlDoc.setAttribute("Compressed", %configObj.Compressed); - %xmlDoc.setAttribute("GenerateMaterialOnImport", %configObj.GenerateMaterialOnImport); - %xmlDoc.setAttribute("PopulateMaterialMaps", %configObj.PopulateMaterialMaps); - %xmlDoc.popElement(); - - %xmlDoc.pushNewElement("Sounds"); - %xmlDoc.setAttribute("VolumeAdjust", %configObj.VolumeAdjust); - %xmlDoc.setAttribute("PitchAdjust", %configObj.PitchAdjust); - %xmlDoc.setAttribute("Compressed", %configObj.Compressed); - %xmlDoc.popElement(); - - %xmlDoc.popElement(); - } - - %xmlDoc.popElement(); - - %xmlDoc.saveFile($AssetBrowser::importConfigsFile); + %success = AssetImportSettings.write(); ImportAssetConfigEditorWindow.setVisible(0); ImportAssetWindow.reloadImportOptionConfigs(); } +function ImportOptionsConfigList::addSettingsField(%this, %settingsFieldName, %labelText, %fieldType, %tooltip, %fieldData) +{ + %moddedSettingsFieldName = strreplace(%settingsFieldName, "/", "-"); + + %this.addCallbackField(%moddedSettingsFieldName, %labelText, %fieldType, "", AssetImportSettings.value(%settingsFieldName), %fieldData, "changeEditorSetting"); +} + +function ImportOptionsConfigList::changeEditorSetting(%this, %varName, %value) +{ + %varName = strreplace(%varName, "-", "/"); + + echo("Set " @ %varName @ " to be " @ %value); + + AssetImportSettings.setValue(%varName, %value); + + %success = AssetImportSettings.write(); +} + function ImportOptionsConfigList::ToggleImportMesh(%this, %fieldName, %newValue, %ownerObject) { %this.setFieldEnabled("DoUpAxisOverride", %newValue); diff --git a/Templates/BaseGame/game/tools/assetBrowser/scripts/assetTypes/image.cs b/Templates/BaseGame/game/tools/assetBrowser/scripts/assetTypes/image.cs index 5cadf69b0..92491ab74 100644 --- a/Templates/BaseGame/game/tools/assetBrowser/scripts/assetTypes/image.cs +++ b/Templates/BaseGame/game/tools/assetBrowser/scripts/assetTypes/image.cs @@ -1,6 +1,6 @@ function AssetBrowser::prepareImportImageAsset(%this, %assetItem) { - if(ImportAssetWindow.activeImportConfig.GenerateMaterialOnImport == 1 && %assetItem.parentAssetItem $= "") + if(getAssetImportConfigValue("Images/GenerateMaterialOnImport", "1") == 1 && %assetItem.parentAssetItem $= "") { //First, see if this already has a suffix of some sort based on our import config logic. Many content pipeline tools like substance automatically appends them %foundSuffixType = ImportAssetWindow.parseImageSuffixes(%assetItem); @@ -45,21 +45,21 @@ function AssetBrowser::prepareImportImageAsset(%this, %assetItem) //if we find these, we'll just populate into the original's material //If we need to append the diffuse suffix and indeed didn't find a suffix on the name, do that here - if(ImportAssetWindow.activeImportConfig.UseDiffuseSuffixOnOriginImg == 1) + if(getAssetImportConfigValue("Images/UseDiffuseSuffixOnOriginImg", "1") == 1) { if(%foundSuffixType $= "") { - %diffuseToken = getToken(ImportAssetWindow.activeImportConfig.DiffuseTypeSuffixes, ",", 0); + %diffuseToken = getToken(getAssetImportConfigValue("Images/DiffuseTypeSuffixes", ""), ",", 0); %assetItem.AssetName = %assetItem.AssetName @ %diffuseToken; - if(ImportAssetWindow.activeImportConfig.PopulateMaterialMaps == 1) + if(getAssetImportConfigValue("Materials/PopulateMaterialMaps", "1") == 1) %materialAsset.diffuseImageAsset = %assetItem; } else if(%foundSuffixType !$= "") { //otherwise, if we have some sort of suffix, we'll want to figure out if we've already got an existing material, and should append to it - if(ImportAssetWindow.activeImportConfig.PopulateMaterialMaps == 1) + if(getAssetImportConfigValue("Materials/PopulateMaterialMaps", "1") == 1) { if(%foundSuffixType $= "diffuse") %materialAsset.diffuseImageAsset = %assetItem; diff --git a/Templates/BaseGame/game/tools/assetBrowser/scripts/assetTypes/material.cs b/Templates/BaseGame/game/tools/assetBrowser/scripts/assetTypes/material.cs index ed8f99b0a..90d585ef9 100644 --- a/Templates/BaseGame/game/tools/assetBrowser/scripts/assetTypes/material.cs +++ b/Templates/BaseGame/game/tools/assetBrowser/scripts/assetTypes/material.cs @@ -62,12 +62,12 @@ function AssetBrowser::prepareImportMaterialAsset(%this, %assetItem) %fileExt = fileExt(%assetItem.filePath); //Check if we need to filter this material out or not - if(ImportAssetWindow.activeImportConfig.IgnoreMaterials !$= "") + if(getAssetImportConfigValue("Materials/IgnoreMaterials", "") !$= "") { - %ignoredMatNamesCount = getTokenCount(ImportAssetWindow.activeImportConfig.IgnoreMaterials, ",;"); + %ignoredMatNamesCount = getTokenCount(getAssetImportConfigValue("Materials/IgnoreMaterials", ""), ",;"); for(%i=0; %i < %ignoredMatNamesCount; %i++) { - %ignoreName = getToken(ImportAssetWindow.activeImportConfig.IgnoreMaterials, ".;", %i); + %ignoreName = getToken(getAssetImportConfigValue("Materials/IgnoreMaterials", ""), ",;", %i); if(strIsMatchExpr(%ignoreName, %fileName)) { @@ -78,7 +78,7 @@ function AssetBrowser::prepareImportMaterialAsset(%this, %assetItem) } } - if(ImportAssetWindow.activeImportConfig.PopulateMaterialMaps == 1) + if(getAssetImportConfigValue("Materials/PopulateMaterialMaps", "") == 1) { %materialItemId = ImportAssetTree.findItemByObjectId(%assetItem); @@ -90,9 +90,9 @@ function AssetBrowser::prepareImportMaterialAsset(%this, %assetItem) %diffuseImageSuffix = ImportAssetWindow.parseImagePathSuffixes(%diffuseImagePath); - if(ImportAssetWindow.activeImportConfig.UseDiffuseSuffixOnOriginImg == 1 && %diffuseImageSuffix $= "") + if(getAssetImportConfigValue("Images/UseDiffuseSuffixOnOriginImage", "1") == 1 && %diffuseImageSuffix $= "") { - %diffuseToken = getToken(ImportAssetWindow.activeImportConfig.DiffuseTypeSuffixes, ",;", 0); + %diffuseToken = getToken(getAssetImportConfigValue("Materials/DiffuseTypeSuffixes", ""), ",;", 0); %diffuseAsset = AssetBrowser.addImportingAsset("Image", %diffuseImagePath, %assetItem, %filename @ %diffuseToken); } @@ -121,10 +121,10 @@ function AssetBrowser::prepareImportMaterialAsset(%this, %assetItem) %diffFileName = fileBase(%assetItem.diffuseImageAsset.filePath); %diffFileExt = fileExt(%assetItem.diffuseImageAsset.filePath); - %suffixCount = getTokenCount(ImportAssetWindow.activeImportConfig.DiffuseTypeSuffixes, ",;"); + %suffixCount = getTokenCount(getAssetImportConfigValue("Materials/DiffuseTypeSuffixes", ""), ",;"); for(%sfx = 0; %sfx < %suffixCount; %sfx++) { - %suffixToken = getToken(ImportAssetWindow.activeImportConfig.DiffuseTypeSuffixes, ",;", %sfx); + %suffixToken = getToken(getAssetImportConfigValue("Materials/DiffuseTypeSuffixes", ""), ",;", %sfx); if(strIsMatchExpr("*"@%suffixToken, %diffFileName)) { %diffFileName = strreplace(%diffFileName, %suffixToken, ""); @@ -143,7 +143,7 @@ function AssetBrowser::prepareImportMaterialAsset(%this, %assetItem) %assetItem.normalImageAsset = %normalAsset; } } - if(%assetItem.specularImageAsset $= "") + /*if(%assetItem.specularImageAsset $= "") { //Specular %listCount = getTokenCount(ImportAssetWindow.activeImportConfig.SpecularTypeSuffixes, ",;"); @@ -163,7 +163,7 @@ function AssetBrowser::prepareImportMaterialAsset(%this, %assetItem) break; } } - } + }*/ if(%assetItem.metalImageAsset $= "") { diff --git a/Templates/BaseGame/game/tools/settings.xml b/Templates/BaseGame/game/tools/settings.xml index 3c5aea189..6b444f490 100644 --- a/Templates/BaseGame/game/tools/settings.xml +++ b/Templates/BaseGame/game/tools/settings.xml @@ -1,157 +1,157 @@ - - 15 - 0.8 - 0 - 100 - 0 - 0.8 - 1 + + 50 + WorldEditorInspectorPlugin + AssetWork_Debug.exe + 6 + screenCenter + 40 + 0 + 1 + + ../../../Documentation/Official Documentation.html + http://www.garagegames.com/products/torque-3d/documentation/user + http://www.garagegames.com/products/torque-3d/forums + ../../../Documentation/Torque 3D - Script Manual.chm + + + 180 180 180 255 + 255 255 255 255 + 48 48 48 255 + 215 215 215 255 + 50 50 50 255 + + + 0 + 255 + 20 + 8 + 1 + + + 0 0 255 255 + 255 255 255 255 + 100 100 100 255 + 255 0 0 255 + 255 255 0 255 + 0 255 0 255 + 255 255 0 255 + + + 2 + 0 + 1 + 0 + 100 + 1 + 0 + + + 1 + 1 + 1 + 1 + 1 + - 0 - 255 255 255 20 - 10 10 10 - 500 - 0 - 0 + 255 255 255 100 + 0 + 51 51 51 100 + 102 102 102 100 + 1 + + + tools/worldEditor/images/LockedHandle + tools/worldEditor/images/DefaultHandle + tools/worldEditor/images/SelectHandle - 72 70 68 255 178 175 172 255 - 72 70 68 255 240 240 240 255 - 50 49 48 255 32 31 30 255 - 96 94 92 255 - 17 16 15 255 - 59 58 57 255 - 43 43 43 255 - 37 36 35 255 - 50 49 48 255 - 236 234 232 255 - 50 49 48 255 - 100 98 96 255 - 59 58 57 255 - 234 232 230 255 255 255 255 255 - - - 40 - WorldEditorInspectorPlugin - 0 - AssetWork_Debug.exe - 1 - 6 - 50 - screenCenter - - 0 - 1 - 8 - 20 - 255 - - - 1 - 51 51 51 100 - 255 255 255 100 - 102 102 102 100 - 0 - - - tools/worldEditor/images/SelectHandle - tools/worldEditor/images/DefaultHandle - tools/worldEditor/images/LockedHandle - - - 1 - 1 - 1 - 1 - 1 - - - 0 - 2 - 1 - 1 - 0 - 0 - 100 - - - 100 100 100 255 - 0 0 255 255 - Lime - 255 255 0 255 - 255 255 255 255 - 255 255 0 255 - 255 0 0 255 - - - 48 48 48 255 - 180 180 180 255 - 50 50 50 255 - 215 215 215 255 - 255 255 255 255 - - - http://www.garagegames.com/products/torque-3d/documentation/user - ../../../Documentation/Torque 3D - Script Manual.chm - http://www.garagegames.com/products/torque-3d/forums - ../../../Documentation/Official Documentation.html - + 59 58 57 255 + 50 49 48 255 + 50 49 48 255 + 43 43 43 255 + 17 16 15 255 + 72 70 68 255 + 72 70 68 255 + 50 49 48 255 + 234 232 230 255 + 100 98 96 255 + 236 234 232 255 + 96 94 92 255 + 37 36 35 255 + 59 58 57 255 - 1024 768 tools/gui - - 1 - 1 - + 1024 768 0 - 0 0 + 0 - 1 - 8 - 1 - 1 - 1 - 2 - 1 0 + 1 + 8 + 1 + 1 + 1 + 2 + 1 - ../../../Documentation/Official Documentation.html - ../../../Documentation/Torque 3D - Script Manual.chm http://www.garagegames.com/products/torque-3d/documentation/user - - - Categorized + ../../../Documentation/Torque 3D - Script Manual.chm + ../../../Documentation/Official Documentation.html 0 + + 1 + 1 + + + Categorized + - - data/FPSGameplay/levels - - - 25 - - - 5 - + + 0 + 0.8 + 1 + 100 + 15 + 0.8 + 0 + + 10 10 10 + 0 + 255 255 255 20 + 500 + 0 + 0 AIPlayer + + data/FPSGameplay/levels + + + 5 + + + 25 + + + Grid_512_Orange