Big update for overworld research

Restructured pretty much everything to allow easier modification down
the road.

Scripts still need more research.
This commit is contained in:
Kurt
2015-11-07 14:34:06 -08:00
parent 0ce28575ec
commit c87658c8bc
3 changed files with 501 additions and 235 deletions

View File

@@ -1022,10 +1022,11 @@ public Image Preview(int s, int ColorShift)
}
public class ZoneData
{
internal static int Size = 0x38;
public byte[] Data;
public int MapMatrix { get { return BitConverter.ToUInt16(Data, 0x04); } set { BitConverter.GetBytes((ushort)value).CopyTo(Data, 0x04);} }
public int TextFile { get { return BitConverter.ToUInt16(Data, 0x06); } set { BitConverter.GetBytes((ushort)value).CopyTo(Data, 0x06); } }
public int OverworldLocation // 0x1C - low 7 bits
public int ParentMap // 0x1C - low 7 bits
{
get { return BitConverter.ToUInt16(Data, 0x1C) & 0x1FF; }
set { BitConverter.GetBytes((ushort)(value | (BitConverter.ToUInt16(Data, 0x1C) & ~0x1FF))).CopyTo(Data, 0x1C); }
@@ -1035,9 +1036,13 @@ public class ZoneData
get { return BitConverter.ToUInt16(Data, 0x1C) >> 9; }
set { BitConverter.GetBytes((ushort)((value << 9) | (BitConverter.ToUInt16(Data, 0x1C) & 0x1FF))).CopyTo(Data, 0x1C); }
}
public int X { get { return BitConverter.ToInt32(Data, 0x2C); } set { BitConverter.GetBytes(value).CopyTo(Data, 0x2C); } }
public int Z { get { return BitConverter.ToInt32(Data, 0x30); } set { BitConverter.GetBytes(value).CopyTo(Data, 0x30); } }
public int Y { get { return BitConverter.ToInt32(Data, 0x34); } set { BitConverter.GetBytes(value).CopyTo(Data, 0x34); } }
public ZoneData(byte[] data)
{
if (data.Length != 0x36)
if (data.Length != Size)
return;
Data = data;
}
@@ -1086,11 +1091,15 @@ public class ZoneEntities
{
public byte[] Data; // File details unknown.
public UInt32 Length;
public Int32 Length;
public Int32 FurnitureCount, NPCCount, WarpCount, TriggerCount;
public Int32 UNKNOWN;
public Byte[] UnknownBytes;
public EntityFurniture[] Furniture;
public EntityNPC[] NPCs;
public EntityWarp[] Warps;
public EntityTrigger[] Triggers;
public Int32 ScriptLength;
public Byte[] ScriptData;
public ZoneEntities(byte[] data)
{
@@ -1098,35 +1107,86 @@ public ZoneEntities(byte[] data)
using (BinaryReader br = new BinaryReader(new MemoryStream(data)))
{
Length = br.ReadUInt32();
Furniture = new EntityFurniture[br.ReadByte()];
NPCs = new EntityNPC[br.ReadByte()];
Warps = new EntityWarp[br.ReadByte()];
Triggers = new EntityTrigger[br.ReadByte()];
for (int i = 0; i < Furniture.Length; i++)
Furniture[i] = new EntityFurniture(br.ReadBytes(Furniture.Length));
for (int i = 0; i < NPCs.Length; i++)
NPCs[i] = new EntityNPC(br.ReadBytes(NPCs.Length));
for (int i = 0; i < Warps.Length; i++)
Warps[i] = new EntityWarp(br.ReadBytes(Warps.Length));
for (int i = 0; i < Triggers.Length; i++)
Triggers[i] = new EntityTrigger(br.ReadBytes(Triggers.Length));
ScriptData = br.ReadBytes((int)(br.BaseStream.Length - br.BaseStream.Position));
// Load Header
Length = br.ReadInt32();
Furniture = new EntityFurniture[FurnitureCount = br.ReadByte()];
NPCs = new EntityNPC[NPCCount = br.ReadByte()];
Warps = new EntityWarp[WarpCount = br.ReadByte()];
Triggers = new EntityTrigger[TriggerCount = br.ReadByte()];
UNKNOWN = br.ReadInt32();
// Load Entitites
for (int i = 0; i < FurnitureCount; i++)
Furniture[i] = new EntityFurniture(br.ReadBytes(EntityFurniture.Size));
for (int i = 0; i < NPCCount; i++)
NPCs[i] = new EntityNPC(br.ReadBytes(EntityNPC.Size));
for (int i = 0; i < WarpCount; i++)
Warps[i] = new EntityWarp(br.ReadBytes(EntityWarp.Size));
for (int i = 0; i < TriggerCount; i++)
Triggers[i] = new EntityTrigger(br.ReadBytes(EntityTrigger.Size));
int ScriptDataOffset = Length + 4;
UnknownBytes = (br.BaseStream.Position == ScriptDataOffset)
? new byte[0]
: br.ReadBytes(ScriptDataOffset - (int)br.BaseStream.Position);
// Load Script Data
ScriptLength = br.ReadInt32();
ScriptData = br.ReadBytes(ScriptLength - 4);
}
}
public byte[] Write()
{
return Data;
byte[] F = new byte[Furniture.Length * EntityFurniture.Size];
for (int i = 0; i < Furniture.Length; i++)
Furniture[i].Write().CopyTo(F, i * EntityFurniture.Size);
byte[] N = new byte[NPCs.Length * EntityNPC.Size];
for (int i = 0; i < NPCs.Length; i++)
NPCs[i].Write().CopyTo(F, i * EntityNPC.Size);
byte[] W = new byte[Warps.Length * EntityWarp.Size];
for (int i = 0; i < Warps.Length; i++)
Warps[i].Write().CopyTo(F, i * EntityWarp.Size);
byte[] T = new byte[Triggers.Length * EntityTrigger.Size];
for (int i = 0; i < Triggers.Length; i++)
Triggers[i].Write().CopyTo(F, i * EntityTrigger.Size);
// Assemble entity information
byte[] OWEntities = F.Concat(N).Concat(W).Concat(T).ToArray();
byte[] EntityCounts = {(byte)Furniture.Length, (byte)NPCs.Length, (byte)Warps.Length, (byte)Triggers.Length};
byte[] EntityLength = BitConverter.GetBytes(8 + OWEntities.Length + 4 + UnknownBytes.Length);
byte[] UNKNOWNCT = BitConverter.GetBytes(UNKNOWN);
// Reassemble NPC portion
byte[] OWEntityData = EntityLength.Concat(EntityCounts).Concat(UNKNOWNCT).Concat(OWEntities).Concat(UnknownBytes).ToArray();
// Add padding zeroes if required (yield above section % 4 == 0)
if (OWEntityData.Length % 4 != 0)
Array.Resize(ref OWEntityData, OWEntityData.Length + 4 - (OWEntityData.Length % 4));
// Reassemble Script portion
byte[] OWScriptData = ScriptData;
// Return final data
return OWEntityData.Concat(OWScriptData).ToArray();
}
// Entity Classes
public class EntityFurniture
{
internal static readonly byte Length = 0x14;
// Usable Attributes
public int X { get { return BitConverter.ToUInt16(Raw, 0x08); } set { BitConverter.GetBytes((ushort)value).CopyTo(Raw, 0x08); } }
public int Y { get { return BitConverter.ToUInt16(Raw, 0x0A); } set { BitConverter.GetBytes((ushort)value).CopyTo(Raw, 0x0A); } }
// Next two bytes should be dealing with furniture width?
public byte[] Raw;
public EntityFurniture(byte[] data)
internal static readonly byte Size = 0x14;
public EntityFurniture(byte[] data = null)
{
Raw = data;
Raw = data ?? new byte[Size];
}
public byte[] Write()
{
@@ -1135,13 +1195,25 @@ public byte[] Write()
}
public class EntityNPC
{
internal static readonly byte Length = 0x30;
public ushort ID;
// Usable Attributes
public int ID { get { return BitConverter.ToUInt16(Raw, 0x00); } set { BitConverter.GetBytes((ushort)value).CopyTo(Raw, 0x00); } }
public int Model { get { return BitConverter.ToUInt16(Raw, 0x02); } set { BitConverter.GetBytes((ushort)value).CopyTo(Raw, 0x02); } }
public int MovePermissions { get { return BitConverter.ToUInt16(Raw, 0x04); } set { BitConverter.GetBytes((ushort)value).CopyTo(Raw, 0x04); } }
public int MovePermissions2 { get { return BitConverter.ToUInt16(Raw, 0x06); } set { BitConverter.GetBytes((ushort)value).CopyTo(Raw, 0x06); } }
public int SpawnFlag { get { return BitConverter.ToUInt16(Raw, 0x08); } set { BitConverter.GetBytes((ushort)value).CopyTo(Raw, 0x08); } }
public int Script { get { return BitConverter.ToUInt16(Raw, 0x0A); } set { BitConverter.GetBytes((ushort)value).CopyTo(Raw, 0x0A); } }
public int FaceDirection { get { return BitConverter.ToUInt16(Raw, 0x0C); } set { BitConverter.GetBytes((ushort)value).CopyTo(Raw, 0x0C); } }
// ??? Eyecatch/Leash Stuff.
public int X { get { return BitConverter.ToUInt16(Raw, 0x28); } set { BitConverter.GetBytes((ushort)value).CopyTo(Raw, 0x28); } }
public int Y { get { return BitConverter.ToUInt16(Raw, 0x2A); } set { BitConverter.GetBytes((ushort)value).CopyTo(Raw, 0x2A); } }
public int ZU { get { return BitConverter.ToUInt16(Raw, 0x2C); } set { BitConverter.GetBytes((ushort)value).CopyTo(Raw, 0x2C); } }
public int Z { get { return BitConverter.ToUInt16(Raw, 0x2E); } set { BitConverter.GetBytes((ushort)value).CopyTo(Raw, 0x2E); } }
public byte[] Raw;
public EntityNPC(byte[] data)
internal static readonly byte Size = 0x30;
public EntityNPC(byte[] data = null)
{
Raw = data;
ID = BitConverter.ToUInt16(data, 0x4);
Raw = data ?? new byte[Size];
}
public byte[] Write()
{
@@ -1150,16 +1222,15 @@ public byte[] Write()
}
public class EntityWarp
{
internal static readonly byte Length = 0x18;
public byte[] Raw;
public ushort DestinationMap;
public ushort DestinationTileIndex;
public EntityWarp(byte[] data)
{
Raw = data;
// Usable Attributes
public int DestinationMap { get { return BitConverter.ToUInt16(Raw, 0x00); } set { BitConverter.GetBytes((ushort)value).CopyTo(Raw, 0x00);} }
public int DestinationTileIndex { get { return BitConverter.ToUInt16(Raw, 0x02); } set { BitConverter.GetBytes((ushort)value).CopyTo(Raw, 0x02);} }
DestinationMap = BitConverter.ToUInt16(data, 0x4);
DestinationTileIndex = BitConverter.ToUInt16(data, 0x6);
public byte[] Raw;
internal static readonly byte Size = 0x18;
public EntityWarp(byte[] data = null)
{
Raw = data ?? new byte[Size];
}
public byte[] Write()
{
@@ -1168,11 +1239,15 @@ public byte[] Write()
}
public class EntityTrigger
{
internal static readonly byte Length = 0x18;
// Usable Attributes
public int X { get { return BitConverter.ToUInt16(Raw, 0x28); } set { BitConverter.GetBytes((ushort)value).CopyTo(Raw, 0x28); } }
public int Y { get { return BitConverter.ToUInt16(Raw, 0x2A); } set { BitConverter.GetBytes((ushort)value).CopyTo(Raw, 0x2A); } }
public byte[] Raw;
public EntityTrigger(byte[] data)
internal static readonly byte Size = 0x18;
public EntityTrigger(byte[] data = null)
{
Raw = data;
Raw = data ?? new byte[Size];
}
public byte[] Write()
{

View File

@@ -51,8 +51,8 @@ private void openQuick(string[] encdata)
string name = Path.GetFileNameWithoutExtension(filepaths[f]);
int LocationNum = Convert.ToInt16(name.Substring(4, name.Length - 4));
int indNum = LocationNum * 56 + 0x1C;
string LocationName = gameLocations[BitConverter.ToUInt16(zonedata, indNum) & 0x1FF];
ZoneData zo = new ZoneData(zonedata.Skip(f * ZoneData.Size).Take(ZoneData.Size).ToArray());
string LocationName = gameLocations[zo.ParentMap];
zdLocations[f] = (LocationNum.ToString("000") + " - " + LocationName);
rawLocations[f] = LocationName;
}
@@ -76,26 +76,33 @@ private void CB_LocationID_SelectedIndexChanged(object sender, EventArgs e)
private void getEntry()
{
if (entry < 0) return;
RTB_F.Text = RTB_O.Text = RTB_W.Text = RTB_T.Text = string.Empty;
byte[] raw = File.ReadAllBytes(filepaths[entry]);
locationData = CTR.mini.unpackMini(raw, "ZO");
if (locationData == null) return;
RichTextBox[] rtba = {RTB_MapInfo, RTB_OWSC, RTB_MapSC, RTB_Encounter, RTB_File5};
for (int i = 0; i < locationData.Length; i++)
rtba[i].Lines = Scripts.getHexLines(locationData[i], 0x10);
// Read master ZD table
byte[] zd = zonedata.Skip(ZoneData.Size * entry).Take(ZoneData.Size).ToArray();
RTB_ZDMaster.Lines = Scripts.getHexLines(zd, 0x10);
// File 0 - ??
// Load from location Data.
CurrentZone = new Zone(locationData);
// File 0 - ZoneData
RTB_ZD.Lines = Scripts.getHexLines(locationData[0], 0x10);
getZoneData();
// File 1 - Overworld Setup & Script
RTB_OWSC.Lines = Scripts.getHexLines(locationData[1], 0x10);
getOWSData();
// File 2 - Map Script
RTB_MapSC.Lines = Scripts.getHexLines(locationData[2], 0x10);
getScriptData();
// File 3 - Encounters
RTB_Encounter.Lines = Scripts.getHexLines(locationData[3], 0x10);
// File 4 - ??
// File 4 - ?? (ORAS Only?)
RTB_File5.Lines = Scripts.getHexLines(locationData.Length <= 4 ? null : locationData[4], 0x10);
}
private void setEntry()
{
@@ -120,11 +127,8 @@ private void setEntry()
//File.WriteAllBytes(filepaths[entry], raw);
}
private byte[][] fData;
private byte[][] nData;
private byte[][] wData;
private byte[][] tData;
private byte[] OWScriptData;
private Zone CurrentZone;
private void getScriptData()
{
@@ -173,64 +177,45 @@ private void getScriptData()
else
RTB_MSCMD.Lines = RTB_MS.Lines = new[] {"No Data"};
}
private void getOWSData()
{
byte[] data = locationData[1];
int len = BitConverter.ToInt32(data, 0);
byte[] zd = zonedata.Skip(56*entry).Take(56).ToArray();
ushort text = BitConverter.ToUInt16(zonedata, 56*entry + 6);
ushort map = BitConverter.ToUInt16(zonedata, 56*entry + 4);
RTB_zonedata.Lines = Scripts.getHexLines(zd, 0x10);
L_ZDPreview.Text = "Text File: " + text
+ Environment.NewLine + "Map File: " + map;
private void getZoneData()
{
L_ZDPreview.Text = "Text File: " + CurrentZone.ZD.TextFile
+ Environment.NewLine + "Map File: " + CurrentZone.ZD.MapMatrix;
// Fetch Map Image
DrawMap = map;
PB_Map.Image = getMapImage();
DrawMap = CurrentZone.ZD.MapMatrix;
PB_Map.Image = (CHK_AutoDraw.Checked) ? getMapImage() : null;
}
private void getOWSData()
{
File.WriteAllBytes("zd.bin", CurrentZone.Entities.Data);
RTB_F.Text = RTB_N.Text = RTB_W.Text = RTB_T.Text = string.Empty;
// Set Counters
NUD_FurnCount.Value = CurrentZone.Entities.FurnitureCount; changeFurnitureCount(null, null);
NUD_NPCCount.Value = CurrentZone.Entities.NPCCount; changeNPCCount(null, null);
NUD_WarpCount.Value = CurrentZone.Entities.WarpCount; changeWarpCount(null, null);
NUD_TrigCount.Value = CurrentZone.Entities.TriggerCount; changeTriggerCount(null, null);
byte[] owData = data.Skip(4).Take(len).ToArray();
// Process owData Header
using (var s = new MemoryStream(owData))
using (var br = new BinaryReader(s))
{
// Prepare Data
byte F = br.ReadByte(); fData = new byte[255][]; for (int i = 0; i < 255; i++) fData[i] = new byte[flen];
byte N = br.ReadByte(); nData = new byte[255][]; for (int i = 0; i < 255; i++) nData[i] = new byte[nlen];
byte W = br.ReadByte(); wData = new byte[255][]; for (int i = 0; i < 255; i++) wData[i] = new byte[wlen];
byte T = br.ReadByte(); tData = new byte[255][]; for (int i = 0; i < 255; i++) tData[i] = new byte[tlen];
// Set Counters
NUD_FurnCount.Value = F; changeFurnitureCount(null, null);
NUD_NPCCount.Value = N; changeNPCCount(null, null);
NUD_WarpCount.Value = W; changeWarpCount(null, null);
NUD_TrigCount.Value = T; changeTriggerCount(null, null);
// Collect/Load Data
for (int i = 0; i < F; i++) fData[i] = br.ReadBytes(flen);
for (int i = 0; i < N; i++) nData[i] = br.ReadBytes(nlen);
for (int i = 0; i < W; i++) wData[i] = br.ReadBytes(wlen);
for (int i = 0; i < T; i++) tData[i] = br.ReadBytes(tlen);
NUD_FE.Value = (NUD_FE.Maximum < 0) ? -1 : 0; changeFurniture(null, null);
NUD_NE.Value = (NUD_NE.Maximum < 0) ? -1 : 0; changeOverworld(null, null);
NUD_WE.Value = (NUD_WE.Maximum < 0) ? -1 : 0; changeWarp(null, null);
NUD_TE.Value = (NUD_TE.Maximum < 0) ? -1 : 0; changeTrigger(null, null);
}
// Collect/Load Data
NUD_FE.Value = (NUD_FE.Maximum < 0) ? -1 : 0; changeFurniture(null, null);
NUD_NE.Value = (NUD_NE.Maximum < 0) ? -1 : 0; changeOverworld(null, null);
NUD_WE.Value = (NUD_WE.Maximum < 0) ? -1 : 0; changeWarp(null, null);
NUD_TE.Value = (NUD_TE.Maximum < 0) ? -1 : 0; changeTrigger(null, null);
// Process Scripts
OWScriptData = data.Skip(4 + owData.Length).Take(data.Length - 4 - owData.Length).ToArray();
OWScriptData = CurrentZone.Entities.ScriptData;
if (OWScriptData.Length > 4)
{
byte[] ScriptData = OWScriptData;
int length = BitConverter.ToInt32(ScriptData, 0);
Array.Resize(ref ScriptData, length); // Cap Size
int length = CurrentZone.Entities.ScriptLength;
RTB_OS.Lines = Scripts.getHexLines(ScriptData);
int start = BitConverter.ToInt32(ScriptData, 0xC);
int moves = BitConverter.ToInt32(ScriptData, 0x10);
int finaloffset = BitConverter.ToInt32(ScriptData, 0x14);
int reserved = BitConverter.ToInt32(ScriptData, 0x18);
int start = BitConverter.ToInt32(ScriptData, 0x8) - 4;
int moves = BitConverter.ToInt32(ScriptData, 0xC) - 4;
int finaloffset = BitConverter.ToInt32(ScriptData, 0x10) - 4;
int reserved = BitConverter.ToInt32(ScriptData, 0x14) - 4;
int compressedLength = length - start;
int decompressedLength = finaloffset - start;
@@ -264,39 +249,7 @@ private void getOWSData()
RTB_OWSCMD.Lines = RTB_OS.Lines = new[] {"No Data"};
}
private byte[] setOWSData()
{
using (var s = new MemoryStream())
using (var bw = new BinaryWriter(s))
{
// Overworld Payload
bw.Write(0); // 4 Byte Length of 0 (Temporary)
bw.Write((byte)NUD_FurnCount.Value);
bw.Write((byte)NUD_NPCCount.Value);
bw.Write((byte)NUD_WarpCount.Value);
bw.Write((byte)NUD_TrigCount.Value);
for (int i = 0; i < NUD_FurnCount.Value; i++) bw.Write(fData[i]);
for (int i = 0; i < NUD_NPCCount.Value; i++) bw.Write(nData[i]);
for (int i = 0; i < NUD_WarpCount.Value; i++) bw.Write(wData[i]);
for (int i = 0; i < NUD_TrigCount.Value; i++) bw.Write(tData[i]);
// have to check for 00 padding
while (s.Length % 4 != 0) bw.Write((byte)0);
s.Position = 0; bw.Write((int)s.Length);
s.Position = s.Length - 1;
// Script Payload
byte[] scriptData = Util.StringToByteArray(RTB_OWSCMD.Text);
bw.Write(scriptData.Length);
bw.Write(scriptData); // ScriptData
return s.ToArray();
}
}
// Overworld Functions
private const int flen = 0x14;
private const int nlen = 0x30;
private const int wlen = 0x18;
private const int tlen = 0x18;
#region Enabling
internal static void toggleEnable(NumericUpDown master, NumericUpDown slave)
{
@@ -306,18 +259,46 @@ internal static void toggleEnable(NumericUpDown master, NumericUpDown slave)
}
private void changeFurnitureCount(object sender, EventArgs e)
{
// Resize array
int count = (int)NUD_FurnCount.Value;
CurrentZone.Entities.FurnitureCount = count;
Array.Resize(ref CurrentZone.Entities.Furniture, count);
for (int i = 0; i < count; i++)
CurrentZone.Entities.Furniture[i] = CurrentZone.Entities.Furniture[i] ?? new Zone.ZoneEntities.EntityFurniture();
toggleEnable(NUD_FurnCount, NUD_FE);
}
private void changeNPCCount(object sender, EventArgs e)
{
// Resize array
int count = (int)NUD_NPCCount.Value;
CurrentZone.Entities.NPCCount = count;
Array.Resize(ref CurrentZone.Entities.NPCs, count);
for (int i = 0; i < count; i++)
CurrentZone.Entities.NPCs[i] = CurrentZone.Entities.NPCs[i] ?? new Zone.ZoneEntities.EntityNPC();
toggleEnable(NUD_NPCCount, NUD_NE);
}
private void changeWarpCount(object sender, EventArgs e)
{
// Resize array
int count = (int)NUD_WarpCount.Value;
CurrentZone.Entities.WarpCount = count;
Array.Resize(ref CurrentZone.Entities.Warps, count);
for (int i = 0; i < count; i++)
CurrentZone.Entities.Warps[i] = CurrentZone.Entities.Warps[i] ?? new Zone.ZoneEntities.EntityWarp();
toggleEnable(NUD_WarpCount, NUD_WE);
}
private void changeTriggerCount(object sender, EventArgs e)
{
// Resize array
int count = (int)NUD_TrigCount.Value;
CurrentZone.Entities.TriggerCount = count;
Array.Resize(ref CurrentZone.Entities.Triggers, count);
for (int i = 0; i < count; i++)
CurrentZone.Entities.Triggers[i] = CurrentZone.Entities.Triggers[i] ?? new Zone.ZoneEntities.EntityTrigger();
toggleEnable(NUD_TrigCount, NUD_TE);
}
#endregion
@@ -329,14 +310,13 @@ private void changeFurniture(object sender, EventArgs e)
// Set Old Data
if (fEntry > 0)
{
byte[] oldData = fData[fEntry];
fData[fEntry] = oldData;
// No attributes editable atm
}
fEntry = (int)NUD_FE.Value;
// Load New Data
byte[] data = fData[fEntry];
RTB_F.Text = Util.getHexString(data);
var Furniture = CurrentZone.Entities.Furniture[fEntry];
RTB_F.Text = Util.getHexString(Furniture.Raw);
}
private void changeOverworld(object sender, EventArgs e)
{
@@ -345,18 +325,32 @@ private void changeOverworld(object sender, EventArgs e)
// Set Old Data
if (nEntry > 0)
{
byte[] oldData = nData[nEntry];
nData[nEntry] = oldData;
var n = CurrentZone.Entities.NPCs[nEntry];
n.ID = (int)NUD_NID.Value;
n.Model = (int)NUD_NModel.Value;
n.SpawnFlag = (int)NUD_NFlag.Value;
n.Script = (int)NUD_NScript.Value;
n.FaceDirection = (int)NUD_NFace.Value;
n.X = (int)NUD_NX.Value;
n.Y = (int)NUD_NY.Value;
}
nEntry = (int)NUD_NE.Value;
// Load New Data
byte[] data = nData[nEntry];
RTB_O.Text = Util.getHexString(data);
var NPC = CurrentZone.Entities.NPCs[nEntry];
ushort ID = BitConverter.ToUInt16(data, 0x4);
// Load new Attributes
NUD_NID.Value = NPC.ID;
NUD_NModel.Value = NPC.Model;
NUD_NFlag.Value = NPC.SpawnFlag;
NUD_NScript.Value = NPC.Script;
NUD_OID.Value = ID;
NUD_NFace.Value = NPC.FaceDirection;
NUD_NX.Value = NPC.X;
NUD_NY.Value = NPC.Y;
RTB_N.Text = Util.getHexString(NPC.Raw);
}
private void changeWarp(object sender, EventArgs e)
{
@@ -365,24 +359,21 @@ private void changeWarp(object sender, EventArgs e)
// Set Old Data
if (wEntry > 0)
{
byte[] oldData = wData[wEntry];
wData[wEntry] = oldData;
CurrentZone.Entities.Warps[wEntry].DestinationMap = (int)NUD_WMap.Value;
CurrentZone.Entities.Warps[wEntry].DestinationTileIndex = (int)NUD_WTile.Value;
}
wEntry = (int)NUD_WE.Value;
// Load New Data
byte[] data = wData[wEntry];
RTB_W.Text = Util.getHexString(data);
var Warp = CurrentZone.Entities.Warps[wEntry];
RTB_W.Text = Util.getHexString(Warp.Raw);
ushort Map = BitConverter.ToUInt16(data, 0x4);
ushort Dest = BitConverter.ToUInt16(data, 0x6);
// Load new Attributes
NUD_WMap.Value = Warp.DestinationMap;
NUD_WTile.Value = Warp.DestinationTileIndex;
// Flavor Mods
string MapName = zdLocations[Map];
L_WarpDest.Text = MapName;
NUD_WMap.Value = Map;
NUD_WTile.Value = Dest;
L_WarpDest.Text = zdLocations[Warp.DestinationMap];
}
private void changeTrigger(object sender, EventArgs e)
{
@@ -391,14 +382,13 @@ private void changeTrigger(object sender, EventArgs e)
// Set Old Data
if (tEntry > 0)
{
byte[] oldData = tData[tEntry];
tData[tEntry] = oldData;
// No attributes editable atm
}
tEntry = (int)NUD_TE.Value;
// Load New Data
byte[] data = tData[tEntry];
RTB_T.Text = Util.getHexString(data);
var Trigger = CurrentZone.Entities.Triggers[tEntry];
RTB_T.Text = Util.getHexString(Trigger.Raw);
}
private void B_HLCMD_Click(object sender, EventArgs e)
@@ -407,7 +397,6 @@ private void B_HLCMD_Click(object sender, EventArgs e)
Util.Alert(String.Format("{0} instance{1} of \"*\" present.", ctr, ctr > 1 ? "s" : ""));
}
private void tabMain_DragEnter(object sender, DragEventArgs e)
{
if (e.Data.GetDataPresent(DataFormats.FileDrop)) e.Effect = DragDropEffects.Copy;

View File

@@ -30,9 +30,9 @@ private void InitializeComponent()
{
this.CB_LocationID = new System.Windows.Forms.ComboBox();
this.L_Location = new System.Windows.Forms.Label();
this.RTB_MapInfo = new System.Windows.Forms.RichTextBox();
this.RTB_ZD = new System.Windows.Forms.RichTextBox();
this.tabControl1 = new System.Windows.Forms.TabControl();
this.tb_MapInfo = new System.Windows.Forms.TabPage();
this.tb_ZoneData = new System.Windows.Forms.TabPage();
this.L_MapInfoTabData = new System.Windows.Forms.Label();
this.tb_OWSC = new System.Windows.Forms.TabPage();
this.L_OWEntities = new System.Windows.Forms.Label();
@@ -48,11 +48,11 @@ private void InitializeComponent()
this.NUD_FE = new System.Windows.Forms.NumericUpDown();
this.L_FE = new System.Windows.Forms.Label();
this.tb_Overworld = new System.Windows.Forms.TabPage();
this.NUD_OID = new System.Windows.Forms.NumericUpDown();
this.L_OID = new System.Windows.Forms.Label();
this.NUD_NID = new System.Windows.Forms.NumericUpDown();
this.L_NID = new System.Windows.Forms.Label();
this.NUD_NE = new System.Windows.Forms.NumericUpDown();
this.L_NE = new System.Windows.Forms.Label();
this.RTB_O = new System.Windows.Forms.RichTextBox();
this.RTB_N = new System.Windows.Forms.RichTextBox();
this.tb_Warp = new System.Windows.Forms.TabPage();
this.L_WarpDest = new System.Windows.Forms.Label();
this.NUD_WTile = new System.Windows.Forms.NumericUpDown();
@@ -84,12 +84,12 @@ private void InitializeComponent()
this.L_File5TabData = new System.Windows.Forms.Label();
this.tb_RAW = new System.Windows.Forms.TabPage();
this.L_File3 = new System.Windows.Forms.Label();
this.L_ZD = new System.Windows.Forms.Label();
this.L_ZDMaster = new System.Windows.Forms.Label();
this.L_File5 = new System.Windows.Forms.Label();
this.L_File4 = new System.Windows.Forms.Label();
this.L_File2 = new System.Windows.Forms.Label();
this.L_File1 = new System.Windows.Forms.Label();
this.RTB_zonedata = new System.Windows.Forms.RichTextBox();
this.RTB_ZDMaster = new System.Windows.Forms.RichTextBox();
this.RTB_File5 = new System.Windows.Forms.RichTextBox();
this.RTB_OWSC = new System.Windows.Forms.RichTextBox();
this.RTB_Encounter = new System.Windows.Forms.RichTextBox();
@@ -103,8 +103,22 @@ private void InitializeComponent()
this.PB_Map = new System.Windows.Forms.PictureBox();
this.L_ZDPreview = new System.Windows.Forms.Label();
this.B_HLCMD = new System.Windows.Forms.Button();
this.CHK_AutoDraw = new System.Windows.Forms.CheckBox();
this.GB_N = new System.Windows.Forms.GroupBox();
this.NUD_NModel = new System.Windows.Forms.NumericUpDown();
this.L_NModel = new System.Windows.Forms.Label();
this.NUD_NX = new System.Windows.Forms.NumericUpDown();
this.L_NX = new System.Windows.Forms.Label();
this.NUD_NY = new System.Windows.Forms.NumericUpDown();
this.L_NY = new System.Windows.Forms.Label();
this.NUD_NFace = new System.Windows.Forms.NumericUpDown();
this.L_NFaceDirection = new System.Windows.Forms.Label();
this.NUD_NScript = new System.Windows.Forms.NumericUpDown();
this.L_NScript = new System.Windows.Forms.Label();
this.NUD_NFlag = new System.Windows.Forms.NumericUpDown();
this.L_NFlag = new System.Windows.Forms.Label();
this.tabControl1.SuspendLayout();
this.tb_MapInfo.SuspendLayout();
this.tb_ZoneData.SuspendLayout();
this.tb_OWSC.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.NUD_TrigCount)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.NUD_WarpCount)).BeginInit();
@@ -113,7 +127,7 @@ private void InitializeComponent()
this.tb_Furniture.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.NUD_FE)).BeginInit();
this.tb_Overworld.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.NUD_OID)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.NUD_NID)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.NUD_NE)).BeginInit();
this.tb_Warp.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.NUD_WTile)).BeginInit();
@@ -131,6 +145,13 @@ private void InitializeComponent()
((System.ComponentModel.ISupportInitialize)(this.NUD_Scale)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.NUD_Flavor)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.PB_Map)).BeginInit();
this.GB_N.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.NUD_NModel)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.NUD_NX)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.NUD_NY)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.NUD_NFace)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.NUD_NScript)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.NUD_NFlag)).BeginInit();
this.SuspendLayout();
//
// CB_LocationID
@@ -154,22 +175,22 @@ private void InitializeComponent()
this.L_Location.TabIndex = 411;
this.L_Location.Text = "Loc:";
//
// RTB_MapInfo
// RTB_ZD
//
this.RTB_MapInfo.Font = new System.Drawing.Font("Courier New", 6.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.RTB_MapInfo.Location = new System.Drawing.Point(217, 3);
this.RTB_MapInfo.Name = "RTB_MapInfo";
this.RTB_MapInfo.ReadOnly = true;
this.RTB_MapInfo.Size = new System.Drawing.Size(266, 36);
this.RTB_MapInfo.TabIndex = 412;
this.RTB_MapInfo.Text = "00 11 22 33 44 55 66 77 88 99 AA BB CC DD EE FF";
this.RTB_ZD.Font = new System.Drawing.Font("Courier New", 6.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.RTB_ZD.Location = new System.Drawing.Point(217, 3);
this.RTB_ZD.Name = "RTB_ZD";
this.RTB_ZD.ReadOnly = true;
this.RTB_ZD.Size = new System.Drawing.Size(266, 36);
this.RTB_ZD.TabIndex = 412;
this.RTB_ZD.Text = "00 11 22 33 44 55 66 77 88 99 AA BB CC DD EE FF";
//
// tabControl1
//
this.tabControl1.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.tabControl1.Controls.Add(this.tb_MapInfo);
this.tabControl1.Controls.Add(this.tb_ZoneData);
this.tabControl1.Controls.Add(this.tb_OWSC);
this.tabControl1.Controls.Add(this.tb_MSC);
this.tabControl1.Controls.Add(this.tb_Encounters);
@@ -182,16 +203,16 @@ private void InitializeComponent()
this.tabControl1.Size = new System.Drawing.Size(494, 497);
this.tabControl1.TabIndex = 417;
//
// tb_MapInfo
// tb_ZoneData
//
this.tb_MapInfo.Controls.Add(this.L_MapInfoTabData);
this.tb_MapInfo.Location = new System.Drawing.Point(4, 22);
this.tb_MapInfo.Name = "tb_MapInfo";
this.tb_MapInfo.Padding = new System.Windows.Forms.Padding(3);
this.tb_MapInfo.Size = new System.Drawing.Size(486, 471);
this.tb_MapInfo.TabIndex = 0;
this.tb_MapInfo.Text = "Map Info";
this.tb_MapInfo.UseVisualStyleBackColor = true;
this.tb_ZoneData.Controls.Add(this.L_MapInfoTabData);
this.tb_ZoneData.Location = new System.Drawing.Point(4, 22);
this.tb_ZoneData.Name = "tb_ZoneData";
this.tb_ZoneData.Padding = new System.Windows.Forms.Padding(3);
this.tb_ZoneData.Size = new System.Drawing.Size(486, 471);
this.tb_ZoneData.TabIndex = 0;
this.tb_ZoneData.Text = "ZoneData";
this.tb_ZoneData.UseVisualStyleBackColor = true;
//
// L_MapInfoTabData
//
@@ -368,11 +389,9 @@ private void InitializeComponent()
//
// tb_Overworld
//
this.tb_Overworld.Controls.Add(this.NUD_OID);
this.tb_Overworld.Controls.Add(this.L_OID);
this.tb_Overworld.Controls.Add(this.GB_N);
this.tb_Overworld.Controls.Add(this.NUD_NE);
this.tb_Overworld.Controls.Add(this.L_NE);
this.tb_Overworld.Controls.Add(this.RTB_O);
this.tb_Overworld.Location = new System.Drawing.Point(4, 22);
this.tb_Overworld.Name = "tb_Overworld";
this.tb_Overworld.Padding = new System.Windows.Forms.Padding(3);
@@ -381,26 +400,26 @@ private void InitializeComponent()
this.tb_Overworld.Text = "Overworld";
this.tb_Overworld.UseVisualStyleBackColor = true;
//
// NUD_OID
// NUD_NID
//
this.NUD_OID.Location = new System.Drawing.Point(129, 33);
this.NUD_OID.Maximum = new decimal(new int[] {
999,
this.NUD_NID.Location = new System.Drawing.Point(93, 16);
this.NUD_NID.Maximum = new decimal(new int[] {
65535,
0,
0,
0});
this.NUD_OID.Name = "NUD_OID";
this.NUD_OID.Size = new System.Drawing.Size(53, 20);
this.NUD_OID.TabIndex = 435;
this.NUD_NID.Name = "NUD_NID";
this.NUD_NID.Size = new System.Drawing.Size(53, 20);
this.NUD_NID.TabIndex = 435;
//
// L_OID
// L_NID
//
this.L_OID.Location = new System.Drawing.Point(3, 34);
this.L_OID.Name = "L_OID";
this.L_OID.Size = new System.Drawing.Size(120, 15);
this.L_OID.TabIndex = 433;
this.L_OID.Text = "Entity ID:";
this.L_OID.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
this.L_NID.Location = new System.Drawing.Point(11, 16);
this.L_NID.Name = "L_NID";
this.L_NID.Size = new System.Drawing.Size(76, 16);
this.L_NID.TabIndex = 433;
this.L_NID.Text = "Entity ID:";
this.L_NID.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
//
// NUD_NE
//
@@ -424,15 +443,16 @@ private void InitializeComponent()
this.L_NE.Text = "Entry:";
this.L_NE.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
//
// RTB_O
// RTB_N
//
this.RTB_O.Font = new System.Drawing.Font("Courier New", 6.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.RTB_O.Location = new System.Drawing.Point(2, 268);
this.RTB_O.Name = "RTB_O";
this.RTB_O.ReadOnly = true;
this.RTB_O.Size = new System.Drawing.Size(245, 42);
this.RTB_O.TabIndex = 414;
this.RTB_O.Text = "00 11 22 33 44 55 66 77 88 99 AA BB CC DD EE FF 00 11 22 33 44 55 66 77 88 99 AA " +
this.RTB_N.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
this.RTB_N.Font = new System.Drawing.Font("Courier New", 6.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.RTB_N.Location = new System.Drawing.Point(6, 275);
this.RTB_N.Name = "RTB_N";
this.RTB_N.ReadOnly = true;
this.RTB_N.Size = new System.Drawing.Size(245, 42);
this.RTB_N.TabIndex = 414;
this.RTB_N.Text = "00 11 22 33 44 55 66 77 88 99 AA BB CC DD EE FF 00 11 22 33 44 55 66 77 88 99 AA " +
"BB CC DD EE FF 00 11 22 33 44 55 66 77 88 99 AA BB CC DD EE FF ";
//
// tb_Warp
@@ -756,13 +776,13 @@ private void InitializeComponent()
// tb_RAW
//
this.tb_RAW.Controls.Add(this.L_File3);
this.tb_RAW.Controls.Add(this.L_ZD);
this.tb_RAW.Controls.Add(this.L_ZDMaster);
this.tb_RAW.Controls.Add(this.L_File5);
this.tb_RAW.Controls.Add(this.L_File4);
this.tb_RAW.Controls.Add(this.L_File2);
this.tb_RAW.Controls.Add(this.L_File1);
this.tb_RAW.Controls.Add(this.RTB_zonedata);
this.tb_RAW.Controls.Add(this.RTB_MapInfo);
this.tb_RAW.Controls.Add(this.RTB_ZDMaster);
this.tb_RAW.Controls.Add(this.RTB_ZD);
this.tb_RAW.Controls.Add(this.RTB_File5);
this.tb_RAW.Controls.Add(this.RTB_OWSC);
this.tb_RAW.Controls.Add(this.RTB_Encounter);
@@ -783,14 +803,14 @@ private void InitializeComponent()
this.L_File3.Text = "Map Environment [3]:";
this.L_File3.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
//
// L_ZD
// L_ZDMaster
//
this.L_ZD.Location = new System.Drawing.Point(-4, 277);
this.L_ZD.Name = "L_ZD";
this.L_ZD.Size = new System.Drawing.Size(141, 23);
this.L_ZD.TabIndex = 428;
this.L_ZD.Text = "ZoneData Information:";
this.L_ZD.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
this.L_ZDMaster.Location = new System.Drawing.Point(-4, 277);
this.L_ZDMaster.Name = "L_ZDMaster";
this.L_ZDMaster.Size = new System.Drawing.Size(141, 23);
this.L_ZDMaster.TabIndex = 428;
this.L_ZDMaster.Text = "Master ZoneData Table:";
this.L_ZDMaster.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
//
// L_File5
//
@@ -825,18 +845,18 @@ private void InitializeComponent()
this.L_File1.Name = "L_File1";
this.L_File1.Size = new System.Drawing.Size(141, 23);
this.L_File1.TabIndex = 423;
this.L_File1.Text = "Map Info [1]:";
this.L_File1.Text = "ZoneData [1]:";
this.L_File1.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
//
// RTB_zonedata
// RTB_ZDMaster
//
this.RTB_zonedata.Font = new System.Drawing.Font("Courier New", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.RTB_zonedata.Location = new System.Drawing.Point(143, 279);
this.RTB_zonedata.Name = "RTB_zonedata";
this.RTB_zonedata.ReadOnly = true;
this.RTB_zonedata.Size = new System.Drawing.Size(340, 64);
this.RTB_zonedata.TabIndex = 422;
this.RTB_zonedata.Text = "00 11 22 33 44 55 66 77 88 99 AA BB CC DD EE FF 00 11 22 33 44 55 66 77 88 99 AA " +
this.RTB_ZDMaster.Font = new System.Drawing.Font("Courier New", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.RTB_ZDMaster.Location = new System.Drawing.Point(143, 279);
this.RTB_ZDMaster.Name = "RTB_ZDMaster";
this.RTB_ZDMaster.ReadOnly = true;
this.RTB_ZDMaster.Size = new System.Drawing.Size(340, 64);
this.RTB_ZDMaster.TabIndex = 422;
this.RTB_ZDMaster.Text = "00 11 22 33 44 55 66 77 88 99 AA BB CC DD EE FF 00 11 22 33 44 55 66 77 88 99 AA " +
"BB CC DD EE FF 00 11 22 33 44 55 66 77 88 99 AA BB CC DD EE FF 00 11 22 33 44 55" +
" 66 77 88 99 AA BB CC DD EE FF";
//
@@ -882,6 +902,7 @@ private void InitializeComponent()
//
// tb_Map
//
this.tb_Map.Controls.Add(this.CHK_AutoDraw);
this.tb_Map.Controls.Add(this.B_Redraw);
this.tb_Map.Controls.Add(this.L_Scale);
this.tb_Map.Controls.Add(this.NUD_Scale);
@@ -987,6 +1008,166 @@ private void InitializeComponent()
this.B_HLCMD.UseVisualStyleBackColor = true;
this.B_HLCMD.Click += new System.EventHandler(this.B_HLCMD_Click);
//
// CHK_AutoDraw
//
this.CHK_AutoDraw.AutoSize = true;
this.CHK_AutoDraw.Location = new System.Drawing.Point(261, 7);
this.CHK_AutoDraw.Name = "CHK_AutoDraw";
this.CHK_AutoDraw.Size = new System.Drawing.Size(76, 17);
this.CHK_AutoDraw.TabIndex = 10;
this.CHK_AutoDraw.Text = "Auto-Draw";
this.CHK_AutoDraw.UseVisualStyleBackColor = true;
//
// GB_N
//
this.GB_N.Controls.Add(this.NUD_NFlag);
this.GB_N.Controls.Add(this.L_NFlag);
this.GB_N.Controls.Add(this.NUD_NScript);
this.GB_N.Controls.Add(this.L_NScript);
this.GB_N.Controls.Add(this.NUD_NFace);
this.GB_N.Controls.Add(this.L_NFaceDirection);
this.GB_N.Controls.Add(this.NUD_NY);
this.GB_N.Controls.Add(this.L_NY);
this.GB_N.Controls.Add(this.NUD_NX);
this.GB_N.Controls.Add(this.L_NX);
this.GB_N.Controls.Add(this.NUD_NModel);
this.GB_N.Controls.Add(this.L_NModel);
this.GB_N.Controls.Add(this.RTB_N);
this.GB_N.Controls.Add(this.NUD_NID);
this.GB_N.Controls.Add(this.L_NID);
this.GB_N.Location = new System.Drawing.Point(6, 60);
this.GB_N.Name = "GB_N";
this.GB_N.Size = new System.Drawing.Size(256, 323);
this.GB_N.TabIndex = 436;
this.GB_N.TabStop = false;
this.GB_N.Text = "Info:";
//
// NUD_NModel
//
this.NUD_NModel.Location = new System.Drawing.Point(93, 42);
this.NUD_NModel.Maximum = new decimal(new int[] {
65535,
0,
0,
0});
this.NUD_NModel.Name = "NUD_NModel";
this.NUD_NModel.Size = new System.Drawing.Size(53, 20);
this.NUD_NModel.TabIndex = 437;
//
// L_NModel
//
this.L_NModel.Location = new System.Drawing.Point(11, 42);
this.L_NModel.Name = "L_NModel";
this.L_NModel.Size = new System.Drawing.Size(76, 16);
this.L_NModel.TabIndex = 436;
this.L_NModel.Text = "Model:";
this.L_NModel.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
//
// NUD_NX
//
this.NUD_NX.Location = new System.Drawing.Point(93, 180);
this.NUD_NX.Maximum = new decimal(new int[] {
65535,
0,
0,
0});
this.NUD_NX.Name = "NUD_NX";
this.NUD_NX.Size = new System.Drawing.Size(53, 20);
this.NUD_NX.TabIndex = 439;
//
// L_NX
//
this.L_NX.Location = new System.Drawing.Point(11, 180);
this.L_NX.Name = "L_NX";
this.L_NX.Size = new System.Drawing.Size(76, 16);
this.L_NX.TabIndex = 438;
this.L_NX.Text = "X Coordinate:";
this.L_NX.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
//
// NUD_NY
//
this.NUD_NY.Location = new System.Drawing.Point(93, 206);
this.NUD_NY.Maximum = new decimal(new int[] {
65535,
0,
0,
0});
this.NUD_NY.Name = "NUD_NY";
this.NUD_NY.Size = new System.Drawing.Size(53, 20);
this.NUD_NY.TabIndex = 441;
//
// L_NY
//
this.L_NY.Location = new System.Drawing.Point(11, 206);
this.L_NY.Name = "L_NY";
this.L_NY.Size = new System.Drawing.Size(76, 16);
this.L_NY.TabIndex = 440;
this.L_NY.Text = "Y Coordinate:";
this.L_NY.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
//
// NUD_NFace
//
this.NUD_NFace.Location = new System.Drawing.Point(93, 154);
this.NUD_NFace.Maximum = new decimal(new int[] {
65535,
0,
0,
0});
this.NUD_NFace.Name = "NUD_NFace";
this.NUD_NFace.Size = new System.Drawing.Size(53, 20);
this.NUD_NFace.TabIndex = 443;
//
// L_NFaceDirection
//
this.L_NFaceDirection.Location = new System.Drawing.Point(11, 154);
this.L_NFaceDirection.Name = "L_NFaceDirection";
this.L_NFaceDirection.Size = new System.Drawing.Size(76, 16);
this.L_NFaceDirection.TabIndex = 442;
this.L_NFaceDirection.Text = "Facing:";
this.L_NFaceDirection.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
//
// NUD_NScript
//
this.NUD_NScript.Location = new System.Drawing.Point(93, 94);
this.NUD_NScript.Maximum = new decimal(new int[] {
65535,
0,
0,
0});
this.NUD_NScript.Name = "NUD_NScript";
this.NUD_NScript.Size = new System.Drawing.Size(53, 20);
this.NUD_NScript.TabIndex = 445;
//
// L_NScript
//
this.L_NScript.Location = new System.Drawing.Point(11, 94);
this.L_NScript.Name = "L_NScript";
this.L_NScript.Size = new System.Drawing.Size(76, 16);
this.L_NScript.TabIndex = 444;
this.L_NScript.Text = "Script:";
this.L_NScript.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
//
// NUD_NFlag
//
this.NUD_NFlag.Location = new System.Drawing.Point(93, 68);
this.NUD_NFlag.Maximum = new decimal(new int[] {
65535,
0,
0,
0});
this.NUD_NFlag.Name = "NUD_NFlag";
this.NUD_NFlag.Size = new System.Drawing.Size(53, 20);
this.NUD_NFlag.TabIndex = 447;
//
// L_NFlag
//
this.L_NFlag.Location = new System.Drawing.Point(11, 68);
this.L_NFlag.Name = "L_NFlag";
this.L_NFlag.Size = new System.Drawing.Size(76, 16);
this.L_NFlag.TabIndex = 446;
this.L_NFlag.Text = "Spawn Flag:";
this.L_NFlag.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
//
// OWSE
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
@@ -1003,8 +1184,8 @@ private void InitializeComponent()
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
this.Text = "Overworld Editor";
this.tabControl1.ResumeLayout(false);
this.tb_MapInfo.ResumeLayout(false);
this.tb_MapInfo.PerformLayout();
this.tb_ZoneData.ResumeLayout(false);
this.tb_ZoneData.PerformLayout();
this.tb_OWSC.ResumeLayout(false);
this.tb_OWSC.PerformLayout();
((System.ComponentModel.ISupportInitialize)(this.NUD_TrigCount)).EndInit();
@@ -1014,7 +1195,7 @@ private void InitializeComponent()
this.tb_Furniture.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.NUD_FE)).EndInit();
this.tb_Overworld.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.NUD_OID)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.NUD_NID)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.NUD_NE)).EndInit();
this.tb_Warp.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.NUD_WTile)).EndInit();
@@ -1037,6 +1218,13 @@ private void InitializeComponent()
((System.ComponentModel.ISupportInitialize)(this.NUD_Scale)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.NUD_Flavor)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.PB_Map)).EndInit();
this.GB_N.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.NUD_NModel)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.NUD_NX)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.NUD_NY)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.NUD_NFace)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.NUD_NScript)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.NUD_NFlag)).EndInit();
this.ResumeLayout(false);
this.PerformLayout();
@@ -1046,9 +1234,9 @@ private void InitializeComponent()
private System.Windows.Forms.ComboBox CB_LocationID;
private System.Windows.Forms.Label L_Location;
private System.Windows.Forms.RichTextBox RTB_MapInfo;
private System.Windows.Forms.RichTextBox RTB_ZD;
private System.Windows.Forms.TabControl tabControl1;
private System.Windows.Forms.TabPage tb_MapInfo;
private System.Windows.Forms.TabPage tb_ZoneData;
private System.Windows.Forms.TabPage tb_OWSC;
private System.Windows.Forms.TabPage tb_MSC;
private System.Windows.Forms.TabPage tb_Encounters;
@@ -1056,7 +1244,7 @@ private void InitializeComponent()
private System.Windows.Forms.TabControl tc_OWSC;
private System.Windows.Forms.TabPage tb_Furniture;
private System.Windows.Forms.TabPage tb_Overworld;
private System.Windows.Forms.RichTextBox RTB_O;
private System.Windows.Forms.RichTextBox RTB_N;
private System.Windows.Forms.TabPage tb_Warp;
private System.Windows.Forms.TabPage tb_Trigger;
private System.Windows.Forms.RichTextBox RTB_OWSC;
@@ -1080,7 +1268,7 @@ private void InitializeComponent()
private System.Windows.Forms.NumericUpDown NUD_TE;
private System.Windows.Forms.Label L_TE;
private System.Windows.Forms.TabPage tb_Script;
private System.Windows.Forms.RichTextBox RTB_zonedata;
private System.Windows.Forms.RichTextBox RTB_ZDMaster;
private System.Windows.Forms.RichTextBox RTB_F;
private System.Windows.Forms.RichTextBox RTB_W;
private System.Windows.Forms.RichTextBox RTB_T;
@@ -1094,13 +1282,13 @@ private void InitializeComponent()
private System.Windows.Forms.Label L_MSSCDesc;
private System.Windows.Forms.RichTextBox RTB_MS;
private System.Windows.Forms.Label L_WarpDest;
private System.Windows.Forms.NumericUpDown NUD_OID;
private System.Windows.Forms.Label L_OID;
private System.Windows.Forms.NumericUpDown NUD_NID;
private System.Windows.Forms.Label L_NID;
private System.Windows.Forms.Label L_ZDPreview;
private System.Windows.Forms.RichTextBox RTB_OS;
private System.Windows.Forms.RichTextBox RTB_MSCMD;
private System.Windows.Forms.Label L_Encounters;
private System.Windows.Forms.Label L_ZD;
private System.Windows.Forms.Label L_ZDMaster;
private System.Windows.Forms.Label L_File5;
private System.Windows.Forms.Label L_File4;
private System.Windows.Forms.Label L_File2;
@@ -1119,6 +1307,20 @@ private void InitializeComponent()
private System.Windows.Forms.Button B_Redraw;
private System.Windows.Forms.Label L_Scale;
private System.Windows.Forms.NumericUpDown NUD_Scale;
private System.Windows.Forms.CheckBox CHK_AutoDraw;
private System.Windows.Forms.GroupBox GB_N;
private System.Windows.Forms.NumericUpDown NUD_NModel;
private System.Windows.Forms.Label L_NModel;
private System.Windows.Forms.NumericUpDown NUD_NY;
private System.Windows.Forms.Label L_NY;
private System.Windows.Forms.NumericUpDown NUD_NX;
private System.Windows.Forms.Label L_NX;
private System.Windows.Forms.NumericUpDown NUD_NFace;
private System.Windows.Forms.Label L_NFaceDirection;
private System.Windows.Forms.NumericUpDown NUD_NScript;
private System.Windows.Forms.Label L_NScript;
private System.Windows.Forms.NumericUpDown NUD_NFlag;
private System.Windows.Forms.Label L_NFlag;
}
}