Merge remote-tracking branch 'refs/remotes/GarageGames/development' into ColorPickerAdvanced
|
|
@ -132,7 +132,7 @@ function MenuBuilder::addItem(%this, %pos, %item)
|
|||
}
|
||||
else
|
||||
{
|
||||
%this.insertItem(%pos, %name !$= "-" ? %name : "", %accel);
|
||||
%this.insertItem(%pos, %name !$= "-" ? %name : "", %accel, %cmd);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
Before Width: | Height: | Size: 502 B After Width: | Height: | Size: 502 B |
|
Before Width: | Height: | Size: 526 B After Width: | Height: | Size: 526 B |
|
Before Width: | Height: | Size: 526 B After Width: | Height: | Size: 526 B |
|
Before Width: | Height: | Size: 652 B After Width: | Height: | Size: 652 B |
|
Before Width: | Height: | Size: 374 B After Width: | Height: | Size: 374 B |
|
Before Width: | Height: | Size: 514 B After Width: | Height: | Size: 514 B |
|
Before Width: | Height: | Size: 800 B After Width: | Height: | Size: 800 B |
|
Before Width: | Height: | Size: 710 B After Width: | Height: | Size: 710 B |
|
Before Width: | Height: | Size: 368 B After Width: | Height: | Size: 368 B |
|
Before Width: | Height: | Size: 132 B After Width: | Height: | Size: 132 B |
|
Before Width: | Height: | Size: 233 B After Width: | Height: | Size: 233 B |
|
Before Width: | Height: | Size: 596 B After Width: | Height: | Size: 596 B |
|
Before Width: | Height: | Size: 505 B After Width: | Height: | Size: 538 B |
|
Before Width: | Height: | Size: 766 B After Width: | Height: | Size: 766 B |
|
Before Width: | Height: | Size: 744 B After Width: | Height: | Size: 744 B |
|
Before Width: | Height: | Size: 470 B After Width: | Height: | Size: 470 B |
|
Before Width: | Height: | Size: 169 B After Width: | Height: | Size: 169 B |
|
Before Width: | Height: | Size: 430 B After Width: | Height: | Size: 430 B |
|
Before Width: | Height: | Size: 591 B After Width: | Height: | Size: 591 B |
|
Before Width: | Height: | Size: 773 B After Width: | Height: | Size: 773 B |
|
Before Width: | Height: | Size: 426 B After Width: | Height: | Size: 426 B |
|
Before Width: | Height: | Size: 323 B After Width: | Height: | Size: 323 B |
|
Before Width: | Height: | Size: 464 B After Width: | Height: | Size: 464 B |
|
Before Width: | Height: | Size: 480 B After Width: | Height: | Size: 480 B |
|
Before Width: | Height: | Size: 503 B After Width: | Height: | Size: 503 B |
|
Before Width: | Height: | Size: 390 B After Width: | Height: | Size: 390 B |
|
Before Width: | Height: | Size: 381 B After Width: | Height: | Size: 381 B |
|
Before Width: | Height: | Size: 688 B After Width: | Height: | Size: 688 B |
|
Before Width: | Height: | Size: 789 B After Width: | Height: | Size: 789 B |
|
Before Width: | Height: | Size: 368 B After Width: | Height: | Size: 368 B |
|
Before Width: | Height: | Size: 624 B After Width: | Height: | Size: 624 B |
|
Before Width: | Height: | Size: 369 B After Width: | Height: | Size: 369 B |
|
Before Width: | Height: | Size: 358 B After Width: | Height: | Size: 358 B |
|
Before Width: | Height: | Size: 236 B After Width: | Height: | Size: 236 B |
|
Before Width: | Height: | Size: 749 B After Width: | Height: | Size: 749 B |
|
Before Width: | Height: | Size: 748 B After Width: | Height: | Size: 748 B |
|
Before Width: | Height: | Size: 732 B After Width: | Height: | Size: 732 B |
|
Before Width: | Height: | Size: 419 B After Width: | Height: | Size: 419 B |
|
Before Width: | Height: | Size: 767 B After Width: | Height: | Size: 767 B |
|
Before Width: | Height: | Size: 607 B After Width: | Height: | Size: 607 B |
|
Before Width: | Height: | Size: 744 B After Width: | Height: | Size: 744 B |
|
Before Width: | Height: | Size: 513 B After Width: | Height: | Size: 513 B |
BIN
Templates/Full/game/tools/classIcons/VolumetricFog.png
Normal file
|
After Width: | Height: | Size: 3.6 KiB |
|
Before Width: | Height: | Size: 543 B After Width: | Height: | Size: 543 B |
|
Before Width: | Height: | Size: 787 B After Width: | Height: | Size: 787 B |
|
Before Width: | Height: | Size: 406 B After Width: | Height: | Size: 406 B |
|
Before Width: | Height: | Size: 560 B After Width: | Height: | Size: 560 B |
|
|
@ -33,15 +33,15 @@ function initializeDebugger()
|
|||
echo(" % - Initializing Debugger");
|
||||
|
||||
// Load the scripts.
|
||||
exec("./Scripts/debugger.ed.cs");
|
||||
exec("./scripts/debugger.ed.cs");
|
||||
|
||||
// And the guis.
|
||||
exec("./Gui/breakConditionDlg.ed.gui");
|
||||
exec("./Gui/connectDlg.ed.gui");
|
||||
exec("./Gui/editWatchDlg.ed.gui");
|
||||
exec("./Gui/findDlg.ed.gui");
|
||||
exec("./Gui/debugger.ed.gui");
|
||||
exec("./Gui/watchDlg.ed.gui");
|
||||
exec("./gui/breakConditionDlg.ed.gui");
|
||||
exec("./gui/connectDlg.ed.gui");
|
||||
exec("./gui/editWatchDlg.ed.gui");
|
||||
exec("./gui/findDlg.ed.gui");
|
||||
exec("./gui/debugger.ed.gui");
|
||||
exec("./gui/watchDlg.ed.gui");
|
||||
}
|
||||
|
||||
function destroyDebugger()
|
||||
|
|
@ -64,5 +64,5 @@ function startDebugger()
|
|||
|
||||
// Set up the GUI.
|
||||
DebuggerConsoleView.setActive(false);
|
||||
Canvas.pushDialog(DebuggerGui);
|
||||
$GameCanvas.pushDialog(DebuggerGui);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -36,6 +36,3 @@ exec("./guiObjectInspector.ed.cs");
|
|||
exec("./uvEditor.ed.gui");
|
||||
exec("./objectSelection.ed.cs");
|
||||
exec("./guiPlatformGenericMenubar.ed.cs");
|
||||
|
||||
if (isDemo())
|
||||
exec("./messageBoxOKBuy.ed.gui");
|
||||
|
|
|
|||
|
|
@ -5,8 +5,8 @@
|
|||
new GuiPlatformGenericMenuBar()
|
||||
{
|
||||
internalName = "menubar";
|
||||
extent = "1024 32";
|
||||
minExtent = "320 32";
|
||||
extent = "1024 20";
|
||||
minExtent = "320 20";
|
||||
horizSizing = "width";
|
||||
profile = "GuiMenuBarProfile";
|
||||
};
|
||||
|
|
|
|||
|
|
@ -1,85 +0,0 @@
|
|||
//--- OBJECT WRITE BEGIN ---
|
||||
%guiContent = new GuiControl(MessageBoxOKBuyDlg) {
|
||||
profile = "ToolsGuiDefaultProfile";
|
||||
horizSizing = "width";
|
||||
vertSizing = "height";
|
||||
position = "0 0";
|
||||
extent = "640 480";
|
||||
minExtent = "8 8";
|
||||
visible = "1";
|
||||
helpTag = "0";
|
||||
|
||||
new GuiWindowCtrl(MBOKBuyFrame) {
|
||||
profile = "ToolsGuiWindowProfile";
|
||||
horizSizing = "center";
|
||||
vertSizing = "center";
|
||||
position = "170 175";
|
||||
extent = "300 100";
|
||||
minExtent = "48 92";
|
||||
visible = "1";
|
||||
helpTag = "0";
|
||||
maxLength = "255";
|
||||
resizeWidth = "1";
|
||||
resizeHeight = "1";
|
||||
canMove = "1";
|
||||
canClose = "1";
|
||||
canMinimize = "0";
|
||||
canMaximize = "0";
|
||||
minSize = "50 50";
|
||||
text = "";
|
||||
closeCommand = "MessageCallback(MessageBoxOKBuyDlg,MessageBoxOKBuyDlg.noCallback);";
|
||||
|
||||
new GuiMLTextCtrl(MBOKBuyText) {
|
||||
profile = "ToolsGuiMLTextProfile";
|
||||
horizSizing = "center";
|
||||
vertSizing = "bottom";
|
||||
position = "11 38";
|
||||
extent = "280 14";
|
||||
minExtent = "8 8";
|
||||
visible = "1";
|
||||
helpTag = "0";
|
||||
lineSpacing = "2";
|
||||
allowColorChars = "0";
|
||||
maxChars = "-1";
|
||||
};
|
||||
new GuiButtonCtrl() {
|
||||
profile = "ToolsGuiButtonProfile";
|
||||
horizSizing = "right";
|
||||
vertSizing = "top";
|
||||
position = "70 68";
|
||||
extent = "80 22";
|
||||
minExtent = "8 8";
|
||||
visible = "1";
|
||||
command = "MessageCallback(MessageBoxOKBuyDlg,MessageBoxOKBuyDlg.OKCallback);";
|
||||
accelerator = "return";
|
||||
helpTag = "0";
|
||||
text = "OK";
|
||||
simpleStyle = "0";
|
||||
};
|
||||
new GuiButtonCtrl() {
|
||||
profile = "ToolsGuiButtonProfile";
|
||||
horizSizing = "right";
|
||||
vertSizing = "top";
|
||||
position = "167 68";
|
||||
extent = "80 22";
|
||||
minExtent = "8 8";
|
||||
visible = "1";
|
||||
command = "MessageCallback(MessageBoxOKBuyDlg,MessageBoxOKBuyDlg.BuyCallback);";
|
||||
accelerator = "escape";
|
||||
helpTag = "0";
|
||||
text = "Buy Now!";
|
||||
simpleStyle = "0";
|
||||
};
|
||||
};
|
||||
};
|
||||
//--- OBJECT WRITE END ---
|
||||
|
||||
function MessageBoxOKBuy(%title, %message, %OKCallback, %BuyCallback)
|
||||
{
|
||||
MBOKBuyFrame.text = %title;
|
||||
MessageBoxOKBuyDlg.profile = "ToolsGuiOverlayProfile";
|
||||
Canvas.pushDialog(MessageBoxOKBuyDlg);
|
||||
MBSetText(MBOKBuyText, MBOKBuyFrame, %message);
|
||||
MessageBoxOKBuyDlg.OKCallback = %OKCallback;
|
||||
MessageBoxOKBuyDlg.BuyCallback = %BuyCallback;
|
||||
}
|
||||
|
|
@ -1067,8 +1067,10 @@ singleton GuiControlProfile( GuiCreatorIconButtonProfile )
|
|||
singleton GuiControlProfile( GuiMenuBarProfile )
|
||||
{
|
||||
fillcolor = "255 255 255";
|
||||
borderColor = "0 0 0";
|
||||
border = 1;
|
||||
fillcolorHL = "213 231 248";
|
||||
borderColor = "98 163 229";
|
||||
borderColorHL = "122 177 232";
|
||||
border = 0;
|
||||
borderThickness = 1;
|
||||
opaque = true;
|
||||
mouseOverSelected = true;
|
||||
|
|
|
|||
|
|
@ -131,12 +131,6 @@ package Tools
|
|||
Tools::LoadResources( $Tools::resourcePath );
|
||||
|
||||
//$Scripts::ignoreDSOs = %toggle;
|
||||
|
||||
if(isWebDemo())
|
||||
{
|
||||
// if this is the web tool demo lets init some value storage
|
||||
//$clicks
|
||||
}
|
||||
}
|
||||
|
||||
function startToolTime(%tool)
|
||||
|
|
|
|||
|
|
@ -3309,7 +3309,7 @@
|
|||
HorizSizing = "width";
|
||||
VertSizing = "bottom";
|
||||
Position = "0 0";
|
||||
Extent = "210 71";
|
||||
Extent = "210 89";
|
||||
|
||||
new GuiPopUpMenuCtrl() {
|
||||
internalName = "blendingTypePopUp";
|
||||
|
|
@ -3480,7 +3480,7 @@
|
|||
Visible = "1";
|
||||
Command = "MaterialEditorGui.updateActiveMaterial(\"castShadows\", $ThisControl.getValue());";
|
||||
tooltipprofile = "ToolsGuiDefaultProfile";
|
||||
ToolTip = "Alows object to cast shadows.";
|
||||
ToolTip = "Object casts shadows.";
|
||||
hovertime = "1000";
|
||||
text = "Cast Shadows";
|
||||
groupNum = "-1";
|
||||
|
|
@ -3488,6 +3488,29 @@
|
|||
useMouseEvents = "0";
|
||||
useInactiveState = "0";
|
||||
};
|
||||
new GuiCheckBoxCtrl() {
|
||||
canSaveDynamicFields = "0";
|
||||
internalName = "castDynamicShadows";
|
||||
Enabled = "1";
|
||||
isContainer = "0";
|
||||
Profile = "ToolsGuiCheckBoxProfile";
|
||||
HorizSizing = "right";
|
||||
VertSizing = "bottom";
|
||||
position = "3 70";
|
||||
Extent = "112 16";
|
||||
MinExtent = "8 2";
|
||||
canSave = "1";
|
||||
Visible = "1";
|
||||
Command = "MaterialEditorGui.updateActiveMaterial(\"castDynamicShadows\", $ThisControl.getValue());";
|
||||
tooltipprofile = "ToolsGuiDefaultProfile";
|
||||
ToolTip = "Object casts dynamic shadows.";
|
||||
hovertime = "1000";
|
||||
text = "Dynamic Shadows";
|
||||
groupNum = "-1";
|
||||
buttonType = "ToggleButton";
|
||||
useMouseEvents = "0";
|
||||
useInactiveState = "0";
|
||||
};
|
||||
new GuiCheckBoxCtrl() {
|
||||
canSaveDynamicFields = "0";
|
||||
internalName = "doubleSidedCheckBox";
|
||||
|
|
|
|||
|
|
@ -754,6 +754,7 @@ function MaterialEditorGui::guiSync( %this, %material )
|
|||
MaterialEditorPropertiesWindow-->transZWriteCheckBox.setValue((%material).translucentZWrite);
|
||||
MaterialEditorPropertiesWindow-->alphaTestCheckBox.setValue((%material).alphaTest);
|
||||
MaterialEditorPropertiesWindow-->castShadows.setValue((%material).castShadows);
|
||||
MaterialEditorPropertiesWindow-->castDynamicShadows.setValue((%material).castDynamicShadows);
|
||||
MaterialEditorPropertiesWindow-->translucentCheckbox.setValue((%material).translucent);
|
||||
|
||||
switch$((%material).translucentBlendOp)
|
||||
|
|
|
|||
|
|
@ -99,6 +99,27 @@ function MissionAreaEditorPlugin::onDeactivated( %this )
|
|||
Parent::onDeactivated(%this);
|
||||
}
|
||||
|
||||
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();");
|
||||
|
||||
return %missionAreaExists;
|
||||
}
|
||||
|
||||
function MissionAreaEditorPlugin::createNewMissionArea(%this)
|
||||
{
|
||||
%newMissionArea = new MissionArea();
|
||||
%newMissionArea.area = "-256 -256 512 512";
|
||||
|
||||
MissionGroup.add(%newMissionArea);
|
||||
|
||||
EditorGui.setEditor(MissionAreaEditorPlugin);
|
||||
|
||||
EWorldEditor.isDirty = true;
|
||||
}
|
||||
//-----------------------------------------------------------------------------
|
||||
// Settings
|
||||
//-----------------------------------------------------------------------------
|
||||
|
|
|
|||
|
|
@ -25,11 +25,14 @@ function MissionAreaEditorGui::onEditorActivated( %this )
|
|||
EWorldEditor.clearSelection();
|
||||
|
||||
%ma = getMissionAreaServerObject();
|
||||
EWorldEditor.selectObject( %ma );
|
||||
EWorldEditor.syncGui();
|
||||
MissionAreaEditorTerrainEditor.updateTerrain();
|
||||
%this.setSelectedMissionArea( %ma );
|
||||
%this.onMissionAreaSelected( %this.getSelectedMissionArea() );
|
||||
if( isObject( %ma ) )
|
||||
{
|
||||
EWorldEditor.selectObject( %ma );
|
||||
EWorldEditor.syncGui();
|
||||
MissionAreaEditorTerrainEditor.updateTerrain();
|
||||
%this.setSelectedMissionArea( %ma );
|
||||
%this.onMissionAreaSelected( %this.getSelectedMissionArea() );
|
||||
}
|
||||
}
|
||||
|
||||
function MissionAreaEditorGui::onEditorDeactivated( %this )
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ function initializeNavEditor()
|
|||
echo(" % - Initializing Navigation Editor");
|
||||
|
||||
// Execute all relevant scripts and GUIs.
|
||||
exec("./NavEditor.cs");
|
||||
exec("./navEditor.cs");
|
||||
exec("./NavEditorGui.gui");
|
||||
exec("./NavEditorToolbar.gui");
|
||||
exec("./NavEditorConsoleDlg.gui");
|
||||
|
|
@ -272,20 +272,3 @@ function ESettingsWindowPopup::onSelect(%this)
|
|||
EditorSettings.setValue(%this.editorSettingsValue, %this.getText());
|
||||
eval(%this.editorSettingsRead);
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Demo
|
||||
//-----------------------------------------------------------------------------
|
||||
|
||||
function OnWalkaboutDemoLimit()
|
||||
{
|
||||
MessageBoxOK("Walkabout demo",
|
||||
"This demo only allows two NavMeshes to be created. Sorry!");
|
||||
}
|
||||
|
||||
function OnWalkaboutDemoSave()
|
||||
{
|
||||
MessageBoxOK("Walkabout demo",
|
||||
"This demo doesn't allow you to save NavMeshes. Sorry!" SPC
|
||||
"The rest of your mission will still be saved.");
|
||||
}
|
||||
|
|
|
|||
|
|
@ -980,7 +980,19 @@ function ObjectBuilderGui::buildObserverDropPoint(%this)
|
|||
//------------------------------------------------------------------------------
|
||||
// System
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
function ObjectBuilderGui::buildVolumetricFog(%this)
|
||||
{
|
||||
// Change this if you want to default to another Folder
|
||||
// Otherwise every time you want to add a Fog you will go this.
|
||||
%defShape = "/art/environment/Fog_Cube.dts";
|
||||
%this.lastPath=getMainDotCsDir() @ %defShape;
|
||||
OBObjectName.setValue( "" );
|
||||
%this.objectClassName = "VolumetricFog";
|
||||
%this.addField( "shapeName", "TypeFile", "Shape (Fog volume)", "", "*.dts;*.dae");
|
||||
%this.addField("Scale", "TypePoint3", "Scale", "1 1 1");
|
||||
%this.addField("FogColor", "TypeColorI", "FogColor", "200 200 200 255");
|
||||
%this.process();
|
||||
}
|
||||
function ObjectBuilderGui::buildPhysicsEntity(%this)
|
||||
{
|
||||
%this.objectClassName = "PhysicsEntity";
|
||||
|
|
@ -1131,3 +1143,14 @@ function ProximityMineData::create( %datablock )
|
|||
|
||||
return %obj;
|
||||
}
|
||||
|
||||
function RibbonData::create( %datablock )
|
||||
{
|
||||
%obj = new RibbonNode()
|
||||
{
|
||||
dataBlock = DefaultRibbonNodeData;
|
||||
ribbon = %datablock;
|
||||
};
|
||||
|
||||
return %obj;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -114,11 +114,14 @@ function initializeWorldEditor()
|
|||
EVisibility.addOption( "Debug Render: Decals", "$Decals::debugRender", "" );
|
||||
EVisibility.addOption( "Debug Render: Light Frustums", "$Light::renderLightFrustums", "" );
|
||||
EVisibility.addOption( "Debug Render: Bounding Boxes", "$Scene::renderBoundingBoxes", "" );
|
||||
EVisibility.addOption( "Debug Render: Physics World", "$PhysicsWorld::render", "togglePhysicsDebugViz" );
|
||||
EVisibility.addOption( "AL: Disable Shadows", "$Shadows::disable", "" );
|
||||
EVisibility.addOption( "AL: Light Color Viz", "$AL_LightColorVisualizeVar", "toggleLightColorViz" );
|
||||
EVisibility.addOption( "AL: Light Specular Viz", "$AL_LightSpecularVisualizeVar", "toggleLightSpecularViz" );
|
||||
EVisibility.addOption( "AL: Normals Viz", "$AL_NormalsVisualizeVar", "toggleNormalsViz" );
|
||||
EVisibility.addOption( "AL: Depth Viz", "$AL_DepthVisualizeVar", "toggleDepthViz" );
|
||||
EVisibility.addOption( "AL: Glow Buffer", "$AL_GlowVisualizeVar", "toggleGlowViz" );
|
||||
EVisibility.addOption( "AL: PSSM Cascade Viz", "$AL::PSSMDebugRender", "" );
|
||||
EVisibility.addOption( "Frustum Lock", "$Scene::lockCull", "" );
|
||||
EVisibility.addOption( "Disable Zone Culling", "$Scene::disableZoneCulling", "" );
|
||||
EVisibility.addOption( "Disable Terrain Occlusion", "$Scene::disableTerrainOcclusion", "" );
|
||||
|
|
|
|||
|
|
@ -561,9 +561,6 @@ function EditorGui::onWake( %this )
|
|||
|
||||
if( %levelName !$= %this.levelName )
|
||||
%this.onNewLevelLoaded( %levelName );
|
||||
|
||||
if (isObject(DemoEditorAlert) && DemoEditorAlert.helpTag<2)
|
||||
Canvas.pushDialog(DemoEditorAlert);
|
||||
}
|
||||
|
||||
function EditorGui::onSleep( %this )
|
||||
|
|
|
|||
|
|
@ -81,9 +81,6 @@ function EditorPlugin::onEditorSleep( %this )
|
|||
/// Push Gui's, stuff like that
|
||||
function EditorPlugin::onActivated( %this )
|
||||
{
|
||||
if(isDemo())
|
||||
startToolTime(%this.getName());
|
||||
|
||||
%this.isActivated = true;
|
||||
}
|
||||
|
||||
|
|
@ -91,9 +88,6 @@ function EditorPlugin::onActivated( %this )
|
|||
/// Pop Gui's, stuff like that
|
||||
function EditorPlugin::onDeactivated( %this )
|
||||
{
|
||||
if(isDemo())
|
||||
endToolTime(%this.getName());
|
||||
|
||||
%this.isActivated = false;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -46,6 +46,7 @@ function EWCreatorWindow::init( %this )
|
|||
%this.registerMissionObject( "SFXEmitter", "Sound Emitter" );
|
||||
%this.registerMissionObject( "Precipitation" );
|
||||
%this.registerMissionObject( "ParticleEmitterNode", "Particle Emitter" );
|
||||
%this.registerMissionObject( "VolumetricFog", "Volumetric Fog" );
|
||||
%this.registerMissionObject( "RibbonNode", "Ribbon" );
|
||||
|
||||
// Legacy features. Users should use Ground Cover and the Forest Editor.
|
||||
|
|
@ -176,12 +177,6 @@ function EWCreatorWindow::createStatic( %this, %file )
|
|||
if ( !$missionRunning )
|
||||
return;
|
||||
|
||||
if(isFunction("getObjectLimit") && MissionGroup.getFullCount() >= getObjectLimit())
|
||||
{
|
||||
MessageBoxOKBuy( "Object Limit Reached", "You have exceeded the object limit of " @ getObjectLimit() @ " for this demo. You can remove objects if you would like to add more.", "", "Canvas.showPurchaseScreen(\"objectlimit\");" );
|
||||
return;
|
||||
}
|
||||
|
||||
if( !isObject(%this.objectGroup) )
|
||||
%this.setNewObjectGroup( MissionGroup );
|
||||
|
||||
|
|
@ -200,12 +195,6 @@ function EWCreatorWindow::createPrefab( %this, %file )
|
|||
if ( !$missionRunning )
|
||||
return;
|
||||
|
||||
if(isFunction("getObjectLimit") && MissionGroup.getFullCount() >= getObjectLimit())
|
||||
{
|
||||
MessageBoxOKBuy( "Object Limit Reached", "You have exceeded the object limit of " @ getObjectLimit() @ " for this demo. You can remove objects if you would like to add more.", "", "Canvas.showPurchaseScreen(\"objectlimit\");" );
|
||||
return;
|
||||
}
|
||||
|
||||
if( !isObject(%this.objectGroup) )
|
||||
%this.setNewObjectGroup( MissionGroup );
|
||||
|
||||
|
|
@ -224,12 +213,6 @@ function EWCreatorWindow::createObject( %this, %cmd )
|
|||
if ( !$missionRunning )
|
||||
return;
|
||||
|
||||
if(isFunction("getObjectLimit") && MissionGroup.getFullCount() >= getObjectLimit())
|
||||
{
|
||||
MessageBoxOKBuy( "Object Limit Reached", "You have exceeded the object limit of " @ getObjectLimit() @ " for this demo. You can remove objects if you would like to add more.", "", "Canvas.showPurchaseScreen(\"objectlimit\");" );
|
||||
return;
|
||||
}
|
||||
|
||||
if( !isObject(%this.objectGroup) )
|
||||
%this.setNewObjectGroup( MissionGroup );
|
||||
|
||||
|
|
|
|||
|
|
@ -28,9 +28,7 @@ $Pref::WorldEditor::FileSpec = "Torque Mission Files (*.mis)|*.mis|All Files (*.
|
|||
|
||||
function EditorFileMenu::onMenuSelect(%this)
|
||||
{
|
||||
// don't do this since it won't exist if this is a "demo"
|
||||
if(!isWebDemo())
|
||||
%this.enableItem(2, EditorIsDirty());
|
||||
%this.enableItem(2, EditorIsDirty());
|
||||
}
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
|
|
@ -88,7 +86,7 @@ function EditorClearDirty()
|
|||
|
||||
function EditorQuitGame()
|
||||
{
|
||||
if( EditorIsDirty() && !isWebDemo())
|
||||
if( EditorIsDirty())
|
||||
{
|
||||
MessageBoxYesNoCancel("Level Modified", "Would you like to save your changes before quitting?", "EditorSaveMissionMenu(); quit();", "quit();", "" );
|
||||
}
|
||||
|
|
@ -98,7 +96,7 @@ function EditorQuitGame()
|
|||
|
||||
function EditorExitMission()
|
||||
{
|
||||
if( EditorIsDirty() && !isWebDemo() )
|
||||
if( EditorIsDirty())
|
||||
{
|
||||
MessageBoxYesNoCancel("Level Modified", "Would you like to save your changes before exiting?", "EditorDoExitMission(true);", "EditorDoExitMission(false);", "");
|
||||
}
|
||||
|
|
@ -108,7 +106,7 @@ function EditorExitMission()
|
|||
|
||||
function EditorDoExitMission(%saveFirst)
|
||||
{
|
||||
if(%saveFirst && !isWebDemo())
|
||||
if(%saveFirst)
|
||||
{
|
||||
EditorSaveMissionMenu();
|
||||
}
|
||||
|
|
@ -202,9 +200,6 @@ function EditorOpenDeclarationInTorsion( %object )
|
|||
|
||||
function EditorNewLevel( %file )
|
||||
{
|
||||
if(isWebDemo())
|
||||
return;
|
||||
|
||||
%saveFirst = false;
|
||||
if ( EditorIsDirty() )
|
||||
{
|
||||
|
|
@ -241,27 +236,15 @@ function EditorNewLevel( %file )
|
|||
|
||||
function EditorSaveMissionMenu()
|
||||
{
|
||||
if(!$Pref::disableSaving && !isWebDemo())
|
||||
{
|
||||
if(EditorGui.saveAs)
|
||||
EditorSaveMissionAs();
|
||||
else
|
||||
EditorSaveMission();
|
||||
}
|
||||
if(EditorGui.saveAs)
|
||||
EditorSaveMissionAs();
|
||||
else
|
||||
{
|
||||
EditorSaveMissionMenuDisableSave();
|
||||
}
|
||||
EditorSaveMission();
|
||||
}
|
||||
|
||||
function EditorSaveMission()
|
||||
{
|
||||
// just save the mission without renaming it
|
||||
if(isFunction("getObjectLimit") && MissionGroup.getFullCount() >= getObjectLimit())
|
||||
{
|
||||
MessageBoxOKBuy( "Object Limit Reached", "You have exceeded the object limit of " @ getObjectLimit() @ " for this demo. You can remove objects if you would like to add more.", "", "Canvas.showPurchaseScreen(\"objectlimit\");" );
|
||||
return;
|
||||
}
|
||||
|
||||
// first check for dirty and read-only files:
|
||||
if((EWorldEditor.isDirty || ETerrainEditor.isMissionDirty) && !isWriteableFileName($Server::MissionFile))
|
||||
|
|
@ -316,146 +299,125 @@ function EditorSaveMission()
|
|||
return true;
|
||||
}
|
||||
|
||||
function EditorSaveMissionMenuDisableSave()
|
||||
{
|
||||
GenericPromptDialog-->GenericPromptWindow.text = "Warning";
|
||||
GenericPromptDialog-->GenericPromptText.setText("Saving disabled in demo mode.");
|
||||
Canvas.pushDialog( GenericPromptDialog );
|
||||
}
|
||||
|
||||
function EditorSaveMissionAs( %missionName )
|
||||
{
|
||||
if(isFunction("getObjectLimit") && MissionGroup.getFullCount() >= getObjectLimit())
|
||||
// If we didn't get passed a new mission name then
|
||||
// prompt the user for one.
|
||||
if ( %missionName $= "" )
|
||||
{
|
||||
MessageBoxOKBuy( "Object Limit Reached", "You have exceeded the object limit of " @ getObjectLimit() @ " for this demo. You can remove objects if you would like to add more.", "", "Canvas.showPurchaseScreen(\"objectlimit\");" );
|
||||
return;
|
||||
}
|
||||
|
||||
if(!$Pref::disableSaving && !isWebDemo())
|
||||
{
|
||||
// If we didn't get passed a new mission name then
|
||||
// prompt the user for one.
|
||||
if ( %missionName $= "" )
|
||||
%dlg = new SaveFileDialog()
|
||||
{
|
||||
%dlg = new SaveFileDialog()
|
||||
{
|
||||
Filters = $Pref::WorldEditor::FileSpec;
|
||||
DefaultPath = EditorSettings.value("LevelInformation/levelsDirectory");
|
||||
ChangePath = false;
|
||||
OverwritePrompt = true;
|
||||
};
|
||||
Filters = $Pref::WorldEditor::FileSpec;
|
||||
DefaultPath = EditorSettings.value("LevelInformation/levelsDirectory");
|
||||
ChangePath = false;
|
||||
OverwritePrompt = true;
|
||||
};
|
||||
|
||||
%ret = %dlg.Execute();
|
||||
if(%ret)
|
||||
{
|
||||
// Immediately override/set the levelsDirectory
|
||||
EditorSettings.setValue( "LevelInformation/levelsDirectory", collapseFilename(filePath( %dlg.FileName )) );
|
||||
|
||||
%missionName = %dlg.FileName;
|
||||
}
|
||||
%ret = %dlg.Execute();
|
||||
if(%ret)
|
||||
{
|
||||
// Immediately override/set the levelsDirectory
|
||||
EditorSettings.setValue( "LevelInformation/levelsDirectory", collapseFilename(filePath( %dlg.FileName )) );
|
||||
|
||||
%dlg.delete();
|
||||
|
||||
if(! %ret)
|
||||
return;
|
||||
%missionName = %dlg.FileName;
|
||||
}
|
||||
|
||||
if( fileExt( %missionName ) !$= ".mis" )
|
||||
%missionName = %missionName @ ".mis";
|
||||
|
||||
EWorldEditor.isDirty = true;
|
||||
%saveMissionFile = $Server::MissionFile;
|
||||
|
||||
$Server::MissionFile = %missionName;
|
||||
|
||||
%copyTerrainsFailed = false;
|
||||
|
||||
// Rename all the terrain files. Save all previous names so we can
|
||||
// reset them if saving fails.
|
||||
%newMissionName = fileBase(%missionName);
|
||||
%oldMissionName = fileBase(%saveMissionFile);
|
||||
|
||||
%dlg.delete();
|
||||
|
||||
if(! %ret)
|
||||
return;
|
||||
}
|
||||
|
||||
if( fileExt( %missionName ) !$= ".mis" )
|
||||
%missionName = %missionName @ ".mis";
|
||||
|
||||
EWorldEditor.isDirty = true;
|
||||
%saveMissionFile = $Server::MissionFile;
|
||||
|
||||
$Server::MissionFile = %missionName;
|
||||
|
||||
%copyTerrainsFailed = false;
|
||||
|
||||
// Rename all the terrain files. Save all previous names so we can
|
||||
// reset them if saving fails.
|
||||
%newMissionName = fileBase(%missionName);
|
||||
%oldMissionName = fileBase(%saveMissionFile);
|
||||
|
||||
initContainerTypeSearch( $TypeMasks::TerrainObjectType );
|
||||
%savedTerrNames = new ScriptObject();
|
||||
for( %i = 0;; %i ++ )
|
||||
{
|
||||
%terrainObject = containerSearchNext();
|
||||
if( !%terrainObject )
|
||||
break;
|
||||
|
||||
%savedTerrNames.array[ %i ] = %terrainObject.terrainFile;
|
||||
|
||||
%terrainFilePath = makeRelativePath( filePath( %terrainObject.terrainFile ), getMainDotCsDir() );
|
||||
%terrainFileName = fileName( %terrainObject.terrainFile );
|
||||
|
||||
// Workaround to have terrains created in an unsaved "New Level..." mission
|
||||
// moved to the correct place.
|
||||
|
||||
if( EditorGui.saveAs && %terrainFilePath $= "tools/art/terrains" )
|
||||
%terrainFilePath = "art/terrains";
|
||||
|
||||
// Try and follow the existing naming convention.
|
||||
// If we can't, use systematic terrain file names.
|
||||
if( strstr( %terrainFileName, %oldMissionName ) >= 0 )
|
||||
%terrainFileName = strreplace( %terrainFileName, %oldMissionName, %newMissionName );
|
||||
else
|
||||
%terrainFileName = %newMissionName @ "_" @ %i @ ".ter";
|
||||
|
||||
%newTerrainFile = %terrainFilePath @ "/" @ %terrainFileName;
|
||||
|
||||
if (!isWriteableFileName(%newTerrainFile))
|
||||
{
|
||||
if (MessageBox("Error", "Terrain file \""@ %newTerrainFile @ "\" is read-only. Continue?", "Ok", "Stop") == $MROk)
|
||||
continue;
|
||||
else
|
||||
{
|
||||
%copyTerrainsFailed = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if( !%terrainObject.save( %newTerrainFile ) )
|
||||
{
|
||||
error( "Failed to save '" @ %newTerrainFile @ "'" );
|
||||
%copyTerrainsFailed = true;
|
||||
break;
|
||||
}
|
||||
|
||||
%terrainObject.terrainFile = %newTerrainFile;
|
||||
}
|
||||
|
||||
ETerrainEditor.isDirty = false;
|
||||
|
||||
// Save the mission.
|
||||
if(%copyTerrainsFailed || !EditorSaveMission())
|
||||
{
|
||||
// It failed, so restore the mission and terrain filenames.
|
||||
|
||||
$Server::MissionFile = %saveMissionFile;
|
||||
|
||||
initContainerTypeSearch( $TypeMasks::TerrainObjectType );
|
||||
%savedTerrNames = new ScriptObject();
|
||||
for( %i = 0;; %i ++ )
|
||||
{
|
||||
%terrainObject = containerSearchNext();
|
||||
if( !%terrainObject )
|
||||
break;
|
||||
|
||||
%savedTerrNames.array[ %i ] = %terrainObject.terrainFile;
|
||||
|
||||
%terrainFilePath = makeRelativePath( filePath( %terrainObject.terrainFile ), getMainDotCsDir() );
|
||||
%terrainFileName = fileName( %terrainObject.terrainFile );
|
||||
|
||||
// Workaround to have terrains created in an unsaved "New Level..." mission
|
||||
// moved to the correct place.
|
||||
|
||||
if( EditorGui.saveAs && %terrainFilePath $= "tools/art/terrains" )
|
||||
%terrainFilePath = "art/terrains";
|
||||
|
||||
// Try and follow the existing naming convention.
|
||||
// If we can't, use systematic terrain file names.
|
||||
if( strstr( %terrainFileName, %oldMissionName ) >= 0 )
|
||||
%terrainFileName = strreplace( %terrainFileName, %oldMissionName, %newMissionName );
|
||||
else
|
||||
%terrainFileName = %newMissionName @ "_" @ %i @ ".ter";
|
||||
|
||||
%newTerrainFile = %terrainFilePath @ "/" @ %terrainFileName;
|
||||
|
||||
if (!isWriteableFileName(%newTerrainFile))
|
||||
{
|
||||
if (MessageBox("Error", "Terrain file \""@ %newTerrainFile @ "\" is read-only. Continue?", "Ok", "Stop") == $MROk)
|
||||
continue;
|
||||
else
|
||||
{
|
||||
%copyTerrainsFailed = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if( !%terrainObject.save( %newTerrainFile ) )
|
||||
{
|
||||
error( "Failed to save '" @ %newTerrainFile @ "'" );
|
||||
%copyTerrainsFailed = true;
|
||||
break;
|
||||
}
|
||||
|
||||
%terrainObject.terrainFile = %newTerrainFile;
|
||||
|
||||
%terrainObject.terrainFile = %savedTerrNames.array[ %i ];
|
||||
}
|
||||
|
||||
ETerrainEditor.isDirty = false;
|
||||
|
||||
// Save the mission.
|
||||
if(%copyTerrainsFailed || !EditorSaveMission())
|
||||
{
|
||||
// It failed, so restore the mission and terrain filenames.
|
||||
|
||||
$Server::MissionFile = %saveMissionFile;
|
||||
|
||||
initContainerTypeSearch( $TypeMasks::TerrainObjectType );
|
||||
for( %i = 0;; %i ++ )
|
||||
{
|
||||
%terrainObject = containerSearchNext();
|
||||
if( !%terrainObject )
|
||||
break;
|
||||
|
||||
%terrainObject.terrainFile = %savedTerrNames.array[ %i ];
|
||||
}
|
||||
}
|
||||
|
||||
%savedTerrNames.delete();
|
||||
}
|
||||
else
|
||||
{
|
||||
EditorSaveMissionMenuDisableSave();
|
||||
}
|
||||
|
||||
%savedTerrNames.delete();
|
||||
}
|
||||
|
||||
function EditorOpenMission(%filename)
|
||||
{
|
||||
if( EditorIsDirty() && !isWebDemo() )
|
||||
if( EditorIsDirty())
|
||||
{
|
||||
// "EditorSaveBeforeLoad();", "getLoadFilename(\"*.mis\", \"EditorDoLoadMission\");"
|
||||
if(MessageBox("Mission Modified", "Would you like to save changes to the current mission \"" @
|
||||
|
|
@ -523,72 +485,67 @@ function EditorOpenMission(%filename)
|
|||
|
||||
function EditorExportToCollada()
|
||||
{
|
||||
if ( !$Pref::disableSaving && !isWebDemo() )
|
||||
|
||||
%dlg = new SaveFileDialog()
|
||||
{
|
||||
%dlg = new SaveFileDialog()
|
||||
{
|
||||
Filters = "COLLADA Files (*.dae)|*.dae|";
|
||||
DefaultPath = $Pref::WorldEditor::LastPath;
|
||||
DefaultFile = "";
|
||||
ChangePath = false;
|
||||
OverwritePrompt = true;
|
||||
};
|
||||
Filters = "COLLADA Files (*.dae)|*.dae|";
|
||||
DefaultPath = $Pref::WorldEditor::LastPath;
|
||||
DefaultFile = "";
|
||||
ChangePath = false;
|
||||
OverwritePrompt = true;
|
||||
};
|
||||
|
||||
%ret = %dlg.Execute();
|
||||
if ( %ret )
|
||||
{
|
||||
$Pref::WorldEditor::LastPath = filePath( %dlg.FileName );
|
||||
%exportFile = %dlg.FileName;
|
||||
}
|
||||
|
||||
if( fileExt( %exportFile ) !$= ".dae" )
|
||||
%exportFile = %exportFile @ ".dae";
|
||||
|
||||
%dlg.delete();
|
||||
|
||||
if ( !%ret )
|
||||
return;
|
||||
|
||||
if ( EditorGui.currentEditor.getId() == ShapeEditorPlugin.getId() )
|
||||
ShapeEdShapeView.exportToCollada( %exportFile );
|
||||
else
|
||||
EWorldEditor.colladaExportSelection( %exportFile );
|
||||
%ret = %dlg.Execute();
|
||||
if ( %ret )
|
||||
{
|
||||
$Pref::WorldEditor::LastPath = filePath( %dlg.FileName );
|
||||
%exportFile = %dlg.FileName;
|
||||
}
|
||||
|
||||
if( fileExt( %exportFile ) !$= ".dae" )
|
||||
%exportFile = %exportFile @ ".dae";
|
||||
|
||||
%dlg.delete();
|
||||
|
||||
if ( !%ret )
|
||||
return;
|
||||
|
||||
if ( EditorGui.currentEditor.getId() == ShapeEditorPlugin.getId() )
|
||||
ShapeEdShapeView.exportToCollada( %exportFile );
|
||||
else
|
||||
EWorldEditor.colladaExportSelection( %exportFile );
|
||||
}
|
||||
|
||||
function EditorMakePrefab()
|
||||
{
|
||||
// Should this be protected or not?
|
||||
if ( !$Pref::disableSaving && !isWebDemo() )
|
||||
|
||||
%dlg = new SaveFileDialog()
|
||||
{
|
||||
%dlg = new SaveFileDialog()
|
||||
{
|
||||
Filters = "Prefab Files (*.prefab)|*.prefab|";
|
||||
DefaultPath = $Pref::WorldEditor::LastPath;
|
||||
DefaultFile = "";
|
||||
ChangePath = false;
|
||||
OverwritePrompt = true;
|
||||
};
|
||||
|
||||
%ret = %dlg.Execute();
|
||||
if ( %ret )
|
||||
{
|
||||
$Pref::WorldEditor::LastPath = filePath( %dlg.FileName );
|
||||
%saveFile = %dlg.FileName;
|
||||
}
|
||||
|
||||
if( fileExt( %saveFile ) !$= ".prefab" )
|
||||
%saveFile = %saveFile @ ".prefab";
|
||||
|
||||
%dlg.delete();
|
||||
|
||||
if ( !%ret )
|
||||
return;
|
||||
|
||||
EWorldEditor.makeSelectionPrefab( %saveFile );
|
||||
|
||||
EditorTree.buildVisibleTree( true );
|
||||
Filters = "Prefab Files (*.prefab)|*.prefab|";
|
||||
DefaultPath = $Pref::WorldEditor::LastPath;
|
||||
DefaultFile = "";
|
||||
ChangePath = false;
|
||||
OverwritePrompt = true;
|
||||
};
|
||||
|
||||
%ret = %dlg.Execute();
|
||||
if ( %ret )
|
||||
{
|
||||
$Pref::WorldEditor::LastPath = filePath( %dlg.FileName );
|
||||
%saveFile = %dlg.FileName;
|
||||
}
|
||||
|
||||
if( fileExt( %saveFile ) !$= ".prefab" )
|
||||
%saveFile = %saveFile @ ".prefab";
|
||||
|
||||
%dlg.delete();
|
||||
|
||||
if ( !%ret )
|
||||
return;
|
||||
|
||||
EWorldEditor.makeSelectionPrefab( %saveFile );
|
||||
|
||||
EditorTree.buildVisibleTree( true );
|
||||
}
|
||||
|
||||
function EditorExplodePrefab()
|
||||
|
|
|
|||
|
|
@ -112,35 +112,30 @@ function EditorGui::buildMenus(%this)
|
|||
barTitle = "File";
|
||||
};
|
||||
|
||||
if(!isWebDemo())
|
||||
{
|
||||
%fileMenu.appendItem("New Level" TAB "" TAB "schedule( 1, 0, \"EditorNewLevel\" );");
|
||||
%fileMenu.appendItem("Open Level..." TAB %cmdCtrl SPC "O" TAB "schedule( 1, 0, \"EditorOpenMission\" );");
|
||||
%fileMenu.appendItem("Save Level" TAB %cmdCtrl SPC "S" TAB "EditorSaveMissionMenu();");
|
||||
%fileMenu.appendItem("Save Level As..." TAB "" TAB "EditorSaveMissionAs();");
|
||||
%fileMenu.appendItem("-");
|
||||
|
||||
if( $platform $= "windows" )
|
||||
{
|
||||
%fileMenu.appendItem( "Open Project in Torsion" TAB "" TAB "EditorOpenTorsionProject();" );
|
||||
%fileMenu.appendItem( "Open Level File in Torsion" TAB "" TAB "EditorOpenFileInTorsion();" );
|
||||
%fileMenu.appendItem( "-" );
|
||||
}
|
||||
%fileMenu.appendItem("New Level" TAB "" TAB "schedule( 1, 0, \"EditorNewLevel\" );");
|
||||
%fileMenu.appendItem("Open Level..." TAB %cmdCtrl SPC "O" TAB "schedule( 1, 0, \"EditorOpenMission\" );");
|
||||
%fileMenu.appendItem("Save Level" TAB %cmdCtrl SPC "S" TAB "EditorSaveMissionMenu();");
|
||||
%fileMenu.appendItem("Save Level As..." TAB "" TAB "EditorSaveMissionAs();");
|
||||
%fileMenu.appendItem("-");
|
||||
|
||||
if( $platform $= "windows" )
|
||||
{
|
||||
%fileMenu.appendItem( "Open Project in Torsion" TAB "" TAB "EditorOpenTorsionProject();" );
|
||||
%fileMenu.appendItem( "Open Level File in Torsion" TAB "" TAB "EditorOpenFileInTorsion();" );
|
||||
%fileMenu.appendItem( "-" );
|
||||
}
|
||||
|
||||
%fileMenu.appendItem("Create Blank Terrain" TAB "" TAB "Canvas.pushDialog( CreateNewTerrainGui );");
|
||||
%fileMenu.appendItem("Import Terrain Heightmap" TAB "" TAB "Canvas.pushDialog( TerrainImportGui );");
|
||||
|
||||
if(!isWebDemo())
|
||||
{
|
||||
%fileMenu.appendItem("Export Terrain Heightmap" TAB "" TAB "Canvas.pushDialog( TerrainExportGui );");
|
||||
%fileMenu.appendItem("-");
|
||||
%fileMenu.appendItem("Export To COLLADA..." TAB "" TAB "EditorExportToCollada();");
|
||||
//item[5] = "Import Terraform Data..." TAB "" TAB "Heightfield::import();";
|
||||
//item[6] = "Import Texture Data..." TAB "" TAB "Texture::import();";
|
||||
//item[7] = "-";
|
||||
//item[8] = "Export Terraform Data..." TAB "" TAB "Heightfield::saveBitmap(\"\");";
|
||||
}
|
||||
%fileMenu.appendItem("Export Terrain Heightmap" TAB "" TAB "Canvas.pushDialog( TerrainExportGui );");
|
||||
%fileMenu.appendItem("-");
|
||||
%fileMenu.appendItem("Export To COLLADA..." TAB "" TAB "EditorExportToCollada();");
|
||||
//item[5] = "Import Terraform Data..." TAB "" TAB "Heightfield::import();";
|
||||
//item[6] = "Import Texture Data..." TAB "" TAB "Texture::import();";
|
||||
//item[7] = "-";
|
||||
//item[8] = "Export Terraform Data..." TAB "" TAB "Heightfield::saveBitmap(\"\");";
|
||||
|
||||
%fileMenu.appendItem( "-" );
|
||||
%fileMenu.appendItem( "Add FMOD Designer Audio..." TAB "" TAB "AddFMODProjectDlg.show();" );
|
||||
|
|
@ -148,11 +143,9 @@ function EditorGui::buildMenus(%this)
|
|||
%fileMenu.appendItem("-");
|
||||
%fileMenu.appendItem("Play Level" TAB "F11" TAB "Editor.close(\"PlayGui\");");
|
||||
|
||||
if(!isWebDemo())
|
||||
{
|
||||
%fileMenu.appendItem("Exit Level" TAB "" TAB "EditorExitMission();");
|
||||
%fileMenu.appendItem("Quit" TAB %quitShortcut TAB "EditorQuitGame();");
|
||||
}
|
||||
%fileMenu.appendItem("Exit Level" TAB "" TAB "EditorExitMission();");
|
||||
%fileMenu.appendItem("Quit" TAB %quitShortcut TAB "EditorQuitGame();");
|
||||
|
||||
%this.menuBar.insert(%fileMenu, %this.menuBar.getCount());
|
||||
|
||||
// Edit Menu
|
||||
|
|
|
|||
|
|
@ -191,3 +191,11 @@ function EVisibility::addClassOptions( %this )
|
|||
%selList.addGuiControl( %selCheckBox );
|
||||
}
|
||||
}
|
||||
|
||||
function togglePhysicsDebugViz( %enable )
|
||||
{
|
||||
if(physicsPluginPresent())
|
||||
{
|
||||
physicsDebugDraw(%enable);
|
||||
}
|
||||
}
|
||||
|
|
|
|||