This commit is contained in:
parent
e6097f7417
commit
826713a65c
23 changed files with 1118 additions and 325 deletions
|
@ -27,12 +27,22 @@ enum CmdMsg
|
|||
CmdMsg_SubViewDelete, // 14
|
||||
CmdMsg_SubViewUpdate, // 15
|
||||
CmdMsg_SubViewSet, // 16
|
||||
|
||||
// TileLayer/TileBank
|
||||
CmdMsg_MirrorX, // 17
|
||||
CmdMsg_MirrorY, // 18
|
||||
CmdMsg_SetColFlag, // 19
|
||||
CmdMsg_ActiveBrushLeft, // 20
|
||||
CmdMsg_ActiveBrushRight, // 21
|
||||
|
||||
// Thing
|
||||
CmdMsg_ThingListDelete, // 23
|
||||
CmdMsg_ThingListSelect, // 24
|
||||
CmdMsg_ThingLevelSelect, // 25
|
||||
CmdMsg_ThingPosSelect, // 26
|
||||
CmdMsg_ThingPosUp, // 27
|
||||
CmdMsg_ThingPosDown, // 28
|
||||
CmdMsg_ThingPosDelete, // 29
|
||||
};
|
||||
#endif
|
||||
/*****************************************************************************/
|
||||
|
|
|
@ -33,7 +33,7 @@
|
|||
|
||||
#include <IniClass.h>
|
||||
|
||||
GString IconzFileName="Iconz.bmp";
|
||||
//GString IconzFileName="Iconz.bmp";
|
||||
|
||||
/*****************************************************************************/
|
||||
/*****************************************************************************/
|
||||
|
@ -53,7 +53,7 @@ GString Filename;
|
|||
IconBank=new CElemBank(16,16,false,false);
|
||||
|
||||
GetExecPath(Filename);
|
||||
Filename+=IconzFileName;
|
||||
Filename+=theApp.GetConfigStr("FileLocation","Iconz");
|
||||
IconBank->AddSet(Filename);
|
||||
}
|
||||
|
||||
|
@ -71,8 +71,8 @@ bool CCore::New()
|
|||
{
|
||||
CGUINewMap Dlg;
|
||||
int Width,Height;
|
||||
Dlg.m_Width=TileLayerMinWidth;
|
||||
Dlg.m_Height=TileLayerMinHeight;
|
||||
Dlg.m_Width=TileLayerMinWidth+2;
|
||||
Dlg.m_Height=TileLayerMinHeight+2;
|
||||
|
||||
#ifndef _DEBUG
|
||||
if (Dlg.DoModal()!=IDOK) return FALSE;
|
||||
|
@ -82,7 +82,7 @@ int Width,Height;
|
|||
|
||||
// Create Tile Layers
|
||||
AddLayer(LAYER_TYPE_TILE,LAYER_SUBTYPE_ACTION, Width, Height);
|
||||
// AddLayer(LAYER_TYPE_ACTOR,LAYER_SUBTYPE_NONE, Width, Height);
|
||||
AddLayer(LAYER_TYPE_ACTOR,LAYER_SUBTYPE_NONE, Width, Height);
|
||||
|
||||
for (int i=0; i<Layer.size(); i++)
|
||||
{
|
||||
|
@ -262,6 +262,20 @@ CLayer *ThisLayer;
|
|||
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CCore::RenderNumber(int No)
|
||||
{
|
||||
int T=No/10;
|
||||
int U=No%10;
|
||||
|
||||
glPushMatrix();
|
||||
IconBank->RenderElem(0,T,0,false);
|
||||
glTranslatef(0.5f,0,0);
|
||||
IconBank->RenderElem(0,U,0,false);
|
||||
glPopMatrix();
|
||||
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
/*** Control *****************************************************************/
|
||||
/*****************************************************************************/
|
||||
|
@ -667,6 +681,7 @@ Vector3 &ThisCam=GetCam();
|
|||
/*****************************************************************************/
|
||||
void CCore::GetExecPath(GString &Path)
|
||||
{
|
||||
#ifndef _DEBUG
|
||||
// Get application path
|
||||
char ExeFilename[2048];
|
||||
GFName Exe;
|
||||
|
@ -675,6 +690,7 @@ GFName Exe;
|
|||
Exe.File(0);
|
||||
Exe.Ext(0);
|
||||
Path=Exe.FullName();
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -43,6 +43,7 @@ public:
|
|||
bool Question(char *Txt);
|
||||
void Render(bool ForceRender=FALSE);
|
||||
void RenderLayers(bool OneShot=false);
|
||||
void RenderNumber(int No);
|
||||
void Export(char *Filename);
|
||||
|
||||
// View Stuff
|
||||
|
@ -116,6 +117,7 @@ public:
|
|||
void ResetView();
|
||||
CElemBank *GetIconBank() {return(IconBank);}
|
||||
void GetExecPath(GString &Path);
|
||||
|
||||
private:
|
||||
CMapEditView *CurrentView;
|
||||
CPoint CurrentMousePos,LastMousePos;
|
||||
|
|
|
@ -108,5 +108,17 @@ BOOL operator==(sExpMapElem const &v1)
|
|||
};
|
||||
*/
|
||||
/*****************************************************************************/
|
||||
/*** Things ******************************************************************/
|
||||
/*****************************************************************************/
|
||||
struct sExpLayerActor
|
||||
{
|
||||
int Speed;
|
||||
int TurnRate;
|
||||
int Health;
|
||||
int AttackStrength;
|
||||
bool CollisionFlag;
|
||||
bool PlayerFlag;
|
||||
int Spare[8];
|
||||
};
|
||||
#endif
|
||||
|
||||
|
|
|
@ -5,6 +5,9 @@
|
|||
#include "mapedit.h"
|
||||
#include "GUILayerActor.h"
|
||||
|
||||
#include "MapEditDoc.h"
|
||||
#include "MainFrm.h"
|
||||
|
||||
#ifdef _DEBUG
|
||||
#define new DEBUG_NEW
|
||||
#undef THIS_FILE
|
||||
|
@ -18,9 +21,10 @@ static char THIS_FILE[] = __FILE__;
|
|||
CGUILayerActor::CGUILayerActor(CWnd* pParent /*=NULL*/)
|
||||
: CDialog(CGUILayerActor::IDD, pParent)
|
||||
{
|
||||
DisableCallback(true);
|
||||
//{{AFX_DATA_INIT(CGUILayerActor)
|
||||
// NOTE: the ClassWizard will add member initialization here
|
||||
//}}AFX_DATA_INIT
|
||||
DisableCallback(false);
|
||||
}
|
||||
|
||||
|
||||
|
@ -28,16 +32,70 @@ void CGUILayerActor::DoDataExchange(CDataExchange* pDX)
|
|||
{
|
||||
CDialog::DoDataExchange(pDX);
|
||||
//{{AFX_DATA_MAP(CGUILayerActor)
|
||||
// NOTE: the ClassWizard will add DDX and DDV calls here
|
||||
DDX_Control(pDX, IDC_ACTOR_COLLISION, m_Collision);
|
||||
DDX_Control(pDX, IDC_ACTOR_PLAYER, m_Player);
|
||||
DDX_Control(pDX, IDC_ACTOR_TURNRATE, m_TurnRate);
|
||||
DDX_Control(pDX, IDC_ACTOR_SPEED, m_Speed);
|
||||
DDX_Control(pDX, IDC_ACTOR_ATTACK, m_Attack);
|
||||
DDX_Control(pDX, IDC_ACTOR_HEALTH, m_Health);
|
||||
DDX_Control(pDX, IDC_LEVEL_ACTOR_LIST, m_LevelList);
|
||||
DDX_Control(pDX, IDC_ACTOR_POS_LIST, m_PosList);
|
||||
DDX_Control(pDX, IDC_ACTOR_LIST, m_List);
|
||||
//}}AFX_DATA_MAP
|
||||
}
|
||||
|
||||
|
||||
BEGIN_MESSAGE_MAP(CGUILayerActor, CDialog)
|
||||
//{{AFX_MSG_MAP(CGUILayerActor)
|
||||
// NOTE: the ClassWizard will add message map macros here
|
||||
ON_BN_CLICKED(IDC_ACTOR_DELETE, OnActorDelete)
|
||||
ON_BN_CLICKED(IDC_ACTOR_POS_UP, OnActorPosUp)
|
||||
ON_BN_CLICKED(IDC_ACTOR_POS_DOWN, OnActorPosDown)
|
||||
ON_BN_CLICKED(IDC_ACTOR_POS_DELETE, OnActorPosDelete)
|
||||
ON_EN_CHANGE(IDC_ACTOR_HEALTH, OnChangeParam)
|
||||
ON_CBN_SELCHANGE(IDC_ACTOR_LIST, OnSelchangeActorList)
|
||||
ON_CBN_SELCHANGE(IDC_LEVEL_ACTOR_LIST, OnSelchangeLevelActorList)
|
||||
ON_LBN_SELCHANGE(IDC_ACTOR_POS_LIST, OnSelchangeActorPosList)
|
||||
ON_EN_CHANGE(IDC_ACTOR_ATTACK, OnChangeParam)
|
||||
ON_BN_CLICKED(IDC_ACTOR_COLLISION, OnChangeParam)
|
||||
ON_EN_CHANGE(IDC_ACTOR_SPEED, OnChangeParam)
|
||||
ON_EN_CHANGE(IDC_ACTOR_TURNRATE, OnChangeParam)
|
||||
//}}AFX_MSG_MAP
|
||||
END_MESSAGE_MAP()
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
void CGUILayerActor::SetVal(CEdit &Dlg,int Val)
|
||||
{
|
||||
CString Str;
|
||||
if (!Dlg) return;
|
||||
DisableCallback(true);
|
||||
Str.Format("%i",Val);
|
||||
Dlg.SetWindowText(Str);
|
||||
DisableCallback(false);
|
||||
}
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
int CGUILayerActor::GetVal(CEdit &Dlg)
|
||||
{
|
||||
CString Str;
|
||||
int Val=0;
|
||||
if (!Dlg) return(0);
|
||||
Dlg.GetWindowText(Str);
|
||||
if (Str.GetLength())
|
||||
Val=atoi(Str);
|
||||
return(Val);
|
||||
}
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CGUILayerActor message handlers
|
||||
|
||||
void CGUILayerActor::OnSelchangeActorList() {theApp.GetCurrent()->Command(CmdMsg_ThingListSelect,m_List.GetCurSel());}
|
||||
void CGUILayerActor::OnActorDelete() {theApp.GetCurrent()->Command(CmdMsg_ThingListDelete,m_List.GetCurSel());}
|
||||
|
||||
void CGUILayerActor::OnSelchangeLevelActorList() {theApp.GetCurrent()->Command(CmdMsg_ThingLevelSelect,m_LevelList.GetCurSel());}
|
||||
|
||||
void CGUILayerActor::OnSelchangeActorPosList() {theApp.GetCurrent()->Command(CmdMsg_ThingPosSelect,m_PosList.GetCurSel());}
|
||||
void CGUILayerActor::OnActorPosUp() {theApp.GetCurrent()->Command(CmdMsg_ThingPosUp,m_PosList.GetCurSel());}
|
||||
void CGUILayerActor::OnActorPosDown() {theApp.GetCurrent()->Command(CmdMsg_ThingPosDown,m_PosList.GetCurSel());}
|
||||
void CGUILayerActor::OnActorPosDelete() {theApp.GetCurrent()->Command(CmdMsg_ThingPosDelete,m_PosList.GetCurSel());}
|
||||
|
||||
void CGUILayerActor::OnChangeParam() {if (!CallbackFlag) theApp.GetCurrent()->GUIChanged();}
|
||||
|
|
|
@ -19,7 +19,15 @@ public:
|
|||
// Dialog Data
|
||||
//{{AFX_DATA(CGUILayerActor)
|
||||
enum { IDD = IDD_LAYER_ACTOR };
|
||||
// NOTE: the ClassWizard will add data members here
|
||||
CButton m_Collision;
|
||||
CButton m_Player;
|
||||
CEdit m_TurnRate;
|
||||
CEdit m_Speed;
|
||||
CEdit m_Attack;
|
||||
CEdit m_Health;
|
||||
CComboBox m_LevelList;
|
||||
CListBox m_PosList;
|
||||
CComboBox m_List;
|
||||
//}}AFX_DATA
|
||||
|
||||
|
||||
|
@ -31,11 +39,24 @@ public:
|
|||
//}}AFX_VIRTUAL
|
||||
|
||||
// Implementation
|
||||
|
||||
public:
|
||||
void DisableCallback(bool f) {CallbackFlag=f;}
|
||||
void SetVal(CEdit &Dlg,int Number);
|
||||
int GetVal(CEdit &Dlg);
|
||||
protected:
|
||||
bool CallbackFlag;
|
||||
|
||||
// Generated message map functions
|
||||
//{{AFX_MSG(CGUILayerActor)
|
||||
// NOTE: the ClassWizard will add member functions here
|
||||
afx_msg void OnActorDelete();
|
||||
afx_msg void OnActorPosUp();
|
||||
afx_msg void OnActorPosDown();
|
||||
afx_msg void OnActorPosDelete();
|
||||
afx_msg void OnChangeParam();
|
||||
afx_msg void OnSelchangeActorList();
|
||||
afx_msg void OnSelchangeLevelActorList();
|
||||
afx_msg void OnSelchangeActorPosList();
|
||||
//}}AFX_MSG
|
||||
DECLARE_MESSAGE_MAP()
|
||||
};
|
||||
|
|
|
@ -30,9 +30,9 @@ void CGUINewMap::DoDataExchange(CDataExchange* pDX)
|
|||
CDialog::DoDataExchange(pDX);
|
||||
//{{AFX_DATA_MAP(CGUINewMap)
|
||||
DDX_Text(pDX, IDC_MAPSIZE_HEIGHT, m_Height);
|
||||
DDV_MinMaxUInt(pDX, m_Height, 34, 1024);
|
||||
DDV_MinMaxUInt(pDX, m_Height, 24, 1024);
|
||||
DDX_Text(pDX, IDC_MAPSIZE_WIDTH, m_Width);
|
||||
DDV_MinMaxUInt(pDX, m_Width, 24, 1024);
|
||||
DDV_MinMaxUInt(pDX, m_Width, 34, 1024);
|
||||
//}}AFX_DATA_MAP
|
||||
}
|
||||
|
||||
|
|
|
@ -22,29 +22,16 @@
|
|||
/*****************************************************************************/
|
||||
/*****************************************************************************/
|
||||
/*****************************************************************************/
|
||||
CLayerActor::CLayerActor(sLayerDef &Def) :CLayerThing(Def)
|
||||
CLayerActor::CLayerActor(sLayerDef &Def)
|
||||
{
|
||||
// CLayerThing::CLayerThing(_SubType,_Width,_Height);
|
||||
LoadThingScript("c:\\temp\\character.txt");
|
||||
InitLayer(Def);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
//CLayerActor::CLayerActor(CFile *File,int Version)
|
||||
//{
|
||||
// CLayerThing::CLayerThing(File,Version);
|
||||
//
|
||||
//}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerActor::Load(CFile *File,int Version)
|
||||
void CLayerActor::InitLayer(sLayerDef &Def)
|
||||
{
|
||||
// CLayerThing::Load(File,Version);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerActor::Save(CFile *File)
|
||||
{
|
||||
CLayerThing::Save(File);
|
||||
CLayerThing::InitLayer(Def);
|
||||
LoadThingScript(theApp.GetConfigStr("LayerScript","ActorScript"));
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
|
@ -52,50 +39,148 @@ void CLayerActor::InitSubView(CCore *Core)
|
|||
{
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerActor::LoadThingScript(const char *Filename)
|
||||
{
|
||||
CLayerThing::LoadThingScript(Filename);
|
||||
// CLayerThing::ThingScript.LoadAndImport(Filename);
|
||||
|
||||
int Count=ThingScript.GetGroupCount();
|
||||
for (int i=0; i<Count; i++)
|
||||
{
|
||||
char *Name=ThingScript.GetGroupName(i);
|
||||
char *Gfx=ThingScript.GetData(Name,"gfx");
|
||||
TRACE2("%s\t\t%s\n",Name,Gfx);
|
||||
if (Gfx) ThingBank->AddSet(Gfx);
|
||||
}
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
/*** Gui *********************************************************************/
|
||||
/*****************************************************************************/
|
||||
void CLayerActor::GUIInit(CCore *Core)
|
||||
{
|
||||
// Core->GUIAdd(GUIToolBar,IDD_TOOLBAR);
|
||||
GUI.DisableCallback(true);
|
||||
Core->GUIAdd(GUI,IDD_LAYER_ACTOR);
|
||||
GUI.DisableCallback(false);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerActor::GUIKill(CCore *Core)
|
||||
{
|
||||
// Core->GUIRemove(GUIToolBar,IDD_TOOLBAR);
|
||||
Core->GUIRemove(GUI,IDD_LAYER_ACTOR);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerActor::GUIUpdate(CCore *Core)
|
||||
{
|
||||
int i,ListSize;
|
||||
CComboBox &List=GUI.m_List;
|
||||
|
||||
// Setup Def Actor List
|
||||
ListSize=DefList.size();
|
||||
List.ResetContent();
|
||||
for (i=0; i<ListSize; i++)
|
||||
{
|
||||
List.AddString(DefList[i].Name);
|
||||
}
|
||||
List.SetCurSel(CurrentDefThing);
|
||||
|
||||
GUIThingUpdate();
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerActor::GUIThingDefClear()
|
||||
{
|
||||
CComboBox &List=GUI.m_List;
|
||||
CurrentDefThing=-1;
|
||||
List.SetCurSel(CurrentDefThing);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerActor::GUIThingUpdate()
|
||||
{
|
||||
int i,ListSize;
|
||||
CComboBox &List=GUI.m_LevelList;
|
||||
// Setup ThingList
|
||||
ListSize=ThingList.size();
|
||||
TRACE1("%i\n",ListSize);
|
||||
List.ResetContent();
|
||||
for (i=0; i<ListSize; i++)
|
||||
{
|
||||
|
||||
List.AddString(ThingList[i].Name);
|
||||
}
|
||||
List.SetCurSel(CurrentThing);
|
||||
GUIThingPointUpdate();
|
||||
// Params
|
||||
GUI.DisableCallback(true);
|
||||
if (CurrentThing!=-1)
|
||||
{
|
||||
sLayerThing &ThisThing=ThingList[CurrentThing];
|
||||
GUI.SetVal(GUI.m_Speed,ThisThing.Data.Speed);
|
||||
GUI.SetVal(GUI.m_TurnRate,ThisThing.Data.TurnRate);
|
||||
GUI.SetVal(GUI.m_Health,ThisThing.Data.Health);
|
||||
GUI.SetVal(GUI.m_Attack,ThisThing.Data.AttackStrength);
|
||||
GUI.m_Collision.SetCheck(ThisThing.Data.CollisionFlag);
|
||||
GUI.m_Player.SetCheck(ThisThing.Data.PlayerFlag);
|
||||
}
|
||||
else
|
||||
{
|
||||
GUI.m_Speed.SetWindowText("");
|
||||
GUI.m_TurnRate.SetWindowText("");
|
||||
GUI.m_Health.SetWindowText("");
|
||||
GUI.m_Attack.SetWindowText("");
|
||||
GUI.m_Collision.SetCheck(false);
|
||||
GUI.m_Player.SetCheck(false);
|
||||
}
|
||||
GUI.DisableCallback(false);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerActor::GUIThingPointUpdate()
|
||||
{
|
||||
int i,ListSize;
|
||||
sLayerThing &ThisThing=ThingList[CurrentThing];
|
||||
CListBox &List=GUI.m_PosList;
|
||||
|
||||
List.ResetContent();
|
||||
if (CurrentThing==-1)
|
||||
{
|
||||
}
|
||||
else
|
||||
{
|
||||
// Setup ThingPointList
|
||||
ListSize=ThisThing.XY.size();
|
||||
for (i=0; i<ListSize; i++)
|
||||
{
|
||||
CString Str;
|
||||
Str.Format("%i: %i, %i",i,ThisThing.XY[i].x,ThisThing.XY[i].y);
|
||||
List.AddString(Str);
|
||||
}
|
||||
List.SetCurSel(CurrentThingPoint);
|
||||
}
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerActor::GUIChanged(CCore *Core)
|
||||
{
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
/*****************************************************************************/
|
||||
/*****************************************************************************/
|
||||
void CLayerActor::Export(CCore *Core,CExport &Exp)
|
||||
if (CurrentThing!=-1)
|
||||
{
|
||||
sLayerThing &ThisThing=ThingList[CurrentThing];
|
||||
ThisThing.Data.Speed=GUI.GetVal(GUI.m_Speed);
|
||||
ThisThing.Data.TurnRate=GUI.GetVal(GUI.m_TurnRate);
|
||||
ThisThing.Data.Health=GUI.GetVal(GUI.m_Health);
|
||||
ThisThing.Data.AttackStrength=GUI.GetVal(GUI.m_Attack);
|
||||
ThisThing.Data.CollisionFlag=GUI.m_Collision.GetCheck()!=0;
|
||||
ThisThing.Data.PlayerFlag=GUI.m_Player.GetCheck()!=0;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
/*** Functions ***************************************************************/
|
||||
/*****************************************************************************/
|
||||
void CLayerActor::ExportThing(CExport &Exp,sLayerThing &ThisThing)
|
||||
{
|
||||
int i,ListSize=ThisThing.XY.size();
|
||||
sExpLayerActor OutThing;
|
||||
// Point List
|
||||
Exp.Write(&ListSize,sizeof(int));
|
||||
for (i=0 ;i<ListSize; i++)
|
||||
{
|
||||
Exp.Write(&ThisThing.XY[i],sizeof(CPoint));
|
||||
}
|
||||
// Thing
|
||||
OutThing.Health=ThisThing.Data.Health;
|
||||
OutThing.AttackStrength=ThisThing.Data.AttackStrength;
|
||||
OutThing.Speed=ThisThing.Data.Speed;
|
||||
OutThing.TurnRate=ThisThing.Data.TurnRate;
|
||||
OutThing.CollisionFlag=ThisThing.Data.CollisionFlag;
|
||||
OutThing.PlayerFlag=ThisThing.Data.PlayerFlag;
|
||||
Exp.Write(&OutThing,sizeof(sExpLayerActor));
|
||||
}
|
||||
|
|
|
@ -8,32 +8,34 @@
|
|||
#include "LayerThing.h"
|
||||
#include "Layer.h"
|
||||
#include "MapEdit.h"
|
||||
#include "GUIToolbar.h"
|
||||
#include "GUILayerActor.h"
|
||||
#include "Elem.h"
|
||||
|
||||
/*****************************************************************************/
|
||||
class CLayerActor : public CLayerThing
|
||||
{
|
||||
public:
|
||||
// CLayerActor(int Type,int SubType,int Width,int Height);
|
||||
CLayerActor(sLayerDef &Def);
|
||||
CLayerActor(CFile *File,int Version) {Load(File,Version);}
|
||||
|
||||
void InitLayer(sLayerDef &Def);
|
||||
void InitSubView(CCore *Core);
|
||||
|
||||
void GUIInit(CCore *Core);
|
||||
void GUIKill(CCore *Core);
|
||||
void GUIUpdate(CCore *Core);
|
||||
void GUIChanged(CCore *Core);
|
||||
bool GUIReady();
|
||||
|
||||
void Load(CFile *File,int Version);
|
||||
void Save(CFile *File);
|
||||
void LoadThingScript(const char *Filename);
|
||||
void GUIThingDefClear();
|
||||
void GUIThingUpdate();
|
||||
void GUIThingPointUpdate();
|
||||
|
||||
void ExportThing(CExport &Exp,sLayerThing &ThisThing);
|
||||
|
||||
void Export(CCore *Core,CExport &Exp);
|
||||
|
||||
protected:
|
||||
CGUIToolBar GUIToolBar;
|
||||
CGUILayerActor GUI;
|
||||
|
||||
};
|
||||
|
||||
|
|
|
@ -21,8 +21,6 @@
|
|||
#include "Select.h"
|
||||
#include "Export.h"
|
||||
|
||||
GString ColFName="Collision.bmp";
|
||||
|
||||
/*****************************************************************************/
|
||||
/*****************************************************************************/
|
||||
/*****************************************************************************/
|
||||
|
@ -48,7 +46,7 @@ GString Filename;
|
|||
SubView=TileBank;
|
||||
|
||||
Core->GetExecPath(Filename);
|
||||
Filename+=ColFName;
|
||||
Filename+=theApp.GetConfigStr("FileLocation","Collision");
|
||||
TileBank->AddSet(Filename);
|
||||
}
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
/******************/
|
||||
/**********************/
|
||||
/*** Layer Item ***/
|
||||
/******************/
|
||||
/**********************/
|
||||
|
||||
#include "stdafx.h"
|
||||
#include <Vector3.h>
|
||||
|
@ -22,28 +22,16 @@
|
|||
/*****************************************************************************/
|
||||
/*****************************************************************************/
|
||||
/*****************************************************************************/
|
||||
// New Layer
|
||||
CLayerItem::CLayerItem(sLayerDef &Def) : CLayerThing (Def)
|
||||
CLayerItem::CLayerItem(sLayerDef &Def)
|
||||
{
|
||||
LoadThingScript("c:\\temp\\character.txt");
|
||||
InitLayer(Def);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
//CLayerItem::CLayerItem(CFile *File,int Version) :CLayerThing (File,Version)
|
||||
//{
|
||||
//
|
||||
//}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerItem::Load(CFile *File,int Version)
|
||||
void CLayerItem::InitLayer(sLayerDef &Def)
|
||||
{
|
||||
CLayerThing::Load(File,Version);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerItem::Save(CFile *File)
|
||||
{
|
||||
CLayerThing::Save(File);
|
||||
CLayerThing::InitLayer(Def);
|
||||
LoadThingScript(theApp.GetConfigStr("LayerScript","ItemScript"));
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
|
@ -51,51 +39,159 @@ void CLayerItem::InitSubView(CCore *Core)
|
|||
{
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerItem::LoadThingScript(const char *Filename)
|
||||
{
|
||||
CLayerThing::LoadThingScript(Filename);
|
||||
// CLayerThing::ThingScript.LoadAndImport(Filename);
|
||||
|
||||
int Count=ThingScript.GetGroupCount();
|
||||
for (int i=0; i<Count; i++)
|
||||
{
|
||||
char *Name=ThingScript.GetGroupName(i);
|
||||
char *Gfx=ThingScript.GetData(Name,"gfx");
|
||||
TRACE2("%s\t\t%s\n",Name,Gfx);
|
||||
if (Gfx)
|
||||
ThingBank->AddSet(Gfx);
|
||||
}
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
/*** Gui *********************************************************************/
|
||||
/*****************************************************************************/
|
||||
void CLayerItem::GUIInit(CCore *Core)
|
||||
{
|
||||
// Core->GUIAdd(GUIToolBar,IDD_TOOLBAR);
|
||||
// GUI.DisableCallback(true);
|
||||
// Core->GUIAdd(GUI,IDD_LAYER_Item);
|
||||
// GUI.DisableCallback(false);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerItem::GUIKill(CCore *Core)
|
||||
{
|
||||
// Core->GUIRemove(GUIToolBar,IDD_TOOLBAR);
|
||||
// Core->GUIRemove(GUI,IDD_LAYER_Item);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerItem::GUIUpdate(CCore *Core)
|
||||
{
|
||||
/*
|
||||
int i,ListSize;
|
||||
CComboBox &List=GUI.m_List;
|
||||
|
||||
// Setup Def Item List
|
||||
ListSize=DefList.size();
|
||||
List.ResetContent();
|
||||
for (i=0; i<ListSize; i++)
|
||||
{
|
||||
List.AddString(DefList[i].Name);
|
||||
}
|
||||
List.SetCurSel(CurrentDefThing);
|
||||
|
||||
GUIThingUpdate();
|
||||
*/
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerItem::GUIThingDefClear()
|
||||
{
|
||||
/*
|
||||
CComboBox &List=GUI.m_List;
|
||||
CurrentDefThing=-1;
|
||||
List.SetCurSel(CurrentDefThing);
|
||||
*/
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerItem::GUIThingUpdate()
|
||||
{
|
||||
/*
|
||||
int i,ListSize;
|
||||
CComboBox &List=GUI.m_LevelList;
|
||||
// Setup ThingList
|
||||
ListSize=ThingList.size();
|
||||
TRACE1("%i\n",ListSize);
|
||||
List.ResetContent();
|
||||
for (i=0; i<ListSize; i++)
|
||||
{
|
||||
|
||||
List.AddString(ThingList[i].Name);
|
||||
}
|
||||
List.SetCurSel(CurrentThing);
|
||||
GUIThingPointUpdate();
|
||||
// Params
|
||||
GUI.DisableCallback(true);
|
||||
if (CurrentThing!=-1)
|
||||
{
|
||||
sLayerThing &ThisThing=ThingList[CurrentThing];
|
||||
GUI.SetVal(GUI.m_Speed,ThisThing.Data.Speed);
|
||||
GUI.SetVal(GUI.m_TurnRate,ThisThing.Data.TurnRate);
|
||||
GUI.SetVal(GUI.m_Health,ThisThing.Data.Health);
|
||||
GUI.SetVal(GUI.m_Attack,ThisThing.Data.AttackStrength);
|
||||
GUI.m_Collision.SetCheck(ThisThing.Data.CollisionFlag);
|
||||
GUI.m_Player.SetCheck(ThisThing.Data.PlayerFlag);
|
||||
}
|
||||
else
|
||||
{
|
||||
GUI.m_Speed.SetWindowText("");
|
||||
GUI.m_TurnRate.SetWindowText("");
|
||||
GUI.m_Health.SetWindowText("");
|
||||
GUI.m_Attack.SetWindowText("");
|
||||
GUI.m_Collision.SetCheck(false);
|
||||
GUI.m_Player.SetCheck(false);
|
||||
}
|
||||
GUI.DisableCallback(false);
|
||||
*/
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerItem::GUIThingPointUpdate()
|
||||
{
|
||||
/*
|
||||
int i,ListSize;
|
||||
sLayerThing &ThisThing=ThingList[CurrentThing];
|
||||
CListBox &List=GUI.m_PosList;
|
||||
|
||||
List.ResetContent();
|
||||
if (CurrentThing==-1)
|
||||
{
|
||||
}
|
||||
else
|
||||
{
|
||||
// Setup ThingPointList
|
||||
ListSize=ThisThing.XY.size();
|
||||
for (i=0; i<ListSize; i++)
|
||||
{
|
||||
CString Str;
|
||||
Str.Format("%i: %i, %i",i,ThisThing.XY[i].x,ThisThing.XY[i].y);
|
||||
List.AddString(Str);
|
||||
}
|
||||
List.SetCurSel(CurrentThingPoint);
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerItem::GUIChanged(CCore *Core)
|
||||
{
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
/*****************************************************************************/
|
||||
/*****************************************************************************/
|
||||
void CLayerItem::Export(CCore *Core,CExport &Exp)
|
||||
/*
|
||||
if (CurrentThing!=-1)
|
||||
{
|
||||
|
||||
sLayerThing &ThisThing=ThingList[CurrentThing];
|
||||
ThisThing.Data.Speed=GUI.GetVal(GUI.m_Speed);
|
||||
ThisThing.Data.TurnRate=GUI.GetVal(GUI.m_TurnRate);
|
||||
ThisThing.Data.Health=GUI.GetVal(GUI.m_Health);
|
||||
ThisThing.Data.AttackStrength=GUI.GetVal(GUI.m_Attack);
|
||||
ThisThing.Data.CollisionFlag=GUI.m_Collision.GetCheck()!=0;
|
||||
ThisThing.Data.PlayerFlag=GUI.m_Player.GetCheck()!=0;
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
/*** Functions ***************************************************************/
|
||||
/*****************************************************************************/
|
||||
void CLayerItem::ExportThing(CExport &Exp,sLayerThing &ThisThing)
|
||||
{
|
||||
/*
|
||||
int i,ListSize=ThisThing.XY.size();
|
||||
sExpLayerItem OutThing;
|
||||
// Point List
|
||||
Exp.Write(&ListSize,sizeof(int));
|
||||
for (i=0 ;i<ListSize; i++)
|
||||
{
|
||||
Exp.Write(&ThisThing.XY[i],sizeof(CPoint));
|
||||
}
|
||||
// Thing
|
||||
OutThing.Health=ThisThing.Data.Health;
|
||||
OutThing.AttackStrength=ThisThing.Data.AttackStrength;
|
||||
OutThing.Speed=ThisThing.Data.Speed;
|
||||
OutThing.TurnRate=ThisThing.Data.TurnRate;
|
||||
OutThing.CollisionFlag=ThisThing.Data.CollisionFlag;
|
||||
OutThing.PlayerFlag=ThisThing.Data.PlayerFlag;
|
||||
Exp.Write(&OutThing,sizeof(sExpLayerItem));
|
||||
*/
|
||||
}
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
/******************/
|
||||
/*******************/
|
||||
/*** Layer Item ***/
|
||||
/******************/
|
||||
/*******************/
|
||||
|
||||
#ifndef __LAYER_ITEM_HEADER__
|
||||
#define __LAYER_ITEM_HEADER__
|
||||
|
@ -8,7 +8,7 @@
|
|||
#include "LayerThing.h"
|
||||
#include "Layer.h"
|
||||
#include "MapEdit.h"
|
||||
#include "GUIToolbar.h"
|
||||
//#include "GUILayerItem.h"
|
||||
#include "Elem.h"
|
||||
|
||||
/*****************************************************************************/
|
||||
|
@ -18,21 +18,24 @@ public:
|
|||
CLayerItem(sLayerDef &Def);
|
||||
CLayerItem(CFile *File,int Version) {Load(File,Version);}
|
||||
|
||||
void InitLayer(sLayerDef &Def);
|
||||
void InitSubView(CCore *Core);
|
||||
|
||||
void GUIInit(CCore *Core);
|
||||
void GUIKill(CCore *Core);
|
||||
void GUIUpdate(CCore *Core);
|
||||
void GUIChanged(CCore *Core);
|
||||
bool GUIReady();
|
||||
|
||||
void Load(CFile *File,int Version);
|
||||
void Save(CFile *File);
|
||||
void LoadThingScript(const char *Filename);
|
||||
void GUIThingDefClear();
|
||||
void GUIThingUpdate();
|
||||
void GUIThingPointUpdate();
|
||||
|
||||
void ExportThing(CExport &Exp,sLayerThing &ThisThing);
|
||||
|
||||
void Export(CCore *Core,CExport &Exp);
|
||||
|
||||
protected:
|
||||
CGUIToolBar GUIToolBar;
|
||||
// CGUILayerItem GUI;
|
||||
|
||||
};
|
||||
|
||||
|
|
|
@ -22,27 +22,16 @@
|
|||
/*****************************************************************************/
|
||||
/*****************************************************************************/
|
||||
/*****************************************************************************/
|
||||
// New Layer
|
||||
CLayerPlatform::CLayerPlatform(sLayerDef &Def) : CLayerThing(Def)
|
||||
CLayerPlatform::CLayerPlatform(sLayerDef &Def)
|
||||
{
|
||||
LoadThingScript("c:\\temp\\character.txt");
|
||||
InitLayer(Def);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
//CLayerPlatform::CLayerPlatform(CFile *File,int Version) :CLayerThing (File,Version)
|
||||
//{
|
||||
//}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerPlatform::Load(CFile *File,int Version)
|
||||
void CLayerPlatform::InitLayer(sLayerDef &Def)
|
||||
{
|
||||
CLayerThing::Load(File,Version);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerPlatform::Save(CFile *File)
|
||||
{
|
||||
CLayerThing::Save(File);
|
||||
CLayerThing::InitLayer(Def);
|
||||
LoadThingScript(theApp.GetConfigStr("LayerScript","PlatformScript"));
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
|
@ -50,51 +39,159 @@ void CLayerPlatform::InitSubView(CCore *Core)
|
|||
{
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerPlatform::LoadThingScript(const char *Filename)
|
||||
{
|
||||
CLayerThing::LoadThingScript(Filename);
|
||||
// CLayerThing::ThingScript.LoadAndImport(Filename);
|
||||
|
||||
int Count=ThingScript.GetGroupCount();
|
||||
for (int i=0; i<Count; i++)
|
||||
{
|
||||
char *Name=ThingScript.GetGroupName(i);
|
||||
char *Gfx=ThingScript.GetData(Name,"gfx");
|
||||
TRACE2("%s\t\t%s\n",Name,Gfx);
|
||||
if (Gfx)
|
||||
ThingBank->AddSet(Gfx);
|
||||
}
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
/*** Gui *********************************************************************/
|
||||
/*****************************************************************************/
|
||||
void CLayerPlatform::GUIInit(CCore *Core)
|
||||
{
|
||||
// Core->GUIAdd(GUIToolBar,IDD_TOOLBAR);
|
||||
// GUI.DisableCallback(true);
|
||||
// Core->GUIAdd(GUI,IDD_LAYER_Platform);
|
||||
// GUI.DisableCallback(false);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerPlatform::GUIKill(CCore *Core)
|
||||
{
|
||||
// Core->GUIRemove(GUIToolBar,IDD_TOOLBAR);
|
||||
// Core->GUIRemove(GUI,IDD_LAYER_Platform);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerPlatform::GUIUpdate(CCore *Core)
|
||||
{
|
||||
/*
|
||||
int i,ListSize;
|
||||
CComboBox &List=GUI.m_List;
|
||||
|
||||
// Setup Def Platform List
|
||||
ListSize=DefList.size();
|
||||
List.ResetContent();
|
||||
for (i=0; i<ListSize; i++)
|
||||
{
|
||||
List.AddString(DefList[i].Name);
|
||||
}
|
||||
List.SetCurSel(CurrentDefThing);
|
||||
|
||||
GUIThingUpdate();
|
||||
*/
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerPlatform::GUIThingDefClear()
|
||||
{
|
||||
/*
|
||||
CComboBox &List=GUI.m_List;
|
||||
CurrentDefThing=-1;
|
||||
List.SetCurSel(CurrentDefThing);
|
||||
*/
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerPlatform::GUIThingUpdate()
|
||||
{
|
||||
/*
|
||||
int i,ListSize;
|
||||
CComboBox &List=GUI.m_LevelList;
|
||||
// Setup ThingList
|
||||
ListSize=ThingList.size();
|
||||
TRACE1("%i\n",ListSize);
|
||||
List.ResetContent();
|
||||
for (i=0; i<ListSize; i++)
|
||||
{
|
||||
|
||||
List.AddString(ThingList[i].Name);
|
||||
}
|
||||
List.SetCurSel(CurrentThing);
|
||||
GUIThingPointUpdate();
|
||||
// Params
|
||||
GUI.DisableCallback(true);
|
||||
if (CurrentThing!=-1)
|
||||
{
|
||||
sLayerThing &ThisThing=ThingList[CurrentThing];
|
||||
GUI.SetVal(GUI.m_Speed,ThisThing.Data.Speed);
|
||||
GUI.SetVal(GUI.m_TurnRate,ThisThing.Data.TurnRate);
|
||||
GUI.SetVal(GUI.m_Health,ThisThing.Data.Health);
|
||||
GUI.SetVal(GUI.m_Attack,ThisThing.Data.AttackStrength);
|
||||
GUI.m_Collision.SetCheck(ThisThing.Data.CollisionFlag);
|
||||
GUI.m_Player.SetCheck(ThisThing.Data.PlayerFlag);
|
||||
}
|
||||
else
|
||||
{
|
||||
GUI.m_Speed.SetWindowText("");
|
||||
GUI.m_TurnRate.SetWindowText("");
|
||||
GUI.m_Health.SetWindowText("");
|
||||
GUI.m_Attack.SetWindowText("");
|
||||
GUI.m_Collision.SetCheck(false);
|
||||
GUI.m_Player.SetCheck(false);
|
||||
}
|
||||
GUI.DisableCallback(false);
|
||||
*/
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerPlatform::GUIThingPointUpdate()
|
||||
{
|
||||
/*
|
||||
int i,ListSize;
|
||||
sLayerThing &ThisThing=ThingList[CurrentThing];
|
||||
CListBox &List=GUI.m_PosList;
|
||||
|
||||
List.ResetContent();
|
||||
if (CurrentThing==-1)
|
||||
{
|
||||
}
|
||||
else
|
||||
{
|
||||
// Setup ThingPointList
|
||||
ListSize=ThisThing.XY.size();
|
||||
for (i=0; i<ListSize; i++)
|
||||
{
|
||||
CString Str;
|
||||
Str.Format("%i: %i, %i",i,ThisThing.XY[i].x,ThisThing.XY[i].y);
|
||||
List.AddString(Str);
|
||||
}
|
||||
List.SetCurSel(CurrentThingPoint);
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerPlatform::GUIChanged(CCore *Core)
|
||||
{
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
/*****************************************************************************/
|
||||
/*****************************************************************************/
|
||||
void CLayerPlatform::Export(CCore *Core,CExport &Exp)
|
||||
/*
|
||||
if (CurrentThing!=-1)
|
||||
{
|
||||
|
||||
sLayerThing &ThisThing=ThingList[CurrentThing];
|
||||
ThisThing.Data.Speed=GUI.GetVal(GUI.m_Speed);
|
||||
ThisThing.Data.TurnRate=GUI.GetVal(GUI.m_TurnRate);
|
||||
ThisThing.Data.Health=GUI.GetVal(GUI.m_Health);
|
||||
ThisThing.Data.AttackStrength=GUI.GetVal(GUI.m_Attack);
|
||||
ThisThing.Data.CollisionFlag=GUI.m_Collision.GetCheck()!=0;
|
||||
ThisThing.Data.PlayerFlag=GUI.m_Player.GetCheck()!=0;
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
/*** Functions ***************************************************************/
|
||||
/*****************************************************************************/
|
||||
void CLayerPlatform::ExportThing(CExport &Exp,sLayerThing &ThisThing)
|
||||
{
|
||||
/*
|
||||
int i,ListSize=ThisThing.XY.size();
|
||||
sExpLayerPlatform OutThing;
|
||||
// Point List
|
||||
Exp.Write(&ListSize,sizeof(int));
|
||||
for (i=0 ;i<ListSize; i++)
|
||||
{
|
||||
Exp.Write(&ThisThing.XY[i],sizeof(CPoint));
|
||||
}
|
||||
// Thing
|
||||
OutThing.Health=ThisThing.Data.Health;
|
||||
OutThing.AttackStrength=ThisThing.Data.AttackStrength;
|
||||
OutThing.Speed=ThisThing.Data.Speed;
|
||||
OutThing.TurnRate=ThisThing.Data.TurnRate;
|
||||
OutThing.CollisionFlag=ThisThing.Data.CollisionFlag;
|
||||
OutThing.PlayerFlag=ThisThing.Data.PlayerFlag;
|
||||
Exp.Write(&OutThing,sizeof(sExpLayerPlatform));
|
||||
*/
|
||||
}
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
/**********************/
|
||||
/*******************/
|
||||
/*** Layer Platform ***/
|
||||
/**********************/
|
||||
/*******************/
|
||||
|
||||
#ifndef __LAYER_PLATFORM_HEADER__
|
||||
#define __LAYER_PLATFORM_HEADER__
|
||||
|
@ -8,7 +8,7 @@
|
|||
#include "LayerThing.h"
|
||||
#include "Layer.h"
|
||||
#include "MapEdit.h"
|
||||
#include "GUIToolbar.h"
|
||||
//#include "GUILayerPlatform.h"
|
||||
#include "Elem.h"
|
||||
|
||||
/*****************************************************************************/
|
||||
|
@ -18,21 +18,24 @@ public:
|
|||
CLayerPlatform(sLayerDef &Def);
|
||||
CLayerPlatform(CFile *File,int Version) {Load(File,Version);}
|
||||
|
||||
void InitLayer(sLayerDef &Def);
|
||||
void InitSubView(CCore *Core);
|
||||
|
||||
void GUIInit(CCore *Core);
|
||||
void GUIKill(CCore *Core);
|
||||
void GUIUpdate(CCore *Core);
|
||||
void GUIChanged(CCore *Core);
|
||||
bool GUIReady();
|
||||
|
||||
void Load(CFile *File,int Version);
|
||||
void Save(CFile *File);
|
||||
void LoadThingScript(const char *Filename);
|
||||
void GUIThingDefClear();
|
||||
void GUIThingUpdate();
|
||||
void GUIThingPointUpdate();
|
||||
|
||||
void ExportThing(CExport &Exp,sLayerThing &ThisThing);
|
||||
|
||||
void Export(CCore *Core,CExport &Exp);
|
||||
|
||||
protected:
|
||||
CGUIToolBar GUIToolBar;
|
||||
// CGUILayerPlatform GUI;
|
||||
|
||||
};
|
||||
|
||||
|
|
|
@ -23,19 +23,11 @@
|
|||
/*****************************************************************************/
|
||||
/*****************************************************************************/
|
||||
/*****************************************************************************/
|
||||
// New Layer
|
||||
CLayerThing::CLayerThing(sLayerDef &Def)
|
||||
{
|
||||
InitLayer(Def);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
// Load Layer
|
||||
//CLayerThing::CLayerThing(CFile *File,int Version)
|
||||
//{
|
||||
//Load(File,Version);
|
||||
//}
|
||||
|
||||
/*****************************************************************************/
|
||||
CLayerThing::~CLayerThing()
|
||||
{
|
||||
|
@ -46,26 +38,116 @@ CLayerThing::~CLayerThing()
|
|||
/*****************************************************************************/
|
||||
void CLayerThing::InitLayer(sLayerDef &Def)
|
||||
{
|
||||
CLayer::InitLayer(Def);
|
||||
Mode=MouseModeNormal;
|
||||
LayerDef.Width=Width;
|
||||
LayerDef.Height=Height;
|
||||
ThingBank=new CElemBank(-1,-1,false,true);
|
||||
Cursor.XY.resize(1);
|
||||
Cursor.ElemID=-1;
|
||||
CurrentDefThing=-1;
|
||||
CurrentThing=-1;
|
||||
CurrentPoint=0;
|
||||
CurrentThingPoint=0;
|
||||
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerThing::Load(CFile *File,int Version)
|
||||
{
|
||||
int i,ListSize;
|
||||
|
||||
File->Read(&Mode,sizeof(MouseMode));
|
||||
File->Read(&CurrentDefThing,sizeof(int));
|
||||
File->Read(&CurrentThing,sizeof(int));
|
||||
File->Read(&CurrentThingPoint,sizeof(int));
|
||||
|
||||
File->Read(&ListSize,sizeof(int));
|
||||
ThingList.resize(ListSize);
|
||||
|
||||
// Load Data
|
||||
for (i=0;i<ListSize;i++)
|
||||
{
|
||||
sLayerThing &ThisThing=ThingList[i];
|
||||
LoadThing(File,Version,ThisThing);
|
||||
File->Read(&ThisThing.Data,sizeof(sLayerThingData));
|
||||
}
|
||||
LoadThingNames(File,Version);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerThing::LoadThing(CFile *File,int Version,sLayerThing &ThisThing)
|
||||
{
|
||||
int i,ListSize;
|
||||
File->Read(&ListSize,sizeof(int));
|
||||
ThisThing.XY.resize(ListSize);
|
||||
for (i=0 ;i<ListSize; i++)
|
||||
{
|
||||
File->Read(&ThisThing.XY[i],sizeof(CPoint));
|
||||
}
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerThing::LoadThingNames(CFile *File,int Version)
|
||||
{
|
||||
int i,ListSize=ThingList.size();
|
||||
|
||||
for (i=0;i<ListSize;i++)
|
||||
{
|
||||
char c=1;
|
||||
sLayerThing &ThisThing=ThingList[i];
|
||||
GString &ThisName=ThisThing.Name;
|
||||
|
||||
while (c)
|
||||
{
|
||||
File->Read(&c,1);
|
||||
ThisName.Append(c);
|
||||
}
|
||||
// Update Gfx ID
|
||||
int Idx=FindDefThing(ThisName);
|
||||
ThisThing.ElemID=DefList[Idx].ElemID;
|
||||
}
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerThing::Save(CFile *File)
|
||||
{
|
||||
int i,ListSize=ThingList.size();
|
||||
// Always Save current version
|
||||
File->Write(&Mode,sizeof(MouseMode));
|
||||
File->Write(&CurrentDefThing,sizeof(int));
|
||||
File->Write(&CurrentThing,sizeof(int));
|
||||
File->Write(&CurrentThingPoint,sizeof(int));
|
||||
|
||||
File->Write(&ListSize,sizeof(int));
|
||||
for (i=0;i<ListSize; i++)
|
||||
{
|
||||
sLayerThing &ThisThing=ThingList[i];
|
||||
SaveThing(File,ThisThing);
|
||||
File->Write(&ThisThing.Data,sizeof(sLayerThingData));
|
||||
}
|
||||
SaveThingNames(File);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerThing::SaveThing(CFile *File,sLayerThing &ThisThing)
|
||||
{
|
||||
int i,ListSize=ThisThing.XY.size();
|
||||
File->Write(&ListSize,sizeof(int));
|
||||
for (i=0 ;i<ListSize; i++)
|
||||
{
|
||||
File->Write(&ThisThing.XY[i],sizeof(CPoint));
|
||||
}
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerThing::SaveThingNames(CFile *File)
|
||||
{
|
||||
int i,ListSize=ThingList.size();
|
||||
|
||||
for (i=0; i<ListSize; i++)
|
||||
{
|
||||
char Txt[256];
|
||||
sprintf(Txt,ThingList[i].Name);
|
||||
File->Write(Txt,strlen(Txt)+1);
|
||||
}
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
|
@ -77,6 +159,40 @@ void CLayerThing::InitSubView(CCore *Core)
|
|||
void CLayerThing::LoadThingScript(const char *Filename)
|
||||
{
|
||||
ThingScript.LoadAndImport(Filename);
|
||||
|
||||
int i,ListSize=ThingScript.GetGroupCount();
|
||||
DefList.resize(ListSize);
|
||||
|
||||
for (i=0; i<ListSize; i++)
|
||||
{
|
||||
sLayerThing &ThisDef=DefList[i];
|
||||
|
||||
char *Name=ThingScript.GetGroupName(i);
|
||||
char *Gfx=ThingScript.GetStr(Name,"gfx");
|
||||
|
||||
ThisDef.Name=Name;
|
||||
ThisDef.Data.WaypointFlag=ThingScript.GetInt(Name,"WayPoints")==1;
|
||||
ThisDef.Data.Speed=ThingScript.GetInt(Name,"Speed");
|
||||
ThisDef.Data.TurnRate=ThingScript.GetInt(Name,"TurnRate");
|
||||
ThisDef.Data.Health=ThingScript.GetInt(Name,"Health");
|
||||
ThisDef.Data.AttackStrength=ThingScript.GetInt(Name,"AttackStrength");
|
||||
ThisDef.Data.PlayerFlag=ThingScript.GetInt(Name,"Player")==1;
|
||||
ThisDef.Data.CollisionFlag=ThingScript.GetInt(Name,"Collision")==1;
|
||||
|
||||
ThisDef.XY.resize(1);
|
||||
TRACE2("%s\t\t%s\n",Name,Gfx);
|
||||
ThisDef.ElemID=ThingBank->GetSetCount();
|
||||
if (Gfx)
|
||||
{
|
||||
ThingBank->AddSet(Gfx);
|
||||
}
|
||||
else
|
||||
{
|
||||
TRACE1("BAD %s\n",Name);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
|
@ -87,7 +203,6 @@ void CLayerThing::Render(CCore *Core,Vector3 &CamPos,bool Is3d)
|
|||
Vector3 ThisCam=Core->OffsetCam(CamPos,GetScaleFactor());
|
||||
int i,ListSize=ThingList.size();
|
||||
|
||||
// Is3d&=Render3dFlag;
|
||||
for (i=0; i<ListSize; i++)
|
||||
{
|
||||
RenderThing(Core,ThisCam,ThingList[i],Is3d,i==CurrentThing);
|
||||
|
@ -102,7 +217,6 @@ float ZoomH=Core->GetZoomH();
|
|||
float ScrOfsX=(ZoomW/2);
|
||||
float ScrOfsY=(ZoomH/2);
|
||||
Vector3 &Scale=Core->GetScaleVector();
|
||||
CElemBank *IconBank=Core->GetIconBank();
|
||||
|
||||
if (ThingBank->NeedLoad()) ThingBank->LoadAllSets(Core);
|
||||
|
||||
|
@ -126,11 +240,11 @@ int ListSize=ThisThing.XY.size();
|
|||
else
|
||||
glColor4f(1,1,1,0.5);
|
||||
|
||||
IconBank->RenderElem(0,i,0,Render3d);
|
||||
Core->RenderNumber(i);
|
||||
if (i==0)
|
||||
{
|
||||
glColor4f(1,1,1,1); // Set default Color
|
||||
ThingBank->RenderElem(ThisThing.Type,0,0,Render3d);
|
||||
ThingBank->RenderElem(ThisThing.ElemID,0,0,Render3d);
|
||||
}
|
||||
glPopMatrix();
|
||||
}
|
||||
|
@ -144,6 +258,7 @@ int ListSize=ThisThing.XY.size();
|
|||
void CLayerThing::GUIInit(CCore *Core)
|
||||
{
|
||||
// Core->GUIAdd(GUIToolBar,IDD_TOOLBAR);
|
||||
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
|
@ -169,19 +284,21 @@ bool CLayerThing::LButtonControl(CCore *Core,UINT nFlags, CPoint &CursorPos,bool
|
|||
{
|
||||
bool Ret=false;
|
||||
|
||||
if (!DownFlag) return(false);
|
||||
switch(Mode)
|
||||
{
|
||||
case MouseModeNormal:
|
||||
if (DownFlag)
|
||||
{
|
||||
if (CurrentThing==-1)
|
||||
SelectThing(CursorPos);
|
||||
GUIThingUpdate();
|
||||
break;
|
||||
case MouseModeNew:
|
||||
AddThing(CursorPos);
|
||||
else
|
||||
AddThingPoint(CursorPos);
|
||||
|
||||
}
|
||||
GUIThingDefClear();
|
||||
GUIThingUpdate();
|
||||
break;
|
||||
case MouseModePoints:
|
||||
AddThingPoint(CursorPos);
|
||||
GUIThingPointUpdate();
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
@ -193,21 +310,9 @@ bool Ret=false;
|
|||
/*****************************************************************************/
|
||||
bool CLayerThing::RButtonControl(CCore *Core,UINT nFlags, CPoint &CursorPos,bool DownFlag)
|
||||
{
|
||||
bool Ret=FALSE;
|
||||
|
||||
switch(Mode)
|
||||
{
|
||||
case MouseModeNormal:
|
||||
if (DownFlag)
|
||||
{
|
||||
SelectThing(CursorPos);
|
||||
}
|
||||
break;
|
||||
case MouseModePoints:
|
||||
break;
|
||||
}
|
||||
|
||||
return(Ret);
|
||||
if (!DownFlag) return(false);
|
||||
Cancel();
|
||||
return(true);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
|
@ -219,13 +324,14 @@ bool Ret=false;
|
|||
{
|
||||
if (nFlags & MK_LBUTTON) // Drag
|
||||
{
|
||||
UpdatePos(CursorPos,CurrentThing,CurrentPoint,true);
|
||||
UpdatePos(CursorPos,CurrentThing,CurrentThingPoint,(nFlags & MK_CONTROL)!=0);
|
||||
GUIThingPointUpdate();
|
||||
Ret=true;
|
||||
}
|
||||
else
|
||||
if (nFlags & MK_RBUTTON) // Cancel
|
||||
{
|
||||
CurrentThing=-1;
|
||||
Cancel();
|
||||
Ret=true;
|
||||
}
|
||||
}
|
||||
|
@ -233,51 +339,98 @@ bool Ret=false;
|
|||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
bool CLayerThing::Command(int CmdMsg,CCore *Core,int Param0,int Param1)
|
||||
void CLayerThing::Cancel()
|
||||
{
|
||||
bool Ret=false;
|
||||
/*
|
||||
switch(CmdMsg)
|
||||
switch(Mode)
|
||||
{
|
||||
case CmdMsg_SetMode:
|
||||
// Mode=(MouseMode)Param0;
|
||||
// Core->GUIUpdate();
|
||||
// break;
|
||||
// case CmdMsg_SubViewSet:
|
||||
// Ret=ThingBank->Command(CmdMsg,Core,Param0,Param1);
|
||||
case MouseModeNormal:
|
||||
CurrentThing=-1;
|
||||
case MouseModeNew:
|
||||
case MouseModePoints:
|
||||
Mode=MouseModeNormal;
|
||||
CurrentThingPoint=0;
|
||||
GUIThingDefClear();
|
||||
GUIThingUpdate();
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
bool CLayerThing::Command(int CmdMsg,CCore *Core,int Param0,int Param1)
|
||||
{
|
||||
bool Ret=false;
|
||||
|
||||
switch(CmdMsg)
|
||||
{
|
||||
case CmdMsg_ThingListDelete:
|
||||
DeleteThing();
|
||||
GUIThingUpdate();
|
||||
break;
|
||||
case CmdMsg_ThingListSelect:
|
||||
CurrentDefThing=Param0;
|
||||
SetCursor(DefList[CurrentDefThing].Name);
|
||||
Mode=MouseModeNew;
|
||||
break;
|
||||
case CmdMsg_ThingLevelSelect:
|
||||
SelectThing(Param0);
|
||||
GUIThingUpdate();
|
||||
break;
|
||||
case CmdMsg_ThingPosSelect:
|
||||
CurrentThingPoint=Param0;
|
||||
GUIThingPointUpdate();
|
||||
break;
|
||||
case CmdMsg_ThingPosUp:
|
||||
MovePoint(-1);
|
||||
break;
|
||||
case CmdMsg_ThingPosDown:
|
||||
MovePoint(+1);
|
||||
break;
|
||||
case CmdMsg_ThingPosDelete:
|
||||
DeletePoint();
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
return(Ret);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
int CLayerThing::FindDefThing(const char *Name)
|
||||
{
|
||||
int i,ListSize=DefList.size();
|
||||
|
||||
for (i=0; i<ListSize; i++)
|
||||
{
|
||||
if (DefList[i]==Name) return(i);
|
||||
}
|
||||
return(-1);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerThing::SetCursor(const char *Name)
|
||||
{
|
||||
int Idx=FindDefThing(Name);
|
||||
if (Idx==-1) return;
|
||||
|
||||
Cursor=DefList[Idx];
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerThing::RenderCursor(CCore *Core,Vector3 &CamPos,bool Is3d)
|
||||
{
|
||||
Vector3 ThisCam=Core->OffsetCam(CamPos,GetScaleFactor());
|
||||
CPoint &CursPos=Core->GetCursorPos();
|
||||
Vector3 Ofs;
|
||||
|
||||
Cursor.XY[0]=CursPos;
|
||||
|
||||
if (CursPos.x<0 || CursPos.y<0) return;
|
||||
if (Mode!=MouseModeNew) return;
|
||||
if (Cursor.ElemID==-1) return;
|
||||
|
||||
Ofs.x=-(CursPos.x-(int)ThisCam.x);
|
||||
Ofs.y=-(CursPos.y-(int)ThisCam.y);
|
||||
ThisCam.x-=(int)ThisCam.x;
|
||||
ThisCam.y-=(int)ThisCam.y;
|
||||
|
||||
Is3d&=GetRender3dFlag();
|
||||
if (Is3d)
|
||||
{
|
||||
glEnable(GL_DEPTH_TEST);
|
||||
// Render(Core,ThisCam,,TRUE,0.5,&Ofs);
|
||||
glDisable(GL_DEPTH_TEST);
|
||||
}
|
||||
else
|
||||
{
|
||||
// Render(Core,ThisCam,Brush,FALSE,0.5,&Ofs);
|
||||
}
|
||||
RenderThing(Core,ThisCam,Cursor,Is3d,true);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
|
@ -313,26 +466,52 @@ int StartIdx=0;
|
|||
void CLayerThing::AddThing(CPoint &Pos)
|
||||
{
|
||||
if (Pos.x==-1 || Pos.y==-1) return; // Off Map?
|
||||
CurrentThing=CheckThing(Pos);
|
||||
CurrentPoint=0;
|
||||
CurrentThing=SelectThing(Pos);
|
||||
if (CurrentThing!=-1) return;
|
||||
|
||||
CurrentThing=ThingList.size();
|
||||
ThingList.resize(CurrentThing+1);
|
||||
|
||||
sLayerThing &ThisThing=ThingList[CurrentThing];
|
||||
|
||||
ThisThing.XY.push_back(Pos);
|
||||
ThisThing.Type=ThingList.size()%22;
|
||||
ThisThing.SubType=0;
|
||||
ThisThing=Cursor;
|
||||
SelectThing(CurrentThing);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerThing::SelectThing(CPoint &Pos)
|
||||
int CLayerThing::SelectThing(CPoint &Pos)
|
||||
{
|
||||
if (Pos.x==-1 || Pos.y==-1) return; // Off Map?
|
||||
CurrentThing=CheckThing(Pos);
|
||||
CurrentPoint=0;
|
||||
if (Pos.x==-1 || Pos.y==-1) return(-1); // Off Map?
|
||||
SelectThing(CheckThing(Pos));
|
||||
return(CurrentThing);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
int CLayerThing::SelectThing(int Idx)
|
||||
{
|
||||
CurrentThing=Idx;
|
||||
CurrentThingPoint=0;
|
||||
if (CurrentThing!=-1)
|
||||
{
|
||||
sLayerThing &ThisThing=ThingList[CurrentThing];
|
||||
if (ThisThing.Data.WaypointFlag)
|
||||
{
|
||||
Mode=MouseModePoints;
|
||||
}
|
||||
else
|
||||
{
|
||||
Mode=MouseModeNormal;
|
||||
}
|
||||
}
|
||||
return(CurrentThing);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerThing::DeleteThing()
|
||||
{
|
||||
if (!ThingList.size()) return;
|
||||
|
||||
ThingList.erase(CurrentThing);
|
||||
CurrentThing--;
|
||||
}
|
||||
|
||||
|
||||
|
@ -369,21 +548,22 @@ int StartIdx=0;
|
|||
void CLayerThing::AddThingPoint(CPoint &Pos)
|
||||
{
|
||||
if (Pos.x==-1 || Pos.y==-1) return; // Off Map?
|
||||
CurrentPoint=CheckThingPoint(Pos);
|
||||
CurrentThingPoint=SelectThingPoint(Pos);
|
||||
|
||||
if (CurrentPoint!=-1) return;
|
||||
if (CurrentThingPoint!=-1) return;
|
||||
sLayerThing &ThisThing=ThingList[CurrentThing];
|
||||
|
||||
CurrentPoint=ThisThing.XY.size();
|
||||
ThisThing.XY.resize(CurrentPoint+1);
|
||||
ThisThing.XY[CurrentPoint]=Pos;
|
||||
CurrentThingPoint=ThisThing.XY.size();
|
||||
ThisThing.XY.resize(CurrentThingPoint+1);
|
||||
ThisThing.XY[CurrentThingPoint]=Pos;
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerThing::SelectThingPoint(CPoint &Pos)
|
||||
int CLayerThing::SelectThingPoint(CPoint &Pos)
|
||||
{
|
||||
if (Pos.x==-1 || Pos.y==-1) return; // Off Map?
|
||||
CurrentPoint=CheckThing(Pos);
|
||||
if (Pos.x==-1 || Pos.y==-1) return(-1); // Off Map?
|
||||
CurrentThingPoint=CheckThingPoint(Pos);
|
||||
return(CurrentThingPoint);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
|
@ -398,7 +578,7 @@ int StartIdx=PosIdx,EndIdx=ThisThing.XY.size();
|
|||
if (!Recurs)
|
||||
{
|
||||
StartIdx=PosIdx;
|
||||
EndIdx=StartIdx++;
|
||||
EndIdx=StartIdx+1;
|
||||
}
|
||||
|
||||
for (int i=StartIdx; i<EndIdx; i++)
|
||||
|
@ -407,46 +587,63 @@ int StartIdx=PosIdx,EndIdx=ThisThing.XY.size();
|
|||
}
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerThing::MovePoint(int Dir)
|
||||
{
|
||||
if (CurrentThing==-1) return;
|
||||
|
||||
int NewPos=CurrentThingPoint+Dir;
|
||||
sLayerThing &ThisThing=ThingList[CurrentThing];
|
||||
|
||||
if (NewPos<0 || NewPos>=ThisThing.XY.size()) return;
|
||||
|
||||
CPoint Tmp=ThisThing.XY[CurrentThingPoint];
|
||||
ThisThing.XY[CurrentThingPoint]=ThisThing.XY[NewPos];
|
||||
ThisThing.XY[NewPos]=Tmp;
|
||||
CurrentThingPoint=NewPos;
|
||||
GUIThingPointUpdate();
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerThing::DeletePoint()
|
||||
{
|
||||
if (!CurrentThingPoint) return;
|
||||
if (CurrentThing==-1) return;
|
||||
|
||||
sLayerThing &ThisThing=ThingList[CurrentThing];
|
||||
|
||||
ThisThing.XY.erase(CurrentThingPoint);
|
||||
CurrentThingPoint--;
|
||||
if (CurrentThingPoint<0) CurrentThingPoint=0;
|
||||
GUIThingPointUpdate();
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
/*****************************************************************************/
|
||||
/*****************************************************************************/
|
||||
void CLayerThing::Export(CCore *Core,CExport &Exp)
|
||||
{
|
||||
/*
|
||||
int Width=Map.GetWidth();
|
||||
int Height=Map.GetHeight();
|
||||
int i,ListSize=ThingList.size();
|
||||
Exp.ExportLayerHeader(LayerDef);
|
||||
|
||||
Exp.ExportLayerHeader(LAYER_TYPE_Elem,SubType,Width,Height);
|
||||
|
||||
for (int Y=0; Y<Height; Y++)
|
||||
Exp.Write(&ListSize,sizeof(int));
|
||||
for (i=0;i<ListSize; i++)
|
||||
{
|
||||
for (int X=0; X<Width; X++)
|
||||
ExportThing(Exp,ThingList[i]);
|
||||
}
|
||||
ExportThingNames(Exp);
|
||||
}
|
||||
|
||||
|
||||
/*****************************************************************************/
|
||||
void CLayerThing::ExportThingNames(CExport &Exp)
|
||||
{
|
||||
sMapElem &MapElem=Map.Get(X,Y);
|
||||
sExpLayerThing OutElem;
|
||||
int i,ListSize=ThingList.size();
|
||||
|
||||
if (MapElem.Set==0 && MapElem.Elem==0)
|
||||
{ // Blank
|
||||
OutElem.Elem=0;
|
||||
OutElem.Flags=0;
|
||||
}
|
||||
else
|
||||
for (i=0; i<ListSize; i++)
|
||||
{
|
||||
sExpElem OutElem;
|
||||
CElem &ThisElem=ElemBank->GetElem(MapElem.Set,MapElem.Elem);
|
||||
|
||||
OutElem.Set=MapElem.Set;
|
||||
OutElem.Elem=MapElem.Elem;
|
||||
OutElem.TriStart=0;
|
||||
OutElem.TriCount=0;
|
||||
OutElem.XOfs=ThisElem.GetTexXOfs();
|
||||
OutElem.YOfs=ThisElem.GetTexYOfs();
|
||||
OutElem.Elem=Exp.AddElem(OutElem);
|
||||
OutElem.Flags=MapElem.Flags;
|
||||
}
|
||||
|
||||
Exp.Write(&OutElem,sizeof(sExpLayerThing));
|
||||
char Txt[256];
|
||||
sprintf(Txt,ThingList[i].Name);
|
||||
Exp.Write(Txt,strlen(Txt)+1);
|
||||
}
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
|
|
@ -11,19 +11,27 @@
|
|||
#include "Elem.h"
|
||||
|
||||
/*****************************************************************************/
|
||||
struct sLayerThing
|
||||
struct sLayerThingData
|
||||
{
|
||||
std::vector<CPoint> XY;
|
||||
int Type;
|
||||
int SubType;
|
||||
bool WaypointFlag;
|
||||
|
||||
int Speed;
|
||||
int TurnRate;
|
||||
int Health;
|
||||
int AttackStrength;
|
||||
bool CollisionFlag;
|
||||
bool PlayerFlag;
|
||||
int Spare[8];
|
||||
|
||||
bool operator==(sLayerThing const &v1)
|
||||
};
|
||||
struct sLayerThing
|
||||
{
|
||||
if (XY[0]!=v1.XY[0]) return(false);
|
||||
return(true);
|
||||
}
|
||||
GString Name;
|
||||
CList<CPoint> XY;
|
||||
int ElemID;
|
||||
sLayerThingData Data;
|
||||
|
||||
bool operator==(const char *Name1) {return (Name==Name1);}
|
||||
};
|
||||
|
||||
/*****************************************************************************/
|
||||
|
@ -34,6 +42,7 @@ public:
|
|||
enum MouseMode
|
||||
{
|
||||
MouseModeNormal=0,
|
||||
MouseModeNew,
|
||||
MouseModePoints,
|
||||
};
|
||||
|
||||
|
@ -54,14 +63,21 @@ virtual void GUIKill(CCore *Core);
|
|||
virtual void GUIUpdate(CCore *Core);
|
||||
virtual void GUIChanged(CCore *Core);
|
||||
|
||||
int GetWidth() {return(Width);}
|
||||
int GetHeight() {return(Height);}
|
||||
virtual void GUIThingDefClear(){};
|
||||
virtual void GUIThingUpdate(){};
|
||||
virtual void GUIThingPointUpdate(){};
|
||||
|
||||
virtual void Load(CFile *File,int Version);
|
||||
virtual void LoadThing(CFile *File,int Version,sLayerThing &ThisThing);
|
||||
virtual void LoadThingNames(CFile *File,int Version);
|
||||
virtual void Save(CFile *File);
|
||||
virtual void SaveThing(CFile *File,sLayerThing &ThisThing);
|
||||
virtual void SaveThingNames(CFile *File);
|
||||
virtual void LoadThingScript(const char *Filename);
|
||||
|
||||
virtual void Export(CCore *Core,CExport &Exp);
|
||||
virtual void ExportThing(CExport &Exp,sLayerThing &ThisThing)=0;
|
||||
virtual void ExportThingNames(CExport &Exp);
|
||||
|
||||
// Functions
|
||||
virtual bool LButtonControl(CCore *Core,UINT nFlags, CPoint &point,bool DownFlag);
|
||||
|
@ -70,22 +86,32 @@ virtual bool MouseMove(CCore *Core,UINT nFlags, CPoint &point);
|
|||
virtual bool Command(int CmdMsg,CCore *Core,int Param0=0,int Param1=0);
|
||||
|
||||
protected:
|
||||
virtual int FindDefThing(const char *Name);
|
||||
virtual void SetCursor(const char *Name);
|
||||
|
||||
void RenderThing(CCore *Core,Vector3 &CamPos,sLayerThing &ThisThing,bool Render3d,bool Selected);
|
||||
int CheckThing(CPoint &Pos);
|
||||
void AddThing(CPoint &Pos);
|
||||
void SelectThing(CPoint &Pos);
|
||||
int SelectThing(CPoint &Pos);
|
||||
int SelectThing(int Idx);
|
||||
void DeleteThing();
|
||||
int CheckThingPoint(CPoint &Pos);
|
||||
void AddThingPoint(CPoint &Pos);
|
||||
void SelectThingPoint(CPoint &Pos);
|
||||
int SelectThingPoint(CPoint &Pos);
|
||||
|
||||
void UpdatePos(CPoint &Pos,int Thing,int PosNo,bool Recurs=false);
|
||||
void MovePoint(int Dir);
|
||||
void DeletePoint();
|
||||
void Cancel();
|
||||
|
||||
int Width,Height;
|
||||
CIni ThingScript;
|
||||
CElemBank *ThingBank;
|
||||
CList<sLayerThing> DefList;
|
||||
CList<sLayerThing> ThingList;
|
||||
int CurrentThing,CurrentPoint;
|
||||
int CurrentDefThing;
|
||||
int CurrentThing,CurrentThingPoint;
|
||||
MouseMode Mode;
|
||||
sLayerThing Cursor;
|
||||
};
|
||||
|
||||
/*****************************************************************************/
|
||||
|
|
|
@ -2,13 +2,13 @@
|
|||
|
||||
[General Info]
|
||||
Version=1
|
||||
LastClass=CAboutDlg
|
||||
LastClass=CGUINewMap
|
||||
LastTemplate=CDialog
|
||||
NewFileInclude1=#include "stdafx.h"
|
||||
NewFileInclude2=#include "mapedit.h"
|
||||
LastPage=0
|
||||
|
||||
ClassCount=18
|
||||
ClassCount=19
|
||||
Class1=CChildFrame
|
||||
Class2=CGLEnabledView
|
||||
Class3=CGUIAddLayer
|
||||
|
@ -28,21 +28,25 @@ Class16=CAboutDlg
|
|||
Class17=CMapEditDoc
|
||||
Class18=CMapEditView
|
||||
|
||||
ResourceCount=14
|
||||
Resource1=IDD_ADDLAYER
|
||||
ResourceCount=17
|
||||
Resource1=IDR_TOOLBAR (English (U.S.))
|
||||
Resource2=IDR_MAPEDITYPE (English (U.S.))
|
||||
Resource3=IDD_TOOLBAR
|
||||
Resource4=IDD_NEWMAP
|
||||
Resource5=IDD_LAYER_LIST
|
||||
Resource6=IDD_TILEBANK
|
||||
Resource7=IDD_RESIZE
|
||||
Resource8=IDD_LAYER_SHADE
|
||||
Resource9=IDD_LAYER_COLLISION
|
||||
Resource10=IDR_TOOLBAR (English (U.S.))
|
||||
Resource11=IDR_MAINFRAME (English (U.S.))
|
||||
Resource12=IDD_ABOUTBOX (English (U.S.))
|
||||
Resource13=IDD_MULTIBAR (English (U.S.))
|
||||
Resource14=IDD_ELEMLIST
|
||||
Resource3=IDD_NEWMAP
|
||||
Resource4=IDD_TOOLBAR
|
||||
Resource5=IDD_LAYER_COLLISION
|
||||
Resource6=IDD_RESIZE
|
||||
Resource7=IDD_ABOUTBOX (English (U.S.))
|
||||
Resource8=xxxx
|
||||
Resource9=IDD_TILEBANK
|
||||
Resource10=IDD_LAYER_SHADE
|
||||
Resource11=IDD_ADDLAYER
|
||||
Resource12=IDD_MULTIBAR (English (U.S.))
|
||||
Resource13=IDD_ELEMLIST
|
||||
Resource14=IDD_LAYER_LIST
|
||||
Resource15=IDD_LAYER_ACTOR2
|
||||
Resource16=IDR_MAINFRAME (English (U.S.))
|
||||
Class19=CGUILayerActor
|
||||
Resource17=IDD_LAYER_ACTOR
|
||||
|
||||
[CLS:CChildFrame]
|
||||
Type=0
|
||||
|
@ -79,6 +83,7 @@ Type=0
|
|||
BaseClass=CDialog
|
||||
HeaderFile=GUILayerList.h
|
||||
ImplementationFile=GUILayerList.cpp
|
||||
LastObject=IDC_LAYERLIST_LIST
|
||||
|
||||
[CLS:CGUIMultiBar]
|
||||
Type=0
|
||||
|
@ -91,6 +96,9 @@ Type=0
|
|||
BaseClass=CDialog
|
||||
HeaderFile=GUINewMap.h
|
||||
ImplementationFile=GUINewMap.cpp
|
||||
Filter=D
|
||||
VirtualFilter=dWC
|
||||
LastObject=IDC_MAPSIZE_HEIGHT
|
||||
|
||||
[CLS:CGUIResize]
|
||||
Type=0
|
||||
|
@ -166,19 +174,6 @@ Class=CGUIElemList
|
|||
ControlCount=1
|
||||
Control1=IDD_ELEM_LIST,combobox,1344339971
|
||||
|
||||
[DLG:IDD_LAYER_COLLISION]
|
||||
Type=1
|
||||
Class=GUILayerCollision
|
||||
ControlCount=8
|
||||
Control1=IDC_LAYERCOLLISION_NORMAL,button,1342242816
|
||||
Control2=IDC_LAYERCOLLISION_DAMAGE,button,1342242816
|
||||
Control3=IDC_LAYERCOLLISION_SLIPPERY,button,1342242816
|
||||
Control4=IDC_LAYERCOLLISION_ELECTRIC,button,1342242816
|
||||
Control5=IDC_LAYERCOLLISION_STICKY,button,1342242816
|
||||
Control6=IDC_LAYERCOLLISION_WATER,button,1342242816
|
||||
Control7=IDC_LAYERCOLLISION_SOLID,button,1342242816
|
||||
Control8=IDC_LAYERCOLLISION_DEATH,button,1342242816
|
||||
|
||||
[DLG:IDD_LAYER_LIST]
|
||||
Type=1
|
||||
Class=CGUILayerList
|
||||
|
@ -363,3 +358,71 @@ ControlCount=2
|
|||
Control1=IDD_LAYERTILE_BTN_PAINT,button,1342177344
|
||||
Control2=IDD_LAYERTILE_BTN_SELECT,button,1342177344
|
||||
|
||||
[DLG:IDD_LAYER_ACTOR2]
|
||||
Type=1
|
||||
Class=GUILayerCollision
|
||||
ControlCount=8
|
||||
Control1=IDC_LAYERCOLLISION_NORMAL,button,1342242816
|
||||
Control2=IDC_LAYERCOLLISION_DAMAGE,button,1342242816
|
||||
Control3=IDC_LAYERCOLLISION_SLIPPERY,button,1342242816
|
||||
Control4=IDC_LAYERCOLLISION_ELECTRIC,button,1342242816
|
||||
Control5=IDC_LAYERCOLLISION_STICKY,button,1342242816
|
||||
Control6=IDC_LAYERCOLLISION_WATER,button,1342242816
|
||||
Control7=IDC_LAYERCOLLISION_SOLID,button,1342242816
|
||||
Control8=IDC_LAYERCOLLISION_DEATH,button,1342242816
|
||||
|
||||
[DLG:xxxx]
|
||||
Type=1
|
||||
Class=?
|
||||
ControlCount=1
|
||||
Control1=IDC_COMBO1,combobox,1344340226
|
||||
|
||||
[DLG:IDD_LAYER_COLLISION]
|
||||
Type=1
|
||||
Class=?
|
||||
ControlCount=8
|
||||
Control1=IDC_LAYERCOLLISION_NORMAL,button,1342242816
|
||||
Control2=IDC_LAYERCOLLISION_DAMAGE,button,1342242816
|
||||
Control3=IDC_LAYERCOLLISION_SLIPPERY,button,1342242816
|
||||
Control4=IDC_LAYERCOLLISION_ELECTRIC,button,1342242816
|
||||
Control5=IDC_LAYERCOLLISION_STICKY,button,1342242816
|
||||
Control6=IDC_LAYERCOLLISION_WATER,button,1342242816
|
||||
Control7=IDC_LAYERCOLLISION_SOLID,button,1342242816
|
||||
Control8=IDC_LAYERCOLLISION_DEATH,button,1342242816
|
||||
|
||||
[DLG:IDD_LAYER_ACTOR]
|
||||
Type=1
|
||||
Class=CGUILayerActor
|
||||
ControlCount=22
|
||||
Control1=IDC_LEVEL_ACTOR_LIST,combobox,1344339971
|
||||
Control2=IDC_ACTOR_POS_LIST,listbox,1352728833
|
||||
Control3=IDC_ACTOR_POS_UP,button,1342242816
|
||||
Control4=IDC_ACTOR_POS_DOWN,button,1342242816
|
||||
Control5=IDC_ACTOR_POS_DELETE,button,1342242816
|
||||
Control6=IDC_ACTOR_SPEED_TEXT,static,1342308354
|
||||
Control7=IDC_ACTOR_SPEED,edit,1350633600
|
||||
Control8=IDC_ACTOR_SPEED_SPIN,msctls_updown32,1342177334
|
||||
Control9=IDC_ACTOR_TURNRATE_TEXT,static,1342308354
|
||||
Control10=IDC_ACTOR_TURNRATE,edit,1350633600
|
||||
Control11=IDC_ACTOR_TURNRATE_SPIN,msctls_updown32,1342177334
|
||||
Control12=IDC_ACTOR_HEALTH_TEXT,static,1342308354
|
||||
Control13=IDC_ACTOR_HEALTH,edit,1350633600
|
||||
Control14=IDC_ACTOR_HEALTH_SPIN,msctls_updown32,1342177334
|
||||
Control15=IDC_ACTOR_ATTACK_TEXT,static,1342308354
|
||||
Control16=IDC_ACTOR_ATTACK,edit,1350633600
|
||||
Control17=IDC_ACTOR_ATTACK_SPIN,msctls_updown32,1342177334
|
||||
Control18=IDC_ACTOR_PLAYER,button,1476461091
|
||||
Control19=IDC_ACTOR_COLLISION,button,1342243363
|
||||
Control20=IDC_LAYER_ACTOR_GROUP,button,1342177287
|
||||
Control21=IDC_ACTOR_LIST,combobox,1344339971
|
||||
Control22=IDC_ACTOR_DELETE,button,1342242816
|
||||
|
||||
[CLS:CGUILayerActor]
|
||||
Type=0
|
||||
HeaderFile=GUILayerActor.h
|
||||
ImplementationFile=GUILayerActor.cpp
|
||||
BaseClass=CDialog
|
||||
Filter=D
|
||||
VirtualFilter=dWC
|
||||
LastObject=CGUILayerActor
|
||||
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
static char THIS_FILE[] = __FILE__;
|
||||
#endif
|
||||
|
||||
const char* ConfigFilename="Mapedit.ini";
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CMapEditApp
|
||||
|
||||
|
@ -106,6 +108,8 @@ BOOL CMapEditApp::InitInstance()
|
|||
pMainFrame->ShowWindow(m_nCmdShow);
|
||||
pMainFrame->UpdateWindow();
|
||||
|
||||
|
||||
MainIni.LoadAndImport(ConfigFilename);
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
|
@ -129,6 +133,16 @@ void CMapEditApp::CloseDoc(CMapEditDoc *Cur)
|
|||
}
|
||||
}
|
||||
|
||||
char *CMapEditApp::GetConfigStr(char *Grp,char *Key)
|
||||
{
|
||||
return(MainIni.GetStr(Grp,Key));
|
||||
}
|
||||
|
||||
int CMapEditApp::GetConfigInt(char *Grp,char *Key)
|
||||
{
|
||||
return(MainIni.GetInt(Grp,Key));
|
||||
}
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CAboutDlg dialog used for App About
|
||||
|
||||
|
|
|
@ -84,7 +84,7 @@ LINK32=link.exe
|
|||
ProjDir=.
|
||||
TargetDir=.\Debug
|
||||
SOURCE="$(InputPath)"
|
||||
PostBuild_Cmds=if not exist $(TargetDir)\collision.bmp copy $(ProjDir)\res\collision.bmp $(TargetDir)\collision.bmp if not exist $(TargetDir)\iconz.bmp copy $(ProjDir)\res\iconz.bmp $(TargetDir)\iconz.bmp
|
||||
PostBuild_Cmds=if not exist $(TargetDir)\collision.bmp copy $(ProjDir)\res\collision.bmp $(TargetDir)\collision.bmp if not exist $(TargetDir)\iconz.bmp copy $(ProjDir)\res\iconz.bmp $(TargetDir)\iconz.bmp copy $(ProjDir)\res\iconz.bmp $(TargetDir)\iconz.bmp
|
||||
# End Special Build Tool
|
||||
|
||||
!ENDIF
|
||||
|
@ -391,6 +391,14 @@ SOURCE=.\GUIElemList.h
|
|||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\GUILayerActor.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\GUILayerActor.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\GUILayerCollision.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
|
|
@ -14,6 +14,7 @@
|
|||
|
||||
#include "resource.h" // main symbols
|
||||
#include "CmdMsg.h"
|
||||
#include "IniClass.h"
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CMapEditApp:
|
||||
|
@ -32,6 +33,8 @@ public:
|
|||
{
|
||||
return(CurrentDoc);
|
||||
}
|
||||
char *GetConfigStr(char *Grp,char *Key);
|
||||
int GetConfigInt(char *Grp,char *Key);
|
||||
|
||||
// Overrides
|
||||
// ClassWizard generated virtual function overrides
|
||||
|
@ -50,6 +53,7 @@ public:
|
|||
|
||||
private:
|
||||
CMapEditDoc *CurrentDoc;
|
||||
CIni MainIni;
|
||||
};
|
||||
|
||||
|
||||
|
|
|
@ -584,6 +584,52 @@ BEGIN
|
|||
WS_TABSTOP
|
||||
END
|
||||
|
||||
IDD_LAYER_ACTOR DIALOG DISCARDABLE 0, 0, 156, 256
|
||||
STYLE WS_CHILD
|
||||
FONT 8, "MS Sans Serif"
|
||||
BEGIN
|
||||
COMBOBOX IDC_LEVEL_ACTOR_LIST,5,25,145,185,CBS_DROPDOWNLIST |
|
||||
WS_VSCROLL | WS_TABSTOP
|
||||
LISTBOX IDC_ACTOR_POS_LIST,5,55,145,55,LBS_NOINTEGRALHEIGHT |
|
||||
WS_VSCROLL | WS_TABSTOP
|
||||
PUSHBUTTON "Pos Up",IDC_ACTOR_POS_UP,10,110,45,15
|
||||
PUSHBUTTON "Pos Down",IDC_ACTOR_POS_DOWN,55,110,45,15
|
||||
PUSHBUTTON "Pos Delete",IDC_ACTOR_POS_DELETE,100,110,45,15
|
||||
RTEXT "Speed",IDC_ACTOR_SPEED_TEXT,10,130,32,8
|
||||
EDITTEXT IDC_ACTOR_SPEED,45,130,35,12,ES_AUTOHSCROLL |
|
||||
ES_READONLY
|
||||
CONTROL "Spin1",IDC_ACTOR_SPEED_SPIN,"msctls_updown32",
|
||||
UDS_SETBUDDYINT | UDS_ALIGNRIGHT | UDS_AUTOBUDDY |
|
||||
UDS_ARROWKEYS,80,130,11,10
|
||||
RTEXT "TurnRate",IDC_ACTOR_TURNRATE_TEXT,10,145,31,8
|
||||
EDITTEXT IDC_ACTOR_TURNRATE,45,145,35,12,ES_AUTOHSCROLL |
|
||||
ES_READONLY
|
||||
CONTROL "Spin1",IDC_ACTOR_TURNRATE_SPIN,"msctls_updown32",
|
||||
UDS_SETBUDDYINT | UDS_ALIGNRIGHT | UDS_AUTOBUDDY |
|
||||
UDS_ARROWKEYS,80,145,11,10
|
||||
RTEXT "Health",IDC_ACTOR_HEALTH_TEXT,10,164,32,8
|
||||
EDITTEXT IDC_ACTOR_HEALTH,45,164,35,12,ES_AUTOHSCROLL |
|
||||
ES_READONLY
|
||||
CONTROL "Spin1",IDC_ACTOR_HEALTH_SPIN,"msctls_updown32",
|
||||
UDS_SETBUDDYINT | UDS_ALIGNRIGHT | UDS_AUTOBUDDY |
|
||||
UDS_ARROWKEYS,80,164,11,10
|
||||
RTEXT "Attack",IDC_ACTOR_ATTACK_TEXT,10,180,31,8
|
||||
EDITTEXT IDC_ACTOR_ATTACK,45,180,35,12,ES_AUTOHSCROLL |
|
||||
ES_READONLY
|
||||
CONTROL "Spin1",IDC_ACTOR_ATTACK_SPIN,"msctls_updown32",
|
||||
UDS_SETBUDDYINT | UDS_ALIGNRIGHT | UDS_AUTOBUDDY |
|
||||
UDS_ARROWKEYS,80,180,11,10
|
||||
CONTROL "Player",IDC_ACTOR_PLAYER,"Button",BS_AUTOCHECKBOX |
|
||||
BS_LEFTTEXT | BS_RIGHT | WS_DISABLED | WS_TABSTOP,95,130,
|
||||
50,10
|
||||
CONTROL "Collision",IDC_ACTOR_COLLISION,"Button",BS_AUTOCHECKBOX |
|
||||
BS_LEFTTEXT | BS_RIGHT | WS_TABSTOP,95,145,50,10
|
||||
GROUPBOX "",IDC_LAYER_ACTOR_GROUP,0,20,155,175
|
||||
COMBOBOX IDC_ACTOR_LIST,5,5,145,185,CBS_DROPDOWNLIST | WS_VSCROLL |
|
||||
WS_TABSTOP
|
||||
PUSHBUTTON "Delete Actor",IDC_ACTOR_DELETE,5,40,75,15
|
||||
END
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
|
@ -664,6 +710,14 @@ BEGIN
|
|||
TOPMARGIN, 7
|
||||
BOTTOMMARGIN, 19
|
||||
END
|
||||
|
||||
IDD_LAYER_ACTOR, DIALOG
|
||||
BEGIN
|
||||
LEFTMARGIN, 7
|
||||
RIGHTMARGIN, 149
|
||||
TOPMARGIN, 7
|
||||
BOTTOMMARGIN, 249
|
||||
END
|
||||
END
|
||||
#endif // APSTUDIO_INVOKED
|
||||
|
||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 2.6 KiB After Width: | Height: | Size: 2.6 KiB |
|
@ -18,6 +18,7 @@
|
|||
#define IDD_LAYER_SHADE 175
|
||||
#define IDD_LAYER_COLLISION 177
|
||||
#define IDD_ELEMLIST 178
|
||||
#define IDD_LAYER_ACTOR 179
|
||||
#define IDC_TOOLBAR_COMBO 1018
|
||||
#define IDC_LAYERLIST_LIST 1019
|
||||
#define IDD_TILEBANK_UPDATE 1029
|
||||
|
@ -45,19 +46,42 @@
|
|||
#define IDC_LAYERCOLLISION_NORMAL 1078
|
||||
#define IDD_ELEM_LIST 1080
|
||||
#define IDC_LAYERSHADE_EDITR2 1081
|
||||
#define IDC_LEVEL_ACTOR_LIST 1081
|
||||
#define IDC_LAYERSHADE_EDITG2 1082
|
||||
#define IDC_LAYERCOLLISION_DAMAGE 1082
|
||||
#define IDC_ACTOR_POS_LIST 1082
|
||||
#define IDC_LAYERSHADE_EDITB2 1083
|
||||
#define IDC_LAYERCOLLISION_SLIPPERY 1083
|
||||
#define IDC_ACTOR_POS_UP 1083
|
||||
#define IDC_LAYERCOLLISION_ELECTRIC 1084
|
||||
#define IDC_ACTOR_POS_DOWN 1084
|
||||
#define IDC_LAYERCOLLISION_STICKY 1085
|
||||
#define IDC_ACTOR_POS_DELETE 1085
|
||||
#define IDC_LAYERSHADE_TEXT7 1086
|
||||
#define IDC_LAYERCOLLISION_WATER 1086
|
||||
#define IDC_ACTOR_SPEED_TEXT 1086
|
||||
#define IDC_LAYERSHADE_EDITR3 1087
|
||||
#define IDC_LAYERCOLLISION_SOLID 1087
|
||||
#define IDC_ACTOR_SPEED 1087
|
||||
#define IDC_LAYERSHADE_EDITG3 1088
|
||||
#define IDC_LAYERCOLLISION_DEATH 1088
|
||||
#define IDC_LAYERSHADE_EDITB3 1089
|
||||
#define IDC_ACTOR_LIST 1089
|
||||
#define IDC_ACTOR_NEW 1090
|
||||
#define IDC_ACTOR_DELETE 1091
|
||||
#define IDC_ACTOR_SPEED_SPIN 1092
|
||||
#define IDC_ACTOR_PLAYER 1094
|
||||
#define IDC_LAYER_ACTOR_GROUP 1095
|
||||
#define IDC_ACTOR_TURNRATE_TEXT 1097
|
||||
#define IDC_ACTOR_TURNRATE 1098
|
||||
#define IDC_ACTOR_TURNRATE_SPIN 1099
|
||||
#define IDC_ACTOR_HEALTH_TEXT 1112
|
||||
#define IDC_ACTOR_HEALTH 1113
|
||||
#define IDC_ACTOR_HEALTH_SPIN 1114
|
||||
#define IDC_ACTOR_ATTACK_TEXT 1115
|
||||
#define IDC_ACTOR_ATTACK 1116
|
||||
#define IDC_ACTOR_ATTACK_SPIN 1117
|
||||
#define IDC_ACTOR_COLLISION 1118
|
||||
#define ID_TOOLBAR_TILEPALETTE 32774
|
||||
#define ID_TOOLBAR_PARAMBAR 32783
|
||||
#define ID_TOGGLE_SUBVIEW 32785
|
||||
|
@ -80,9 +104,9 @@
|
|||
#ifdef APSTUDIO_INVOKED
|
||||
#ifndef APSTUDIO_READONLY_SYMBOLS
|
||||
#define _APS_3D_CONTROLS 1
|
||||
#define _APS_NEXT_RESOURCE_VALUE 178
|
||||
#define _APS_NEXT_RESOURCE_VALUE 180
|
||||
#define _APS_NEXT_COMMAND_VALUE 32800
|
||||
#define _APS_NEXT_CONTROL_VALUE 1081
|
||||
#define _APS_NEXT_CONTROL_VALUE 1097
|
||||
#define _APS_NEXT_SYMED_VALUE 101
|
||||
#endif
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue