From ef882d30b3b09f8afee34f70e0538a653e8ed9f8 Mon Sep 17 00:00:00 2001 From: Daveo Date: Fri, 6 Apr 2001 19:03:58 +0000 Subject: [PATCH] --- Utils/MapEdit/LayerFX.cpp | 165 +++++++++++++++++++++++++++++++++ Utils/MapEdit/LayerFX.h | 50 ++++++++++ Utils/MapEdit/LayerTrigger.cpp | 165 +++++++++++++++++++++++++++++++++ Utils/MapEdit/LayerTrigger.h | 50 ++++++++++ 4 files changed, 430 insertions(+) create mode 100644 Utils/MapEdit/LayerFX.cpp create mode 100644 Utils/MapEdit/LayerFX.h create mode 100644 Utils/MapEdit/LayerTrigger.cpp create mode 100644 Utils/MapEdit/LayerTrigger.h diff --git a/Utils/MapEdit/LayerFX.cpp b/Utils/MapEdit/LayerFX.cpp new file mode 100644 index 000000000..dc392a416 --- /dev/null +++ b/Utils/MapEdit/LayerFX.cpp @@ -0,0 +1,165 @@ +/**********************/ +/*** Layer Platform ***/ +/**********************/ + +#include "stdafx.h" +#include +#include +#include +#include "GLEnabledView.h" + +#include "MapEdit.h" +#include "MapEditDoc.h" +#include "MapEditView.h" +#include "MainFrm.h" + +#include "Core.h" +#include "LayerThing.h" +#include "LayerPlatform.h" +#include "Utils.h" +#include "Export.h" + +/*****************************************************************************/ +/*****************************************************************************/ +/*****************************************************************************/ +CLayerPlatform::CLayerPlatform(sLayerDef &Def) +{ + InitLayer(Def); +} + +/*****************************************************************************/ +void CLayerPlatform::InitLayer(sLayerDef &Def) +{ + ThingBank=new CElemBank(-1,-1,false,CElem::CentreModeLR | CElem::CentreModeB); + CLayerThing::InitLayer(Def); + LoadThingScript(theApp.GetConfigStr("LayerScript","PlatformScript")); +} + +/*****************************************************************************/ +void CLayerPlatform::InitSubView(CCore *Core) +{ +} + +/*****************************************************************************/ +/*** Gui *********************************************************************/ +/*****************************************************************************/ +void CLayerPlatform::GUIInit(CCore *Core) +{ + GUIPlatform.DisableCallback(true); + Core->GUIAdd(GUIThing,IDD_LAYER_THING); + Core->GUIAdd(GUIThingPos,IDD_LAYER_THING_POS); + Core->GUIAdd(GUIPlatform,IDD_LAYER_PLATFORM); + GUIPlatform.DisableCallback(false); + +// Init type lists + { +CComboBox &List=GUIPlatform.m_MoveList; + List.AddString("Linear"); + List.AddString("Circular"); + } + + { +CComboBox &List=GUIPlatform.m_Type; + List.AddString("Normal"); + List.AddString("Weighted"); + List.AddString("Rotating"); + } + + +} + +/*****************************************************************************/ +void CLayerPlatform::GUIKill(CCore *Core) +{ + Core->GUIRemove(GUIThing,IDD_LAYER_THING); + Core->GUIRemove(GUIThingPos,IDD_LAYER_THING_POS); + Core->GUIRemove(GUIPlatform,IDD_LAYER_PLATFORM); +} + +/*****************************************************************************/ +void CLayerPlatform::GUIUpdate(CCore *Core) +{ +int i,ListSize; +CComboBox &List=GUIThing.m_DefList; + +// Setup Def Platform List + ListSize=DefList.size(); + List.ResetContent(); + for (i=0; i +#include +#include +#include "GLEnabledView.h" + +#include "MapEdit.h" +#include "MapEditDoc.h" +#include "MapEditView.h" +#include "MainFrm.h" + +#include "Core.h" +#include "LayerThing.h" +#include "LayerPlatform.h" +#include "Utils.h" +#include "Export.h" + +/*****************************************************************************/ +/*****************************************************************************/ +/*****************************************************************************/ +CLayerPlatform::CLayerPlatform(sLayerDef &Def) +{ + InitLayer(Def); +} + +/*****************************************************************************/ +void CLayerPlatform::InitLayer(sLayerDef &Def) +{ + ThingBank=new CElemBank(-1,-1,false,CElem::CentreModeLR | CElem::CentreModeB); + CLayerThing::InitLayer(Def); + LoadThingScript(theApp.GetConfigStr("LayerScript","PlatformScript")); +} + +/*****************************************************************************/ +void CLayerPlatform::InitSubView(CCore *Core) +{ +} + +/*****************************************************************************/ +/*** Gui *********************************************************************/ +/*****************************************************************************/ +void CLayerPlatform::GUIInit(CCore *Core) +{ + GUIPlatform.DisableCallback(true); + Core->GUIAdd(GUIThing,IDD_LAYER_THING); + Core->GUIAdd(GUIThingPos,IDD_LAYER_THING_POS); + Core->GUIAdd(GUIPlatform,IDD_LAYER_PLATFORM); + GUIPlatform.DisableCallback(false); + +// Init type lists + { +CComboBox &List=GUIPlatform.m_MoveList; + List.AddString("Linear"); + List.AddString("Circular"); + } + + { +CComboBox &List=GUIPlatform.m_Type; + List.AddString("Normal"); + List.AddString("Weighted"); + List.AddString("Rotating"); + } + + +} + +/*****************************************************************************/ +void CLayerPlatform::GUIKill(CCore *Core) +{ + Core->GUIRemove(GUIThing,IDD_LAYER_THING); + Core->GUIRemove(GUIThingPos,IDD_LAYER_THING_POS); + Core->GUIRemove(GUIPlatform,IDD_LAYER_PLATFORM); +} + +/*****************************************************************************/ +void CLayerPlatform::GUIUpdate(CCore *Core) +{ +int i,ListSize; +CComboBox &List=GUIThing.m_DefList; + +// Setup Def Platform List + ListSize=DefList.size(); + List.ResetContent(); + for (i=0; i