Shifts the tools messageboxes to be distinct from any messageboxes in the main game

Reorged the canvas handling of gamepad inputs for the axis and triggers to use the SI_ versions in the right spots
Fixed issue where pause menu would be hidden and not display again
Made the pause menu active from the gamepad start button rather than back
This commit is contained in:
Areloch 2020-07-24 00:40:03 -05:00
parent ef4cc8b573
commit 5b289bce5e
57 changed files with 217 additions and 217 deletions

View file

@ -1075,14 +1075,12 @@ bool GuiCanvas::processGamepadEvent(InputEventInfo &inputEvent)
switch (inputEvent.objInst)
{
case XI_LEFT_TRIGGER:
case XI_RIGHT_TRIGGER:
case SI_ZAXIS:
case SI_RZAXIS:
return mFirstResponder->onGamepadTrigger(mLastEvent);
case SI_ZAXIS:
case SI_YAXIS:
case XI_THUMBLY:
case XI_THUMBRY:
case SI_RYAXIS:
if (!negative)
{
return mFirstResponder->onGamepadAxisDown(mLastEvent);
@ -1093,8 +1091,7 @@ bool GuiCanvas::processGamepadEvent(InputEventInfo &inputEvent)
}
case SI_XAXIS:
case XI_THUMBLX:
case XI_THUMBRX:
case SI_RXAXIS:
default:
if (negative)
{

View file

@ -136,7 +136,7 @@ ExampleMoveMap.bind( gamepad, thumbly, "D", "-0.23 0.23", gamePadMoveY );
ExampleMoveMap.bind( gamepad, btn_a, jump );
ExampleMoveMap.bind( gamepad, btn_x, moveup );
ExampleMoveMap.bind( gamepad, btn_y, movedown );
ExampleMoveMap.bindCmd( gamepad, btn_back, "Canvas.pushDialog(PauseMenu);", "" );
ExampleMoveMap.bindCmd( gamepad, btn_start, "Canvas.pushDialog(PauseMenu);", "" );
//------------------------------------------------------------------------------
// Misc.

View file

@ -9,6 +9,8 @@ function PauseMenu::onWake(%this)
{
$timescale = 0;
PauseMenuList.hidden = false;
PauseMenuList.setFirstResponder();
PauseButtonHolder.setActive();
}
@ -21,6 +23,7 @@ function PauseMenu::onSleep(%this)
function PauseMenu::onReturnTo(%this)
{
PauseMenuList.hidden = false;
PauseMenuList.setFirstResponder();
PauseButtonHolder.setActive();
}

View file

@ -283,7 +283,7 @@ function VerveEditorGroupBuilderGUI::_Build( %this, %groupLabel )
{
if ( %groupLabel $= "" )
{
messageBox( "Warning", "You must provide a Valid Group Label.", "Ok" );
toolsMessageBox( "Warning", "You must provide a Valid Group Label.", "Ok" );
return;
}

View file

@ -30,7 +30,7 @@ function VGroup::OnAdd( %this )
if ( %groupObject.isMemberOfClass( %ourClass ) )
{
// Alert Message.
messageBox( "Verve Editor", "You cannot have more than one \"" @ %ourClass @ "\" in your sequence.", "Ok", "Warning" );
toolsMessageBox( "Verve Editor", "You cannot have more than one \"" @ %ourClass @ "\" in your sequence.", "Ok", "Warning" );
// Invalid.
return false;

View file

@ -172,7 +172,7 @@ function VerveEditor::SavePrompt()
return true;
}
%result = messageBox( "Verve Editor", "Save Changes to your sequence?", "SaveDontSave", "Warning" );
%result = toolsMessageBox( "Verve Editor", "Save Changes to your sequence?", "SaveDontSave", "Warning" );
if ( %result $= $MROk )
{
// Save.
@ -189,7 +189,7 @@ function VerveEditor::SavePromptCancel()
return true;
}
%result = messageBox( "Verve Editor", "Save Changes to your sequence?", "SaveDontSaveCancel", "Warning" );
%result = toolsMessageBox( "Verve Editor", "Save Changes to your sequence?", "SaveDontSaveCancel", "Warning" );
if ( %result $= $MRCancel )
{
return false;

View file

@ -30,7 +30,7 @@ function VTrack::OnAdd( %this )
if ( %trackObject.isMemberOfClass( %ourClass ) )
{
// Alert Message.
messageBox( "Verve Editor", "You cannot have more than one \"" @ %ourClass @ "\" in a group.", "Ok", "Warning" );
toolsMessageBox( "Verve Editor", "You cannot have more than one \"" @ %ourClass @ "\" in a group.", "Ok", "Warning" );
// Invalid.
return false;

View file

@ -928,7 +928,7 @@ function AssetBrowser::showDeleteDialog( %this )
if( isObject( %material ) )
{
MessageBoxYesNoCancel("Delete Material?",
toolsMessageBoxYesNoCancel("Delete Material?",
"Are you sure you want to delete<br><br>" @ %material.getName() @ "<br><br> Material deletion won't take affect until the engine is quit.",
"AssetBrowser.deleteMaterial( " @ %material @ ", " @ %secondFilter @ ", " @ %secondFilterName @" );",
"",
@ -2320,7 +2320,7 @@ function AssetBrowserFilterTree::onControlDropped( %this, %payload, %position )
if(%path !$= AssetBrowser.dirHandler.CurrentAddress)
{
//we're trying to move the asset to a different module!
//MessageBoxYesNo( "Move Asset", "Do you wish to move asset " @ %assetName @ " to " @ %path @ "?",
//toolsMessageBoxYesNo( "Move Asset", "Do you wish to move asset " @ %assetName @ " to " @ %path @ "?",
// "AssetBrowser.moveAsset(\""@ %moduleName @ ":" @ %assetName @"\", \""@%path@"\");", "");
if(%assetType $= "Folder")

View file

@ -422,19 +422,19 @@ function ImportAssetWindow::reloadImportOptionConfigs(%this)
EditorSettings.value("Assets/AssetImporDefaultConfig") $= "" ||
EditorSettings.value("Assets/AutoImport", false) == false)
{
MessageBoxOK("Unable to AutoImport", "Attempted to import a loose file " @ %filePath @ " with AutoImport but was unable to either due to lacking a valid import config, or the editor settings are not set to auto import.");
toolsMessageBoxOK("Unable to AutoImport", "Attempted to import a loose file " @ %filePath @ " with AutoImport but was unable to either due to lacking a valid import config, or the editor settings are not set to auto import.");
return false;
}
if(%assetType $= "folder" || %assetType $= "zip")
{
MessageBoxOK("Unable to AutoImport", "Unable to auto import folders or zips at this time");
toolsMessageBoxOK("Unable to AutoImport", "Unable to auto import folders or zips at this time");
return false;
}
if(%assetType $= "")
{
MessageBoxOK("Unable to AutoImport", "Unable to auto import unknown file type for file " @ %filePath);
toolsMessageBoxOK("Unable to AutoImport", "Unable to auto import unknown file type for file " @ %filePath);
return false;
}
}
@ -706,7 +706,7 @@ function ImportAssetWindow::doRefresh(%this)
if(ImportAssetWindow.importConfigsList.count() == 0)
{
MessageBoxOK( "Warning", "No base import config. Please create an import configuration set to simplify asset importing.");
toolsMessageBoxOK( "Warning", "No base import config. Please create an import configuration set to simplify asset importing.");
}
%this.dirty = false;
@ -978,7 +978,7 @@ function ImportAssetWindow::ImportAssets(%this)
if(!isObject(%module))
{
MessageBoxOK( "Error!", "No module selected. You must select or create a module for the assets to be added to.");
toolsMessageBoxOK( "Error!", "No module selected. You must select or create a module for the assets to be added to.");
return;
}

View file

@ -168,7 +168,7 @@ function AssetImportConfigEditor::createNewImportConfig(%this)
function AssetImportConfigEditor::deleteConfig(%this)
{
%callback = "AssetImportConfigEditor.onDeleteConfig();";
MessageBoxOKCancel("Delete Import Config", "This will delete the " @ AssetImportConfigList.currentConfig @ " config. Continue?", %callback, "");
toolsMessageBoxOKCancel("Delete Import Config", "This will delete the " @ AssetImportConfigList.currentConfig @ " config. Continue?", %callback, "");
}
function AssetImportConfigEditor::onDeleteConfig(%this)

View file

@ -349,7 +349,7 @@ function AssetBrowser::deleteAsset(%this)
//%assetDef = AssetDatabase.acquireAsset(EditAssetPopup.assetId);
//%assetType = %assetDef.getClassName();
MessageBoxOKCancel("Warning!", "This will delete the selected content and the files associated to it, do you wish to continue?",
toolsMessageBoxOKCancel("Warning!", "This will delete the selected content and the files associated to it, do you wish to continue?",
"AssetBrowser.confirmDeleteAsset();", "");
}

View file

@ -20,7 +20,7 @@ function AssetBrowser::CreateNewModule(%this)
function AssetBrowser::promptNewModuleFolders(%this)
{
MessageBoxYesNo("Create Folders?",
toolsMessageBoxYesNo("Create Folders?",
"Do you want to create some common folders for organization of your new Module?",
"AssetBrowser.makeModuleFolders();", //if yes, make the foldesr
"AssetBrowser.loadDirectories();"); //if no, just refresh

View file

@ -157,7 +157,7 @@ function CreateNewAsset()
if(%assetName $= "")
{
MessageBoxOK( "Error", "Attempted to make a new asset with no name!");
toolsMessageBoxOK( "Error", "Attempted to make a new asset with no name!");
return;
}
@ -166,7 +166,7 @@ function CreateNewAsset()
if(%moduleName $= "")
{
MessageBoxOK( "Error", "Attempted to make a new asset with no module!");
toolsMessageBoxOK( "Error", "Attempted to make a new asset with no module!");
return;
}
@ -175,7 +175,7 @@ function CreateNewAsset()
%assetType = AssetBrowser.newAssetSettings.assetType;
if(%assetType $= "")
{
MessageBoxOK( "Error", "Attempted to make a new asset with no type!");
toolsMessageBoxOK( "Error", "Attempted to make a new asset with no type!");
return;
}

View file

@ -610,7 +610,7 @@ function DatablockEditorPlugin::deleteDatablock( %this )
// Show some confirmation.
if( %numSelected == 1 )
MessageBoxOk( "Datablock Deleted", "The datablock (" @ %db.getName() @ ") has been removed from " @
toolsMessageBoxOk( "Datablock Deleted", "The datablock (" @ %db.getName() @ ") has been removed from " @
"it's file (" @ %db.getFilename() @ ") and upon restart will cease to exist" );
}
@ -622,7 +622,7 @@ function DatablockEditorPlugin::deleteDatablock( %this )
// Show confirmation for multiple datablocks.
if( %numSelected > 1 )
MessageBoxOk( "Datablocks Deleted", "The datablocks have been deleted and upon restart will cease to exist." );
toolsMessageBoxOk( "Datablocks Deleted", "The datablocks have been deleted and upon restart will cease to exist." );
// Clear selection.

View file

@ -141,7 +141,7 @@ function RetargetDecalButton::onClick( %this )
if( !isObject(%datablock) )
{
MessageBoxOK("Error", "A valid Decal Template must be selected.");
toolsMessageBoxOK("Error", "A valid Decal Template must be selected.");
return;
}
@ -184,7 +184,7 @@ function DeleteDecalButton::onClick( %this )
%id = DecalDataList.getSelectedItem();
%datablock = DecalDataList.getItemText(%id );
MessageBoxYesNoCancel("Delete Decal Datablock?",
toolsMessageBoxYesNoCancel("Delete Decal Datablock?",
"Are you sure you want to delete<br><br>" @ %datablock @ "<br><br> Datablock deletion won't take affect until the engine is quit.",
"DecalEditorGui.deleteSelectedDecalDatablock();",
"",

View file

@ -95,7 +95,7 @@ function ProjectBase::_onProjectOpen( %this, %data )
if( !%this.LoadProject( %data ) )
{
messageBox("Unable to Load Project", "The project file you're attempting to open was created with an incompatible version of this software\n\nConversion of 1.1.X projects will be addressed soon, we apologize for the inconvenience.","Ok","Error");
toolsMessageBox("Unable to Load Project", "The project file you're attempting to open was created with an incompatible version of this software\n\nConversion of 1.1.X projects will be addressed soon, we apologize for the inconvenience.","Ok","Error");
return false;
}

View file

@ -40,7 +40,7 @@ function ForestEditorGui::onActiveForestUpdated( %this, %forest, %createNew )
// Give the user a chance to add a forest.
if ( !%gotForest && %createNew )
{
MessageBoxYesNo( "Forest",
toolsMessageBoxYesNo( "Forest",
"There is not a Forest in this mission. Do you want to add one?",
%this @ ".createForest();", "" );
return;
@ -245,7 +245,7 @@ function ForestEditorGui::deleteMesh( %this )
if ( isObject( %obj ) )
{
MessageBoxOKCancel( "Warning",
toolsMessageBoxOKCancel( "Warning",
"Deleting this mesh will also delete BrushesElements and ForestItems referencing it.",
"ForestEditorGui.okDeleteMesh(" @ %obj @ ");",
"" );
@ -389,7 +389,7 @@ function ForestEditBrushTree::handleRenameObject( %this, %name, %obj )
%found = ForestBrushGroup.findObjectByInternalName( %name );
if ( isObject( %found ) && %found.getId() != %obj.getId() )
{
MessageBoxOK( "Error", "Brush or Element with that name already exists.", "" );
toolsMessageBoxOK( "Error", "Brush or Element with that name already exists.", "" );
// true as in, we handled it, don't rename the object.
return true;

View file

@ -205,7 +205,7 @@ function ForestEditorPlugin::onActivated( %this )
}
if ( %this.showError )
MessageBoxOK( "Error", "Your tools/forestEditor folder does not contain a valid brushes.cs. Brushes you create will not be saved!" );
toolsMessageBoxOK( "Error", "Your tools/forestEditor folder does not contain a valid brushes.cs. Brushes you create will not be saved!" );
}
function ForestEditorPlugin::onDeactivated( %this )

View file

@ -1368,7 +1368,7 @@ function MaterialSelector::createFilter( %this, %filter )
{
if( %filter $= %existingFilters )
{
MessageBoxOK( "Error", "Can not create blank filter.");
toolsMessageBoxOK( "Error", "Can not create blank filter.");
return;
}
@ -1377,7 +1377,7 @@ function MaterialSelector::createFilter( %this, %filter )
%existingFilters = MaterialSelector-->filterArray.getObject(%i).getObject(0).filter;
if( %filter $= %existingFilters )
{
MessageBoxOK( "Error", "Can not create two filters of the same name.");
toolsMessageBoxOK( "Error", "Can not create two filters of the same name.");
return;
}
}
@ -1713,7 +1713,7 @@ function MaterialSelector::showDeleteDialog( %this )
if( isObject( %material ) )
{
MessageBoxYesNoCancel("Delete Material?",
toolsMessageBoxYesNoCancel("Delete Material?",
"Are you sure you want to delete<br><br>" @ %material.getName() @ "<br><br> Material deletion won't take affect until the engine is quit.",
"MaterialSelector.deleteMaterial( " @ %material @ ", " @ %secondFilter @ ", " @ %secondFilterName @" );",
"",

View file

@ -24,16 +24,16 @@
// Cleanup Dialog created by 'core'
if( isObject( MessagePopupDlg ) )
MessagePopupDlg.delete();
if( isObject( MessageBoxYesNoDlg ) )
MessageBoxYesNoDlg.delete();
if( isObject( MessageBoxYesNoCancelDlg ) )
MessageBoxYesNoCancelDlg.delete();
if( isObject( MessageBoxOKCancelDetailsDlg ) )
MessageBoxOKCancelDetailsDlg.delete();
if( isObject( MessageBoxOKCancelDlg ) )
MessageBoxOKCancelDlg.delete();
if( isObject( MessageBoxOKDlg ) )
MessageBoxOKDlg.delete();
if( isObject( toolsMessageBoxYesNoDlg ) )
toolsMessageBoxYesNoDlg.delete();
if( isObject( toolsMessageBoxYesNoCancelDlg ) )
toolsMessageBoxYesNoCancelDlg.delete();
if( isObject( toolsMessageBoxOKCancelDetailsDlg ) )
toolsMessageBoxOKCancelDetailsDlg.delete();
if( isObject( toolsMessageBoxOKCancelDlg ) )
toolsMessageBoxOKCancelDlg.delete();
if( isObject( toolsMessageBoxOKDlg ) )
toolsMessageBoxOKDlg.delete();
if( isObject( IODropdownDlg ) )
IODropdownDlg.delete();
@ -51,7 +51,7 @@ exec("./messagePopup.ed.gui");
// --------------------------------------------------------------------
// Message Sound
// --------------------------------------------------------------------
/*new SFXDescription(MessageBoxAudioDescription)
/*new SFXDescription(toolsMessageBoxAudioDescription)
{
volume = 1.0;
isLooping = false;
@ -59,10 +59,10 @@ exec("./messagePopup.ed.gui");
channel = $GuiAudioType;
};
new SFXProfile(messageBoxBeep)
new SFXProfile(toolsMessageBoxBeep)
{
filename = "./messageBoxSound";
description = MessageBoxAudioDescription;
filename = "./toolsMessageBoxSound";
description = toolsMessageBoxAudioDescription;
preload = true;
};*/
@ -122,7 +122,7 @@ function MBSetText(%text, %frame, %msg)
%frame.canMinimize = "0";
%frame.canMaximize = "0";
//sfxPlayOnce( messageBoxBeep );
//sfxPlayOnce( toolsMessageBoxBeep );
}
//---------------------------------------------------------------------------------------------
@ -130,34 +130,34 @@ function MBSetText(%text, %frame, %msg)
// callback for each button.
//---------------------------------------------------------------------------------------------
function MessageBoxOK(%title, %message, %callback)
function toolsMessageBoxOK(%title, %message, %callback)
{
MBOKFrame.text = %title;
Canvas.pushDialog(MessageBoxOKDlg);
Canvas.pushDialog(toolsMessageBoxOKDlg);
MBSetText(MBOKText, MBOKFrame, %message);
MessageBoxOKDlg.callback = %callback;
toolsMessageBoxOKDlg.callback = %callback;
}
function MessageBoxOKDlg::onSleep( %this )
function toolsMessageBoxOKDlg::onSleep( %this )
{
%this.callback = "";
}
function MessageBoxOKCancel(%title, %message, %callback, %cancelCallback)
function toolsMessageBoxOKCancel(%title, %message, %callback, %cancelCallback)
{
MBOKCancelFrame.text = %title;
Canvas.pushDialog(MessageBoxOKCancelDlg);
Canvas.pushDialog(toolsMessageBoxOKCancelDlg);
MBSetText(MBOKCancelText, MBOKCancelFrame, %message);
MessageBoxOKCancelDlg.callback = %callback;
MessageBoxOKCancelDlg.cancelCallback = %cancelCallback;
toolsMessageBoxOKCancelDlg.callback = %callback;
toolsMessageBoxOKCancelDlg.cancelCallback = %cancelCallback;
}
function MessageBoxOKCancelDlg::onSleep( %this )
function toolsMessageBoxOKCancelDlg::onSleep( %this )
{
%this.callback = "";
}
function MessageBoxOKCancelDetails(%title, %message, %details, %callback, %cancelCallback)
function toolsMessageBoxOKCancelDetails(%title, %message, %details, %callback, %cancelCallback)
{
if(%details $= "")
{
@ -168,7 +168,7 @@ function MessageBoxOKCancelDetails(%title, %message, %details, %callback, %cance
MBOKCancelDetailsFrame.setText( %title );
Canvas.pushDialog(MessageBoxOKCancelDetailsDlg);
Canvas.pushDialog(toolsMessageBoxOKCancelDetailsDlg);
MBSetText(MBOKCancelDetailsText, MBOKCancelDetailsFrame, %message);
MBOKCancelDetailsInfoText.setText(%details);
@ -183,8 +183,8 @@ function MessageBoxOKCancelDetails(%title, %message, %details, %callback, %cance
MBOKCancelDetailsFrame.setExtent(300, %extentY);
MessageBoxOKCancelDetailsDlg.callback = %callback;
MessageBoxOKCancelDetailsDlg.cancelCallback = %cancelCallback;
toolsMessageBoxOKCancelDetailsDlg.callback = %callback;
toolsMessageBoxOKCancelDetailsDlg.cancelCallback = %cancelCallback;
MBOKCancelDetailsFrame.defaultExtent = MBOKCancelDetailsFrame.getExtent();
}
@ -223,33 +223,33 @@ function MBOKCancelDetailsToggleInfoFrame()
}
}
function MessageBoxOKCancelDetailsDlg::onSleep( %this )
function toolsMessageBoxOKCancelDetailsDlg::onSleep( %this )
{
%this.callback = "";
}
function MessageBoxYesNo(%title, %message, %yesCallback, %noCallback)
function toolsMessageBoxYesNo(%title, %message, %yesCallback, %noCallback)
{
MBYesNoFrame.text = %title;
MessageBoxYesNoDlg.profile = "GuiOverlayProfile";
Canvas.pushDialog(MessageBoxYesNoDlg);
toolsMessageBoxYesNoDlg.profile = "GuiOverlayProfile";
Canvas.pushDialog(toolsMessageBoxYesNoDlg);
MBSetText(MBYesNoText, MBYesNoFrame, %message);
MessageBoxYesNoDlg.yesCallBack = %yesCallback;
MessageBoxYesNoDlg.noCallback = %noCallBack;
toolsMessageBoxYesNoDlg.yesCallBack = %yesCallback;
toolsMessageBoxYesNoDlg.noCallback = %noCallBack;
}
function MessageBoxYesNoCancel(%title, %message, %yesCallback, %noCallback, %cancelCallback)
function toolsMessageBoxYesNoCancel(%title, %message, %yesCallback, %noCallback, %cancelCallback)
{
MBYesNoCancelFrame.text = %title;
MessageBoxYesNoDlg.profile = "GuiOverlayProfile";
Canvas.pushDialog(MessageBoxYesNoCancelDlg);
toolsMessageBoxYesNoDlg.profile = "GuiOverlayProfile";
Canvas.pushDialog(toolsMessageBoxYesNoCancelDlg);
MBSetText(MBYesNoCancelText, MBYesNoCancelFrame, %message);
MessageBoxYesNoCancelDlg.yesCallBack = %yesCallback;
MessageBoxYesNoCancelDlg.noCallback = %noCallBack;
MessageBoxYesNoCancelDlg.cancelCallback = %cancelCallback;
toolsMessageBoxYesNoCancelDlg.yesCallBack = %yesCallback;
toolsMessageBoxYesNoCancelDlg.noCallback = %noCallBack;
toolsMessageBoxYesNoCancelDlg.cancelCallback = %cancelCallback;
}
function MessageBoxYesNoDlg::onSleep( %this )
function toolsMessageBoxYesNoDlg::onSleep( %this )
{
%this.yesCallback = "";
%this.noCallback = "";
@ -311,15 +311,15 @@ function CloseMessagePopup()
// "Old" message box function aliases for backwards-compatibility.
//---------------------------------------------------------------------------------------------
function MessageBoxOKOld( %title, %message, %callback )
function toolsMessageBoxOKOld( %title, %message, %callback )
{
MessageBoxOK( %title, %message, %callback );
toolsMessageBoxOK( %title, %message, %callback );
}
function MessageBoxOKCancelOld( %title, %message, %callback, %cancelCallback )
function toolsMessageBoxOKCancelOld( %title, %message, %callback, %cancelCallback )
{
MessageBoxOKCancel( %title, %message, %callback, %cancelCallback );
toolsMessageBoxOKCancel( %title, %message, %callback, %cancelCallback );
}
function MessageBoxYesNoOld( %title, %message, %yesCallback, %noCallback )
function toolsMessageBoxYesNoOld( %title, %message, %yesCallback, %noCallback )
{
MessageBoxYesNo( %title, %message, %yesCallback, %noCallback );
toolsMessageBoxYesNo( %title, %message, %yesCallback, %noCallback );
}

View file

@ -1,5 +1,5 @@
//--- OBJECT WRITE BEGIN ---
%guiContent = new GuiControl(MessageBoxOKDlg) {
%guiContent = new GuiControl(toolsMessageBoxOKDlg) {
profile = "GuiOverlayProfile";
horizSizing = "width";
vertSizing = "height";
@ -49,7 +49,7 @@
extent = "80 24";
minExtent = "8 8";
visible = "1";
command = "MessageCallback(MessageBoxOKDlg,MessageBoxOKDlg.callback);";
command = "MessageCallback(toolsMessageBoxOKDlg,toolsMessageBoxOKDlg.callback);";
accelerator = "return";
helpTag = "0";
text = "Ok";

View file

@ -1,5 +1,5 @@
//--- OBJECT WRITE BEGIN ---
%guiContent = new GuiControl(MessageBoxOKBuyDlg) {
%guiContent = new GuiControl(toolsMessageBoxOKBuyDlg) {
profile = "ToolsGuiDefaultProfile";
horizSizing = "width";
vertSizing = "height";
@ -27,7 +27,7 @@
canMaximize = "0";
minSize = "50 50";
text = "";
closeCommand = "MessageCallback(MessageBoxOKBuyDlg,MessageBoxOKBuyDlg.noCallback);";
closeCommand = "MessageCallback(toolsMessageBoxOKBuyDlg,toolsMessageBoxOKBuyDlg.noCallback);";
new GuiMLTextCtrl(MBOKBuyText) {
profile = "ToolsGuiMLTextProfile";
@ -50,7 +50,7 @@
extent = "80 22";
minExtent = "8 8";
visible = "1";
command = "MessageCallback(MessageBoxOKBuyDlg,MessageBoxOKBuyDlg.OKCallback);";
command = "MessageCallback(toolsMessageBoxOKBuyDlg,toolsMessageBoxOKBuyDlg.OKCallback);";
accelerator = "return";
helpTag = "0";
text = "OK";
@ -64,7 +64,7 @@
extent = "80 22";
minExtent = "8 8";
visible = "1";
command = "MessageCallback(MessageBoxOKBuyDlg,MessageBoxOKBuyDlg.BuyCallback);";
command = "MessageCallback(toolsMessageBoxOKBuyDlg,toolsMessageBoxOKBuyDlg.BuyCallback);";
accelerator = "escape";
helpTag = "0";
text = "Buy Now!";
@ -74,12 +74,12 @@
};
//--- OBJECT WRITE END ---
function MessageBoxOKBuy(%title, %message, %OKCallback, %BuyCallback)
function toolsMessageBoxOKBuy(%title, %message, %OKCallback, %BuyCallback)
{
MBOKBuyFrame.text = %title;
MessageBoxOKBuyDlg.profile = "ToolsGuiOverlayProfile";
Canvas.pushDialog(MessageBoxOKBuyDlg);
toolsMessageBoxOKBuyDlg.profile = "ToolsGuiOverlayProfile";
Canvas.pushDialog(toolsMessageBoxOKBuyDlg);
MBSetText(MBOKBuyText, MBOKBuyFrame, %message);
MessageBoxOKBuyDlg.OKCallback = %OKCallback;
MessageBoxOKBuyDlg.BuyCallback = %BuyCallback;
toolsMessageBoxOKBuyDlg.OKCallback = %OKCallback;
toolsMessageBoxOKBuyDlg.BuyCallback = %BuyCallback;
}

View file

@ -1,5 +1,5 @@
//--- OBJECT WRITE BEGIN ---
%guiContent = new GuiControl(MessageBoxOKCancelDlg) {
%guiContent = new GuiControl(toolsMessageBoxOKCancelDlg) {
profile = "GuiOverlayProfile";
horizSizing = "width";
vertSizing = "height";
@ -50,7 +50,7 @@
extent = "80 24";
minExtent = "8 8";
visible = "1";
command = "MessageCallback(MessageBoxOKCancelDlg,MessageBoxOKCancelDlg.callback);";
command = "MessageCallback(toolsMessageBoxOKCancelDlg,toolsMessageBoxOKCancelDlg.callback);";
accelerator = "return";
helpTag = "0";
text = "Ok";
@ -64,7 +64,7 @@
extent = "80 24";
minExtent = "8 8";
visible = "1";
command = "MessageCallback(MessageBoxOKCancelDlg,MessageBoxOKCancelDlg.cancelCallback);";
command = "MessageCallback(toolsMessageBoxOKCancelDlg,toolsMessageBoxOKCancelDlg.cancelCallback);";
accelerator = "escape";
helpTag = "0";
text = "Cancel";

View file

@ -1,5 +1,5 @@
//--- OBJECT WRITE BEGIN ---
%guiContent = new GuiControl(MessageBoxOKCancelDetailsDlg) {
%guiContent = new GuiControl(toolsMessageBoxOKCancelDetailsDlg) {
canSaveDynamicFields = "0";
Profile = "GuiOverlayProfile";
HorizSizing = "width";
@ -57,7 +57,7 @@
MinExtent = "8 8";
canSave = "1";
Visible = "1";
Command = "MessageCallback(MessageBoxOKCancelDetailsDlg,MessageBoxOKCancelDetailsDlg.callback);";
Command = "MessageCallback(toolsMessageBoxOKCancelDetailsDlg,toolsMessageBoxOKCancelDetailsDlg.callback);";
Accelerator = "return";
hovertime = "1000";
text = "OK";
@ -74,7 +74,7 @@
MinExtent = "8 8";
canSave = "1";
Visible = "1";
Command = "MessageCallback(MessageBoxOKCancelDetailsDlg,MessageBoxOKCancelDetailsDlg.cancelCallback);";
Command = "MessageCallback(toolsMessageBoxOKCancelDetailsDlg,toolsMessageBoxOKCancelDetailsDlg.cancelCallback);";
Accelerator = "escape";
hovertime = "1000";
text = "CANCEL";

View file

@ -1,5 +1,5 @@
//--- OBJECT WRITE BEGIN ---
%guiContent = new GuiControl(MessageBoxYesNoDlg) {
%guiContent = new GuiControl(toolsMessageBoxYesNoDlg) {
profile = "GuiOverlayProfile";
horizSizing = "width";
vertSizing = "height";
@ -27,7 +27,7 @@
canMaximize = "0";
minSize = "50 50";
text = "";
closeCommand = "MessageCallback(MessageBoxYesNoDlg,MessageBoxYesNoDlg.noCallback);";
closeCommand = "MessageCallback(toolsMessageBoxYesNoDlg,toolsMessageBoxYesNoDlg.noCallback);";
new GuiMLTextCtrl(MBYesNoText) {
profile = "ToolsGuiMLTextProfile";
@ -50,7 +50,7 @@
extent = "80 22";
minExtent = "8 8";
visible = "1";
command = "MessageCallback(MessageBoxYesNoDlg,MessageBoxYesNoDlg.yesCallback);";
command = "MessageCallback(toolsMessageBoxYesNoDlg,toolsMessageBoxYesNoDlg.yesCallback);";
accelerator = "return";
helpTag = "0";
text = "Yes";
@ -64,7 +64,7 @@
extent = "80 22";
minExtent = "8 8";
visible = "1";
command = "MessageCallback(MessageBoxYesNoDlg,MessageBoxYesNoDlg.noCallback);";
command = "MessageCallback(toolsMessageBoxYesNoDlg,toolsMessageBoxYesNoDlg.noCallback);";
accelerator = "escape";
helpTag = "0";
text = "No";

View file

@ -1,5 +1,5 @@
//--- OBJECT WRITE BEGIN ---
%guiContent = new GuiControl(MessageBoxYesNoCancelDlg) {
%guiContent = new GuiControl(toolsMessageBoxYesNoCancelDlg) {
canSaveDynamicFields = "0";
Profile = "GuiOverlayProfile";
HorizSizing = "width";
@ -31,7 +31,7 @@
canMaximize = "0";
minSize = "50 50";
text = "";
closeCommand="MessageCallback(MessageBoxYesNoCancelDlg,MessageBoxYesNoCancelDlg.cancelCallback);";
closeCommand="MessageCallback(toolsMessageBoxYesNoCancelDlg,toolsMessageBoxYesNoCancelDlg.cancelCallback);";
new GuiMLTextCtrl(MBYesNoCancelText) {
canSaveDynamicFields = "0";
@ -58,7 +58,7 @@
MinExtent = "8 8";
canSave = "1";
Visible = "1";
Command = "MessageCallback(MessageBoxYesNoCancelDlg,MessageBoxYesNoCancelDlg.yesCallback);";
Command = "MessageCallback(toolsMessageBoxYesNoCancelDlg,toolsMessageBoxYesNoCancelDlg.yesCallback);";
Accelerator = "return";
hovertime = "1000";
text = "Yes";
@ -75,7 +75,7 @@
MinExtent = "8 8";
canSave = "1";
Visible = "1";
Command = "MessageCallback(MessageBoxYesNoCancelDlg,MessageBoxYesNoCancelDlg.noCallback);";
Command = "MessageCallback(toolsMessageBoxYesNoCancelDlg,toolsMessageBoxYesNoCancelDlg.noCallback);";
hovertime = "1000";
text = "No";
groupNum = "-1";
@ -91,7 +91,7 @@
MinExtent = "8 8";
canSave = "1";
Visible = "1";
Command = "MessageCallback(MessageBoxYesNoCancelDlg,MessageBoxYesNoCancelDlg.cancelCallback);";
Command = "MessageCallback(toolsMessageBoxYesNoCancelDlg,toolsMessageBoxYesNoCancelDlg.cancelCallback);";
Accelerator = "escape";
hovertime = "1000";
text = "Cancel";

View file

@ -1,5 +1,5 @@
//--- OBJECT WRITE BEGIN ---
%guiContent = new GuiControl(MessageBoxSaveChangesDlg, EditorGuiGroup) {
%guiContent = new GuiControl(toolsMessageBoxSaveChangesDlg, EditorGuiGroup) {
canSaveDynamicFields = "0";
Profile = "ToolsGuiDefaultProfile";
HorizSizing = "width";
@ -136,45 +136,45 @@
};
//--- OBJECT WRITE END ---
function MessageBoxSaveChangesDlg::onWake( %this )
function toolsMessageBoxSaveChangesDlg::onWake( %this )
{
MBSaveChangesFrame.setText( %this.Data );
}
function mbSaveDlgSaveButton::onClick( %this )
{
if( MessageBoxSaveChangesDlg.SaveCallback !$= "" )
eval( MessageBoxSaveChangesDlg.SaveCallback @ "(" @ MessageBoxSaveChangesDlg.Data @ ");" );
Canvas.popDialog( MessageBoxSaveChangesDlg );
if( toolsMessageBoxSaveChangesDlg.SaveCallback !$= "" )
eval( toolsMessageBoxSaveChangesDlg.SaveCallback @ "(" @ toolsMessageBoxSaveChangesDlg.Data @ ");" );
Canvas.popDialog( toolsMessageBoxSaveChangesDlg );
}
function mbSaveDlgCancelButton::onClick( %this )
{
Canvas.popDialog( MessageBoxSaveChangesDlg );
Canvas.popDialog( toolsMessageBoxSaveChangesDlg );
}
function mbSaveDlgDontButton::onClick( %this )
{
if( MessageBoxSaveChangesDlg.DontSaveCallback !$= "" )
eval( MessageBoxSaveChangesDlg.DontSaveCallback @ "(" @ MessageBoxSaveChangesDlg.Data @ ");" );
Canvas.popDialog( MessageBoxSaveChangesDlg );
if( toolsMessageBoxSaveChangesDlg.DontSaveCallback !$= "" )
eval( toolsMessageBoxSaveChangesDlg.DontSaveCallback @ "(" @ toolsMessageBoxSaveChangesDlg.Data @ ");" );
Canvas.popDialog( toolsMessageBoxSaveChangesDlg );
}
// Deprecated when platform layers are all sufficient
function checkSaveChangesOld( %data, %saveCallback, %dontSaveCallback )
{
// Sanity Check
if( MessageBoxSaveChangesDlg.isAwake() )
if( toolsMessageBoxSaveChangesDlg.isAwake() )
{
warn("Save Changes Dialog already Awake, NOT creating second instance.");
return;
}
// Set Proper State
MessageBoxSaveChangesDlg.SaveCallback = %saveCallback;
MessageBoxSaveChangesDlg.DontSaveCallback = %dontSaveCallback;
MessageBoxSaveChangesDlg.Data = %data;
toolsMessageBoxSaveChangesDlg.SaveCallback = %saveCallback;
toolsMessageBoxSaveChangesDlg.DontSaveCallback = %dontSaveCallback;
toolsMessageBoxSaveChangesDlg.Data = %data;
// Show Dialog
Canvas.pushDialog( MessageBoxSaveChangesDlg );
Canvas.pushDialog( toolsMessageBoxSaveChangesDlg );
}

View file

@ -51,7 +51,7 @@ function GE_OpenGUIFile()
// group. And, it should be the only thing in the group.
if( !isObject( %guiContent ) )
{
MessageBox( getEngineName(),
toolsMessageBox( getEngineName(),
"You have loaded a Gui file that was created before this version. It has been loaded but you must open it manually from the content list dropdown",
"Ok", "Information" );
GuiEditContent( Canvas.getContent() );

View file

@ -32,7 +32,7 @@ function GuiEdit( %val )
{
if (Canvas.isFullscreen())
{
MessageBoxOK("Windowed Mode Required", "Please switch to windowed mode to access the GUI Editor.");
toolsMessageBoxOK("Windowed Mode Required", "Please switch to windowed mode to access the GUI Editor.");
return;
}

View file

@ -283,7 +283,7 @@ function GuiEditCanvas::load( %this, %filename )
// group. And, it should be the only thing in the group.
if( !isObject( %guiContent ) )
{
MessageBox( getEngineName(),
toolsMessageBox( getEngineName(),
"You have loaded a Gui file that was created before this version. It has been loaded but you must open it manually from the content list dropdown",
"Ok", "Information" );
return 0;
@ -333,7 +333,7 @@ function GuiEditCanvas::save( %this, %selectedOnly, %noPrompt )
return;
else if( %selected.getCount() > 1 )
{
MessageBox( "Invalid selection", "Only a single control hierarchy can be saved to a file. Make sure you have selected only one control in the tree view." );
toolsMessageBox( "Invalid selection", "Only a single control hierarchy can be saved to a file. Make sure you have selected only one control in the tree view." );
return;
}
@ -464,7 +464,7 @@ function GuiEditCanvas::save( %this, %selectedOnly, %noPrompt )
GuiEditorStatusBar.print( "Saved file '" @ %currentObject.getFileName() @ "'" );
}
else
MessageBox( "Error writing to file", "There was an error writing to file '" @ %currentFile @ "'. The file may be read-only.", "Ok", "Error" );
toolsMessageBox( "Error writing to file", "There was an error writing to file '" @ %currentFile @ "'. The file may be read-only.", "Ok", "Error" );
}
//---------------------------------------------------------------------------------------------
@ -490,7 +490,7 @@ function GuiEditCanvas::append( %this )
if( !isObject( %guiContent ) )
{
MessageBox( "Error loading GUI file", "The GUI content controls could not be found. This function can only be used with files saved by the GUI editor.", "Ok", "Error" );
toolsMessageBox( "Error loading GUI file", "The GUI content controls could not be found. This function can only be used with files saved by the GUI editor.", "Ok", "Error" );
return;
}
@ -519,7 +519,7 @@ function GuiEditCanvas::revert( %this )
if( %filename $= "" )
return;
if( MessageBox( "Revert Gui", "Really revert the current Gui? This cannot be undone.", "OkCancel", "Question" ) == $MROk )
if( toolsMessageBox( "Revert Gui", "Really revert the current Gui? This cannot be undone.", "OkCancel", "Question" ) == $MROk )
%this.load( %filename );
}

View file

@ -30,11 +30,11 @@ if( !isDefined( "$GuiEditor::GuiFilterList" ) )
$GuiEditor::GuiFilterList =
"GuiEditorGui" TAB
"AL_ShadowVizOverlayCtrl" TAB
"MessageBoxOKDlg" TAB
"MessageBoxOKCancelDlg" TAB
"MessageBoxOKCancelDetailsDlg" TAB
"MessageBoxYesNoDlg" TAB
"MessageBoxYesNoCancelDlg" TAB
"toolsMessageBoxOKDlg" TAB
"toolsMessageBoxOKCancelDlg" TAB
"toolsMessageBoxOKCancelDetailsDlg" TAB
"toolsMessageBoxYesNoDlg" TAB
"toolsMessageBoxYesNoCancelDlg" TAB
"MessagePopupDlg";
}

View file

@ -81,7 +81,7 @@ function GuiEditorNewGuiDialog::onOK( %this )
if( isObject( %name ) && %name.isMemberOfClass( "GuiControl" ) )
{
if( MessageBox( "Warning", "Replace the existing control '" @ %name @ "'?", "OkCancel", "Question" ) == $MROk )
if( toolsMessageBox( "Warning", "Replace the existing control '" @ %name @ "'?", "OkCancel", "Question" ) == $MROk )
%name.delete();
else
return;

View file

@ -86,13 +86,13 @@ function GuiEditor::showDeleteProfileDialog( %this, %profile )
if( %profile.isInUse() )
{
MessageBoxOk( "Error",
toolsMessageBoxOk( "Error",
"The profile '" @ %profile.getName() @ "' is still used by Gui controls."
);
return;
}
MessageBoxYesNo( "Delete Profile?",
toolsMessageBoxYesNo( "Delete Profile?",
"Do you really want to delete '" @ %profile.getName() @ "'?",
"GuiEditor.deleteProfile( " @ %profile @ " );"
);

View file

@ -436,7 +436,7 @@ function MaterialEditorGui::setActiveMaterial( %this, %material )
// Warn if selecting a CustomMaterial (they can't be properly previewed or edited)
if ( isObject( %material ) && %material.isMemberOfClass( "CustomMaterial" ) )
{
MessageBoxOK( "Warning", "The selected Material (" @ %material.getName() @
toolsMessageBoxOK( "Warning", "The selected Material (" @ %material.getName() @
") is a CustomMaterial, and cannot be edited using the Material Editor." );
return;
}
@ -1794,7 +1794,7 @@ function MaterialEditorGui::addCubemap( %this,%cubemapName )
{
if( %cubemapName $= "" )
{
MessageBoxOK( "Error", "Can not create a cubemap without a valid name.");
toolsMessageBoxOK( "Error", "Can not create a cubemap without a valid name.");
return;
}
@ -1802,7 +1802,7 @@ function MaterialEditorGui::addCubemap( %this,%cubemapName )
{
if( %cubemapName $= RootGroup.getObject(%i).getName() )
{
MessageBoxOK( "Error", "There is already an object with the same name.");
toolsMessageBoxOK( "Error", "There is already an object with the same name.");
return;
}
}
@ -1884,7 +1884,7 @@ function MaterialEditorGui::showDeleteCubemapDialog(%this)
if( isObject( %cubemap ) )
{
MessageBoxYesNoCancel("Delete Cubemap?",
toolsMessageBoxYesNoCancel("Delete Cubemap?",
"Are you sure you want to delete<br><br>" @ %cubemap.getName() @ "<br><br> Cubemap deletion won't take affect until the engine is quit.",
"MaterialEditorGui.deleteCubemap( " @ %cubemap @ ", " @ %idx @ " );",
"",
@ -1926,7 +1926,7 @@ function matEd_cubemapEd_availableCubemapList::onSelect( %this, %id, %cubemap )
if( matEd_cubemapEditor.dirty )
{
%savedCubemap = MaterialEditorGui.currentCubemap;
MessageBoxYesNoCancel("Save Existing Cubemap?",
toolsMessageBoxYesNoCancel("Save Existing Cubemap?",
"Do you want to save changes to <br><br>" @ %savedCubemap.getName(),
"MaterialEditorGui.saveCubemap(" @ true @ ");",
"MaterialEditorGui.saveCubemapDialogDontSave(" @ %cubemap @ ");",
@ -1942,7 +1942,7 @@ function MaterialEditorGui::showSaveCubemapDialog( %this )
if( !isObject(%cubemap) )
return;
MessageBoxYesNoCancel("Save Cubemap?",
toolsMessageBoxYesNoCancel("Save Cubemap?",
"Do you want to save changes to <br><br>" @ %cubemap.getName(),
"MaterialEditorGui.saveCubemap( " @ %cubemap @ " );",
"",
@ -2070,7 +2070,7 @@ function MaterialEditorGui::copyCubemaps( %this, %copyFrom, %copyTo)
function MaterialEditorGui::showSaveDialog( %this, %toMaterial )
{
MessageBoxYesNoCancel("Save Material?",
toolsMessageBoxYesNoCancel("Save Material?",
"The material " @ MaterialEditorGui.currentMaterial.getName() @ " has unsaved changes. <br>Do you want to save?",
"MaterialEditorGui.saveDialogSave(" @ %toMaterial @ ");",
"MaterialEditorGui.saveDialogDontSave(" @ %toMaterial @ ");",
@ -2081,7 +2081,7 @@ function MaterialEditorGui::showMaterialChangeSaveDialog( %this, %toMaterial )
{
%fromMaterial = MaterialEditorGui.currentMaterial;
MessageBoxYesNoCancel("Save Material?",
toolsMessageBoxYesNoCancel("Save Material?",
"The material " @ %fromMaterial.getName() @ " has unsaved changes. <br>Do you want to save before changing the material?",
"MaterialEditorGui.saveDialogSave(" @ %toMaterial @ "); MaterialEditorGui.changeMaterial(" @ %fromMaterial @ ", " @ %toMaterial @ ");",
"MaterialEditorGui.saveDialogDontSave(" @ %toMaterial @ "); MaterialEditorGui.changeMaterial(" @ %fromMaterial @ ", " @ %toMaterial @ ");",
@ -2091,7 +2091,7 @@ function MaterialEditorGui::showMaterialChangeSaveDialog( %this, %toMaterial )
/*
function MaterialEditorGui::showCreateNewMaterialSaveDialog( %this, %toMaterial )
{
MessageBoxYesNoCancel("Save Material?",
toolsMessageBoxYesNoCancel("Save Material?",
"The material " @ MaterialEditorGui.currentMaterial.getName() @ " has unsaved changes. <br>Do you want to save before changing the material?",
"MaterialEditorGui.save(); MaterialEditorGui.createNewMaterial(" @ %toMaterial @ ");",
"MaterialEditorGui.saveDialogDontSave(" @ %toMaterial @ "); MaterialEditorGui.changeMaterial(" @ %toMaterial @ ");",
@ -2133,7 +2133,7 @@ function MaterialEditorGui::save( %this )
{
if( MaterialEditorGui.currentMaterial.getName() $= "" )
{
MessageBoxOK("Cannot perform operation", "Saved materials cannot be named \"\". A name must be given before operation is performed" );
toolsMessageBoxOK("Cannot perform operation", "Saved materials cannot be named \"\". A name must be given before operation is performed" );
return;
}
@ -2143,7 +2143,7 @@ function MaterialEditorGui::save( %this )
%currentMaterial = MaterialEditorGui.currentMaterial;
if( %currentMaterial == -1 )
{
MessageBoxOK("Cannot perform operation", "Could not locate material" );
toolsMessageBoxOK("Cannot perform operation", "Could not locate material" );
return;
}
@ -2348,7 +2348,7 @@ function MaterialEditorGui::lookupMaterialInstances( %this )
{
if( MaterialEditorGui.currentMaterial.getName() $= "" )
{
MessageBoxOK("Cannot perform operation", "Unable to look up a material with a blank name" );
toolsMessageBoxOK("Cannot perform operation", "Unable to look up a material with a blank name" );
return;
}

View file

@ -104,7 +104,7 @@ function MissionAreaEditorPlugin::setEditorFunction( %this )
%missionAreaExists = isObject(getMissionAreaServerObject());
if( %missionAreaExists == false )
MessageBoxYesNoCancel("No Mission Area","Would you like to create a New Mission Area?", "MissionAreaEditorPlugin.createNewMissionArea();");
toolsMessageBoxYesNoCancel("No Mission Area","Would you like to create a New Mission Area?", "MissionAreaEditorPlugin.createNewMissionArea();");
return %missionAreaExists;
}

View file

@ -346,7 +346,7 @@ function CreateNewNavMeshDlg::create(%this)
%name = %this-->MeshName.getText();
if(%name $= "" || nameToID(%name) != -1)
{
MessageBoxOk("Error", "A NavMesh must have a unique name!");
toolsMessageBoxOk("Error", "A NavMesh must have a unique name!");
return;
}
@ -356,7 +356,7 @@ function CreateNewNavMeshDlg::create(%this)
{
if(!isObject(getScene(0)))
{
MessageBoxOk("Error", "You must have a Scene to use the mission bounds function.");
toolsMessageBoxOk("Error", "You must have a Scene to use the mission bounds function.");
return;
}
// Get maximum extents of all objects.

View file

@ -132,7 +132,7 @@ function NavEditorPlugin::onActivated(%this)
if(!isObject(ServerNavMeshSet))
new SimSet(ServerNavMeshSet);
if(ServerNavMeshSet.getCount() == 0)
MessageBoxYesNo("No NavMesh", "There is no NavMesh in this level. Would you like to create one?" SPC
toolsMessageBoxYesNo("No NavMesh", "There is no NavMesh in this level. Would you like to create one?" SPC
"If not, please use the Nav Editor to create a new NavMesh.",
"Canvas.pushDialog(CreateNewNavMeshDlg);");
NavTreeView.open(ServerNavMeshSet, true);

View file

@ -122,7 +122,7 @@ function NavEditorGui::deleteSelected(%this)
case "SelectMode":
// Try to delete the selected NavMesh.
if(isObject(NavEditorGui.selectedObject))
MessageBoxYesNo("Warning",
toolsMessageBoxYesNo("Warning",
"Are you sure you want to delete" SPC NavEditorGui.selectedObject.getName(),
"NavEditorGui.deleteMesh();");
case "TestMode":
@ -277,7 +277,7 @@ function NavEditorGui::followObject(%this)
{
eval("%obj = " @ %text);
if(!isObject(%obj))
MessageBoxOk("Error", "Cannot find object" SPC %text);
toolsMessageBoxOk("Error", "Cannot find object" SPC %text);
}
if(isObject(%obj))
%this.getPlayer().followObject(%obj, NavEditorOptionsWindow-->TestProperties->FollowRadius.getText());

View file

@ -420,7 +420,7 @@ function PE_EmitterEditor::updateParticlesFields( %this )
if( %changedEditParticle && PE_ParticleEditor.dirty )
{
MessageBoxYesNoCancel("Save Particle Changes?",
toolsMessageBoxYesNoCancel("Save Particle Changes?",
"Do you wish to save the changes made to the <br>current particle before changing the particle?",
"PE_ParticleEditor.saveParticle( " @ PE_ParticleEditor.currParticle.getName() @ " ); PE_EmitterEditor.updateEmitter( \"particles\"," @ %particles @ ");",
"PE_ParticleEditor.saveParticleDialogDontSave( " @ PE_ParticleEditor.currParticle.getName() @ " ); PE_EmitterEditor.updateEmitter( \"particles\"," @ %particles @ ");",
@ -447,14 +447,14 @@ function PE_EmitterEditor::onNewEmitter( %this )
if( PE_ParticleEditor.dirty )
{
MessageBoxYesNo("Save Existing Particle?",
toolsMessageBoxYesNo("Save Existing Particle?",
"Do you want to save changes to <br><br>" @ PE_ParticleEditor.currParticle.getName(),
"PE_ParticleEditor.saveParticle(" @ PE_ParticleEditor.currParticle @ ");"
);
}
%savedEmitter = PE_EmitterEditor.currEmitter;
MessageBoxYesNoCancel("Save Existing Emitter?",
toolsMessageBoxYesNoCancel("Save Existing Emitter?",
"Do you want to save changes to <br><br>" @ %savedEmitter.getName(),
"PE_EmitterEditor.saveEmitter(" @ %savedEmitter@ "); PE_EmitterEditor.loadNewEmitter();",
"PE_EmitterEditor.saveEmitterDialogDontSave(" @ %savedEmitter @ "); PE_EmitterEditor.loadNewEmitter();"
@ -527,7 +527,7 @@ function PE_EmitterEditor::showNewDialog( %this )
if( PE_ParticleEditor.dirty )
{
MessageBoxYesNo("Save Existing Particle?",
toolsMessageBoxYesNo("Save Existing Particle?",
"Do you want to save changes to <br><br>" @ PE_ParticleEditor.currParticle.getName(),
"PE_ParticleEditor.saveParticle(" @ PE_ParticleEditor.currParticle @ ");"
);
@ -535,7 +535,7 @@ function PE_EmitterEditor::showNewDialog( %this )
if( PE_EmitterEditor.dirty )
{
MessageBoxYesNoCancel("Save Emitter Changes?",
toolsMessageBoxYesNoCancel("Save Emitter Changes?",
"Do you wish to save the changes made to the <br>current emitter before changing the emitter?",
"PE_EmitterEditor.saveEmitter( " @ PE_EmitterEditor.currEmitter.getName() @ " ); PE_EmitterEditor.createEmitter();",
"PE_EmitterEditor.saveEmitterDialogDontSave( " @ PE_EmitterEditor.currEmitter.getName() @ " ); PE_EmitterEditor.createEmitter();"
@ -579,13 +579,13 @@ function PE_EmitterEditor::showDeleteDialog( %this )
{
if( PE_EmitterEditor.currEmitter.getName() $= "DefaultEmitter" )
{
MessageBoxOK( "Error", "Cannot delete DefaultEmitter");
toolsMessageBoxOK( "Error", "Cannot delete DefaultEmitter");
return;
}
if( isObject( PE_EmitterEditor.currEmitter ) )
{
MessageBoxYesNoCancel("Delete Emitter?",
toolsMessageBoxYesNoCancel("Delete Emitter?",
"Are you sure you want to delete<br><br>" @ PE_EmitterEditor.currEmitter.getName() @ "<br><br> Emitter deletion won't take affect until the level is exited.",
"PE_EmitterEditor.saveEmitterDialogDontSave( " @ PE_EmitterEditor.currEmitter.getName() @ " ); PE_EmitterEditor.deleteEmitter();"
);

View file

@ -366,7 +366,7 @@ function PE_ParticleEditor::onNewParticle( %this )
// Load new particle if we're not in a dirty state
if( PE_ParticleEditor.dirty )
{
MessageBoxYesNoCancel("Save Existing Particle?",
toolsMessageBoxYesNoCancel("Save Existing Particle?",
"Do you want to save changes to <br><br>" @ PE_ParticleEditor.currParticle.getName(),
"PE_ParticleEditor.saveParticle(" @ PE_ParticleEditor.currParticle @ ");",
"PE_ParticleEditor.saveParticleDialogDontSave(" @ PE_ParticleEditor.currParticle @ "); PE_ParticleEditor.loadNewParticle();"
@ -430,7 +430,7 @@ function PE_ParticleEditor::showNewDialog( %this, %replaceSlot )
// Open a dialog if the current Particle is dirty
if( PE_ParticleEditor.dirty )
{
MessageBoxYesNoCancel("Save Particle Changes?",
toolsMessageBoxYesNoCancel("Save Particle Changes?",
"Do you wish to save the changes made to the <br>current particle before changing the particle?",
"PE_ParticleEditor.saveParticle( " @ PE_ParticleEditor.currParticle.getName() @ " ); PE_ParticleEditor.createParticle( " @ %replaceSlot @ " );",
"PE_ParticleEditor.saveParticleDialogDontSave( " @ PE_ParticleEditor.currParticle.getName() @ " ); PE_ParticleEditor.createParticle( " @ %replaceSlot @ " );"
@ -453,7 +453,7 @@ function PE_ParticleEditor::createParticle( %this, %replaceSlot )
%numExistingParticles = getWordCount( PE_EmitterEditor.currEmitter.particles );
if( %numExistingParticles > 3 )
{
MessageBoxOK( "Error", "An emitter cannot have more than 4 particles assigned to it." );
toolsMessageBoxOK( "Error", "An emitter cannot have more than 4 particles assigned to it." );
return;
}
@ -493,7 +493,7 @@ function PE_ParticleEditor::showDeleteDialog( %this )
if( PE_ParticleEditor.currParticle.getName() $= "DefaultParticle" )
{
MessageBoxOK( "Error", "Cannot delete DefaultParticle");
toolsMessageBoxOK( "Error", "Cannot delete DefaultParticle");
return;
}
@ -501,7 +501,7 @@ function PE_ParticleEditor::showDeleteDialog( %this )
if( getWordCount( PE_EmitterEditor.currEmitter.particles ) == 1 )
{
MessageBoxOK( "Error", "At least one particle must remain on the particle emitter.");
toolsMessageBoxOK( "Error", "At least one particle must remain on the particle emitter.");
return;
}
@ -509,7 +509,7 @@ function PE_ParticleEditor::showDeleteDialog( %this )
if( isObject( PE_ParticleEditor.currParticle ) )
{
MessageBoxYesNoCancel( "Delete Particle?",
toolsMessageBoxYesNoCancel( "Delete Particle?",
"Are you sure you want to delete<br><br>" @ PE_ParticleEditor.currParticle.getName() @ "<br><br> Particle deletion won't take affect until the engine is quit.",
"PE_ParticleEditor.saveParticleDialogDontSave( " @ PE_ParticleEditor.currParticle.getName() @ " ); PE_ParticleEditor.deleteParticle();",
"",

View file

@ -166,7 +166,7 @@ function RoadEditorPlugin::setEditorFunction( %this )
%terrainExists = parseMissionGroup( "TerrainBlock" );
if( %terrainExists == false )
MessageBoxYesNoCancel("No Terrain","Would you like to create a New Terrain?", "AssetBrowser.setupCreateNewAsset(\"TerrainAsset\", AssetBrowser.selectedModule, createTerrainBlock);");
toolsMessageBoxYesNoCancel("No Terrain","Would you like to create a New Terrain?", "AssetBrowser.setupCreateNewAsset(\"TerrainAsset\", AssetBrowser.selectedModule, createTerrainBlock);");
return %terrainExists;
}

View file

@ -62,7 +62,7 @@ function RoadEditorGui::onDeleteKey( %this )
}
else
{
MessageBoxOKCancel( "Notice", "Delete selected DecalRoad?", "RoadEditorGui.deleteRoad();", "" );
toolsMessageBoxOKCancel( "Notice", "Delete selected DecalRoad?", "RoadEditorGui.deleteRoad();", "" );
}
}

View file

@ -323,7 +323,7 @@ function ShapeEditorPlugin::openShape( %this, %path, %discardChangesToCurrent )
if( ShapeEditor.isDirty() && !%discardChangesToCurrent )
{
MessageBoxYesNo( "Save Changes?",
toolsMessageBoxYesNo( "Save Changes?",
"Save changes to current shape?",
"ShapeEditor.saveChanges(); ShapeEditorPlugin.openShape(\"" @ %path @ "\");",
"ShapeEditorPlugin.openShape(\"" @ %path @ "\");" );

View file

@ -265,7 +265,7 @@ function ShapeEdSelectWindow::onSelect( %this, %path )
if ( ShapeEditor.isDirty() )
{
%cmd = "showImportDialog( \"" @ %path @ "\", \"ShapeEditor.selectShape( \\\"" @ %path @ "\\\", ";
MessageBoxYesNoCancel( "Shape Modified", "Would you like to save your changes?", %cmd @ "true );\" );", %cmd @ "false );\" );" );
toolsMessageBoxYesNoCancel( "Shape Modified", "Would you like to save your changes?", %cmd @ "true );\" );", %cmd @ "false );\" );" );
}
else
{
@ -296,7 +296,7 @@ function ShapeEditor::selectShape( %this, %path, %saveOld )
// Initialise the shape preview window
if ( !ShapeEdShapeView.setModel( %path ) )
{
MessageBoxOK( "Error", "Failed to load '" @ %path @ "'. Check the console for error messages." );
toolsMessageBoxOK( "Error", "Failed to load '" @ %path @ "'. Check the console for error messages." );
return;
}
ShapeEdShapeView.fitToShape();
@ -1617,7 +1617,7 @@ function ShapeEdSequences::onEditBlend( %this )
%blendFrame = %this-->blendFrame.getText();
if ( ( %blendSeq $= "" ) || ( %blendFrame $= "" ) )
{
MessageBoxOK( "Blend reference not set", "The blend reference sequence and " @
toolsMessageBoxOK( "Blend reference not set", "The blend reference sequence and " @
"frame must be set before changing the blend flag or frame." );
ShapeEdSequences-->blendFlag.setStateOn( %oldBlend );
return;
@ -2231,7 +2231,7 @@ function ShapeEdSequences::onAddTrigger( %this )
%frame = mRound( ShapeEdSeqSlider.getValue() ) - %this-->startFrame.getText();
if ((%frame < 0) || (%frame > %this-->endFrame.getText() - %this-->startFrame.getText()))
{
MessageBoxOK( "Error", "Trigger out of range of the selected animation." );
toolsMessageBoxOK( "Error", "Trigger out of range of the selected animation." );
}
else
{
@ -3157,7 +3157,7 @@ function ShapeEdColWindow::editCollision( %this )
if ( ( ShapeEditor.shape.getDetailLevelIndex( -1 ) >= 0 ) &&
( getField(%this.lastColSettings, 0) $= "" ) )
{
MessageBoxYesNo( "Warning", "Existing collision geometry at detail size " @
toolsMessageBoxYesNo( "Warning", "Existing collision geometry at detail size " @
"-1 will be removed, and this cannot be undone. Do you want to continue?",
"ShapeEdColWindow.editCollisionOK();", "" );
}
@ -3366,7 +3366,7 @@ function ShapeEdMountWindow::mountShape( %this, %slot )
}
else
{
MessageBoxOK( "Error", "Failed to mount \"" @ %model @ "\". Check the console for error messages.", "" );
toolsMessageBoxOK( "Error", "Failed to mount \"" @ %model @ "\". Check the console for error messages.", "" );
}
}

View file

@ -95,7 +95,7 @@ function ShapeEditor::doAction( %this, %action )
}
else
{
MessageBoxOK( "Error", %action.actionName SPC "failed. Check the console for error messages.", "" );
toolsMessageBoxOK( "Error", %action.actionName SPC "failed. Check the console for error messages.", "" );
}
}
@ -108,7 +108,7 @@ function BaseShapeEdAction::redo( %this )
}
else
{
MessageBoxOK( "Error", "Redo" SPC %this.actionName SPC "failed. Check the console for error messages.", "" );
toolsMessageBoxOK( "Error", "Redo" SPC %this.actionName SPC "failed. Check the console for error messages.", "" );
}
}
@ -122,7 +122,7 @@ function BaseShapeEdAction::undo( %this )
function ShapeEditor::doRemoveShapeData( %this, %type, %name )
{
// Removing data from the shape cannot be undone => so warn the user first
MessageBoxYesNo( "Warning", "Deleting a " @ %type @ " cannot be undone. Do " @
toolsMessageBoxYesNo( "Warning", "Deleting a " @ %type @ " cannot be undone. Do " @
"you want to continue?", "ShapeEditor.doRemove" @ %type @ "( \"" @ %name @ "\" );", "" );
}

View file

@ -413,7 +413,7 @@ function ECameraSettingsPage::deleteCameraSettingsGroup( %this, %levelName, %rol
{
if( %levelName $= EditorGui.levelName )
{
MessageBoxOK("Error", "You may not delete the settings group associated with the currently loaded level");
toolsMessageBoxOK("Error", "You may not delete the settings group associated with the currently loaded level");
return;
}

View file

@ -238,7 +238,7 @@ function TerrainExportGui::export( %this )
%terrainObj = TerrainSelectListBox.getItemObject( %itemId );
if ( !isObject( %terrainObj ) )
{
MessageBoxOK( "Export failed", "Could not find the selected TerrainBlock!" );
toolsMessageBoxOK( "Export failed", "Could not find the selected TerrainBlock!" );
return;
}

View file

@ -620,7 +620,7 @@ function TerrainImportGui::import( %this )
}
else
{
MessageBox( "Import Terrain",
toolsMessageBox( "Import Terrain",
"Terrain import failed! Check console for error messages.",
"Ok", "Error" );
}

View file

@ -716,7 +716,7 @@ function ObjectBuilderGui::buildScatterSky( %this, %dontWarnAboutSun )
if( %object.isMemberOfClass( "Sun" ) )
{
MessageBoxYesNo( "Warning",
toolsMessageBoxYesNo( "Warning",
"A ScatterSky object will conflict with the Sun object that is already in the level." SPC
"Do you still want to create a ScatterSky object?",
%this @ ".buildScatterSky( true );" );
@ -812,7 +812,7 @@ function ObjectBuilderGui::buildSun( %this, %dontWarnAboutScatterSky )
if( %object.isMemberOfClass( "ScatterSky" ) )
{
MessageBoxYesNo( "Warning",
toolsMessageBoxYesNo( "Warning",
"A Sun object will conflict with the ScatterSky object that is already in the level." SPC
"Do you still want to create a Sun object?",
%this @ ".buildSun( true );" );

View file

@ -45,7 +45,7 @@ function AddFMODProjectDlg::show( %this )
if( getField( sfxGetDeviceInfo(), $SFX::DEVICE_INFO_PROVIDER ) !$= "FMOD" )
{
MessageBoxOK( "Error",
toolsMessageBoxOK( "Error",
"You do not currently have FMOD selected as your sound system." NL
"" NL
"To install FMOD, place the FMOD DLLs (" @ %fmodex @ " and " @ %fmodevent @ ")" SPC
@ -64,7 +64,7 @@ function AddFMODProjectDlg::show( %this )
%deviceCaps = getField( sfxGetDeviceInfo(), $SFX::DEVICE_INFO_CAPS );
if( !( %deviceCaps & $SFX::DEVICE_CAPS_FMODDESIGNER ) )
{
MessageBoxOK( "Error",
toolsMessageBoxOK( "Error",
"You do not have the requisite FMOD Event DLL in place." NL
"" NL
"Please copy " @ %fmodevent @ " into your game/ folder and restart Torque."
@ -114,14 +114,14 @@ function AddFMODProjectDlg::onOK( %this )
if( %fileName $= "" )
{
MessageBoxOK( "Error",
toolsMessageBoxOK( "Error",
"Please enter a project file name."
);
return;
}
if( !isFile( %fileName ) )
{
MessageBoxOK( "Error",
toolsMessageBoxOK( "Error",
"'" @ %fileName @ "' is not a valid file."
);
return;
@ -131,7 +131,7 @@ function AddFMODProjectDlg::onOK( %this )
if( !isDirectory( %mediaPath ) )
{
MessageBoxOK( "Error",
toolsMessageBoxOK( "Error",
"'" @ %mediaPath @ "' is not a valid directory."
);
return;
@ -155,7 +155,7 @@ function AddFMODProjectDlg::onOK( %this )
if( !isObject( %objName ) )
{
MessageBoxOK( "Error",
toolsMessageBoxOK( "Error",
"Failed to create the object. Please take a look at the log for details."
);
return;

View file

@ -2088,7 +2088,7 @@ function EWorldEditor::addSimGroup( %this, %groupCurrentSelection )
%activeSelection = %this.getActiveSelection();
if ( %activeSelection.getObjectIndex( getScene(0) ) != -1 )
{
MessageBoxOK( "Error", "Cannot add Scene to a new SimGroup" );
toolsMessageBoxOK( "Error", "Cannot add Scene to a new SimGroup" );
return;
}

View file

@ -84,7 +84,7 @@ function EManageSFXParameters::createNewParameter( %this, %name )
function EManageSFXParameters::showDeleteParameterDlg( %this, %parameter )
{
MessageBoxOkCancel( "Confirmation",
toolsMessageBoxOkCancel( "Confirmation",
"Really delete '" @ %parameter.getInternalName() @ "'?" NL
"" NL
"The parameter will be removed from the file '" @ %parameter.getFileName() @ "'.",

View file

@ -133,7 +133,7 @@ function ESelectObjectsWindow::onSelectObjects( %this, %val, %reuseExistingSet )
{
if( !%name.isMemberOfClass( "WorldEditorSelection" ) )
{
MessageBoxOk( "Error",
toolsMessageBoxOk( "Error",
"An object called '" @ %name @ "' already exists and is not a selection." NL
"" NL
"Please choose a different name." );
@ -141,7 +141,7 @@ function ESelectObjectsWindow::onSelectObjects( %this, %val, %reuseExistingSet )
}
else if( !%reuseExistingSet )
{
MessageBoxYesNo( "Question",
toolsMessageBoxYesNo( "Question",
"A selection called '" @ %name @ "' already exists. Modify the existing selection?",
%this @ ".onSelectObjects( " @ %val @ ", true );" );
return;
@ -159,7 +159,7 @@ function ESelectObjectsWindow::onSelectObjects( %this, %val, %reuseExistingSet )
eval( "%sel = new WorldEditorSelection( " @ %name @ " ) { parentGroup = Selections; canSave = true; };" );
if( !isObject( %sel ) )
{
MessageBoxOk( "Error",
toolsMessageBoxOk( "Error",
"Could not create the selection set. Please look at the console.log for details." );
return;
}

View file

@ -338,7 +338,7 @@ function EManageBookmarksTextEdit::onValidate( %this )
{
%id = %this.getId();
%callback = %id @ ".setText(\"" @ %oldname @ "\"); " @ %id @ ".makeFirstResponder(true); " @ %id @ ".selectAllText();";
MessageBoxOK("Create Bookmark", "You must provide a unique name for the new bookmark.", %callback);
toolsMessageBoxOK("Create Bookmark", "You must provide a unique name for the new bookmark.", %callback);
return;
}

View file

@ -189,7 +189,7 @@ function EPainter::updateLayers( %this, %matIndex )
function EPainter::showMaterialDeleteDlg( %this, %matInternalName )
{
MessageBoxYesNo( "Confirmation",
toolsMessageBoxYesNo( "Confirmation",
"Really remove material '" @ %matInternalName @ "' from the terrain?",
%this @ ".removeMaterial( " @ %matInternalName @ " );", "" );
}
@ -389,7 +389,7 @@ function TerrainEditorPlugin::setEditorFunction(%this)
%terrainExists = parseMissionGroup( "TerrainBlock" );
if( %terrainExists == false )
MessageBoxYesNoCancel("No Terrain","Would you like to create a New Terrain? No to Select Existing Terrain Block Asset",
toolsMessageBoxYesNoCancel("No Terrain","Would you like to create a New Terrain? No to Select Existing Terrain Block Asset",
"AssetBrowser.setupCreateNewAsset(\"TerrainAsset\", AssetBrowser.selectedModule, createTerrainBlock);",
"AssetBrowser.showDialog(\"TerrainAsset\", createTerrainBlock, \"\", \"\", \"\");");
@ -401,7 +401,7 @@ function TerrainPainterPlugin::setEditorFunction(%this, %overrideGroup)
%terrainExists = parseMissionGroup( "TerrainBlock" );
if( %terrainExists == false )
MessageBoxYesNoCancel("No Terrain","Would you like to create a New Terrain? No to Select Existing Terrain Block Asset",
toolsMessageBoxYesNoCancel("No Terrain","Would you like to create a New Terrain? No to Select Existing Terrain Block Asset",
"AssetBrowser.setupCreateNewAsset(\"TerrainAsset\", AssetBrowser.selectedModule, createTerrainBlock);",
"AssetBrowser.showDialog(\"TerrainAsset\", createTerrainBlock, \"\", \"\", \"\");");

View file

@ -206,7 +206,7 @@ function TerrainMaterialDlg::setMaterialName( %this, %newName )
%existingMat = TerrainMaterialSet.findObjectByInternalName( %newName );
if( isObject( %existingMat ) )
{
MessageBoxOK( "Error",
toolsMessageBoxOK( "Error",
"There already is a terrain material called '" @ %newName @ "'.", "", "" );
}
else
@ -366,7 +366,7 @@ function TerrainMaterialDlg::deleteMat( %this )
if ( ( ETerrainEditor.getMaterialCount() == 1 ) &&
( ETerrainEditor.getMaterialIndex( %this.activeMat.internalName ) != -1 ) )
{
MessageBoxOK( "Error", "Cannot delete this Material, it is the only " @
toolsMessageBoxOK( "Error", "Cannot delete this Material, it is the only " @
"Material still in use by the active Terrain." );
return;
}
@ -543,7 +543,7 @@ function TerrainMaterialDlg::saveDirtyMaterial( %this, %mat )
%existingMat = TerrainMaterialSet.findObjectByInternalName( %newName );
if( isObject( %existingMat ) )
{
MessageBoxOK( "Error",
toolsMessageBoxOK( "Error",
"There already is a terrain material called '" @ %newName @ "'.", "", "" );
// Reset the name edit control to the old name.

View file

@ -88,7 +88,7 @@ function EditorQuitGame()
{
if( EditorIsDirty())
{
MessageBoxYesNoCancel("Level Modified", "Would you like to save your changes before quitting?", "EditorSaveMissionMenu(); quit();", "quit();", "" );
toolsMessageBoxYesNoCancel("Level Modified", "Would you like to save your changes before quitting?", "EditorSaveMissionMenu(); quit();", "quit();", "" );
}
else
quit();
@ -98,7 +98,7 @@ function EditorExitMission()
{
if( EditorIsDirty())
{
MessageBoxYesNoCancel("Level Modified", "Would you like to save your changes before exiting?", "EditorDoExitMission(true);", "EditorDoExitMission(false);", "");
toolsMessageBoxYesNoCancel("Level Modified", "Would you like to save your changes before exiting?", "EditorDoExitMission(true);", "EditorDoExitMission(false);", "");
}
else
EditorDoExitMission(false);
@ -129,7 +129,7 @@ function EditorOpenTorsionProject( %projectFile )
%torsionPath = EditorSettings.value( "WorldEditor/torsionPath" );
if( !isFile( %torsionPath ) )
{
MessageBoxOK(
toolsMessageBoxOK(
"Torsion Not Found",
"Torsion not found at '" @ %torsionPath @ "'. Please set the correct path in the Editor Settings."
);
@ -147,7 +147,7 @@ function EditorOpenTorsionProject( %projectFile )
%projectFile = findFirstFile( "*.torsion", false );
if( !isFile( %projectFile ) )
{
MessageBoxOK(
toolsMessageBoxOK(
"Project File Not Found",
"Cannot find .torsion project file in '" @ getMainDotCsDir() @ "'."
);
@ -168,7 +168,7 @@ function EditorOpenFileInTorsion( %file, %line )
%torsionPath = EditorSettings.value( "WorldEditor/torsionPath" );
if( !isFile( %torsionPath ) )
{
MessageBoxOK(
toolsMessageBoxOK(
"Torsion Not Found",
"Torsion not found at '" @ %torsionPath @ "'. Please set the correct path in the Editor Settings."
);
@ -205,7 +205,7 @@ function EditorNewLevel( %file )
if ( EditorIsDirty() )
{
error(knob);
%saveFirst = MessageBox("Mission Modified", "Would you like to save changes to the current mission \"" @
%saveFirst = toolsMessageBox("Mission Modified", "Would you like to save changes to the current mission \"" @
$Server::MissionFile @ "\" before creating a new mission?", "SaveDontSave", "Question") == $MROk;
}
@ -239,7 +239,7 @@ function EditorNewLevel( %file )
function EditorSaveAsDefaultLevel()
{
MessageBoxYesNo("Save as Default?", "This will save the currently active root scene as the default level the editor loads when it is opened. Continue?",
toolsMessageBoxYesNo("Save as Default?", "This will save the currently active root scene as the default level the editor loads when it is opened. Continue?",
"doEditorSaveAsDefaultLevel();", "");
}
@ -250,7 +250,7 @@ function doEditorSaveAsDefaultLevel()
function EditorResetDefaultLevel()
{
MessageBoxYesNo("Reset Default?", "This will reset the default level for the editor back to the original. Continue?",
toolsMessageBoxYesNo("Reset Default?", "This will reset the default level for the editor back to the original. Continue?",
"doEditorResetDefaultLevel();", "");
}
@ -279,7 +279,7 @@ function EditorSaveMission()
// first check for dirty and read-only files:
if((EWorldEditor.isDirty || ETerrainEditor.isMissionDirty) && !isWriteableFileName($Server::MissionFile))
{
MessageBox("Error", "Mission file \""@ $Server::MissionFile @ "\" is read-only. Continue?", "Ok", "Stop");
toolsMessageBox("Error", "Mission file \""@ $Server::MissionFile @ "\" is read-only. Continue?", "Ok", "Stop");
return false;
}
if(ETerrainEditor.isDirty)
@ -291,7 +291,7 @@ function EditorSaveMission()
{
if (!isWriteableFileName(%terrainObject.terrainFile))
{
if (MessageBox("Error", "Terrain file \""@ %terrainObject.terrainFile @ "\" is read-only. Continue?", "Ok", "Stop") == $MROk)
if (toolsMessageBox("Error", "Terrain file \""@ %terrainObject.terrainFile @ "\" is read-only. Continue?", "Ok", "Stop") == $MROk)
continue;
else
return false;
@ -370,7 +370,7 @@ function EditorOpenMission(%levelAsset)
if( EditorIsDirty())
{
// "EditorSaveBeforeLoad();", "getLoadFilename(\"*.mis\", \"EditorDoLoadMission\");"
if(MessageBox("Mission Modified", "Would you like to save changes to the current mission \"" @
if(toolsMessageBox("Mission Modified", "Would you like to save changes to the current mission \"" @
$Server::MissionFile @ "\" before opening a new mission?", SaveDontSave, Question) == $MROk)
{
if(! EditorSaveMission())