mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-07-15 16:44:36 +00:00
* BugFix: More cleanup of MSVC compiler warnings.
This commit is contained in:
parent
22d6b4a1f1
commit
74cc60508b
7 changed files with 2 additions and 42 deletions
|
|
@ -65,8 +65,6 @@ ConsoleSetType(TypeGUIAssetPtr)
|
||||||
if (argc == 1)
|
if (argc == 1)
|
||||||
{
|
{
|
||||||
// Yes, so fetch field value.
|
// Yes, so fetch field value.
|
||||||
const char* pFieldValue = argv[0];
|
|
||||||
|
|
||||||
*((const char**)dptr) = StringTable->insert(argv[0]);
|
*((const char**)dptr) = StringTable->insert(argv[0]);
|
||||||
|
|
||||||
return;
|
return;
|
||||||
|
|
|
||||||
|
|
@ -275,21 +275,6 @@ void ImageAsset::loadImage()
|
||||||
mLoadedState = Ok;
|
mLoadedState = Ok;
|
||||||
mIsValidImage = true;
|
mIsValidImage = true;
|
||||||
return;
|
return;
|
||||||
|
|
||||||
//GFXTexHandle texture = getTexture(&GFXStaticTextureSRGBProfile);
|
|
||||||
|
|
||||||
//mTexture.set(mImagePath, &GFXStaticTextureSRGBProfile, avar("%s() - mImage (line %d)", __FUNCTION__, __LINE__));
|
|
||||||
|
|
||||||
/*if (texture.isValid())
|
|
||||||
{
|
|
||||||
mIsValidImage = true;
|
|
||||||
|
|
||||||
//mBitmap = texture.getBitmap();
|
|
||||||
|
|
||||||
return;
|
|
||||||
}*/
|
|
||||||
|
|
||||||
mChangeSignal.trigger();
|
|
||||||
}
|
}
|
||||||
mLoadedState = BadFileReference;
|
mLoadedState = BadFileReference;
|
||||||
|
|
||||||
|
|
@ -497,8 +482,6 @@ GuiControl* GuiInspectorTypeImageAssetPtr::constructEditControl()
|
||||||
mInspector->getInspectObject()->getIdString(), mCaption);
|
mInspector->getInspectObject()->getIdString(), mCaption);
|
||||||
mBrowseButton->setField("Command", szBuffer);
|
mBrowseButton->setField("Command", szBuffer);
|
||||||
|
|
||||||
const char* id = mInspector->getInspectObject()->getIdString();
|
|
||||||
|
|
||||||
setDataField(StringTable->insert("targetObject"), NULL, mInspector->getInspectObject()->getIdString());
|
setDataField(StringTable->insert("targetObject"), NULL, mInspector->getInspectObject()->getIdString());
|
||||||
|
|
||||||
// Create "Open in ShapeEditor" button
|
// Create "Open in ShapeEditor" button
|
||||||
|
|
|
||||||
|
|
@ -191,16 +191,6 @@ bool ScriptAsset::execScript()
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
if (Torque::FS::IsScriptFile(mScriptPath))
|
|
||||||
{
|
|
||||||
return Con::executeFile(mScriptPath, false, false);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
Con::errorf("ScriptAsset:execScript() - Script asset must have a valid file to exec");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
DefineEngineMethod(ScriptAsset, execScript, bool, (), ,
|
DefineEngineMethod(ScriptAsset, execScript, bool, (), ,
|
||||||
|
|
|
||||||
|
|
@ -603,8 +603,6 @@ GuiControl* GuiInspectorTypeShapeAssetPtr::constructEditControl()
|
||||||
mInspector->getInspectObject()->getIdString(), mCaption);
|
mInspector->getInspectObject()->getIdString(), mCaption);
|
||||||
mBrowseButton->setField("Command", szBuffer);
|
mBrowseButton->setField("Command", szBuffer);
|
||||||
|
|
||||||
const char* id = mInspector->getInspectObject()->getIdString();
|
|
||||||
|
|
||||||
setDataField(StringTable->insert("targetObject"), NULL, mInspector->getInspectObject()->getIdString());
|
setDataField(StringTable->insert("targetObject"), NULL, mInspector->getInspectObject()->getIdString());
|
||||||
|
|
||||||
// Create "Open in ShapeEditor" button
|
// Create "Open in ShapeEditor" button
|
||||||
|
|
|
||||||
|
|
@ -468,8 +468,6 @@ GuiControl* GuiInspectorTypeTerrainAssetPtr::constructEditControl()
|
||||||
mInspector->getInspectObject()->getIdString(), mCaption);
|
mInspector->getInspectObject()->getIdString(), mCaption);
|
||||||
mBrowseButton->setField("Command", szBuffer);
|
mBrowseButton->setField("Command", szBuffer);
|
||||||
|
|
||||||
const char* id = mInspector->getInspectObject()->getIdString();
|
|
||||||
|
|
||||||
setDataField(StringTable->insert("targetObject"), NULL, mInspector->getInspectObject()->getIdString());
|
setDataField(StringTable->insert("targetObject"), NULL, mInspector->getInspectObject()->getIdString());
|
||||||
|
|
||||||
// Create "Open in ShapeEditor" button
|
// Create "Open in ShapeEditor" button
|
||||||
|
|
|
||||||
|
|
@ -1821,10 +1821,8 @@ void AssetImporter::processShapeAsset(AssetImportObject* assetItem)
|
||||||
}
|
}
|
||||||
|
|
||||||
S32 meshCount = dAtoi(assetItem->shapeInfo->getDataField(StringTable->insert("_meshCount"), nullptr));
|
S32 meshCount = dAtoi(assetItem->shapeInfo->getDataField(StringTable->insert("_meshCount"), nullptr));
|
||||||
S32 shapeItem = assetItem->shapeInfo->findItemByName("Meshes");
|
|
||||||
|
|
||||||
S32 animCount = dAtoi(assetItem->shapeInfo->getDataField(StringTable->insert("_animCount"), nullptr));
|
S32 animCount = dAtoi(assetItem->shapeInfo->getDataField(StringTable->insert("_animCount"), nullptr));
|
||||||
S32 animItem = assetItem->shapeInfo->findItemByName("Animations");
|
|
||||||
|
|
||||||
S32 materialCount = dAtoi(assetItem->shapeInfo->getDataField(StringTable->insert("_materialCount"), nullptr));
|
S32 materialCount = dAtoi(assetItem->shapeInfo->getDataField(StringTable->insert("_materialCount"), nullptr));
|
||||||
S32 matItem = assetItem->shapeInfo->findItemByName("Materials");
|
S32 matItem = assetItem->shapeInfo->findItemByName("Materials");
|
||||||
|
|
@ -2005,9 +2003,7 @@ void AssetImporter::validateAsset(AssetImportObject* assetItem)
|
||||||
if (assetItem->importStatus == AssetImportObject::Skipped || assetItem->importStatus == AssetImportObject::NotProcessed)
|
if (assetItem->importStatus == AssetImportObject::Skipped || assetItem->importStatus == AssetImportObject::NotProcessed)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
bool hasCollision = checkAssetForCollision(assetItem);
|
if (checkAssetForCollision(assetItem))
|
||||||
|
|
||||||
if (hasCollision)
|
|
||||||
{
|
{
|
||||||
importIssues = true;
|
importIssues = true;
|
||||||
return;
|
return;
|
||||||
|
|
@ -2018,7 +2014,6 @@ void AssetImporter::validateAsset(AssetImportObject* assetItem)
|
||||||
AssetQuery aQuery;
|
AssetQuery aQuery;
|
||||||
U32 numAssetsFound = AssetDatabase.findAllAssets(&aQuery);
|
U32 numAssetsFound = AssetDatabase.findAllAssets(&aQuery);
|
||||||
|
|
||||||
bool hasCollision = false;
|
|
||||||
for (U32 i = 0; i < numAssetsFound; i++)
|
for (U32 i = 0; i < numAssetsFound; i++)
|
||||||
{
|
{
|
||||||
StringTableEntry assetId = aQuery.mAssetList[i];
|
StringTableEntry assetId = aQuery.mAssetList[i];
|
||||||
|
|
@ -2032,7 +2027,6 @@ void AssetImporter::validateAsset(AssetImportObject* assetItem)
|
||||||
|
|
||||||
if (assetName == StringTable->insert(assetItem->assetName.c_str()))
|
if (assetName == StringTable->insert(assetItem->assetName.c_str()))
|
||||||
{
|
{
|
||||||
hasCollision = true;
|
|
||||||
assetItem->status = "Error";
|
assetItem->status = "Error";
|
||||||
assetItem->statusType = "DuplicateAsset";
|
assetItem->statusType = "DuplicateAsset";
|
||||||
assetItem->statusInfo = "Duplicate asset names found within the target module!\nAsset \"" + assetItem->assetName + "\" of type \"" + assetItem->assetType + "\" has a matching name.\nPlease rename it and try again!";
|
assetItem->statusInfo = "Duplicate asset names found within the target module!\nAsset \"" + assetItem->assetName + "\" of type \"" + assetItem->assetType + "\" has a matching name.\nPlease rename it and try again!";
|
||||||
|
|
@ -2241,7 +2235,6 @@ void AssetImporter::resetImportConfig()
|
||||||
activeImportConfig->registerObject();
|
activeImportConfig->registerObject();
|
||||||
}
|
}
|
||||||
|
|
||||||
bool foundConfig = false;
|
|
||||||
Settings* editorSettings;
|
Settings* editorSettings;
|
||||||
//See if we can get our editor settings
|
//See if we can get our editor settings
|
||||||
if (Sim::findObject("EditorSettings", editorSettings))
|
if (Sim::findObject("EditorSettings", editorSettings))
|
||||||
|
|
|
||||||
|
|
@ -550,7 +550,7 @@ void PlatformWindowSDL::_triggerTextNotify(const SDL_Event& evt)
|
||||||
}
|
}
|
||||||
else // get a wchar string
|
else // get a wchar string
|
||||||
{
|
{
|
||||||
const U32 len = strlen(evt.text.text);
|
const dsize_t len = strlen(evt.text.text);
|
||||||
U16 wchar[16] = {};
|
U16 wchar[16] = {};
|
||||||
dMemcpy(wchar, evt.text.text, sizeof(char)*len);
|
dMemcpy(wchar, evt.text.text, sizeof(char)*len);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue