Merge pull request #22 from Mixone-FinallyHere/itemEditor

Item editor working, needs ui code to be finished
This commit is contained in:
Miguel 2025-06-12 16:17:36 +01:00 committed by GitHub
commit 8ba9533a6e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
14 changed files with 2164 additions and 577 deletions

View File

@ -138,6 +138,12 @@
<Compile Include="Editors\HeadbuttEncounterEditorTab.Designer.cs">
<DependentUpon>HeadbuttEncounterEditorTab.cs</DependentUpon>
</Compile>
<Compile Include="Editors\ItemEditor.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="Editors\ItemEditor.Designer.cs">
<DependentUpon>ItemEditor.cs</DependentUpon>
</Compile>
<Compile Include="Editors\LevelScriptEditor.cs">
<SubType>UserControl</SubType>
</Compile>
@ -277,6 +283,7 @@
<Compile Include="ROMFiles\HeadbuttEncounterMap.cs" />
<Compile Include="ROMFiles\HeadbuttTree.cs" />
<Compile Include="ROMFiles\HeadbuttTreeGroup.cs" />
<Compile Include="ROMFiles\ItemData.cs" />
<Compile Include="ROMFiles\LearnsetData.cs" />
<Compile Include="ROMFiles\LevelScriptFile.cs" />
<Compile Include="ROMFiles\MoveData.cs" />
@ -429,6 +436,9 @@
<EmbeddedResource Include="Editors\HeadbuttEncounterEditorTab.resx">
<DependentUpon>HeadbuttEncounterEditorTab.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="Editors\ItemEditor.resx">
<DependentUpon>ItemEditor.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="Editors\LevelScriptEditor.resx">
<DependentUpon>LevelScriptEditor.cs</DependentUpon>
</EmbeddedResource>

View File

@ -29,7 +29,7 @@ namespace DSPRE
string moveDataPath = Path.Combine(docsFolderPath, "MoveData.csv");
string TMHMDataPath = Path.Combine(docsFolderPath, "TMHMData.csv");
DSUtils.TryUnpackNarcs(new List<DirNames> { DirNames.personalPokeData, DirNames.learnsets, DirNames.evolutions, DirNames.trainerParty, DirNames.trainerProperties ,DirNames.moveData});
DSUtils.TryUnpackNarcs(new List<DirNames> { DirNames.personalPokeData, DirNames.learnsets, DirNames.evolutions, DirNames.trainerParty, DirNames.trainerProperties ,DirNames.moveData, DirNames.itemData});
string[] pokeNames = RomInfo.GetPokemonNames();
string[] itemNames = RomInfo.GetItemNames();

524
DS_Map/Editors/ItemEditor.Designer.cs generated Normal file
View File

@ -0,0 +1,524 @@
namespace DSPRE.Editors
{
partial class ItemEditor
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.itemNumberNumericUpDown = new System.Windows.Forms.NumericUpDown();
this.holdEffectComboBox = new System.Windows.Forms.ComboBox();
this.fieldPocketComboBox = new System.Windows.Forms.ComboBox();
this.battlePocketComboBox = new System.Windows.Forms.ComboBox();
this.itemNameInputComboBox = new System.Windows.Forms.ComboBox();
this.priceNumericUpDown = new System.Windows.Forms.NumericUpDown();
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
this.holdEffectLabel = new System.Windows.Forms.Label();
this.fieldPocketLabel = new System.Windows.Forms.Label();
this.battlePocketLabel = new System.Windows.Forms.Label();
this.priceLabel = new System.Windows.Forms.Label();
this.saveDataButton = new System.Windows.Forms.Button();
this.holdEffectParameterLabel = new System.Windows.Forms.Label();
this.holdFlowLayoutPanel = new System.Windows.Forms.FlowLayoutPanel();
this.holdGroupBox = new System.Windows.Forms.GroupBox();
this.holdEffectParameterNumericUpDown = new System.Windows.Forms.NumericUpDown();
this.pocketFlowLayoutPanel = new System.Windows.Forms.FlowLayoutPanel();
this.pocketGroupBox = new System.Windows.Forms.GroupBox();
this.moveRelatedFlowLayoutPanel = new System.Windows.Forms.FlowLayoutPanel();
this.moveRelatedGroupBox = new System.Windows.Forms.GroupBox();
this.naturalGiftTypeComboBox = new System.Windows.Forms.ComboBox();
this.naturalGiftTypeLabel = new System.Windows.Forms.Label();
this.naturalGiftPowerLabel = new System.Windows.Forms.Label();
this.flingEffectLabel = new System.Windows.Forms.Label();
this.naturalGiftPowerNumericUpDown = new System.Windows.Forms.NumericUpDown();
this.flingEffectNumericUpDown = new System.Windows.Forms.NumericUpDown();
this.flingPowerNumericUpDown = new System.Windows.Forms.NumericUpDown();
this.pluckEffectNumericUpDown = new System.Windows.Forms.NumericUpDown();
this.flingPowerLabel = new System.Windows.Forms.Label();
this.pluckEffectLabel = new System.Windows.Forms.Label();
this.checksFlowLayoutPanel = new System.Windows.Forms.FlowLayoutPanel();
this.checksGroupBox = new System.Windows.Forms.GroupBox();
this.preventTossCheckBox = new System.Windows.Forms.CheckBox();
this.canSelectCheckBox = new System.Windows.Forms.CheckBox();
((System.ComponentModel.ISupportInitialize)(this.itemNumberNumericUpDown)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.priceNumericUpDown)).BeginInit();
this.tableLayoutPanel1.SuspendLayout();
this.holdFlowLayoutPanel.SuspendLayout();
this.holdGroupBox.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.holdEffectParameterNumericUpDown)).BeginInit();
this.pocketFlowLayoutPanel.SuspendLayout();
this.pocketGroupBox.SuspendLayout();
this.moveRelatedFlowLayoutPanel.SuspendLayout();
this.moveRelatedGroupBox.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.naturalGiftPowerNumericUpDown)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.flingEffectNumericUpDown)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.flingPowerNumericUpDown)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.pluckEffectNumericUpDown)).BeginInit();
this.checksFlowLayoutPanel.SuspendLayout();
this.checksGroupBox.SuspendLayout();
this.SuspendLayout();
//
// itemNumberNumericUpDown
//
this.itemNumberNumericUpDown.Anchor = System.Windows.Forms.AnchorStyles.None;
this.itemNumberNumericUpDown.Location = new System.Drawing.Point(605, 60);
this.itemNumberNumericUpDown.Name = "itemNumberNumericUpDown";
this.itemNumberNumericUpDown.Size = new System.Drawing.Size(120, 20);
this.itemNumberNumericUpDown.TabIndex = 0;
this.itemNumberNumericUpDown.ValueChanged += new System.EventHandler(this.itemNumberNumericUpDown_ValueChanged);
//
// holdEffectComboBox
//
this.holdEffectComboBox.Anchor = System.Windows.Forms.AnchorStyles.None;
this.holdEffectComboBox.FormattingEnabled = true;
this.holdEffectComboBox.Location = new System.Drawing.Point(106, 35);
this.holdEffectComboBox.Name = "holdEffectComboBox";
this.holdEffectComboBox.Size = new System.Drawing.Size(121, 21);
this.holdEffectComboBox.TabIndex = 1;
this.holdEffectComboBox.SelectedIndexChanged += new System.EventHandler(this.holdEffectComboBox_SelectedIndexChanged);
//
// fieldPocketComboBox
//
this.fieldPocketComboBox.Anchor = System.Windows.Forms.AnchorStyles.None;
this.fieldPocketComboBox.FormattingEnabled = true;
this.fieldPocketComboBox.Location = new System.Drawing.Point(107, 35);
this.fieldPocketComboBox.Name = "fieldPocketComboBox";
this.fieldPocketComboBox.Size = new System.Drawing.Size(121, 21);
this.fieldPocketComboBox.TabIndex = 2;
this.fieldPocketComboBox.SelectedIndexChanged += new System.EventHandler(this.fieldPocketComboBox_SelectedIndexChanged);
//
// battlePocketComboBox
//
this.battlePocketComboBox.Anchor = System.Windows.Forms.AnchorStyles.None;
this.battlePocketComboBox.FormattingEnabled = true;
this.battlePocketComboBox.Location = new System.Drawing.Point(107, 78);
this.battlePocketComboBox.Name = "battlePocketComboBox";
this.battlePocketComboBox.Size = new System.Drawing.Size(121, 21);
this.battlePocketComboBox.TabIndex = 3;
this.battlePocketComboBox.SelectedIndexChanged += new System.EventHandler(this.battlePocketComboBox_SelectedIndexChanged);
//
// itemNameInputComboBox
//
this.itemNameInputComboBox.Anchor = System.Windows.Forms.AnchorStyles.None;
this.itemNameInputComboBox.FormattingEnabled = true;
this.itemNameInputComboBox.Location = new System.Drawing.Point(338, 59);
this.itemNameInputComboBox.Name = "itemNameInputComboBox";
this.itemNameInputComboBox.Size = new System.Drawing.Size(121, 21);
this.itemNameInputComboBox.TabIndex = 4;
this.itemNameInputComboBox.SelectedIndexChanged += new System.EventHandler(this.itemNameInputComboBox_SelectedIndexChanged);
//
// priceNumericUpDown
//
this.priceNumericUpDown.Anchor = System.Windows.Forms.AnchorStyles.None;
this.priceNumericUpDown.Location = new System.Drawing.Point(871, 340);
this.priceNumericUpDown.Name = "priceNumericUpDown";
this.priceNumericUpDown.Size = new System.Drawing.Size(120, 20);
this.priceNumericUpDown.TabIndex = 5;
this.priceNumericUpDown.ValueChanged += new System.EventHandler(this.priceNumericUpDown_ValueChanged);
//
// tableLayoutPanel1
//
this.tableLayoutPanel1.ColumnCount = 4;
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 25F));
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 25F));
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 25F));
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 25F));
this.tableLayoutPanel1.Controls.Add(this.priceNumericUpDown, 3, 2);
this.tableLayoutPanel1.Controls.Add(this.itemNumberNumericUpDown, 2, 0);
this.tableLayoutPanel1.Controls.Add(this.itemNameInputComboBox, 1, 0);
this.tableLayoutPanel1.Controls.Add(this.priceLabel, 3, 1);
this.tableLayoutPanel1.Controls.Add(this.saveDataButton, 3, 0);
this.tableLayoutPanel1.Controls.Add(this.holdFlowLayoutPanel, 0, 1);
this.tableLayoutPanel1.Controls.Add(this.pocketFlowLayoutPanel, 1, 1);
this.tableLayoutPanel1.Controls.Add(this.moveRelatedFlowLayoutPanel, 0, 2);
this.tableLayoutPanel1.Controls.Add(this.checksFlowLayoutPanel, 2, 1);
this.tableLayoutPanel1.Location = new System.Drawing.Point(12, 12);
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
this.tableLayoutPanel1.RowCount = 4;
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 25F));
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 25F));
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 25F));
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 25F));
this.tableLayoutPanel1.Size = new System.Drawing.Size(1065, 563);
this.tableLayoutPanel1.TabIndex = 6;
//
// holdEffectLabel
//
this.holdEffectLabel.Anchor = System.Windows.Forms.AnchorStyles.None;
this.holdEffectLabel.AutoSize = true;
this.holdEffectLabel.Location = new System.Drawing.Point(26, 38);
this.holdEffectLabel.Name = "holdEffectLabel";
this.holdEffectLabel.Size = new System.Drawing.Size(35, 13);
this.holdEffectLabel.TabIndex = 6;
this.holdEffectLabel.Text = "Effect";
this.holdEffectLabel.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// fieldPocketLabel
//
this.fieldPocketLabel.Anchor = System.Windows.Forms.AnchorStyles.None;
this.fieldPocketLabel.AutoSize = true;
this.fieldPocketLabel.Location = new System.Drawing.Point(21, 38);
this.fieldPocketLabel.Name = "fieldPocketLabel";
this.fieldPocketLabel.Size = new System.Drawing.Size(66, 13);
this.fieldPocketLabel.TabIndex = 7;
this.fieldPocketLabel.Text = "Field Pocket";
this.fieldPocketLabel.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// battlePocketLabel
//
this.battlePocketLabel.Anchor = System.Windows.Forms.AnchorStyles.None;
this.battlePocketLabel.AutoSize = true;
this.battlePocketLabel.Location = new System.Drawing.Point(16, 81);
this.battlePocketLabel.Name = "battlePocketLabel";
this.battlePocketLabel.Size = new System.Drawing.Size(71, 13);
this.battlePocketLabel.TabIndex = 8;
this.battlePocketLabel.Text = "Battle Pocket";
this.battlePocketLabel.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// priceLabel
//
this.priceLabel.Anchor = System.Windows.Forms.AnchorStyles.None;
this.priceLabel.AutoSize = true;
this.priceLabel.Location = new System.Drawing.Point(916, 203);
this.priceLabel.Name = "priceLabel";
this.priceLabel.Size = new System.Drawing.Size(31, 13);
this.priceLabel.TabIndex = 9;
this.priceLabel.Text = "Price";
this.priceLabel.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// saveDataButton
//
this.saveDataButton.Anchor = System.Windows.Forms.AnchorStyles.None;
this.saveDataButton.Location = new System.Drawing.Point(883, 58);
this.saveDataButton.Name = "saveDataButton";
this.saveDataButton.Size = new System.Drawing.Size(96, 23);
this.saveDataButton.TabIndex = 10;
this.saveDataButton.Text = "Save Changes";
this.saveDataButton.UseVisualStyleBackColor = true;
this.saveDataButton.Click += new System.EventHandler(this.saveDataButton_Click);
//
// holdEffectParameterLabel
//
this.holdEffectParameterLabel.Anchor = System.Windows.Forms.AnchorStyles.None;
this.holdEffectParameterLabel.AutoSize = true;
this.holdEffectParameterLabel.Location = new System.Drawing.Point(6, 81);
this.holdEffectParameterLabel.Name = "holdEffectParameterLabel";
this.holdEffectParameterLabel.Size = new System.Drawing.Size(55, 13);
this.holdEffectParameterLabel.TabIndex = 7;
this.holdEffectParameterLabel.Text = "Parameter";
this.holdEffectParameterLabel.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// holdFlowLayoutPanel
//
this.holdFlowLayoutPanel.Controls.Add(this.holdGroupBox);
this.holdFlowLayoutPanel.Location = new System.Drawing.Point(3, 143);
this.holdFlowLayoutPanel.Name = "holdFlowLayoutPanel";
this.holdFlowLayoutPanel.Size = new System.Drawing.Size(260, 134);
this.holdFlowLayoutPanel.TabIndex = 11;
//
// holdGroupBox
//
this.holdGroupBox.Controls.Add(this.holdEffectParameterNumericUpDown);
this.holdGroupBox.Controls.Add(this.holdEffectParameterLabel);
this.holdGroupBox.Controls.Add(this.holdEffectLabel);
this.holdGroupBox.Controls.Add(this.holdEffectComboBox);
this.holdGroupBox.Location = new System.Drawing.Point(3, 3);
this.holdGroupBox.Name = "holdGroupBox";
this.holdGroupBox.Size = new System.Drawing.Size(257, 131);
this.holdGroupBox.TabIndex = 0;
this.holdGroupBox.TabStop = false;
this.holdGroupBox.Text = "Hold Effects";
//
// holdEffectParameterNumericUpDown
//
this.holdEffectParameterNumericUpDown.Anchor = System.Windows.Forms.AnchorStyles.None;
this.holdEffectParameterNumericUpDown.Location = new System.Drawing.Point(107, 79);
this.holdEffectParameterNumericUpDown.Name = "holdEffectParameterNumericUpDown";
this.holdEffectParameterNumericUpDown.Size = new System.Drawing.Size(120, 20);
this.holdEffectParameterNumericUpDown.TabIndex = 12;
this.holdEffectParameterNumericUpDown.ValueChanged += new System.EventHandler(this.holdEffectParameterNumericUpDown_ValueChanged);
//
// pocketFlowLayoutPanel
//
this.pocketFlowLayoutPanel.Controls.Add(this.pocketGroupBox);
this.pocketFlowLayoutPanel.Location = new System.Drawing.Point(269, 143);
this.pocketFlowLayoutPanel.Name = "pocketFlowLayoutPanel";
this.pocketFlowLayoutPanel.Size = new System.Drawing.Size(260, 134);
this.pocketFlowLayoutPanel.TabIndex = 12;
//
// pocketGroupBox
//
this.pocketGroupBox.Controls.Add(this.battlePocketComboBox);
this.pocketGroupBox.Controls.Add(this.fieldPocketLabel);
this.pocketGroupBox.Controls.Add(this.fieldPocketComboBox);
this.pocketGroupBox.Controls.Add(this.battlePocketLabel);
this.pocketGroupBox.Location = new System.Drawing.Point(3, 3);
this.pocketGroupBox.Name = "pocketGroupBox";
this.pocketGroupBox.Size = new System.Drawing.Size(257, 131);
this.pocketGroupBox.TabIndex = 0;
this.pocketGroupBox.TabStop = false;
this.pocketGroupBox.Text = "Pocket Data";
//
// moveRelatedFlowLayoutPanel
//
this.tableLayoutPanel1.SetColumnSpan(this.moveRelatedFlowLayoutPanel, 2);
this.moveRelatedFlowLayoutPanel.Controls.Add(this.moveRelatedGroupBox);
this.moveRelatedFlowLayoutPanel.Location = new System.Drawing.Point(3, 283);
this.moveRelatedFlowLayoutPanel.Name = "moveRelatedFlowLayoutPanel";
this.moveRelatedFlowLayoutPanel.Size = new System.Drawing.Size(526, 134);
this.moveRelatedFlowLayoutPanel.TabIndex = 13;
//
// moveRelatedGroupBox
//
this.moveRelatedGroupBox.Controls.Add(this.flingPowerNumericUpDown);
this.moveRelatedGroupBox.Controls.Add(this.pluckEffectNumericUpDown);
this.moveRelatedGroupBox.Controls.Add(this.flingPowerLabel);
this.moveRelatedGroupBox.Controls.Add(this.pluckEffectLabel);
this.moveRelatedGroupBox.Controls.Add(this.flingEffectNumericUpDown);
this.moveRelatedGroupBox.Controls.Add(this.naturalGiftPowerNumericUpDown);
this.moveRelatedGroupBox.Controls.Add(this.flingEffectLabel);
this.moveRelatedGroupBox.Controls.Add(this.naturalGiftPowerLabel);
this.moveRelatedGroupBox.Controls.Add(this.naturalGiftTypeLabel);
this.moveRelatedGroupBox.Controls.Add(this.naturalGiftTypeComboBox);
this.moveRelatedGroupBox.Location = new System.Drawing.Point(3, 3);
this.moveRelatedGroupBox.Name = "moveRelatedGroupBox";
this.moveRelatedGroupBox.Size = new System.Drawing.Size(523, 131);
this.moveRelatedGroupBox.TabIndex = 0;
this.moveRelatedGroupBox.TabStop = false;
this.moveRelatedGroupBox.Text = "Move Related";
//
// naturalGiftTypeComboBox
//
this.naturalGiftTypeComboBox.Anchor = System.Windows.Forms.AnchorStyles.None;
this.naturalGiftTypeComboBox.FormattingEnabled = true;
this.naturalGiftTypeComboBox.Location = new System.Drawing.Point(106, 53);
this.naturalGiftTypeComboBox.Name = "naturalGiftTypeComboBox";
this.naturalGiftTypeComboBox.Size = new System.Drawing.Size(121, 21);
this.naturalGiftTypeComboBox.TabIndex = 3;
this.naturalGiftTypeComboBox.SelectedIndexChanged += new System.EventHandler(this.naturalGiftTypeComboBox_SelectedIndexChanged);
//
// naturalGiftTypeLabel
//
this.naturalGiftTypeLabel.Anchor = System.Windows.Forms.AnchorStyles.Bottom;
this.naturalGiftTypeLabel.AutoSize = true;
this.naturalGiftTypeLabel.Location = new System.Drawing.Point(6, 56);
this.naturalGiftTypeLabel.Name = "naturalGiftTypeLabel";
this.naturalGiftTypeLabel.Size = new System.Drawing.Size(87, 13);
this.naturalGiftTypeLabel.TabIndex = 8;
this.naturalGiftTypeLabel.Text = "Natural Gift Type";
this.naturalGiftTypeLabel.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// naturalGiftPowerLabel
//
this.naturalGiftPowerLabel.Anchor = System.Windows.Forms.AnchorStyles.Bottom;
this.naturalGiftPowerLabel.AutoSize = true;
this.naturalGiftPowerLabel.Location = new System.Drawing.Point(6, 86);
this.naturalGiftPowerLabel.Name = "naturalGiftPowerLabel";
this.naturalGiftPowerLabel.Size = new System.Drawing.Size(93, 13);
this.naturalGiftPowerLabel.TabIndex = 10;
this.naturalGiftPowerLabel.Text = "Natural Gift Power";
this.naturalGiftPowerLabel.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// flingEffectLabel
//
this.flingEffectLabel.Anchor = System.Windows.Forms.AnchorStyles.Bottom;
this.flingEffectLabel.AutoSize = true;
this.flingEffectLabel.Location = new System.Drawing.Point(306, 81);
this.flingEffectLabel.Name = "flingEffectLabel";
this.flingEffectLabel.Size = new System.Drawing.Size(60, 13);
this.flingEffectLabel.TabIndex = 12;
this.flingEffectLabel.Text = "Fling Effect";
this.flingEffectLabel.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// naturalGiftPowerNumericUpDown
//
this.naturalGiftPowerNumericUpDown.Anchor = System.Windows.Forms.AnchorStyles.None;
this.naturalGiftPowerNumericUpDown.Location = new System.Drawing.Point(107, 84);
this.naturalGiftPowerNumericUpDown.Name = "naturalGiftPowerNumericUpDown";
this.naturalGiftPowerNumericUpDown.Size = new System.Drawing.Size(120, 20);
this.naturalGiftPowerNumericUpDown.TabIndex = 13;
this.naturalGiftPowerNumericUpDown.ValueChanged += new System.EventHandler(this.naturalGiftPowerNumericUpDown_ValueChanged);
//
// flingEffectNumericUpDown
//
this.flingEffectNumericUpDown.Anchor = System.Windows.Forms.AnchorStyles.None;
this.flingEffectNumericUpDown.Location = new System.Drawing.Point(389, 79);
this.flingEffectNumericUpDown.Name = "flingEffectNumericUpDown";
this.flingEffectNumericUpDown.Size = new System.Drawing.Size(120, 20);
this.flingEffectNumericUpDown.TabIndex = 14;
this.flingEffectNumericUpDown.ValueChanged += new System.EventHandler(this.flingEffectNumericUpDown_ValueChanged);
//
// flingPowerNumericUpDown
//
this.flingPowerNumericUpDown.Anchor = System.Windows.Forms.AnchorStyles.None;
this.flingPowerNumericUpDown.Location = new System.Drawing.Point(389, 105);
this.flingPowerNumericUpDown.Name = "flingPowerNumericUpDown";
this.flingPowerNumericUpDown.Size = new System.Drawing.Size(120, 20);
this.flingPowerNumericUpDown.TabIndex = 18;
this.flingPowerNumericUpDown.ValueChanged += new System.EventHandler(this.flingPowerNumericUpDown_ValueChanged);
//
// pluckEffectNumericUpDown
//
this.pluckEffectNumericUpDown.Anchor = System.Windows.Forms.AnchorStyles.None;
this.pluckEffectNumericUpDown.Location = new System.Drawing.Point(389, 28);
this.pluckEffectNumericUpDown.Name = "pluckEffectNumericUpDown";
this.pluckEffectNumericUpDown.Size = new System.Drawing.Size(120, 20);
this.pluckEffectNumericUpDown.TabIndex = 17;
this.pluckEffectNumericUpDown.ValueChanged += new System.EventHandler(this.pluckEffectNumericUpDown_ValueChanged);
//
// flingPowerLabel
//
this.flingPowerLabel.Anchor = System.Windows.Forms.AnchorStyles.Bottom;
this.flingPowerLabel.AutoSize = true;
this.flingPowerLabel.Location = new System.Drawing.Point(306, 107);
this.flingPowerLabel.Name = "flingPowerLabel";
this.flingPowerLabel.Size = new System.Drawing.Size(62, 13);
this.flingPowerLabel.TabIndex = 16;
this.flingPowerLabel.Text = "Fling Power";
this.flingPowerLabel.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// pluckEffectLabel
//
this.pluckEffectLabel.Anchor = System.Windows.Forms.AnchorStyles.Bottom;
this.pluckEffectLabel.AutoSize = true;
this.pluckEffectLabel.Location = new System.Drawing.Point(307, 31);
this.pluckEffectLabel.Name = "pluckEffectLabel";
this.pluckEffectLabel.Size = new System.Drawing.Size(65, 13);
this.pluckEffectLabel.TabIndex = 15;
this.pluckEffectLabel.Text = "Pluck Effect";
this.pluckEffectLabel.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// checksFlowLayoutPanel
//
this.checksFlowLayoutPanel.Controls.Add(this.checksGroupBox);
this.checksFlowLayoutPanel.Location = new System.Drawing.Point(535, 143);
this.checksFlowLayoutPanel.Name = "checksFlowLayoutPanel";
this.checksFlowLayoutPanel.Size = new System.Drawing.Size(260, 134);
this.checksFlowLayoutPanel.TabIndex = 14;
//
// checksGroupBox
//
this.checksGroupBox.Controls.Add(this.canSelectCheckBox);
this.checksGroupBox.Controls.Add(this.preventTossCheckBox);
this.checksGroupBox.Location = new System.Drawing.Point(3, 3);
this.checksGroupBox.Name = "checksGroupBox";
this.checksGroupBox.Size = new System.Drawing.Size(257, 131);
this.checksGroupBox.TabIndex = 0;
this.checksGroupBox.TabStop = false;
this.checksGroupBox.Text = "Checks";
//
// preventTossCheckBox
//
this.preventTossCheckBox.AutoSize = true;
this.preventTossCheckBox.Location = new System.Drawing.Point(17, 38);
this.preventTossCheckBox.Name = "preventTossCheckBox";
this.preventTossCheckBox.Size = new System.Drawing.Size(89, 17);
this.preventTossCheckBox.TabIndex = 0;
this.preventTossCheckBox.Text = "Prevent Toss";
this.preventTossCheckBox.UseVisualStyleBackColor = true;
this.preventTossCheckBox.CheckedChanged += new System.EventHandler(this.preventTossCheckBox_CheckedChanged);
//
// canSelectCheckBox
//
this.canSelectCheckBox.AutoSize = true;
this.canSelectCheckBox.Location = new System.Drawing.Point(17, 77);
this.canSelectCheckBox.Name = "canSelectCheckBox";
this.canSelectCheckBox.Size = new System.Drawing.Size(76, 17);
this.canSelectCheckBox.TabIndex = 1;
this.canSelectCheckBox.Text = "Selectable";
this.canSelectCheckBox.UseVisualStyleBackColor = true;
this.canSelectCheckBox.CheckedChanged += new System.EventHandler(this.canSelectCheckBox_CheckedChanged);
//
// ItemEditor
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(1089, 587);
this.Controls.Add(this.tableLayoutPanel1);
this.Name = "ItemEditor";
this.Text = "ItemEditor";
((System.ComponentModel.ISupportInitialize)(this.itemNumberNumericUpDown)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.priceNumericUpDown)).EndInit();
this.tableLayoutPanel1.ResumeLayout(false);
this.tableLayoutPanel1.PerformLayout();
this.holdFlowLayoutPanel.ResumeLayout(false);
this.holdGroupBox.ResumeLayout(false);
this.holdGroupBox.PerformLayout();
((System.ComponentModel.ISupportInitialize)(this.holdEffectParameterNumericUpDown)).EndInit();
this.pocketFlowLayoutPanel.ResumeLayout(false);
this.pocketGroupBox.ResumeLayout(false);
this.pocketGroupBox.PerformLayout();
this.moveRelatedFlowLayoutPanel.ResumeLayout(false);
this.moveRelatedGroupBox.ResumeLayout(false);
this.moveRelatedGroupBox.PerformLayout();
((System.ComponentModel.ISupportInitialize)(this.naturalGiftPowerNumericUpDown)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.flingEffectNumericUpDown)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.flingPowerNumericUpDown)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.pluckEffectNumericUpDown)).EndInit();
this.checksFlowLayoutPanel.ResumeLayout(false);
this.checksGroupBox.ResumeLayout(false);
this.checksGroupBox.PerformLayout();
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.NumericUpDown itemNumberNumericUpDown;
private System.Windows.Forms.ComboBox holdEffectComboBox;
private System.Windows.Forms.ComboBox fieldPocketComboBox;
private System.Windows.Forms.ComboBox battlePocketComboBox;
private System.Windows.Forms.ComboBox itemNameInputComboBox;
private System.Windows.Forms.NumericUpDown priceNumericUpDown;
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
private System.Windows.Forms.Label holdEffectLabel;
private System.Windows.Forms.Label fieldPocketLabel;
private System.Windows.Forms.Label battlePocketLabel;
private System.Windows.Forms.Label priceLabel;
private System.Windows.Forms.Button saveDataButton;
private System.Windows.Forms.Label holdEffectParameterLabel;
private System.Windows.Forms.FlowLayoutPanel holdFlowLayoutPanel;
private System.Windows.Forms.GroupBox holdGroupBox;
private System.Windows.Forms.NumericUpDown holdEffectParameterNumericUpDown;
private System.Windows.Forms.FlowLayoutPanel pocketFlowLayoutPanel;
private System.Windows.Forms.GroupBox pocketGroupBox;
private System.Windows.Forms.FlowLayoutPanel moveRelatedFlowLayoutPanel;
private System.Windows.Forms.GroupBox moveRelatedGroupBox;
private System.Windows.Forms.Label naturalGiftTypeLabel;
private System.Windows.Forms.ComboBox naturalGiftTypeComboBox;
private System.Windows.Forms.Label flingEffectLabel;
private System.Windows.Forms.Label naturalGiftPowerLabel;
private System.Windows.Forms.NumericUpDown flingPowerNumericUpDown;
private System.Windows.Forms.NumericUpDown pluckEffectNumericUpDown;
private System.Windows.Forms.Label flingPowerLabel;
private System.Windows.Forms.Label pluckEffectLabel;
private System.Windows.Forms.NumericUpDown flingEffectNumericUpDown;
private System.Windows.Forms.NumericUpDown naturalGiftPowerNumericUpDown;
private System.Windows.Forms.FlowLayoutPanel checksFlowLayoutPanel;
private System.Windows.Forms.GroupBox checksGroupBox;
private System.Windows.Forms.CheckBox preventTossCheckBox;
private System.Windows.Forms.CheckBox canSelectCheckBox;
}
}

View File

@ -0,0 +1,331 @@
using DSPRE.Resources;
using DSPRE.ROMFiles;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Net.Sockets;
using System.Text;
using System.Windows.Forms;
using MessageBox = System.Windows.Forms.MessageBox;
namespace DSPRE.Editors
{
public partial class ItemEditor : Form
{
private string[] itemFileNames;
//private readonly string[] itemDescriptions;
private int currentLoadedId = 0;
private ItemData currentLoadedFile = null;
private static bool dirty = false;
private static readonly string formName = "Item Data Editor";
public ItemEditor(string[] itemFileNames) //, string[] itemDescriptions)
{
int killCount = 0;
List<string> cleanNames = itemFileNames.ToList();
for (int i = 0; i < itemFileNames.Length; i++)
{
if (itemFileNames[i] == null || itemFileNames[i] == "???")
{
cleanNames.RemoveAt(i-killCount);
killCount++;
}
}
this.itemFileNames = cleanNames.ToArray();
//this.itemDescriptions = itemDescriptions;
InitializeComponent();
Helpers.DisableHandlers();
// Set up max and min for numerics
priceNumericUpDown.Minimum = 0;
priceNumericUpDown.Maximum = 65535;
itemNumberNumericUpDown.Minimum = 1;
itemNumberNumericUpDown.Maximum = this.itemFileNames.Length - 1;
holdEffectParameterNumericUpDown.Minimum = 0;
holdEffectParameterNumericUpDown.Maximum = 255;
pluckEffectNumericUpDown.Minimum = 0;
pluckEffectNumericUpDown.Maximum = 255;
flingEffectNumericUpDown.Minimum = 0;
flingEffectNumericUpDown.Maximum = 255;
flingPowerNumericUpDown.Minimum = 0;
flingPowerNumericUpDown.Maximum = 255;
naturalGiftPowerNumericUpDown.Minimum = 0;
naturalGiftPowerNumericUpDown.Maximum = 255;
// Set up combobox ranges
itemNameInputComboBox.Items.AddRange(this.itemFileNames);
holdEffectComboBox.Items.AddRange(Enum.GetNames(typeof(HoldEffect)));
fieldPocketComboBox.Items.AddRange(Enum.GetNames(typeof(FieldPocket)));
battlePocketComboBox.Items.AddRange(Enum.GetNames(typeof(BattlePocket)));
naturalGiftTypeComboBox.Items.AddRange(Enum.GetNames(typeof(NaturalGiftType)));
Helpers.EnableHandlers();
itemNameInputComboBox.SelectedIndex = 1;
}
private void setDirty(bool status)
{
if (status)
{
dirty = true;
this.Text = formName + "*";
}
else
{
dirty = false;
this.Text = formName;
}
}
private bool CheckDiscardChanges()
{
if (!dirty)
{
return true;
}
DialogResult res = MessageBox.Show(this, "There are unsaved changes to the current Item data.\nDiscard and proceed?", "Unsaved changes", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
if (res == DialogResult.Yes)
{
return true;
}
itemNumberNumericUpDown.Value = currentLoadedId;
itemNameInputComboBox.SelectedIndex = currentLoadedId;
return false;
}
private void ChangeLoadedFile(int toLoad)
{
Console.WriteLine("ItemEditor: ChangeLoadedFile: toLoad = " + toLoad);
currentLoadedId = toLoad;
currentLoadedFile = new ItemData(toLoad);
PopulateAllFromCurrentFile();
setDirty(false);
}
private void PopulateAllFromCurrentFile()
{
// Hold effects
holdEffectComboBox.SelectedIndex = (int)currentLoadedFile.holdEffect;
holdEffectParameterNumericUpDown.Value = currentLoadedFile.HoldEffectParam;
// Pockets
fieldPocketComboBox.SelectedIndex = (int)currentLoadedFile.fieldPocket;
// Set the selected value for non sequential enums
BattlePocket battlePocket = (BattlePocket)currentLoadedFile.battlePocket;
string battlePocketEnum = Enum.GetName(typeof(BattlePocket), battlePocket);
battlePocketComboBox.SelectedItem = battlePocketEnum;
// Move Related
// Set the selected value for non sequential enums
NaturalGiftType naturalGiftType = (NaturalGiftType)currentLoadedFile.naturalGiftType;
string naturalGiftTypeEnum = Enum.GetName(typeof(NaturalGiftType), naturalGiftType);
naturalGiftTypeComboBox.SelectedItem = naturalGiftTypeEnum;
naturalGiftPowerNumericUpDown.Value = currentLoadedFile.NaturalGiftPower;
flingEffectNumericUpDown.Value = currentLoadedFile.FlingEffect;
flingPowerNumericUpDown.Value = currentLoadedFile.FlingPower;
pluckEffectNumericUpDown.Value = currentLoadedFile.PluckEffect;
// Checks
preventTossCheckBox.Checked = currentLoadedFile.PreventToss;
canSelectCheckBox.Checked = currentLoadedFile.Selectable;
// Price
priceNumericUpDown.Value = currentLoadedFile.price;
//descriptionTextBox.Text = itemDescriptions[currentLoadedId];
}
private void saveDataButton_Click(object sender, EventArgs e)
{
currentLoadedFile.SaveToFileDefaultDir(currentLoadedId, true);
setDirty(false);
}
private void itemNameInputComboBox_SelectedIndexChanged(object sender, EventArgs e)
{
if (Helpers.HandlersDisabled)
{
return;
}
Helpers.DisableHandlers();
if (CheckDiscardChanges())
{
int newId = itemNameInputComboBox.SelectedIndex;
Console.WriteLine("ItemEditor: itemNameInputComboBox_SelectedIndexChanged: newId = " + newId);
itemNumberNumericUpDown.Value = newId;
ChangeLoadedFile(newId);
}
Helpers.EnableHandlers();
}
private void itemNumberNumericUpDown_ValueChanged(object sender, EventArgs e)
{
if (Helpers.HandlersDisabled)
{
return;
}
Helpers.DisableHandlers();
if (CheckDiscardChanges())
{
int newId = (int)itemNumberNumericUpDown.Value;
itemNameInputComboBox.SelectedIndex = newId;
Console.WriteLine("ItemEditor: itemNumberNumericUpDown_ValueChanged: newId = " + newId);
ChangeLoadedFile(newId);
}
Helpers.EnableHandlers();
}
private void saveToFileToolStripMenuItem_Click(object sender, EventArgs e)
{
string suggestedFilename = this.itemFileNames[currentLoadedId];
currentLoadedFile.SaveToFileExplorePath(suggestedFilename, true);
}
private void holdEffectComboBox_SelectedIndexChanged(object sender, EventArgs e)
{
if (Helpers.HandlersDisabled)
{
return;
}
currentLoadedFile.holdEffect = (HoldEffect)holdEffectComboBox.SelectedIndex;
setDirty(true);
}
private void fieldPocketComboBox_SelectedIndexChanged(object sender, EventArgs e)
{
if (Helpers.HandlersDisabled)
{
return;
}
currentLoadedFile.fieldPocket = (FieldPocket)fieldPocketComboBox.SelectedIndex;
setDirty(true);
}
private void battlePocketComboBox_SelectedIndexChanged(object sender, EventArgs e)
{
if (Helpers.HandlersDisabled)
{
return;
}
currentLoadedFile.battlePocket = (BattlePocket)battlePocketComboBox.SelectedValue;
setDirty(true);
}
private void priceNumericUpDown_ValueChanged(object sender, EventArgs e)
{
if (Helpers.HandlersDisabled)
{
return;
}
currentLoadedFile.price = (ushort)priceNumericUpDown.Value;
setDirty(true);
}
private void holdEffectParameterNumericUpDown_ValueChanged(object sender, EventArgs e)
{
if (Helpers.HandlersDisabled)
{
return;
}
currentLoadedFile.HoldEffectParam = (byte)holdEffectParameterNumericUpDown.Value;
setDirty(true);
}
private void naturalGiftTypeComboBox_SelectedIndexChanged(object sender, EventArgs e)
{
if (Helpers.HandlersDisabled)
{
return;
}
currentLoadedFile.naturalGiftType = (NaturalGiftType)naturalGiftTypeComboBox.SelectedIndex;
setDirty(true);
}
private void naturalGiftPowerNumericUpDown_ValueChanged(object sender, EventArgs e)
{
if (Helpers.HandlersDisabled)
{
return;
}
currentLoadedFile.NaturalGiftPower = (byte)naturalGiftPowerNumericUpDown.Value;
setDirty(true);
}
private void pluckEffectNumericUpDown_ValueChanged(object sender, EventArgs e)
{
if (Helpers.HandlersDisabled)
{
return;
}
currentLoadedFile.PluckEffect = (byte)pluckEffectNumericUpDown.Value;
setDirty(true);
}
private void flingEffectNumericUpDown_ValueChanged(object sender, EventArgs e)
{
if (Helpers.HandlersDisabled)
{
return;
}
currentLoadedFile.FlingEffect = (byte)flingEffectNumericUpDown.Value;
setDirty(true);
}
private void flingPowerNumericUpDown_ValueChanged(object sender, EventArgs e)
{
if (Helpers.HandlersDisabled)
{
return;
}
currentLoadedFile.FlingPower = (byte)flingPowerNumericUpDown.Value;
setDirty(true);
}
private void preventTossCheckBox_CheckedChanged(object sender, EventArgs e)
{
if (Helpers.HandlersDisabled)
{
return;
}
currentLoadedFile.PreventToss = preventTossCheckBox.Checked;
setDirty(true);
}
private void canSelectCheckBox_CheckedChanged(object sender, EventArgs e)
{
if (Helpers.HandlersDisabled)
{
return;
}
currentLoadedFile.Selectable = canSelectCheckBox.Checked;
setDirty(true);
}
}
}

View File

@ -0,0 +1,120 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@ -23,15 +23,16 @@
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent() {
this.components = new System.ComponentModel.Container();
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(PokemonEditor));
this.tabControl = new System.Windows.Forms.TabControl();
this.personalPage = new System.Windows.Forms.TabPage();
this.learnsetPage = new System.Windows.Forms.TabPage();
this.evoPage = new System.Windows.Forms.TabPage();
this.syncChangesCheckbox = new System.Windows.Forms.CheckBox();
this.syncChangesLabel = new System.Windows.Forms.Label();
this.flowLayoutPanel1 = new System.Windows.Forms.FlowLayoutPanel();
this.spritePage = new System.Windows.Forms.TabPage();
this.syncChangesCheckbox = new System.Windows.Forms.CheckBox();
this.flowLayoutPanel1 = new System.Windows.Forms.FlowLayoutPanel();
this.toolTip1 = new System.Windows.Forms.ToolTip(this.components);
this.tabControl.SuspendLayout();
this.flowLayoutPanel1.SuspendLayout();
this.SuspendLayout();
@ -56,7 +57,7 @@
this.personalPage.Location = new System.Drawing.Point(4, 22);
this.personalPage.Name = "personalPage";
this.personalPage.Padding = new System.Windows.Forms.Padding(3);
this.personalPage.Size = new System.Drawing.Size(1024, 534);
this.personalPage.Size = new System.Drawing.Size(1024, 817);
this.personalPage.TabIndex = 0;
this.personalPage.Text = "Personal Editor";
this.personalPage.UseVisualStyleBackColor = true;
@ -66,7 +67,7 @@
this.learnsetPage.Location = new System.Drawing.Point(4, 22);
this.learnsetPage.Name = "learnsetPage";
this.learnsetPage.Padding = new System.Windows.Forms.Padding(3);
this.learnsetPage.Size = new System.Drawing.Size(1024, 526);
this.learnsetPage.Size = new System.Drawing.Size(1024, 817);
this.learnsetPage.TabIndex = 1;
this.learnsetPage.Text = "Learnset Editor";
this.learnsetPage.UseVisualStyleBackColor = true;
@ -76,11 +77,21 @@
this.evoPage.Location = new System.Drawing.Point(4, 22);
this.evoPage.Name = "evoPage";
this.evoPage.Padding = new System.Windows.Forms.Padding(3);
this.evoPage.Size = new System.Drawing.Size(1024, 526);
this.evoPage.Size = new System.Drawing.Size(1024, 817);
this.evoPage.TabIndex = 2;
this.evoPage.Text = "Evolution Editor";
this.evoPage.UseVisualStyleBackColor = true;
//
// spritePage
//
this.spritePage.Location = new System.Drawing.Point(4, 22);
this.spritePage.Name = "spritePage";
this.spritePage.Padding = new System.Windows.Forms.Padding(3);
this.spritePage.Size = new System.Drawing.Size(1024, 817);
this.spritePage.TabIndex = 3;
this.spritePage.Text = "Sprite Editor";
this.spritePage.UseVisualStyleBackColor = true;
//
// syncChangesCheckbox
//
this.syncChangesCheckbox.AutoSize = true;
@ -91,42 +102,17 @@
this.syncChangesCheckbox.TabIndex = 1;
this.syncChangesCheckbox.Text = "Synchronize Pokémon selection";
this.syncChangesCheckbox.UseVisualStyleBackColor = true;
//
// syncChangesLabel
//
this.syncChangesLabel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right)));
this.syncChangesLabel.AutoSize = true;
this.syncChangesLabel.Dock = System.Windows.Forms.DockStyle.Bottom;
this.syncChangesLabel.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.syncChangesLabel.ForeColor = System.Drawing.SystemColors.Highlight;
this.syncChangesLabel.Location = new System.Drawing.Point(186, 10);
this.syncChangesLabel.Name = "syncChangesLabel";
this.syncChangesLabel.Size = new System.Drawing.Size(433, 13);
this.syncChangesLabel.TabIndex = 2;
this.syncChangesLabel.Text = "When this CheckBox is marked, mon selection will be synchronized accross all tabs" +
" below.";
//
// flowLayoutPanel1
//
this.flowLayoutPanel1.AutoSize = true;
this.flowLayoutPanel1.Controls.Add(this.syncChangesCheckbox);
this.flowLayoutPanel1.Controls.Add(this.syncChangesLabel);
this.flowLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Top;
this.flowLayoutPanel1.Location = new System.Drawing.Point(0, 0);
this.flowLayoutPanel1.Name = "flowLayoutPanel1";
this.flowLayoutPanel1.Size = new System.Drawing.Size(1032, 23);
this.flowLayoutPanel1.TabIndex = 3;
//
// spritePage
//
this.spritePage.Location = new System.Drawing.Point(4, 22);
this.spritePage.Name = "spritePage";
this.spritePage.Padding = new System.Windows.Forms.Padding(3);
this.spritePage.Size = new System.Drawing.Size(1024, 817);
this.spritePage.TabIndex = 3;
this.spritePage.Text = "Sprite Editor";
this.spritePage.UseVisualStyleBackColor = true;
//
// PokemonEditor
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
@ -154,8 +140,8 @@
private System.Windows.Forms.TabPage learnsetPage;
private System.Windows.Forms.TabPage evoPage;
private System.Windows.Forms.CheckBox syncChangesCheckbox;
private System.Windows.Forms.Label syncChangesLabel;
private System.Windows.Forms.FlowLayoutPanel flowLayoutPanel1;
private System.Windows.Forms.TabPage spritePage;
private System.Windows.Forms.ToolTip toolTip1;
}
}

View File

@ -41,8 +41,10 @@ namespace DSPRE {
spriteEditor.TopLevel = false;
spriteEditor.Show();
spritePage.Controls.Add(spriteEditor);
spritePage.Enabled = false;
spritePage.Visible = false;
//spritePage.Enabled = false;
//spritePage.Visible = false;
toolTip1.SetToolTip(syncChangesCheckbox, "When this CheckBox is marked, mon selection will be synchronized accross all tabs below.");
}
public void TrySyncIndices(ComboBox sender) {

View File

@ -117,6 +117,9 @@
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="toolTip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="$this.Icon" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>

View File

@ -103,6 +103,7 @@ namespace DSPRE.Editors
Button SaveSingle;
Button MakeShiny;
Button OpenOther;
Button SaveChanges;
NarcReader nr;
PictureBox[,] Display;
@ -350,6 +351,7 @@ namespace DSPRE.Editors
SaveSingle = new Button();
MakeShiny = new Button();
OpenOther = new Button();
SaveChanges = new Button();
lblMale = new Label();
lblFemale = new Label();
@ -449,6 +451,12 @@ namespace DSPRE.Editors
MakeShiny.Text = "Create Shiny Palette";
MakeShiny.Click += (MakeShiny_Click);
SaveChanges.Location = new Point(754, 8);
SaveChanges.Name = "SaveChanges";
SaveChanges.Size = new Size(70, 21);
SaveChanges.Text = "Save Changes";
SaveChanges.Click += (SaveChanges_Click);
lblFemale.Text = "Female";
lblFemale.Location = new Point(232, 36);
Controls.Add(lblFemale);
@ -485,6 +493,7 @@ namespace DSPRE.Editors
Controls.Add(SaveSingle);
Controls.Add(MakeShiny);
Controls.Add(OpenOther);
Controls.Add(SaveChanges);
AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
Width = 760;
Height = 808;
@ -492,6 +501,7 @@ namespace DSPRE.Editors
FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog;
MaximizeBox = false;
OpenPngs.Enabled = false;
OpenOther.Visible = false;
}
void IndexBox_SelectedIndexChanged(object sender, EventArgs e)
@ -987,7 +997,7 @@ namespace DSPRE.Editors
OpenPngs.Enabled = true;
}
void menuItem8_Click(object sender, EventArgs e)
void SaveChanges_Click(object sender, EventArgs e)
{
if (OpenPngs.Enabled == false)
return;

File diff suppressed because it is too large Load Diff

View File

@ -9248,7 +9248,7 @@ namespace DSPRE {
private void unpackToFolderToolStripMenuItem_Click(object sender, EventArgs e) {
OpenFileDialog of = new OpenFileDialog {
Filter = "NARC File (*.narc)|*.narc"
Filter = "NARC File (*.narc)|*.narc|All files (*.*)|*.*"
};
if (of.ShowDialog(this) != DialogResult.OK) {
return;
@ -10080,5 +10080,21 @@ namespace DSPRE {
var flyEditor = new FlyEditor(gameFamily, headerListBoxNames);
flyEditor.Show();
}
private void itemEditorToolStripMenuItem_Click(object sender, EventArgs e)
{
Helpers.statusLabelMessage("Setting up Item Data Editor...");
Update();
DSUtils.TryUnpackNarcs(new List<DirNames> { DirNames.itemData });
ItemEditor itemEditor = new ItemEditor(
RomInfo.GetItemNames()
);
itemEditor.ShowDialog();
Helpers.statusLabelMessage();
Update();
}
}
}

View File

@ -117,145 +117,7 @@
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="toolTip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>533, 20</value>
</metadata>
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="addHeadersButton.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
vAAADrwBlbxySQAAAFxJREFUOE9j+P//PwM2zDBF7h/DFLn/DNNk/4PY6PJwdegCKAYsUPgPxqMG4DcA
HtoYWBaiGWwAJCawYhSFpGJQFFPBACzOAmMivYAeKCQHIrrAqAFoBiASFk4DAOQLbokdS+snAAAAAElF
TkSuQmCC
</value>
</data>
<data name="removeMatrixButton.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
vAAADrwBlbxySQAAAFBJREFUOE+l0bEJwDAMRNFDG3ijrJfeeJ8sFoW0vur7itd8sBCyulsJC5QFygJl
gdJduhKaqjehpepH48j/Nh+wr0TlR9y/hbJAWaAsUBaoD7HiY1fWoY0CAAAAAElFTkSuQmCC
</value>
</data>
<data name="addHeightsButton.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
vAAADrwBlbxySQAAAFxJREFUOE9j+P//PwM2zDBF7h/DFLn/DNNk/4PY6PJwdegCKAYsUPgPxqMG4DcA
HtoYWBaiGWwAJCawYhSFpGJQFFPBACzOAmMivYAeKCQHIrrAqAFoBiASFk4DAOQLbokdS+snAAAAAElF
TkSuQmCC
</value>
</data>
<data name="addMatrixButton.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
vAAADrwBlbxySQAAAFxJREFUOE9j+P//PwM2zDBF7h/DFLn/DNNk/4PY6PJwdegCKAYsUPgPxqMG4DcA
HtoYWBaiGWwAJCawYhSFpGJQFFPBACzOAmMivYAeKCQHIrrAqAFoBiASFk4DAOQLbokdS+snAAAAAElF
TkSuQmCC
</value>
</data>
<data name="removeHeadersButton.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
vAAADrwBlbxySQAAAFBJREFUOE+l0bEJwDAMRNFDG3ijrJfeeJ8sFoW0vur7itd8sBCyulsJC5QFygJl
gdJduhKaqjehpepH48j/Nh+wr0TlR9y/hbJAWaAsUBaoD7HiY1fWoY0CAAAAAElFTkSuQmCC
</value>
</data>
<data name="removeHeightsButton.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
vAAADrwBlbxySQAAAFBJREFUOE+l0bEJwDAMRNFDG3ijrJfeeJ8sFoW0vur7itd8sBCyulsJC5QFygJl
gdJduhKaqjehpepH48j/Nh+wr0TlR9y/hbJAWaAsUBaoD7HiY1fWoY0CAAAAAElFTkSuQmCC
</value>
</data>
<metadata name="mainTabImageList.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>239, 17</value>
</metadata>
<data name="mainTabImageList.ImageStream" mimetype="application/x-microsoft.net.object.binary.base64">
<value>
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAACM
EgAAAk1TRnQBSQFMAgEBCgEAASABHQEgAR0BEAEAARABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
AwABQAMAATADAAEBAQABCAYAAQwYAAGAAgABgAMAAoABAAGAAwABgAEAAYABAAKAAgADwAEAAcAB3AHA
AQAB8AHKAaYBAAEzBQABMwEAATMBAAEzAQACMwIAAxYBAAMcAQADIgEAAykBAANVAQADTQEAA0IBAAM5
AQABgAF8Af8BAAJQAf8BAAGTAQAB1gEAAf8B7AHMAQABxgHWAe8BAAHWAucBAAGQAakBrQIAAf8BMwMA
AWYDAAGZAwABzAIAATMDAAIzAgABMwFmAgABMwGZAgABMwHMAgABMwH/AgABZgMAAWYBMwIAAmYCAAFm
AZkCAAFmAcwCAAFmAf8CAAGZAwABmQEzAgABmQFmAgACmQIAAZkBzAIAAZkB/wIAAcwDAAHMATMCAAHM
AWYCAAHMAZk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EBwAEAAYABAQEA
ARgBwAEAAcABAQGAAQEBgAE8AcABAAHAAQEBgAEBAY4BPwHAAQAB4AEPAYABAQEEAR8BgAEAAeABHwHA
AQMBJAGfAgAB4AE/AcABAwEEAR8BAAEBAeAB/wHgAQcBjgE/AZgBDwHwAf8B8AEPAv8B+AF/Av8B/AE/
Av8BgAEDAv8BgAEDAv8BgAEDAQABAQEAAQEB/AE/AaABGwEAAQEBfwH9AfABDwGvAdsBAAExAX8B/QHg
AQcBqAFbAQABSQFAAQUBwAEDAagBSwEAAUkBQAEFAcABAwGoAUsBAAExAUABBQGBAQEBqAFLAQABAQFA
AQUBgAEBAa8BywEAAQEBQAEFAYABAQGgAQsBAAH9AUABBQGAAQEBoAF7ARgBxQFAAQUBwAEDAaABiwEk
Ae0BQAEFAcABAwGgAbMBJAHNAUABBQHgAQcBoAGnARgB7QFAAQUB8AEPAb8BzwEAAf0BfwH9AfwBPwGA
AR8BAAEBAQABAQL/Cw==
</value>
</data>
<data name="worldmapCoordsPasteButton.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
@ -694,6 +556,51 @@
WQT4nDhGC/CgsUPIUQsMIa2AlrPAbAJ8TiYP4RCSgBa1AH+S86/gZAKaXbEkwF9T9BAC7OcgoYELaBEF
unRPhsBWCzsfHq7haAII0uyIuuD6owgA/K8jLBZxPxALbowVDuGFx8IDY/kD7lUZk+GYq/AAAAAASUVO
RK5CYII=
</value>
</data>
<data name="addHeadersButton.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
vAAADrwBlbxySQAAAFxJREFUOE9j+P//PwM2zDBF7h/DFLn/DNNk/4PY6PJwdegCKAYsUPgPxqMG4DcA
HtoYWBaiGWwAJCawYhSFpGJQFFPBACzOAmMivYAeKCQHIrrAqAFoBiASFk4DAOQLbokdS+snAAAAAElF
TkSuQmCC
</value>
</data>
<data name="removeMatrixButton.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
vAAADrwBlbxySQAAAFBJREFUOE+l0bEJwDAMRNFDG3ijrJfeeJ8sFoW0vur7itd8sBCyulsJC5QFygJl
gdJduhKaqjehpepH48j/Nh+wr0TlR9y/hbJAWaAsUBaoD7HiY1fWoY0CAAAAAElFTkSuQmCC
</value>
</data>
<data name="addHeightsButton.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
vAAADrwBlbxySQAAAFxJREFUOE9j+P//PwM2zDBF7h/DFLn/DNNk/4PY6PJwdegCKAYsUPgPxqMG4DcA
HtoYWBaiGWwAJCawYhSFpGJQFFPBACzOAmMivYAeKCQHIrrAqAFoBiASFk4DAOQLbokdS+snAAAAAElF
TkSuQmCC
</value>
</data>
<data name="addMatrixButton.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
vAAADrwBlbxySQAAAFxJREFUOE9j+P//PwM2zDBF7h/DFLn/DNNk/4PY6PJwdegCKAYsUPgPxqMG4DcA
HtoYWBaiGWwAJCawYhSFpGJQFFPBACzOAmMivYAeKCQHIrrAqAFoBiASFk4DAOQLbokdS+snAAAAAElF
TkSuQmCC
</value>
</data>
<data name="removeHeadersButton.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
vAAADrwBlbxySQAAAFBJREFUOE+l0bEJwDAMRNFDG3ijrJfeeJ8sFoW0vur7itd8sBCyulsJC5QFygJl
gdJduhKaqjehpepH48j/Nh+wr0TlR9y/hbJAWaAsUBaoD7HiY1fWoY0CAAAAAElFTkSuQmCC
</value>
</data>
<data name="removeHeightsButton.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
vAAADrwBlbxySQAAAFBJREFUOE+l0bEJwDAMRNFDG3ijrJfeeJ8sFoW0vur7itd8sBCyulsJC5QFygJl
gdJduhKaqjehpepH48j/Nh+wr0TlR9y/hbJAWaAsUBaoD7HiY1fWoY0CAAAAAElFTkSuQmCC
</value>
</data>
<data name="addMapFileButton.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
@ -1034,6 +941,96 @@
NaU33+5Z3SbBeCjNjTd7hGN5BvoHcLjuU61DOJY7hFqN2+9TVrdJMLmucutdkkiqit0+xMT0LAYQSZYP
gTp3PkpWt0kw9Pw7Vxa/8TAUZdBu3xh3z2wsfIkyG/yL+bctha1u18TK1oHguBDiohCi7x8a/430CiG6
zeXfJelqUKnUyCAAAAAASUVORK5CYII=
</value>
</data>
<metadata name="mainTabImageList.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>239, 17</value>
</metadata>
<data name="mainTabImageList.ImageStream" mimetype="application/x-microsoft.net.object.binary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FA
AQUBgAEBAa8BywEAAQEBQAEFAYABAQGgAQsBAAH9AUABBQGAAQEBoAF7ARgBxQFAAQUBwAEDAaABiwEk
Ae0BQAEFAcABAwGgAbMBJAHNAUABBQHgAQcBoAGnARgB7QFAAQUB8AEPAb8BzwEAAf0BfwH9AfwBPwGA
AR8BAAEBAQABAQL/Cw==
</value>
</data>
<metadata name="menuStrip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">

568
DS_Map/ROMFiles/ItemData.cs Normal file
View File

@ -0,0 +1,568 @@
using System;
using System.IO;
using static DSPRE.RomInfo;
using static Microsoft.WindowsAPICodePack.Shell.PropertySystem.SystemProperties.System;
namespace DSPRE.ROMFiles
{
public enum NaturalGiftType
{
Normal = 0,
Fighting = 1,
Flying = 2,
Poison = 3,
Ground = 4,
Rock = 5,
Bug = 6,
Ghost = 7,
Steel = 8,
Fire = 10,
Water = 11,
Grass = 12,
Electric = 13,
Psychic = 14,
Ice = 15,
Dragon = 16,
Dark = 17,
NONE = 31
}
public enum FieldPocket
{
Items = 0,
Medicine = 1,
Balls = 2,
TmHms = 3,
Berries = 4,
Mail = 5,
BattleItems = 6,
KeyItems = 7
}
public enum BattlePocket
{
None = 0,
PokeBalls = 1,
BattleItems = 2,
HpRestore = 4,
StatusHealers = 8,
PpRestore = 16
}
public enum HoldEffect
{
None = 0,
HpRestore = 1,
GiratinaBoost = 2,
DialgaBoost = 3,
PalkiaBoost = 4,
PrzRestore = 5,
SlpRestore = 6,
PsnRestore = 7,
BrnRestore = 8,
FrzRestore = 9,
PpRestore = 10,
ConfuseRestore = 11,
StatusRestore = 12,
HpPctRestore = 13,
HpRestoreSpicy = 14,
HpRestoreDry = 15,
HpRestoreSweet = 16,
HpRestoreBitter = 17,
HpRestoreSour = 18,
WeakenSeFire = 19,
WeakenSeWater = 20,
WeakenSeElectric = 21,
WeakenSeGrass = 22,
WeakenSeIce = 23,
WeakenSeFight = 24,
WeakenSePoison = 25,
WeakenSeGround = 26,
WeakenSeFlying = 27,
WeakenSePsychic = 28,
WeakenSeBug = 29,
WeakenSeRock = 30,
WeakenSeGhost = 31,
WeakenSeDragon = 32,
WeakenSeDark = 33,
WeakenSeSteel = 34,
WeakenNormal = 35,
PinchAtkUp = 36,
PinchDefUp = 37,
PinchSpeedUp = 38,
PinchSpAtkUp = 39,
PinchSpDefUp = 40,
PinchCritrateUp = 41,
PinchRandomUp = 42,
HpRestoreSe = 43,
PinchAccUp = 44,
PinchPriority = 45,
RecoilPhysical = 46,
RecoilSpecial = 47,
AccReduce = 48,
StatdownRestore = 49,
EvsUpSpeedDown = 50,
ExpShare = 51,
SometimesPriority = 52,
FriendshipUp = 53,
HealInfatuation = 54,
ChoiceAtk = 55,
SometimesFlinch = 56,
StrengthenBug = 57,
MoneyUp = 58,
EncountersDown = 59,
LatiSpecial = 60,
ClamperlSpAtk = 61,
ClamperlSpDef = 62,
Flee = 63,
NoEvolve = 64,
MaybeEndure = 65,
ExpUp = 66,
CritrateUp = 67,
StrengthenSteel = 68,
HpRestoreGradual = 69,
EvolveSeadra = 70,
PikaSpAtkUp = 71,
StrengthenGround = 72,
StrengthenRock = 73,
StrengthenGrass = 74,
StrengthenDark = 75,
StrengthenFight = 76,
StrengthenElectric = 77,
StrengthenWater = 78,
StrengthenFlying = 79,
StrengthenPoison = 80,
StrengthenIce = 81,
StrengthenGhost = 82,
StrengthenPsychic = 83,
StrengthenFire = 84,
StrengthenDragon = 85,
StrengthenNormal = 86,
EvolvePorygon = 87,
HpRestoreOnDmg = 88,
ChanseyCritrateUp = 89,
DittoDefUp = 90,
CuboneAtkUp = 91,
FarfetchdCritrateUp = 92,
AccuracyUp = 93,
PowerUpPhys = 94,
PowerUpSpec = 95,
PowerUpSe = 96,
ExtendScreens = 97,
HpDrainOnAtk = 98,
ChargeSkip = 99,
PsnUser = 100,
BrnUser = 101,
DittoSpeedUp = 102,
Endure = 103,
AccuracyUpSlower = 104,
BoostRepeated = 105,
SpeedDownGrounded = 106,
PriorityDown = 107,
ReciprocateInfat = 108,
HpRestorePsnType = 109,
ExtendHail = 110,
ExtendSandstorm = 111,
ExtendSun = 112,
ExtendRain = 113,
ExtendTrapping = 114,
ChoiceSpeed = 115,
DmgUserContactXfr = 116,
LvlupAtkEvUp = 117,
LvlupDefEvUp = 118,
LvlupSpAtkEvUp = 119,
LvlupSpDefEvUp = 120,
LvlupSpeedEvUp = 121,
LvlupHpEvUp = 122,
Switch = 123,
LeechBoost = 124,
ChoiceSpAtk = 125,
ArceusFire = 126,
ArceusWater = 127,
ArceusElectric = 128,
ArceusGrass = 129,
ArceusIce = 130,
ArceusFighting = 131,
ArceusPoison = 132,
ArceusGround = 133,
ArceusFlying = 134,
ArceusPsychic = 135,
ArceusBug = 136,
ArceusRock = 137,
ArceusGhost = 138,
ArceusDragon = 139,
ArceusDark = 140,
ArceusSteel = 141,
EvolveRhydon = 142,
EvolveElectabuzz = 143,
EvolveMagmar = 144,
EvolvePorygon2 = 145,
EvolveDusclops = 146,
// These are hg-engine items, not in gen 4
//BurnDrive = 147,
//ChillDrive = 148,
//DouseDrive = 149,
//ShockDrive = 150,
//EvolveFeebas = 151,
//Eviolite = 152,
//HalveWeight = 153,
//DamageOnContact = 154,
//UngroundDestroyedOnHit = 155,
//ForceSwitchOnDamage = 156,
//LoseTypeImmunities = 157,
//TrappingDamageUp = 158,
//BoostSpecialAttackOnWaterHit = 159,
//BoostAtkOnElectricHit = 160,
//SwitchOutWhenHit = 161,
//BoostAtkAndSpAtkOnSe = 162,
//SpDefBoostNoStatusMoves = 163,
//ArceusFairy = 164,
//EvolveSwirlix = 165,
//EvolveSpritzee = 166,
//BoostSpecialDefenseOnWaterHit = 167,
//BoostAtkOnIceHit = 168,
//SporePowderImmunity = 169,
//WeakenSeFairy = 170,
//BoostDefOnPhysicalHit = 171,
//BoostSpDefOnSpecialHit = 172,
//IntimidateBoostSpeed = 173,
//ExtendTerrain = 174,
//PreventContactEffects = 175,
//BoostDefOnElectricTerrain = 176,
//BoostSpDefOnPsychicTerrain = 177,
//BoostSpDefOnMistyTerrain = 178,
//BoostDefOnGrassyTerrain = 179,
//FightingMemory = 180,
//FlyingMemory = 181,
//PoisonMemory = 182,
//GroundMemory = 183,
//RockMemory = 184,
//BugMemory = 185,
//GhostMemory = 186,
//SteelMemory = 187,
//FireMemory = 188,
//WaterMemory = 189,
//GrassMemory = 190,
//ElectricMemory = 191,
//PsychicMemory = 192,
//IceMemory = 193,
//DragonMemory = 194,
//DarkMemory = 195,
//FairyMemory = 196,
//TransformZacian = 197,
//TransformZamazenta = 198,
//BoostSpAtkOnSoundMove = 199,
//SwitchOutOnStatDrop = 200,
//IgnoreEntryHazards = 201,
//BoostSpeedOnMiss = 202,
//DropSpeedInTrickRoom = 203,
//UnaffectedByRainOrSun = 204,
//DialgaBoostAndTransform = 205,
//PalkiaBoostAndTransform = 206,
//GiratinaBoostAndTransform = 207,
//ArceusNormal = 208,
//ActivateParadoxAbilities = 209,
//PreventAbilityChanges = 210,
//PreventStatDrops = 211,
//CopyStatIncrease = 212,
//IncreasePunchingMoveDmg = 213,
//PreventSecondaryEffects = 214,
//IncreaseMultiStrikeMinimum = 215,
//StrengthenFairy = 216,
//CornerstoneMask = 217,
//WellspringMask = 218,
//HearthflameMask = 219
}
public class ItemData : RomFile
{
public ushort price;
public HoldEffect holdEffect;
public byte HoldEffectParam;
public byte PluckEffect;
public byte FlingEffect;
public byte FlingPower;
public byte NaturalGiftPower;
// Bit-packed 16-bit value
public NaturalGiftType naturalGiftType; // 5 bits
public bool PreventToss; // 1 bit
public bool Selectable; // 1 bit
public FieldPocket fieldPocket; // 4 bits
public BattlePocket battlePocket; // 5 bits
public byte FieldUseFunc;
public byte BattleUseFunc;
public byte PartyUse;
public ItemPartyUseParam PartyUseParam;
public ItemData(Stream stream)
{
using (BinaryReader reader = new BinaryReader(stream))
{
price = reader.ReadUInt16();
holdEffect = (HoldEffect)reader.ReadByte();
HoldEffectParam = reader.ReadByte();
PluckEffect = reader.ReadByte();
FlingEffect = reader.ReadByte();
FlingPower = reader.ReadByte();
NaturalGiftPower = reader.ReadByte();
ushort bitfield = reader.ReadUInt16();
naturalGiftType = (NaturalGiftType)(bitfield & 0b0001_1111);
PreventToss = (bitfield & (1 << 5)) != 0;
Selectable = (bitfield & (1 << 6)) != 0;
fieldPocket = (FieldPocket)((bitfield >> 7) & 0b1111);
battlePocket = (BattlePocket)((bitfield >> 11) & 0b11111);
FieldUseFunc = reader.ReadByte();
BattleUseFunc = reader.ReadByte();
PartyUse = reader.ReadByte();
//reader.ReadByte(); // skip 1 byte padding_0D
PartyUseParam = new ItemPartyUseParam(reader);
reader.ReadBytes(2); // skip padding_22
}
}
public ItemData(int ID) : this(new FileStream(RomInfo.gameDirs[DirNames.itemData].unpackedDir + "\\" + ID.ToString("D4"), FileMode.Open)) { }
public override byte[] ToByteArray()
{
using (MemoryStream stream = new MemoryStream())
using (BinaryWriter writer = new BinaryWriter(stream))
{
writer.Write(price);
writer.Write((byte)holdEffect);
writer.Write(HoldEffectParam);
writer.Write(PluckEffect);
writer.Write(FlingEffect);
writer.Write(FlingPower);
writer.Write(NaturalGiftPower);
ushort bitfield = 0;
bitfield |= (ushort)((byte)naturalGiftType & 0b11111);
if (PreventToss) bitfield |= (1 << 5);
if (Selectable) bitfield |= (1 << 6);
bitfield |= (ushort)(((byte)fieldPocket & 0b1111) << 7);
bitfield |= (ushort)(((byte)battlePocket & 0b11111) << 11);
writer.Write(bitfield);
writer.Write(FieldUseFunc);
writer.Write(BattleUseFunc);
writer.Write(PartyUse);
writer.Write((byte)0); // padding
PartyUseParam.WriteTo(writer);
writer.Write(new byte[2]); // padding
return stream.ToArray();
}
}
public void SaveToFileDefaultDir(int IDtoReplace, bool showSuccessMessage = true)
{
SaveToFileDefaultDir(DirNames.itemData, IDtoReplace, showSuccessMessage);
}
public void SaveToFileExplorePath(string suggestedFileName, bool showSuccessMessage = true)
{
SaveToFileExplorePath("Gen IV Item data", "bin", suggestedFileName, showSuccessMessage);
}
public class ItemPartyUseParam
{
// Flags (bit-packed)
public bool SlpHeal;
public bool PsnHeal;
public bool BrnHeal;
public bool FrzHeal;
public bool PrzHeal;
public bool CfsHeal;
public bool InfHeal;
public bool GuardSpec;
public bool Revive;
public bool ReviveAll;
public bool LevelUp;
public bool Evolve;
public sbyte AtkStages;
public sbyte DefStages;
public sbyte SpAtkStages;
public sbyte SpDefStages;
public sbyte SpeedStages;
public sbyte AccuracyStages;
public sbyte CritRateStages;
public bool PPUps;
public bool PPMax;
public bool PPRestore;
public bool PPRestoreAll;
public bool HPRestore;
public bool[] EVUps = new bool[6]; // hp, atk, def, speed, spatk, spdef
public bool[] FriendshipMods = new bool[3]; // lo, med, hi
public sbyte[] EVParams = new sbyte[6]; // hp, atk, def, speed, spatk, spdef
public byte HPRestoreParam;
public byte PPRestoreParam;
public sbyte[] FriendshipParams = new sbyte[3]; // lo, med, hi
public ItemPartyUseParam(BinaryReader reader)
{
byte[] data = reader.ReadBytes(19); // Total size of struct
// Byte 0: HealStatus1 bits
byte healStatus1 = data[0];
SlpHeal = (healStatus1 & (1 << 0)) != 0;
PsnHeal = (healStatus1 & (1 << 1)) != 0;
BrnHeal = (healStatus1 & (1 << 2)) != 0;
FrzHeal = (healStatus1 & (1 << 3)) != 0;
PrzHeal = (healStatus1 & (1 << 4)) != 0;
CfsHeal = (healStatus1 & (1 << 5)) != 0;
InfHeal = (healStatus1 & (1 << 6)) != 0;
GuardSpec = (healStatus1 & (1 << 7)) != 0;
// Byte 1: revive, revive_all, level_up, evolve, + 4 bits padding
byte flags1 = data[1];
Revive = (flags1 & (1 << 0)) != 0;
ReviveAll = (flags1 & (1 << 1)) != 0;
LevelUp = (flags1 & (1 << 2)) != 0;
Evolve = (flags1 & (1 << 3)) != 0;
// Byte 2: atk_stages (4 bits), def_stages (4 bits)
byte stages1 = data[2];
AtkStages = (sbyte)(stages1 & 0x0F);
DefStages = (sbyte)((stages1 >> 4) & 0x0F);
// Byte 3: spatk_stages (4 bits), spdef_stages (4 bits)
byte stages2 = data[3];
SpAtkStages = (sbyte)(stages2 & 0x0F);
SpDefStages = (sbyte)((stages2 >> 4) & 0x0F);
// Byte 4: speed_stages (4 bits), accuracy_stages (4 bits)
byte stages3 = data[4];
SpeedStages = (sbyte)(stages3 & 0x0F);
AccuracyStages = (sbyte)((stages3 >> 4) & 0x0F);
// Byte 5: critrate_stages (2 bits), pp_up, pp_max, pp_restore, pp_restore_all, hp_restore (5 bits)
byte flags2 = data[5];
CritRateStages = (sbyte)(flags2 & 0x03);
PPUps = (flags2 & (1 << 2)) != 0;
PPMax = (flags2 & (1 << 3)) != 0;
PPRestore = (flags2 & (1 << 4)) != 0;
PPRestoreAll = (flags2 & (1 << 5)) != 0;
HPRestore = (flags2 & (1 << 6)) != 0;
// Byte 6: ev flags
byte evFlags = data[6];
EVUps = new bool[6];
for (int i = 0; i < 6; i++)
EVUps[i] = (evFlags & (1 << i)) != 0;
// Byte 7: friendship flags
byte friendFlags = data[7];
FriendshipMods = new bool[3];
for (int i = 0; i < 3; i++)
FriendshipMods[i] = (friendFlags & (1 << i)) != 0;
// Bytes 8-13: EVParams
EVParams = new sbyte[6];
for (int i = 0; i < 6; i++)
EVParams[i] = (sbyte)data[8 + i];
// Byte 14: HPRestoreParam
HPRestoreParam = data[14];
// Byte 15: PPRestoreParam
PPRestoreParam = data[15];
// Bytes 1618: FriendshipParams
FriendshipParams = new sbyte[3];
for (int i = 0; i < 3; i++)
FriendshipParams[i] = (sbyte)data[16 + i];
// Padding is ignored (2 bytes assumed to follow)
}
public void WriteTo(BinaryWriter writer)
{
byte[] data = new byte[18];
// Byte 0: HealStatus1
data[0] = 0;
if (SlpHeal) data[0] |= (1 << 0);
if (PsnHeal) data[0] |= (1 << 1);
if (BrnHeal) data[0] |= (1 << 2);
if (FrzHeal) data[0] |= (1 << 3);
if (PrzHeal) data[0] |= (1 << 4);
if (CfsHeal) data[0] |= (1 << 5);
if (InfHeal) data[0] |= (1 << 6);
if (GuardSpec) data[0] |= (1 << 7);
// Byte 1: revive, revive_all, level_up, evolve
data[1] = 0;
if (Revive) data[1] |= (1 << 0);
if (ReviveAll) data[1] |= (1 << 1);
if (LevelUp) data[1] |= (1 << 2);
if (Evolve) data[1] |= (1 << 3);
// Byte 2: atk + def stages
data[2] = (byte)((DefStages & 0x0F) << 4 | (AtkStages & 0x0F));
// Byte 3: spatk + spdef stages
data[3] = (byte)((SpDefStages & 0x0F) << 4 | (SpAtkStages & 0x0F));
// Byte 4: speed + accuracy stages
data[4] = (byte)((AccuracyStages & 0x0F) << 4 | (SpeedStages & 0x0F));
// Byte 5: crit rate + pp/hp flags
data[5] = (byte)(CritRateStages & 0x03);
if (PPUps) data[5] |= (1 << 2);
if (PPMax) data[5] |= (1 << 3);
if (PPRestore) data[5] |= (1 << 4);
if (PPRestoreAll) data[5] |= (1 << 5);
if (HPRestore) data[5] |= (1 << 6);
// Byte 6: EV flags
data[6] = 0;
for (int i = 0; i < 6; i++)
if (EVUps[i]) data[6] |= (byte)(1 << i);
// Byte 7: Friendship flags
data[7] = 0;
for (int i = 0; i < 3; i++)
if (FriendshipMods[i]) data[7] |= (byte)(1 << i);
// Bytes 8-13: EVParams
for (int i = 0; i < 6; i++)
data[8 + i] = (byte)EVParams[i];
// Byte 14: HPRestoreParam
data[14] = HPRestoreParam;
// Byte 15: PPRestoreParam
data[15] = PPRestoreParam;
// Bytes 1618: FriendshipParams
for (int i = 0; i < 3; i++)
data[16 + i] = (byte)FriendshipParams[i];
// Write all bytes
writer.Write(data);
// Write padding
writer.Write(new byte[2]);
}
}
}
}

View File

@ -70,6 +70,7 @@ namespace DSPRE
public static int attackNamesTextNumber { get; private set; }
public static int[] pokemonNamesTextNumbers { get; private set; }
public static int itemNamesTextNumber { get; private set; }
public static int itemDescriptionsTextNumber { get; private set; }
public static int itemScriptFileNumber { get; internal set; }
public static int trainerClassMessageNumber { get; private set; }
public static int trainerNamesMessageNumber { get; private set; }
@ -171,7 +172,9 @@ namespace DSPRE
interiorBuildingModels,
learnsets,
evolutions
evolutions,
itemData
};
public static Dictionary<DirNames, (string packedDir, string unpackedDir)> gameDirs { get; private set; }
@ -223,7 +226,7 @@ namespace DSPRE
SetAbilityNamesTextNumber();
SetAttackNamesTextNumber();
SetPokemonNamesTextNumber();
SetItemNamesTextNumber();
SetItemsTextNumber();
SetItemScriptFileNumber();
SetLocationNamesTextNumber();
SetTrainerNamesMessageNumber();
@ -1015,20 +1018,23 @@ namespace DSPRE
}
}
private static void SetItemNamesTextNumber()
private static void SetItemsTextNumber()
{
switch (gameFamily)
{
case GameFamilies.DP:
itemNamesTextNumber = 344;
itemDescriptionsTextNumber = 0;
break;
case GameFamilies.Plat:
itemNamesTextNumber = 392;
itemDescriptionsTextNumber = 0;
break;
default:
itemNamesTextNumber = gameLanguage == GameLanguages.Japanese ? 219 : 222;
itemDescriptionsTextNumber = 221;
break;
}
}
@ -1461,6 +1467,8 @@ namespace DSPRE
[DirNames.pokemonBattleSprites] = @"data\poketool\pokegra\pokegra.narc",
[DirNames.otherPokemonBattleSprites] = @"data\poketool\pokegra\otherpoke.narc",
[DirNames.itemData] = @"data\itemtool\item_data.narc",
};
//Personal Data archive is different for Pearl
@ -1513,6 +1521,8 @@ namespace DSPRE
[DirNames.encounters] = @"data\fielddata\encountdata\" + suffix + '_' + "enc_data.narc",
[DirNames.learnsets] = @"data\poketool\personal\wotbl.narc",
[DirNames.evolutions] = @"data\poketool\personal\evo.narc",
[DirNames.itemData] = @"data\itemtool\pl_item_data.narc",
};
break;
@ -1552,7 +1562,7 @@ namespace DSPRE
[DirNames.interiorBuildingModels] = @"data\a\1\4\8",
[DirNames.learnsets] = @"data\a\0\3\3",
[DirNames.evolutions] = @"data\a\0\3\4",
[DirNames.itemData] = @"data\a\0\1\7",
[DirNames.safariZone] = @"data\a\2\3\0",
[DirNames.headbutt] = @"data\a\2\5\2", //both versions use the same folder with different data
};