Peds form progress, playing peds animations and loading some textures

This commit is contained in:
dexy 2019-11-07 23:14:39 +11:00
parent 8bfca3a338
commit 465b21d7ac
9 changed files with 687 additions and 395 deletions

View File

@ -1,5 +1,6 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.IO;
using System.Linq;
using System.Text;
@ -7,6 +8,7 @@ using System.Threading.Tasks;
namespace CodeWalker.GameFiles
{
[TypeConverter(typeof(ExpandableObjectConverter))]
public class YtdFile : GameFile, PackedFile
{
public TextureDictionary TextureDict { get; set; }

View File

@ -3493,6 +3493,7 @@ namespace CodeWalker.GameFiles
SpecialAbilityType = 2011786168,
DefaultSpawnPreference = 888587604,
numAlternatives = 2806194106,
bHasDrawblVariations = 4086467184,
CScenarioChainingEdge__eAction = 3609807418,
CScenarioChainingEdge__eNavMode = 3971773454,
@ -3553,13 +3554,13 @@ namespace CodeWalker.GameFiles
numAvailProps = 2598445407,
numAvailTex = 3371516811,
ownsCloth = 2828247905,
aComponentData3 = 3796409423, //is this a collision? it's good enough for now!
aComponentData3 = 3796409423,
aDrawblData3 = 1756136273,
bHasTexVariations = 1235281004,
//GranularSound dat54.rel FileName hashes from NotGigo
engine_accel = 3748922026,
exhaust_accel = 598446449,

View File

@ -1018,7 +1018,7 @@ namespace CodeWalker.GameFiles
case MetaName.CPedVariationInfo:
return new MetaStructureInfo(MetaName.CPedVariationInfo, 4030871161, 768, 112,
new MetaStructureEntryInfo_s(MetaName.bHasTexVariations, 0, MetaStructureEntryDataType.Boolean, 0, 0, 0),
new MetaStructureEntryInfo_s((MetaName)4086467184, 1, MetaStructureEntryDataType.Boolean, 0, 0, 0),
new MetaStructureEntryInfo_s(MetaName.bHasDrawblVariations, 1, MetaStructureEntryDataType.Boolean, 0, 0, 0),
new MetaStructureEntryInfo_s((MetaName)911147899, 2, MetaStructureEntryDataType.Boolean, 0, 0, 0),
new MetaStructureEntryInfo_s((MetaName)315291935, 3, MetaStructureEntryDataType.Boolean, 0, 0, 0),
new MetaStructureEntryInfo_s((MetaName)MetaTypeName.ARRAYINFO, 0, MetaStructureEntryDataType.UnsignedByte, 0, 0, 0),
@ -1036,7 +1036,7 @@ namespace CodeWalker.GameFiles
return new MetaStructureInfo((MetaName)3538495220, 2024084511, 768, 24,
new MetaStructureEntryInfo_s(MetaName.numAvailTex, 0, MetaStructureEntryDataType.UnsignedByte, 0, 0, 0),
new MetaStructureEntryInfo_s((MetaName)MetaTypeName.ARRAYINFO, 0, MetaStructureEntryDataType.Structure, 0, 0, (MetaName)1535046754),
new MetaStructureEntryInfo_s((MetaName)1756136273, 8, MetaStructureEntryDataType.Array, 0, 1, 0)
new MetaStructureEntryInfo_s(MetaName.aDrawblData3, 8, MetaStructureEntryDataType.Array, 0, 1, 0)
);
case (MetaName)2236980467:
return new MetaStructureInfo((MetaName)2236980467, 508935687, 0, 24,
@ -5993,7 +5993,7 @@ namespace CodeWalker.GameFiles
public struct CPedVariationInfo : IPsoSwapEnd //112 bytes, Key:4030871161 //COMPONENT PEDS YMT ROOT - in componentpeds .rpf's
{
public byte bHasTexVariations { get; set; } //0 0: Boolean: 0: bHasTexVariations
public byte Unk_4086467184 { get; set; } //1 1: Boolean: 0: 4086467184
public byte bHasDrawblVariations { get; set; } //1 1: Boolean: 0: bHasDrawblVariations
public byte Unk_911147899 { get; set; } //2 2: Boolean: 0: 911147899
public byte Unk_315291935 { get; set; } //3 3: Boolean: 0: 315291935
public ArrayOfBytes12 Unk_2996560424 { get; set; } //4 4: ArrayOfBytes: 12: 2996560424
@ -6019,7 +6019,7 @@ namespace CodeWalker.GameFiles
public CPedVariationInfo Data { get { return _Data; } }
public byte[] ComponentIndices { get; set; }
public MUnk_3538495220[] ComponentVariations { get; set; }
public MUnk_3538495220[] ComponentData3 { get; set; }
public MCPedSelectionSet[] SelectionSets { get; set; }
public MCComponentInfo[] CompInfos { get; set; }
public MCPedPropInfo PropInfo { get; set; }
@ -6040,13 +6040,13 @@ namespace CodeWalker.GameFiles
ComponentIndices = data.Unk_2996560424.GetArray();
var vComponentVariations = MetaTypes.ConvertDataArray<Unk_3538495220>(meta, (MetaName)3538495220, _Data.aComponentData3);
if (vComponentVariations != null)
var aComponentData3 = MetaTypes.ConvertDataArray<Unk_3538495220>(meta, (MetaName)3538495220, _Data.aComponentData3);
if (aComponentData3 != null)
{
ComponentVariations = new MUnk_3538495220[vComponentVariations.Length];
for (int i = 0; i < vComponentVariations.Length; i++)
ComponentData3 = new MUnk_3538495220[aComponentData3.Length];
for (int i = 0; i < aComponentData3.Length; i++)
{
ComponentVariations[i] = new MUnk_3538495220(meta, vComponentVariations[i], this);
ComponentData3[i] = new MUnk_3538495220(meta, aComponentData3[i], this);
}
}
@ -6077,14 +6077,14 @@ namespace CodeWalker.GameFiles
for (int i = 0; i < 12; i++) //set the component type indices on all the component variants, for them to use
{
var compInd = ComponentIndices[i];
if ((compInd > 0) && (compInd < ComponentVariations?.Length))
if ((compInd > 0) && (compInd < ComponentData3?.Length))
{
var compvar = ComponentVariations[compInd];
var compvar = ComponentData3[compInd];
compvar.ComponentType = i;
if (compvar.Variations != null)
if (compvar.DrawblData3 != null)
{
foreach (var cvp in compvar.Variations)
foreach (var cvp in compvar.DrawblData3)
{
cvp.ComponentType = i;
//cvp.GetDrawableName();//testing
@ -6108,13 +6108,13 @@ namespace CodeWalker.GameFiles
}
public MUnk_3538495220 GetVariations(int componentType)
public MUnk_3538495220 GetComponentData(int componentType)
{
if ((componentType < 0) || (componentType > 11)) return null;
if (ComponentIndices == null) return null;
var index = ComponentIndices[componentType];
if (index > ComponentVariations?.Length) return null;
return ComponentVariations[index];
if (index > ComponentData3?.Length) return null;
return ComponentData3[index];
}
}
@ -6125,7 +6125,7 @@ namespace CodeWalker.GameFiles
public byte Unused0 { get; set; }//1
public ushort Unused1 { get; set; }//2
public uint Unused2 { get; set; }//4
public Array_Structure Unk_1756136273 { get; set; } //8 8: Array: 0: 1756136273 {0: Structure: 1535046754: 256}
public Array_Structure aDrawblData3 { get; set; } //8 8: Array: 0: aDrawblData3 {0: Structure: 1535046754: 256}
}
public class MUnk_3538495220 : MetaWrapper
{
@ -6135,7 +6135,7 @@ namespace CodeWalker.GameFiles
public Unk_3538495220 Data { get { return _Data; } }
public MUnk_1535046754[] Variations { get; set; }
public MUnk_1535046754[] DrawblData3 { get; set; }
public int ComponentType { get; set; } = 0;
public static string[] ComponentTypeNames { get; } =
@ -6166,13 +6166,13 @@ namespace CodeWalker.GameFiles
private void Init(Meta meta)
{
var vVariations = MetaTypes.ConvertDataArray<Unk_1535046754>(meta, (MetaName)1535046754, _Data.Unk_1756136273);
if (vVariations != null)
var aDrawblData3 = MetaTypes.ConvertDataArray<Unk_1535046754>(meta, (MetaName)1535046754, _Data.aDrawblData3);
if (aDrawblData3 != null)
{
Variations = new MUnk_1535046754[vVariations.Length];
for (int i = 0; i < vVariations.Length; i++)
DrawblData3 = new MUnk_1535046754[aDrawblData3.Length];
for (int i = 0; i < aDrawblData3.Length; i++)
{
Variations[i] = new MUnk_1535046754(meta, vVariations[i], this, i);
DrawblData3[i] = new MUnk_1535046754(meta, aDrawblData3[i], this, i);
}
}
}
@ -6192,7 +6192,7 @@ namespace CodeWalker.GameFiles
public override string ToString()
{
string r = (ComponentType < 12) ? ComponentTypeNames[ComponentType] : "error";
return r + " : " + Variations?.Length.ToString() ?? base.ToString();
return r + " : " + DrawblData3?.Length.ToString() ?? base.ToString();
}
}

View File

@ -13213,7 +13213,7 @@ namespace CodeWalker.GameFiles
case MetaName.CPedVariationInfo:
return new PsoStructureInfo(MetaName.CPedVariationInfo, 0, 0, 112,
new PsoStructureEntryInfo(MetaName.bHasTexVariations, PsoDataType.Bool, 0, 0, 0),
new PsoStructureEntryInfo((MetaName)4086467184, PsoDataType.Bool, 1, 0, 0),
new PsoStructureEntryInfo(MetaName.bHasDrawblVariations, PsoDataType.Bool, 1, 0, 0),
new PsoStructureEntryInfo((MetaName)911147899, PsoDataType.Bool, 2, 0, 0),
new PsoStructureEntryInfo((MetaName)315291935, PsoDataType.Bool, 3, 0, 0),
new PsoStructureEntryInfo((MetaName)MetaTypeName.ARRAYINFO, PsoDataType.UByte, 0, 0, 0),
@ -13239,7 +13239,7 @@ namespace CodeWalker.GameFiles
return new PsoStructureInfo((MetaName)3538495220, 0, 0, 24,
new PsoStructureEntryInfo(MetaName.numAvailTex, PsoDataType.UByte, 0, 0, 0),
new PsoStructureEntryInfo((MetaName)MetaTypeName.ARRAYINFO, PsoDataType.Structure, 0, 0, (MetaName)1535046754),
new PsoStructureEntryInfo((MetaName)1756136273, PsoDataType.Array, 8, 0, (MetaName)1)
new PsoStructureEntryInfo(MetaName.aDrawblData3, PsoDataType.Array, 8, 0, (MetaName)1)
);
case (MetaName)1535046754:
return new PsoStructureInfo((MetaName)1535046754, 0, 0, 48,

View File

@ -749,6 +749,7 @@ namespace CodeWalker.GameFiles
public Vector4 EvaluateVector(int frame)
{
if (Channels == null) return Vector4.Zero;
if (IsType7Quat) return EvaluateQuaternion(frame).ToVector4();
var v = Vector4.Zero;
int c = 0;
for (int i = 0; i < Channels.Length; i++)

View File

@ -76,33 +76,38 @@
this.PedNameComboBox = new System.Windows.Forms.ComboBox();
this.StatsUpdateTimer = new System.Windows.Forms.Timer(this.components);
this.ToolsPedTabPage = new System.Windows.Forms.TabPage();
this.ToolsTabControl = new System.Windows.Forms.TabControl();
this.ToolsPanel = new System.Windows.Forms.Panel();
this.label4 = new System.Windows.Forms.Label();
this.label5 = new System.Windows.Forms.Label();
this.CompHeadComboBox = new System.Windows.Forms.ComboBox();
this.label6 = new System.Windows.Forms.Label();
this.CompBerdComboBox = new System.Windows.Forms.ComboBox();
this.label7 = new System.Windows.Forms.Label();
this.CompHairComboBox = new System.Windows.Forms.ComboBox();
this.label8 = new System.Windows.Forms.Label();
this.CompUpprComboBox = new System.Windows.Forms.ComboBox();
this.label9 = new System.Windows.Forms.Label();
this.CompLowrComboBox = new System.Windows.Forms.ComboBox();
this.label12 = new System.Windows.Forms.Label();
this.CompHandComboBox = new System.Windows.Forms.ComboBox();
this.label13 = new System.Windows.Forms.Label();
this.CompFeetComboBox = new System.Windows.Forms.ComboBox();
this.label15 = new System.Windows.Forms.Label();
this.CompTeefComboBox = new System.Windows.Forms.ComboBox();
this.label16 = new System.Windows.Forms.Label();
this.CompAccsComboBox = new System.Windows.Forms.ComboBox();
this.label17 = new System.Windows.Forms.Label();
this.CompTaskComboBox = new System.Windows.Forms.ComboBox();
this.label18 = new System.Windows.Forms.Label();
this.CompDeclComboBox = new System.Windows.Forms.ComboBox();
this.label20 = new System.Windows.Forms.Label();
this.CompJbibComboBox = new System.Windows.Forms.ComboBox();
this.label18 = new System.Windows.Forms.Label();
this.CompDeclComboBox = new System.Windows.Forms.ComboBox();
this.label17 = new System.Windows.Forms.Label();
this.CompTaskComboBox = new System.Windows.Forms.ComboBox();
this.label16 = new System.Windows.Forms.Label();
this.CompAccsComboBox = new System.Windows.Forms.ComboBox();
this.label15 = new System.Windows.Forms.Label();
this.CompTeefComboBox = new System.Windows.Forms.ComboBox();
this.label13 = new System.Windows.Forms.Label();
this.CompFeetComboBox = new System.Windows.Forms.ComboBox();
this.label12 = new System.Windows.Forms.Label();
this.CompHandComboBox = new System.Windows.Forms.ComboBox();
this.label9 = new System.Windows.Forms.Label();
this.CompLowrComboBox = new System.Windows.Forms.ComboBox();
this.label8 = new System.Windows.Forms.Label();
this.CompUpprComboBox = new System.Windows.Forms.ComboBox();
this.label7 = new System.Windows.Forms.Label();
this.CompHairComboBox = new System.Windows.Forms.ComboBox();
this.label6 = new System.Windows.Forms.Label();
this.CompBerdComboBox = new System.Windows.Forms.ComboBox();
this.label5 = new System.Windows.Forms.Label();
this.CompHeadComboBox = new System.Windows.Forms.ComboBox();
this.label4 = new System.Windows.Forms.Label();
this.ToolsTabControl = new System.Windows.Forms.TabControl();
this.ToolsPanel = new System.Windows.Forms.Panel();
this.label21 = new System.Windows.Forms.Label();
this.ClipDictComboBox = new System.Windows.Forms.ComboBox();
this.label22 = new System.Windows.Forms.Label();
this.ClipComboBox = new System.Windows.Forms.ComboBox();
this.label23 = new System.Windows.Forms.Label();
this.ConsolePanel.SuspendLayout();
this.ToolsOptionsTabPage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.TimeOfDayTrackBar)).BeginInit();
@ -651,6 +656,11 @@
//
// ToolsPedTabPage
//
this.ToolsPedTabPage.Controls.Add(this.label23);
this.ToolsPedTabPage.Controls.Add(this.label22);
this.ToolsPedTabPage.Controls.Add(this.ClipComboBox);
this.ToolsPedTabPage.Controls.Add(this.label21);
this.ToolsPedTabPage.Controls.Add(this.ClipDictComboBox);
this.ToolsPedTabPage.Controls.Add(this.label20);
this.ToolsPedTabPage.Controls.Add(this.CompJbibComboBox);
this.ToolsPedTabPage.Controls.Add(this.label18);
@ -685,6 +695,279 @@
this.ToolsPedTabPage.Text = "Ped";
this.ToolsPedTabPage.UseVisualStyleBackColor = true;
//
// label20
//
this.label20.AutoSize = true;
this.label20.Location = new System.Drawing.Point(22, 373);
this.label20.Name = "label20";
this.label20.Size = new System.Drawing.Size(29, 13);
this.label20.TabIndex = 26;
this.label20.Text = "Jbib:";
//
// CompJbibComboBox
//
this.CompJbibComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompJbibComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompJbibComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompJbibComboBox.FormattingEnabled = true;
this.CompJbibComboBox.Location = new System.Drawing.Point(54, 370);
this.CompJbibComboBox.Name = "CompJbibComboBox";
this.CompJbibComboBox.Size = new System.Drawing.Size(182, 21);
this.CompJbibComboBox.TabIndex = 25;
this.CompJbibComboBox.SelectedIndexChanged += new System.EventHandler(this.CompJbibComboBox_SelectedIndexChanged);
//
// label18
//
this.label18.AutoSize = true;
this.label18.Location = new System.Drawing.Point(19, 346);
this.label18.Name = "label18";
this.label18.Size = new System.Drawing.Size(32, 13);
this.label18.TabIndex = 24;
this.label18.Text = "Decl:";
//
// CompDeclComboBox
//
this.CompDeclComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompDeclComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompDeclComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompDeclComboBox.FormattingEnabled = true;
this.CompDeclComboBox.Location = new System.Drawing.Point(54, 343);
this.CompDeclComboBox.Name = "CompDeclComboBox";
this.CompDeclComboBox.Size = new System.Drawing.Size(182, 21);
this.CompDeclComboBox.TabIndex = 23;
this.CompDeclComboBox.SelectedIndexChanged += new System.EventHandler(this.CompDeclComboBox_SelectedIndexChanged);
//
// label17
//
this.label17.AutoSize = true;
this.label17.Location = new System.Drawing.Point(17, 319);
this.label17.Name = "label17";
this.label17.Size = new System.Drawing.Size(34, 13);
this.label17.TabIndex = 22;
this.label17.Text = "Task:";
//
// CompTaskComboBox
//
this.CompTaskComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompTaskComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompTaskComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompTaskComboBox.FormattingEnabled = true;
this.CompTaskComboBox.Location = new System.Drawing.Point(54, 316);
this.CompTaskComboBox.Name = "CompTaskComboBox";
this.CompTaskComboBox.Size = new System.Drawing.Size(182, 21);
this.CompTaskComboBox.TabIndex = 21;
this.CompTaskComboBox.SelectedIndexChanged += new System.EventHandler(this.CompTaskComboBox_SelectedIndexChanged);
//
// label16
//
this.label16.AutoSize = true;
this.label16.Location = new System.Drawing.Point(17, 292);
this.label16.Name = "label16";
this.label16.Size = new System.Drawing.Size(34, 13);
this.label16.TabIndex = 20;
this.label16.Text = "Accs:";
//
// CompAccsComboBox
//
this.CompAccsComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompAccsComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompAccsComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompAccsComboBox.FormattingEnabled = true;
this.CompAccsComboBox.Location = new System.Drawing.Point(54, 289);
this.CompAccsComboBox.Name = "CompAccsComboBox";
this.CompAccsComboBox.Size = new System.Drawing.Size(182, 21);
this.CompAccsComboBox.TabIndex = 19;
this.CompAccsComboBox.SelectedIndexChanged += new System.EventHandler(this.CompAccsComboBox_SelectedIndexChanged);
//
// label15
//
this.label15.AutoSize = true;
this.label15.Location = new System.Drawing.Point(19, 265);
this.label15.Name = "label15";
this.label15.Size = new System.Drawing.Size(32, 13);
this.label15.TabIndex = 18;
this.label15.Text = "Teef:";
//
// CompTeefComboBox
//
this.CompTeefComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompTeefComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompTeefComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompTeefComboBox.FormattingEnabled = true;
this.CompTeefComboBox.Location = new System.Drawing.Point(54, 262);
this.CompTeefComboBox.Name = "CompTeefComboBox";
this.CompTeefComboBox.Size = new System.Drawing.Size(182, 21);
this.CompTeefComboBox.TabIndex = 17;
this.CompTeefComboBox.SelectedIndexChanged += new System.EventHandler(this.CompTeefComboBox_SelectedIndexChanged);
//
// label13
//
this.label13.AutoSize = true;
this.label13.Location = new System.Drawing.Point(20, 238);
this.label13.Name = "label13";
this.label13.Size = new System.Drawing.Size(31, 13);
this.label13.TabIndex = 16;
this.label13.Text = "Feet:";
//
// CompFeetComboBox
//
this.CompFeetComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompFeetComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompFeetComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompFeetComboBox.FormattingEnabled = true;
this.CompFeetComboBox.Location = new System.Drawing.Point(54, 235);
this.CompFeetComboBox.Name = "CompFeetComboBox";
this.CompFeetComboBox.Size = new System.Drawing.Size(182, 21);
this.CompFeetComboBox.TabIndex = 15;
this.CompFeetComboBox.SelectedIndexChanged += new System.EventHandler(this.CompFeetComboBox_SelectedIndexChanged);
//
// label12
//
this.label12.AutoSize = true;
this.label12.Location = new System.Drawing.Point(15, 211);
this.label12.Name = "label12";
this.label12.Size = new System.Drawing.Size(36, 13);
this.label12.TabIndex = 14;
this.label12.Text = "Hand:";
//
// CompHandComboBox
//
this.CompHandComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompHandComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompHandComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompHandComboBox.FormattingEnabled = true;
this.CompHandComboBox.Location = new System.Drawing.Point(54, 208);
this.CompHandComboBox.Name = "CompHandComboBox";
this.CompHandComboBox.Size = new System.Drawing.Size(182, 21);
this.CompHandComboBox.TabIndex = 13;
this.CompHandComboBox.SelectedIndexChanged += new System.EventHandler(this.CompHandComboBox_SelectedIndexChanged);
//
// label9
//
this.label9.AutoSize = true;
this.label9.Location = new System.Drawing.Point(18, 184);
this.label9.Name = "label9";
this.label9.Size = new System.Drawing.Size(33, 13);
this.label9.TabIndex = 12;
this.label9.Text = "Lowr:";
//
// CompLowrComboBox
//
this.CompLowrComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompLowrComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompLowrComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompLowrComboBox.FormattingEnabled = true;
this.CompLowrComboBox.Location = new System.Drawing.Point(54, 181);
this.CompLowrComboBox.Name = "CompLowrComboBox";
this.CompLowrComboBox.Size = new System.Drawing.Size(182, 21);
this.CompLowrComboBox.TabIndex = 11;
this.CompLowrComboBox.SelectedIndexChanged += new System.EventHandler(this.CompLowrComboBox_SelectedIndexChanged);
//
// label8
//
this.label8.AutoSize = true;
this.label8.Location = new System.Drawing.Point(18, 157);
this.label8.Name = "label8";
this.label8.Size = new System.Drawing.Size(33, 13);
this.label8.TabIndex = 10;
this.label8.Text = "Uppr:";
//
// CompUpprComboBox
//
this.CompUpprComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompUpprComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompUpprComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompUpprComboBox.FormattingEnabled = true;
this.CompUpprComboBox.Location = new System.Drawing.Point(54, 154);
this.CompUpprComboBox.Name = "CompUpprComboBox";
this.CompUpprComboBox.Size = new System.Drawing.Size(182, 21);
this.CompUpprComboBox.TabIndex = 9;
this.CompUpprComboBox.SelectedIndexChanged += new System.EventHandler(this.CompUpprComboBox_SelectedIndexChanged);
//
// label7
//
this.label7.AutoSize = true;
this.label7.Location = new System.Drawing.Point(22, 130);
this.label7.Name = "label7";
this.label7.Size = new System.Drawing.Size(29, 13);
this.label7.TabIndex = 8;
this.label7.Text = "Hair:";
//
// CompHairComboBox
//
this.CompHairComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompHairComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompHairComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompHairComboBox.FormattingEnabled = true;
this.CompHairComboBox.Location = new System.Drawing.Point(54, 127);
this.CompHairComboBox.Name = "CompHairComboBox";
this.CompHairComboBox.Size = new System.Drawing.Size(182, 21);
this.CompHairComboBox.TabIndex = 7;
this.CompHairComboBox.SelectedIndexChanged += new System.EventHandler(this.CompHairComboBox_SelectedIndexChanged);
//
// label6
//
this.label6.AutoSize = true;
this.label6.Location = new System.Drawing.Point(19, 103);
this.label6.Name = "label6";
this.label6.Size = new System.Drawing.Size(32, 13);
this.label6.TabIndex = 6;
this.label6.Text = "Berd:";
//
// CompBerdComboBox
//
this.CompBerdComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompBerdComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompBerdComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompBerdComboBox.FormattingEnabled = true;
this.CompBerdComboBox.Location = new System.Drawing.Point(54, 100);
this.CompBerdComboBox.Name = "CompBerdComboBox";
this.CompBerdComboBox.Size = new System.Drawing.Size(182, 21);
this.CompBerdComboBox.TabIndex = 5;
this.CompBerdComboBox.SelectedIndexChanged += new System.EventHandler(this.CompBerdComboBox_SelectedIndexChanged);
//
// label5
//
this.label5.AutoSize = true;
this.label5.Location = new System.Drawing.Point(15, 76);
this.label5.Name = "label5";
this.label5.Size = new System.Drawing.Size(36, 13);
this.label5.TabIndex = 4;
this.label5.Text = "Head:";
//
// CompHeadComboBox
//
this.CompHeadComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompHeadComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompHeadComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompHeadComboBox.FormattingEnabled = true;
this.CompHeadComboBox.Location = new System.Drawing.Point(54, 73);
this.CompHeadComboBox.Name = "CompHeadComboBox";
this.CompHeadComboBox.Size = new System.Drawing.Size(182, 21);
this.CompHeadComboBox.TabIndex = 3;
this.CompHeadComboBox.SelectedIndexChanged += new System.EventHandler(this.CompHeadComboBox_SelectedIndexChanged);
//
// label4
//
this.label4.AutoSize = true;
this.label4.Location = new System.Drawing.Point(3, 53);
this.label4.Name = "label4";
this.label4.Size = new System.Drawing.Size(69, 13);
this.label4.TabIndex = 2;
this.label4.Text = "Components:";
//
// ToolsTabControl
//
this.ToolsTabControl.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
@ -715,278 +998,59 @@
this.ToolsPanel.TabIndex = 7;
this.ToolsPanel.Visible = false;
//
// label4
// label21
//
this.label4.AutoSize = true;
this.label4.Location = new System.Drawing.Point(3, 53);
this.label4.Name = "label4";
this.label4.Size = new System.Drawing.Size(69, 13);
this.label4.TabIndex = 2;
this.label4.Text = "Components:";
this.label21.AutoSize = true;
this.label21.Location = new System.Drawing.Point(2, 445);
this.label21.Name = "label21";
this.label21.Size = new System.Drawing.Size(49, 13);
this.label21.TabIndex = 28;
this.label21.Text = "Clip Dict:";
//
// label5
// ClipDictComboBox
//
this.label5.AutoSize = true;
this.label5.Location = new System.Drawing.Point(12, 76);
this.label5.Name = "label5";
this.label5.Size = new System.Drawing.Size(36, 13);
this.label5.TabIndex = 4;
this.label5.Text = "Head:";
//
// CompHeadComboBox
//
this.CompHeadComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
this.ClipDictComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompHeadComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompHeadComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompHeadComboBox.FormattingEnabled = true;
this.CompHeadComboBox.Location = new System.Drawing.Point(54, 73);
this.CompHeadComboBox.Name = "CompHeadComboBox";
this.CompHeadComboBox.Size = new System.Drawing.Size(182, 21);
this.CompHeadComboBox.TabIndex = 3;
this.CompHeadComboBox.SelectedIndexChanged += new System.EventHandler(this.CompHeadComboBox_SelectedIndexChanged);
this.ClipDictComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.ClipDictComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.CustomSource;
this.ClipDictComboBox.FormattingEnabled = true;
this.ClipDictComboBox.Location = new System.Drawing.Point(54, 442);
this.ClipDictComboBox.Name = "ClipDictComboBox";
this.ClipDictComboBox.Size = new System.Drawing.Size(182, 21);
this.ClipDictComboBox.TabIndex = 27;
this.ClipDictComboBox.TextChanged += new System.EventHandler(this.ClipDictComboBox_TextChanged);
//
// label6
// label22
//
this.label6.AutoSize = true;
this.label6.Location = new System.Drawing.Point(16, 103);
this.label6.Name = "label6";
this.label6.Size = new System.Drawing.Size(32, 13);
this.label6.TabIndex = 6;
this.label6.Text = "Berd:";
this.label22.AutoSize = true;
this.label22.Location = new System.Drawing.Point(24, 472);
this.label22.Name = "label22";
this.label22.Size = new System.Drawing.Size(27, 13);
this.label22.TabIndex = 30;
this.label22.Text = "Clip:";
//
// CompBerdComboBox
// ClipComboBox
//
this.CompBerdComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
this.ClipComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompBerdComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompBerdComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompBerdComboBox.FormattingEnabled = true;
this.CompBerdComboBox.Location = new System.Drawing.Point(54, 100);
this.CompBerdComboBox.Name = "CompBerdComboBox";
this.CompBerdComboBox.Size = new System.Drawing.Size(182, 21);
this.CompBerdComboBox.TabIndex = 5;
this.CompBerdComboBox.SelectedIndexChanged += new System.EventHandler(this.CompBerdComboBox_SelectedIndexChanged);
this.ClipComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.ClipComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.ClipComboBox.FormattingEnabled = true;
this.ClipComboBox.Location = new System.Drawing.Point(54, 469);
this.ClipComboBox.Name = "ClipComboBox";
this.ClipComboBox.Size = new System.Drawing.Size(182, 21);
this.ClipComboBox.TabIndex = 29;
this.ClipComboBox.SelectedIndexChanged += new System.EventHandler(this.ClipComboBox_SelectedIndexChanged);
this.ClipComboBox.TextChanged += new System.EventHandler(this.ClipComboBox_TextChanged);
//
// label7
// label23
//
this.label7.AutoSize = true;
this.label7.Location = new System.Drawing.Point(19, 130);
this.label7.Name = "label7";
this.label7.Size = new System.Drawing.Size(29, 13);
this.label7.TabIndex = 8;
this.label7.Text = "Hair:";
//
// CompHairComboBox
//
this.CompHairComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompHairComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompHairComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompHairComboBox.FormattingEnabled = true;
this.CompHairComboBox.Location = new System.Drawing.Point(54, 127);
this.CompHairComboBox.Name = "CompHairComboBox";
this.CompHairComboBox.Size = new System.Drawing.Size(182, 21);
this.CompHairComboBox.TabIndex = 7;
this.CompHairComboBox.SelectedIndexChanged += new System.EventHandler(this.CompHairComboBox_SelectedIndexChanged);
//
// label8
//
this.label8.AutoSize = true;
this.label8.Location = new System.Drawing.Point(15, 157);
this.label8.Name = "label8";
this.label8.Size = new System.Drawing.Size(33, 13);
this.label8.TabIndex = 10;
this.label8.Text = "Uppr:";
//
// CompUpprComboBox
//
this.CompUpprComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompUpprComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompUpprComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompUpprComboBox.FormattingEnabled = true;
this.CompUpprComboBox.Location = new System.Drawing.Point(54, 154);
this.CompUpprComboBox.Name = "CompUpprComboBox";
this.CompUpprComboBox.Size = new System.Drawing.Size(182, 21);
this.CompUpprComboBox.TabIndex = 9;
this.CompUpprComboBox.SelectedIndexChanged += new System.EventHandler(this.CompUpprComboBox_SelectedIndexChanged);
//
// label9
//
this.label9.AutoSize = true;
this.label9.Location = new System.Drawing.Point(15, 184);
this.label9.Name = "label9";
this.label9.Size = new System.Drawing.Size(33, 13);
this.label9.TabIndex = 12;
this.label9.Text = "Lowr:";
//
// CompLowrComboBox
//
this.CompLowrComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompLowrComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompLowrComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompLowrComboBox.FormattingEnabled = true;
this.CompLowrComboBox.Location = new System.Drawing.Point(54, 181);
this.CompLowrComboBox.Name = "CompLowrComboBox";
this.CompLowrComboBox.Size = new System.Drawing.Size(182, 21);
this.CompLowrComboBox.TabIndex = 11;
this.CompLowrComboBox.SelectedIndexChanged += new System.EventHandler(this.CompLowrComboBox_SelectedIndexChanged);
//
// label12
//
this.label12.AutoSize = true;
this.label12.Location = new System.Drawing.Point(12, 211);
this.label12.Name = "label12";
this.label12.Size = new System.Drawing.Size(36, 13);
this.label12.TabIndex = 14;
this.label12.Text = "Hand:";
//
// CompHandComboBox
//
this.CompHandComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompHandComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompHandComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompHandComboBox.FormattingEnabled = true;
this.CompHandComboBox.Location = new System.Drawing.Point(54, 208);
this.CompHandComboBox.Name = "CompHandComboBox";
this.CompHandComboBox.Size = new System.Drawing.Size(182, 21);
this.CompHandComboBox.TabIndex = 13;
this.CompHandComboBox.SelectedIndexChanged += new System.EventHandler(this.CompHandComboBox_SelectedIndexChanged);
//
// label13
//
this.label13.AutoSize = true;
this.label13.Location = new System.Drawing.Point(17, 238);
this.label13.Name = "label13";
this.label13.Size = new System.Drawing.Size(31, 13);
this.label13.TabIndex = 16;
this.label13.Text = "Feet:";
//
// CompFeetComboBox
//
this.CompFeetComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompFeetComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompFeetComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompFeetComboBox.FormattingEnabled = true;
this.CompFeetComboBox.Location = new System.Drawing.Point(54, 235);
this.CompFeetComboBox.Name = "CompFeetComboBox";
this.CompFeetComboBox.Size = new System.Drawing.Size(182, 21);
this.CompFeetComboBox.TabIndex = 15;
this.CompFeetComboBox.SelectedIndexChanged += new System.EventHandler(this.CompFeetComboBox_SelectedIndexChanged);
//
// label15
//
this.label15.AutoSize = true;
this.label15.Location = new System.Drawing.Point(16, 265);
this.label15.Name = "label15";
this.label15.Size = new System.Drawing.Size(32, 13);
this.label15.TabIndex = 18;
this.label15.Text = "Teef:";
//
// CompTeefComboBox
//
this.CompTeefComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompTeefComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompTeefComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompTeefComboBox.FormattingEnabled = true;
this.CompTeefComboBox.Location = new System.Drawing.Point(54, 262);
this.CompTeefComboBox.Name = "CompTeefComboBox";
this.CompTeefComboBox.Size = new System.Drawing.Size(182, 21);
this.CompTeefComboBox.TabIndex = 17;
this.CompTeefComboBox.SelectedIndexChanged += new System.EventHandler(this.CompTeefComboBox_SelectedIndexChanged);
//
// label16
//
this.label16.AutoSize = true;
this.label16.Location = new System.Drawing.Point(14, 292);
this.label16.Name = "label16";
this.label16.Size = new System.Drawing.Size(34, 13);
this.label16.TabIndex = 20;
this.label16.Text = "Accs:";
//
// CompAccsComboBox
//
this.CompAccsComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompAccsComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompAccsComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompAccsComboBox.FormattingEnabled = true;
this.CompAccsComboBox.Location = new System.Drawing.Point(54, 289);
this.CompAccsComboBox.Name = "CompAccsComboBox";
this.CompAccsComboBox.Size = new System.Drawing.Size(182, 21);
this.CompAccsComboBox.TabIndex = 19;
this.CompAccsComboBox.SelectedIndexChanged += new System.EventHandler(this.CompAccsComboBox_SelectedIndexChanged);
//
// label17
//
this.label17.AutoSize = true;
this.label17.Location = new System.Drawing.Point(14, 319);
this.label17.Name = "label17";
this.label17.Size = new System.Drawing.Size(34, 13);
this.label17.TabIndex = 22;
this.label17.Text = "Task:";
//
// CompTaskComboBox
//
this.CompTaskComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompTaskComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompTaskComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompTaskComboBox.FormattingEnabled = true;
this.CompTaskComboBox.Location = new System.Drawing.Point(54, 316);
this.CompTaskComboBox.Name = "CompTaskComboBox";
this.CompTaskComboBox.Size = new System.Drawing.Size(182, 21);
this.CompTaskComboBox.TabIndex = 21;
this.CompTaskComboBox.SelectedIndexChanged += new System.EventHandler(this.CompTaskComboBox_SelectedIndexChanged);
//
// label18
//
this.label18.AutoSize = true;
this.label18.Location = new System.Drawing.Point(16, 346);
this.label18.Name = "label18";
this.label18.Size = new System.Drawing.Size(32, 13);
this.label18.TabIndex = 24;
this.label18.Text = "Decl:";
//
// CompDeclComboBox
//
this.CompDeclComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompDeclComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompDeclComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompDeclComboBox.FormattingEnabled = true;
this.CompDeclComboBox.Location = new System.Drawing.Point(54, 343);
this.CompDeclComboBox.Name = "CompDeclComboBox";
this.CompDeclComboBox.Size = new System.Drawing.Size(182, 21);
this.CompDeclComboBox.TabIndex = 23;
this.CompDeclComboBox.SelectedIndexChanged += new System.EventHandler(this.CompDeclComboBox_SelectedIndexChanged);
//
// label20
//
this.label20.AutoSize = true;
this.label20.Location = new System.Drawing.Point(19, 373);
this.label20.Name = "label20";
this.label20.Size = new System.Drawing.Size(29, 13);
this.label20.TabIndex = 26;
this.label20.Text = "Jbib:";
//
// CompJbibComboBox
//
this.CompJbibComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.CompJbibComboBox.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.CompJbibComboBox.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.CompJbibComboBox.FormattingEnabled = true;
this.CompJbibComboBox.Location = new System.Drawing.Point(54, 370);
this.CompJbibComboBox.Name = "CompJbibComboBox";
this.CompJbibComboBox.Size = new System.Drawing.Size(182, 21);
this.CompJbibComboBox.TabIndex = 25;
this.CompJbibComboBox.SelectedIndexChanged += new System.EventHandler(this.CompJbibComboBox_SelectedIndexChanged);
this.label23.AutoSize = true;
this.label23.Location = new System.Drawing.Point(3, 422);
this.label23.Name = "label23";
this.label23.Size = new System.Drawing.Size(56, 13);
this.label23.TabIndex = 31;
this.label23.Text = "Animation:";
//
// PedsForm
//
@ -1103,5 +1167,10 @@
private System.Windows.Forms.ComboBox CompJbibComboBox;
private System.Windows.Forms.Label label18;
private System.Windows.Forms.ComboBox CompDeclComboBox;
private System.Windows.Forms.Label label22;
private System.Windows.Forms.ComboBox ClipComboBox;
private System.Windows.Forms.Label label21;
private System.Windows.Forms.ComboBox ClipDictComboBox;
private System.Windows.Forms.Label label23;
}
}

View File

@ -74,12 +74,6 @@ namespace CodeWalker.Peds
string SelectedPedName = string.Empty;
MetaHash SelectedPedHash = 0;//ped name hash
CPedModelInfo__InitData SelectedPedInit = null; //ped init data
YddFile SelectedPedYdd = null; //ped drawables
YftFile SelectedPedYft = null; //ped skeleton YFT
PedFile SelectedPedYmt = null; //ped variation info
Drawable SelectedHead = null;
Drawable SelectedBerd = null;
@ -94,8 +88,24 @@ namespace CodeWalker.Peds
Drawable SelectedDecl = null;
Drawable SelectedJbib = null;
[TypeConverter(typeof(ExpandableObjectConverter))] public class PedSelection
{
public string Name { get; set; } = string.Empty;
public MetaHash NameHash { get; set; } = 0;//ped name hash
public CPedModelInfo__InitData InitData { get; set; } = null; //ped init data
public YddFile Ydd { get; set; } = null; //ped drawables
public YtdFile Ytd { get; set; } = null; //ped textures
public YcdFile Ycd { get; set; } = null; //ped animations
public YftFile Yft { get; set; } = null; //ped skeleton YFT
public PedFile Ymt { get; set; } = null; //ped variation info
public Dictionary<MetaHash, RpfFileEntry> DrawableFilesDict { get; set; } = null;
public Dictionary<MetaHash, RpfFileEntry> TextureFilesDict { get; set; } = null;
public RpfFileEntry[] DrawableFiles { get; set; } = null;
public RpfFileEntry[] TextureFiles { get; set; } = null;
public ClipMapEntry AnimClip { get; set; } = null;
}
PedSelection SelectedPed = new PedSelection();
@ -118,9 +128,9 @@ namespace CodeWalker.Peds
//Renderer.renderclouds = true;
//Renderer.individualcloudfrag = "Contrails";
Renderer.rendermoon = false;
Renderer.renderskeletons = true;
Renderer.SelectionFlagsTestAll = true;
Renderer.renderskeletons = false;
//Renderer.SelectionFlagsTestAll = true;
Renderer.swaphemisphere = true;
}
public void InitScene(Device device)
@ -146,8 +156,8 @@ namespace CodeWalker.Peds
camera.CurrentDistance = 2.0f;
camera.TargetRotation.Y = 0.2f;
camera.CurrentRotation.Y = 0.2f;
camera.TargetRotation.X = 0.5f * (float)Math.PI;
camera.CurrentRotation.X = 0.5f * (float)Math.PI;
camera.TargetRotation.X = 1.0f * (float)Math.PI;
camera.CurrentRotation.X = 1.0f * (float)Math.PI;
LoadSettings();
@ -454,8 +464,8 @@ namespace CodeWalker.Peds
rad = Math.Max(0.01f, rad*0.1f);
camera.FollowEntity.Position = pos;
camera.TargetDistance = rad * 1.6f;
camera.CurrentDistance = rad * 1.6f;
camera.TargetDistance = rad * 1.2f;
camera.CurrentDistance = rad * 1.2f;
camera.ZFar = Math.Min(rad * 200.0f, 12000.0f);
camera.ZNear = Math.Min(camera.ZFar * 5e-5f, 0.5f);
@ -614,8 +624,23 @@ namespace CodeWalker.Peds
}
else
{
PedNameComboBox.Items.Clear();
ClipComboBox.Items.Clear();
ClipDictComboBox.Items.Clear();
var ycds = GameFileCache.YcdDict.Values.ToList();
ycds.Sort((a, b) => { return a.Name.CompareTo(b.Name); });
ClipDictComboBox.AutoCompleteCustomSource.Clear();
List<string> ycdlist = new List<string>();
foreach (var ycde in ycds)
{
ycdlist.Add(ycde.GetShortName());
}
ClipDictComboBox.AutoCompleteCustomSource.AddRange(ycdlist.ToArray());
ClipDictComboBox.Text = "";
PedNameComboBox.Items.Clear();
var peds = GameFileCache.PedsInitDict.Values.ToList();
peds.Sort((a, b) => { return a.Name.CompareTo(b.Name); });
foreach (var ped in peds)
@ -624,7 +649,9 @@ namespace CodeWalker.Peds
}
if (peds.Count > 0)
{
PedNameComboBox.SelectedIndex = 0;
var ind = PedNameComboBox.FindString("A_F_M_Beach_01"); // //A_C_Pug
PedNameComboBox.SelectedIndex = Math.Max(ind, 0);
//PedNameComboBox.SelectedIndex = 0;
}
}
@ -688,12 +715,15 @@ namespace CodeWalker.Peds
var pednamel = pedname.ToLowerInvariant();
MetaHash pedhash = JenkHash.GenHash(pednamel);
SelectedPedName = string.Empty;
SelectedPedHash = 0;
SelectedPedInit = null;
SelectedPedYdd = null;
SelectedPedYft = null;
SelectedPedYmt = null;
SelectedPed.Name = string.Empty;
SelectedPed.NameHash = 0;
SelectedPed.InitData = null;
SelectedPed.Ydd = null;
SelectedPed.Ytd = null;
SelectedPed.Ycd = null;
SelectedPed.Yft = null;
SelectedPed.Ymt = null;
SelectedPed.AnimClip = null;
ClearCombo(CompHeadComboBox); SelectedHead = null;
ClearCombo(CompBerdComboBox); SelectedBerd = null;
ClearCombo(CompHairComboBox); SelectedHair = null;
@ -707,51 +737,89 @@ namespace CodeWalker.Peds
ClearCombo(CompDeclComboBox); SelectedDecl = null;
ClearCombo(CompJbibComboBox); SelectedJbib = null;
DetailsPropertyGrid.SelectedObject = null;
CPedModelInfo__InitData initdata = null;
if (!GameFileCache.PedsInitDict.TryGetValue(pedhash, out initdata)) return;
var ycdhash = JenkHash.GenHash(initdata.ClipDictionaryName.ToLowerInvariant());
bool pedchange = SelectedPedHash != pedhash;
SelectedPedName = pedname;
SelectedPedHash = pedhash;
SelectedPedInit = initdata;
SelectedPedYdd = GameFileCache.GetYdd(pedhash);
SelectedPedYft = GameFileCache.GetYft(pedhash);
GameFileCache.PedVariationsDict?.TryGetValue(pedhash, out SelectedPedYmt);
bool pedchange = SelectedPed.NameHash != pedhash;
SelectedPed.Name = pedname;
SelectedPed.NameHash = pedhash;
SelectedPed.InitData = initdata;
SelectedPed.Ydd = GameFileCache.GetYdd(pedhash);
SelectedPed.Ytd = GameFileCache.GetYtd(pedhash);
SelectedPed.Ycd = GameFileCache.GetYcd(ycdhash);
SelectedPed.Yft = GameFileCache.GetYft(pedhash);
while ((SelectedPedYdd != null) && (!SelectedPedYdd.Loaded))
PedFile pedFile = null;
GameFileCache.PedVariationsDict?.TryGetValue(pedhash, out pedFile);
SelectedPed.Ymt = pedFile;
Dictionary<MetaHash, RpfFileEntry> peddict = null;
GameFileCache.PedDrawableDicts.TryGetValue(SelectedPed.NameHash, out peddict);
SelectedPed.DrawableFilesDict = peddict;
SelectedPed.DrawableFiles = SelectedPed.DrawableFilesDict?.Values.ToArray();
GameFileCache.PedTextureDicts.TryGetValue(SelectedPed.NameHash, out peddict);
SelectedPed.TextureFilesDict = peddict;
SelectedPed.TextureFiles = SelectedPed.TextureFilesDict?.Values.ToArray();
while ((SelectedPed.Ydd != null) && (!SelectedPed.Ydd.Loaded))
{
Thread.Sleep(20);//kinda hacky
SelectedPedYdd = GameFileCache.GetYdd(SelectedPedHash);
SelectedPed.Ydd = GameFileCache.GetYdd(pedhash);
}
while ((SelectedPedYft != null) && (!SelectedPedYft.Loaded))
while ((SelectedPed.Ytd != null) && (!SelectedPed.Ytd.Loaded))
{
Thread.Sleep(20);//kinda hacky
SelectedPedYft = GameFileCache.GetYft(SelectedPedHash);
SelectedPed.Ytd = GameFileCache.GetYtd(pedhash);
}
while ((SelectedPed.Ycd != null) && (!SelectedPed.Ycd.Loaded))
{
Thread.Sleep(20);//kinda hacky
SelectedPed.Ycd = GameFileCache.GetYcd(ycdhash);
}
while ((SelectedPed.Yft != null) && (!SelectedPed.Yft.Loaded))
{
Thread.Sleep(20);//kinda hacky
SelectedPed.Yft = GameFileCache.GetYft(pedhash);
}
LoadModel(SelectedPedYft, pedchange);
LoadModel(SelectedPed.Yft, pedchange);
var vi = SelectedPedYmt?.VariationInfo;
var vi = SelectedPed.Ymt?.VariationInfo;
if (vi != null)
{
PopulateCompCombo(CompHeadComboBox, vi.GetVariations(0));
PopulateCompCombo(CompBerdComboBox, vi.GetVariations(1));
PopulateCompCombo(CompHairComboBox, vi.GetVariations(2));
PopulateCompCombo(CompUpprComboBox, vi.GetVariations(3));
PopulateCompCombo(CompLowrComboBox, vi.GetVariations(4));
PopulateCompCombo(CompHandComboBox, vi.GetVariations(5));
PopulateCompCombo(CompFeetComboBox, vi.GetVariations(6));
PopulateCompCombo(CompTeefComboBox, vi.GetVariations(7));
PopulateCompCombo(CompAccsComboBox, vi.GetVariations(8));
PopulateCompCombo(CompTaskComboBox, vi.GetVariations(9));
PopulateCompCombo(CompDeclComboBox, vi.GetVariations(10));
PopulateCompCombo(CompJbibComboBox, vi.GetVariations(11));
PopulateCompCombo(CompHeadComboBox, vi.GetComponentData(0));
PopulateCompCombo(CompBerdComboBox, vi.GetComponentData(1));
PopulateCompCombo(CompHairComboBox, vi.GetComponentData(2));
PopulateCompCombo(CompUpprComboBox, vi.GetComponentData(3));
PopulateCompCombo(CompLowrComboBox, vi.GetComponentData(4));
PopulateCompCombo(CompHandComboBox, vi.GetComponentData(5));
PopulateCompCombo(CompFeetComboBox, vi.GetComponentData(6));
PopulateCompCombo(CompTeefComboBox, vi.GetComponentData(7));
PopulateCompCombo(CompAccsComboBox, vi.GetComponentData(8));
PopulateCompCombo(CompTaskComboBox, vi.GetComponentData(9));
PopulateCompCombo(CompDeclComboBox, vi.GetComponentData(10));
PopulateCompCombo(CompJbibComboBox, vi.GetComponentData(11));
}
ClipDictComboBox.Text = SelectedPed.InitData?.ClipDictionaryName ?? "";
ClipComboBox.Text = "idle";
MetaHash cliphash = JenkHash.GenHash("idle");
ClipMapEntry cme = null;
SelectedPed.Ycd?.ClipMap?.TryGetValue(cliphash, out cme);
SelectedPed.AnimClip = cme;
DetailsPropertyGrid.SelectedObject = SelectedPed;
}
public void LoadModel(YftFile yft, bool movecamera = true)
@ -775,18 +843,19 @@ namespace CodeWalker.Peds
private void ClearCombo(ComboBox c)
{
c.Items.Clear();
c.Items.Add("");
c.Text = string.Empty;
}
private void PopulateCompCombo(ComboBox c, MUnk_3538495220 vars)
private void PopulateCompCombo(ComboBox c, MUnk_3538495220 compData)
{
if (vars?.Variations == null) return;
foreach (var item in vars.Variations)
if (compData?.DrawblData3 == null) return;
foreach (var item in compData.DrawblData3)
{
c.Items.Add(item.GetDrawableName());
}
if (vars.Variations.Length > 0)
if (compData.DrawblData3.Length > 0)
{
c.SelectedIndex = 0;
c.SelectedIndex = 1;
}
}
@ -794,20 +863,21 @@ namespace CodeWalker.Peds
private Drawable GetComponentDrawable(string name)
{
if (string.IsNullOrEmpty(name)) return null;
var namel = name.ToLowerInvariant();
MetaHash hash = JenkHash.GenHash(namel);
Drawable d;
if (SelectedPedYdd?.Dict != null)
if (SelectedPed.Ydd?.Dict != null)
{
if (SelectedPedYdd.Dict.TryGetValue(hash, out d)) return d;
if (SelectedPed.Ydd.Dict.TryGetValue(hash, out d)) return d;
}
Dictionary<MetaHash, RpfFileEntry> peddict = null;
if (GameFileCache.PedDrawableDicts.TryGetValue(SelectedPedHash, out peddict))
if (SelectedPed.DrawableFilesDict != null)
{
RpfFileEntry file = null;
if (peddict.TryGetValue(hash, out file))
if (SelectedPed.DrawableFilesDict.TryGetValue(hash, out file))
{
var ydd = GameFileCache.GetFileUncached<YddFile>(file);
while ((ydd != null) && (!ydd.Loaded))
@ -1011,31 +1081,65 @@ namespace CodeWalker.Peds
private void RenderPed()
{
YftFile yft = SelectedPedYft;// GameFileCache.GetYft(SelectedModelHash);
YftFile yft = SelectedPed.Yft;// GameFileCache.GetYft(SelectedModelHash);
if (yft != null)
{
if (yft.Loaded)
{
if (yft.Fragment != null)
{
var f = yft.Fragment;
var txdhash = 0u;// SelectedVehicleHash;// yft.RpfFileEntry?.ShortNameHash ?? 0;
//var f = yft.Fragment;
//var txdhash = 0u;// SelectedVehicleHash;// yft.RpfFileEntry?.ShortNameHash ?? 0;
//var namelower = yft.RpfFileEntry?.GetShortNameLower();
Archetype arch = null;// TryGetArchetype(hash);
Renderer.RenderFragment(arch, null, f, txdhash);
//Archetype arch = null;// TryGetArchetype(hash);
//Renderer.RenderFragment(arch, null, f, txdhash);
//seldrwbl = f.Drawable;
}
}
var vi = SelectedPed.Ymt?.VariationInfo;
if (vi != null)
{
RenderPedComponent(SelectedHead, vi.GetComponentData(0));
RenderPedComponent(SelectedBerd, vi.GetComponentData(1));
RenderPedComponent(SelectedHair, vi.GetComponentData(2));
RenderPedComponent(SelectedUppr, vi.GetComponentData(3));
RenderPedComponent(SelectedLowr, vi.GetComponentData(4));
RenderPedComponent(SelectedHand, vi.GetComponentData(5));
RenderPedComponent(SelectedFeet, vi.GetComponentData(6));
RenderPedComponent(SelectedTeef, vi.GetComponentData(7));
RenderPedComponent(SelectedAccs, vi.GetComponentData(8));
RenderPedComponent(SelectedTask, vi.GetComponentData(9));
RenderPedComponent(SelectedDecl, vi.GetComponentData(10));
RenderPedComponent(SelectedJbib, vi.GetComponentData(11));
}
}
}
private void RenderPedComponent(Drawable drawable, MUnk_3538495220 compData)
{
if (drawable == null) return;
if (compData == null) return;
var td = SelectedPed.Ytd?.TextureDict;
var ac = SelectedPed.AnimClip;
var skel = SelectedPed.Yft?.Fragment?.Drawable?.Skeleton;
if (skel != null)
{
drawable.Skeleton = skel;
}
Renderer.RenderDrawable(drawable, null, null, 0, td, ac);
}
@ -1598,7 +1702,63 @@ namespace CodeWalker.Peds
SelectedJbib = GetComponentDrawable(CompJbibComboBox.Text);
}
private void ClipDictComboBox_TextChanged(object sender, EventArgs e)
{
var ycdhash = JenkHash.GenHash(ClipDictComboBox.Text.ToLowerInvariant());
var ycd = GameFileCache.GetYcd(ycdhash);
while ((ycd != null) && (!ycd.Loaded))
{
Thread.Sleep(20);//kinda hacky
ycd = GameFileCache.GetYcd(ycdhash);
}
SelectedPed.Ycd = ycd;
ClipComboBox.Items.Clear();
ClipComboBox.Items.Add("");
if (ycd?.ClipMapEntries == null)
{
ClipComboBox.SelectedIndex = 0;
SelectedPed.AnimClip = null;
return;
}
foreach (var cme in ycd.ClipMapEntries)
{
var animclip = cme.Clip as ClipAnimation;
if (animclip != null)
{
ClipComboBox.Items.Add(animclip.ShortName);
continue;
}
var animcliplist = cme.Clip as ClipAnimationList;
if (animcliplist?.Animations?.Data != null)
{
ClipComboBox.Items.Add(animcliplist.ShortName);
continue;
}
}
}
private void ClipComboBox_SelectedIndexChanged(object sender, EventArgs e)
{
var name = ClipComboBox.Text;
MetaHash cliphash = JenkHash.GenHash(name);
ClipMapEntry cme = null;
SelectedPed.Ycd?.ClipMap?.TryGetValue(cliphash, out cme);
SelectedPed.AnimClip = cme;
}
private void ClipComboBox_TextChanged(object sender, EventArgs e)
{
ClipComboBox_SelectedIndexChanged(sender, e);
}
}
}

View File

@ -407,8 +407,34 @@ namespace CodeWalker.Rendering
}
private void UpdateAnim(ClipMapEntry cme)
{
var clipanim = cme.Clip as ClipAnimation;//maybe ClipAnimationList?
var clipanim = cme.Clip as ClipAnimation;
var anim = clipanim?.Animation;
if (anim != null)
{
UpdateAnim(anim);
}
var clipanimlist = cme.Clip as ClipAnimationList;
if (clipanimlist?.Animations != null)
{
if (clipanimlist.Animations.Count > 0)
{
UpdateAnim(clipanimlist.Animations[0].Animation);
}
////needs more work to synchronise these... seems to be multi layers, but timings are different
////sort of represents animations LODs, higher detail stuff like fingers and feet movements in the layers
//foreach (var canim in clipanimlist.Animations)
//{
// if (canim?.Animation == null) continue;
// UpdateAnim(canim.Animation);
// //break;
//}
}
}
private void UpdateAnim(Animation anim)
{
if (anim == null)
{ return; }
if (anim.BoneIds?.data_items == null)
@ -436,6 +462,9 @@ namespace CodeWalker.Rendering
if (bones == null)
{ return; }
Vector4 v0, v1, v;
Quaternion q0, q1, q;
for (int i = 0; i < anim.BoneIds.data_items.Length; i++)
{
var boneiditem = anim.BoneIds.data_items[i];
@ -454,19 +483,34 @@ namespace CodeWalker.Rendering
switch (track)
{
case 0: //bone position
var v0 = aseq.EvaluateVector(frame0);
var v1 = aseq.EvaluateVector(frame1);
var v = interpolate ? (v0 * ialpha) + (v1 * falpha) : v0;
v0 = aseq.EvaluateVector(frame0);
v1 = aseq.EvaluateVector(frame1);
v = interpolate ? (v0 * ialpha) + (v1 * falpha) : v0;
bone.AnimTranslation = v.XYZ();
break;
case 1: //bone orientation
var q0 = new Quaternion(aseq.EvaluateVector(frame0));
var q1 = new Quaternion(aseq.EvaluateVector(frame1));
var q = interpolate ? Quaternion.Slerp(q0, q1, falpha) : q0;
q0 = new Quaternion(aseq.EvaluateVector(frame0));
q1 = new Quaternion(aseq.EvaluateVector(frame1));
q = interpolate ? Quaternion.Slerp(q0, q1, falpha) : q0;
bone.AnimRotation = q;
break;
case 2: //scale?
break;
case 5://vector3...
//v0 = aseq.EvaluateVector(frame0);
//v1 = aseq.EvaluateVector(frame1);
//v = interpolate ? (v0 * ialpha) + (v1 * falpha) : v0;
//bone.AnimScale = v.XYZ();
break;
case 6://quaternion...
break;
case 134://single float?
case 136:
case 137:
case 138:
case 139:
case 140:
break;
default:
break;
}

View File

@ -113,6 +113,8 @@ namespace CodeWalker.Rendering
public bool renderhdtextures = true;
public bool swaphemisphere = false;//can be used to get better lighting in model viewers
public MapSelectionMode SelectionMode = MapSelectionMode.Entity; //to assist in rendering embedded collisions properly...
@ -498,6 +500,11 @@ namespace CodeWalker.Rendering
moonax = Vector3.Normalize(maxis.Multiply(Vector3.UnitY));
//bool usemoon = false;
if (swaphemisphere)
{
sundir.Y = -sundir.Y;
}
lightdir = sundir;
//if (lightdir.Z < -0.5f) lightdir.Z = -lightdir.Z; //make sure the lightsource is always above the horizon...
@ -2488,17 +2495,24 @@ namespace CodeWalker.Rendering
return res;
}
public bool RenderDrawable(DrawableBase drawable, Archetype arche, YmapEntityDef entity, uint txdHash = 0)
public bool RenderDrawable(DrawableBase drawable, Archetype arche, YmapEntityDef entity, uint txdHash = 0, TextureDictionary txdExtra = null, ClipMapEntry animClip = null)
{
//enqueue a single drawable for rendering.
if (drawable == null)
return false;
Renderable rndbl = TryGetRenderable(arche, drawable, txdHash);
Renderable rndbl = TryGetRenderable(arche, drawable, txdHash, txdExtra);
if (rndbl == null)
return false;
if (animClip != null)
{
rndbl.ClipMapEntry = animClip;
rndbl.ClipDict = animClip.Clip?.Ycd;
rndbl.HasAnims = true;
}
return RenderRenderable(rndbl, arche, entity);
}
@ -2784,7 +2798,7 @@ namespace CodeWalker.Rendering
private Renderable TryGetRenderable(Archetype arche, DrawableBase drawable, uint txdHash = 0)
private Renderable TryGetRenderable(Archetype arche, DrawableBase drawable, uint txdHash = 0, TextureDictionary txdExtra = null)
{
if (drawable == null) return null;
//BUG: only last texdict used!! needs to cache textures per archetype........
@ -2836,7 +2850,8 @@ namespace CodeWalker.Rendering
}
var yptTexDict = (drawable.Owner as YptFile)?.PtfxList?.TextureDictionary;
var extraTexDict = (drawable.Owner as YptFile)?.PtfxList?.TextureDictionary;
if (extraTexDict == null) extraTexDict = txdExtra;
bool cacheSD = (rndbl.SDtxds == null);
bool cacheHD = (renderhdtextures && (rndbl.HDtxds == null));
@ -2939,9 +2954,9 @@ namespace CodeWalker.Rendering
if ((tex != null) && (ttex == null))
{
//TextureRef means this RenderableTexture needs to be loaded from texture dict...
if (yptTexDict != null) //for ypt files, first try the embedded tex dict..
if (extraTexDict != null) //for ypt files, first try the embedded tex dict..
{
dtex = yptTexDict.Lookup(tex.NameHash);
dtex = extraTexDict.Lookup(tex.NameHash);
}
if (dtex == null) //else //if (texDict != 0)