diff --git a/GBAPokemonGameEditor.v12.suo b/GBAPokemonGameEditor.v12.suo
index c756478..8285881 100644
Binary files a/GBAPokemonGameEditor.v12.suo and b/GBAPokemonGameEditor.v12.suo differ
diff --git a/GBAPokemonGameEditor/ChangeNameFunctions.vb b/GBAPokemonGameEditor/ChangeNameFunctions.vb
index 1d90c63..1cda75e 100644
--- a/GBAPokemonGameEditor/ChangeNameFunctions.vb
+++ b/GBAPokemonGameEditor/ChangeNameFunctions.vb
@@ -291,4 +291,27 @@ Module ChangeNameFunctions
ChangeTradeOTName = NewName
End Function
+
+ Public Function ChangeTrainerName(ByVal Index As Integer, ByVal NewName As String)
+ Dim offvar As Long
+
+ offvar = Int32.Parse((GetString(GetINIFileLocation(), header, "TrainerTable", "")), System.Globalization.NumberStyles.HexNumber)
+ If header3 = "J" Then
+
+ Else
+
+ FileNum = FreeFile()
+ FileOpen(FileNum, LoadedROM, OpenMode.Binary)
+ Dim PokeName As String = "xxxxxxxxxxx"
+ Dim filler As Byte = "&HFF"
+ PokeName = NameAsc2Sapp(NewName)
+ FilePut(FileNum, PokeName, offvar + 1 + 4 + (Index * 40))
+ FilePut(FileNum, filler, offvar + 1 + 4 + (Index * 40) + Len(NewName))
+
+
+ End If
+ FileClose(FileNum)
+ ChangeTrainerName = NewName
+
+ End Function
End Module
diff --git a/GBAPokemonGameEditor/HexFunctions.vb b/GBAPokemonGameEditor/HexFunctions.vb
index 6a7b180..d186435 100644
--- a/GBAPokemonGameEditor/HexFunctions.vb
+++ b/GBAPokemonGameEditor/HexFunctions.vb
@@ -70,6 +70,7 @@ ErrHandle:
Public Function WriteHEX(ByRef FilePath As String, ByRef Start As Integer, ByRef Data As String) As Object
On Error GoTo ErrHandle
+ WriteHEX = 0
Dim iFile As Integer
Dim sPost As Integer
Dim bytHex As Byte
@@ -89,6 +90,7 @@ ErrHandle:
sPost = sPost + 1
Loop
FileClose(iFile)
+ WriteHEX = 1
Exit Function
ErrHandle:
MsgBox(Err.Description, MsgBoxStyle.OkOnly, "Error: " & Err.Number)
diff --git a/GBAPokemonGameEditor/PokemonAdder.Designer.vb b/GBAPokemonGameEditor/PokemonAdder.Designer.vb
index efc316e..84e8211 100644
--- a/GBAPokemonGameEditor/PokemonAdder.Designer.vb
+++ b/GBAPokemonGameEditor/PokemonAdder.Designer.vb
@@ -45,6 +45,7 @@ Partial Class PokemonAdder
Me.Label8 = New System.Windows.Forms.Label()
Me.Label9 = New System.Windows.Forms.Label()
Me.Button2 = New System.Windows.Forms.Button()
+ Me.LinkLabel2 = New System.Windows.Forms.LinkLabel()
Me.TabControl1.SuspendLayout()
Me.TabPage1.SuspendLayout()
Me.TabPage2.SuspendLayout()
@@ -54,10 +55,11 @@ Partial Class PokemonAdder
'
Me.TabControl1.Controls.Add(Me.TabPage1)
Me.TabControl1.Controls.Add(Me.TabPage2)
- Me.TabControl1.Location = New System.Drawing.Point(12, 21)
+ Me.TabControl1.Location = New System.Drawing.Point(16, 26)
+ Me.TabControl1.Margin = New System.Windows.Forms.Padding(4, 4, 4, 4)
Me.TabControl1.Name = "TabControl1"
Me.TabControl1.SelectedIndex = 0
- Me.TabControl1.Size = New System.Drawing.Size(302, 381)
+ Me.TabControl1.Size = New System.Drawing.Size(403, 469)
Me.TabControl1.TabIndex = 0
'
'TabPage1
@@ -76,10 +78,11 @@ Partial Class PokemonAdder
Me.TabPage1.Controls.Add(Me.Button1)
Me.TabPage1.Controls.Add(Me.LinkLabel1)
Me.TabPage1.Controls.Add(Me.CheckBox1)
- Me.TabPage1.Location = New System.Drawing.Point(4, 22)
+ Me.TabPage1.Location = New System.Drawing.Point(4, 25)
+ Me.TabPage1.Margin = New System.Windows.Forms.Padding(4, 4, 4, 4)
Me.TabPage1.Name = "TabPage1"
- Me.TabPage1.Padding = New System.Windows.Forms.Padding(3)
- Me.TabPage1.Size = New System.Drawing.Size(294, 355)
+ Me.TabPage1.Padding = New System.Windows.Forms.Padding(4, 4, 4, 4)
+ Me.TabPage1.Size = New System.Drawing.Size(395, 440)
Me.TabPage1.TabIndex = 0
Me.TabPage1.Text = "Fire Red"
Me.TabPage1.UseVisualStyleBackColor = True
@@ -89,9 +92,10 @@ Partial Class PokemonAdder
Me.CheckBox2.AutoSize = True
Me.CheckBox2.Checked = True
Me.CheckBox2.CheckState = System.Windows.Forms.CheckState.Checked
- Me.CheckBox2.Location = New System.Drawing.Point(14, 109)
+ Me.CheckBox2.Location = New System.Drawing.Point(19, 134)
+ Me.CheckBox2.Margin = New System.Windows.Forms.Padding(4, 4, 4, 4)
Me.CheckBox2.Name = "CheckBox2"
- Me.CheckBox2.Size = New System.Drawing.Size(100, 17)
+ Me.CheckBox2.Size = New System.Drawing.Size(129, 21)
Me.CheckBox2.TabIndex = 13
Me.CheckBox2.Text = "Delete Old data"
Me.CheckBox2.UseVisualStyleBackColor = True
@@ -99,104 +103,116 @@ Partial Class PokemonAdder
'Label7
'
Me.Label7.AutoSize = True
- Me.Label7.Location = New System.Drawing.Point(11, 217)
+ Me.Label7.Location = New System.Drawing.Point(15, 267)
+ Me.Label7.Margin = New System.Windows.Forms.Padding(4, 0, 4, 0)
Me.Label7.Name = "Label7"
- Me.Label7.Size = New System.Drawing.Size(109, 13)
+ Me.Label7.Size = New System.Drawing.Size(144, 17)
Me.Label7.TabIndex = 12
Me.Label7.Text = "Caught flags location:"
'
'Label6
'
Me.Label6.AutoSize = True
- Me.Label6.Location = New System.Drawing.Point(11, 192)
+ Me.Label6.Location = New System.Drawing.Point(15, 236)
+ Me.Label6.Margin = New System.Windows.Forms.Padding(4, 0, 4, 0)
Me.Label6.Name = "Label6"
- Me.Label6.Size = New System.Drawing.Size(103, 13)
+ Me.Label6.Size = New System.Drawing.Size(136, 17)
Me.Label6.TabIndex = 11
Me.Label6.Text = "Seen flags location: "
'
'TextBox3
'
- Me.TextBox3.Location = New System.Drawing.Point(167, 163)
+ Me.TextBox3.Location = New System.Drawing.Point(223, 201)
+ Me.TextBox3.Margin = New System.Windows.Forms.Padding(4, 4, 4, 4)
Me.TextBox3.Name = "TextBox3"
- Me.TextBox3.Size = New System.Drawing.Size(67, 20)
+ Me.TextBox3.Size = New System.Drawing.Size(88, 22)
Me.TextBox3.TabIndex = 10
Me.TextBox3.Text = "0203C0C8"
'
'Label5
'
Me.Label5.AutoSize = True
- Me.Label5.Location = New System.Drawing.Point(11, 166)
+ Me.Label5.Location = New System.Drawing.Point(15, 204)
+ Me.Label5.Margin = New System.Windows.Forms.Padding(4, 0, 4, 0)
Me.Label5.Name = "Label5"
- Me.Label5.Size = New System.Drawing.Size(135, 13)
+ Me.Label5.Size = New System.Drawing.Size(181, 17)
Me.Label5.TabIndex = 9
Me.Label5.Text = "Base offset to use for flags:"
'
'TextBox2
'
- Me.TextBox2.Location = New System.Drawing.Point(167, 81)
+ Me.TextBox2.Location = New System.Drawing.Point(223, 100)
+ Me.TextBox2.Margin = New System.Windows.Forms.Padding(4, 4, 4, 4)
Me.TextBox2.Name = "TextBox2"
- Me.TextBox2.Size = New System.Drawing.Size(48, 20)
+ Me.TextBox2.Size = New System.Drawing.Size(63, 22)
Me.TextBox2.TabIndex = 8
Me.TextBox2.Text = "335"
'
'TextBox1
'
- Me.TextBox1.Location = New System.Drawing.Point(167, 37)
+ Me.TextBox1.Location = New System.Drawing.Point(223, 46)
+ Me.TextBox1.Margin = New System.Windows.Forms.Padding(4, 4, 4, 4)
Me.TextBox1.Name = "TextBox1"
- Me.TextBox1.Size = New System.Drawing.Size(48, 20)
+ Me.TextBox1.Size = New System.Drawing.Size(63, 22)
Me.TextBox1.TabIndex = 7
Me.TextBox1.Text = "335"
'
'Label4
'
Me.Label4.AutoSize = True
- Me.Label4.Location = New System.Drawing.Point(11, 40)
+ Me.Label4.Location = New System.Drawing.Point(15, 49)
+ Me.Label4.Margin = New System.Windows.Forms.Padding(4, 0, 4, 0)
Me.Label4.Name = "Label4"
- Me.Label4.Size = New System.Drawing.Size(140, 13)
+ Me.Label4.Size = New System.Drawing.Size(185, 17)
Me.Label4.TabIndex = 6
Me.Label4.Text = "Number of Pokemon to add:"
'
'Label3
'
Me.Label3.AutoSize = True
- Me.Label3.Location = New System.Drawing.Point(11, 84)
+ Me.Label3.Location = New System.Drawing.Point(15, 103)
+ Me.Label3.Margin = New System.Windows.Forms.Padding(4, 0, 4, 0)
Me.Label3.Name = "Label3"
- Me.Label3.Size = New System.Drawing.Size(148, 13)
+ Me.Label3.Size = New System.Drawing.Size(197, 17)
Me.Label3.TabIndex = 5
Me.Label3.Text = "Number of Dex entries to add:"
'
'Label2
'
Me.Label2.AutoSize = True
- Me.Label2.Location = New System.Drawing.Point(11, 62)
+ Me.Label2.Location = New System.Drawing.Point(15, 76)
+ Me.Label2.Margin = New System.Windows.Forms.Padding(4, 0, 4, 0)
Me.Label2.Name = "Label2"
- Me.Label2.Size = New System.Drawing.Size(154, 13)
+ Me.Label2.Size = New System.Drawing.Size(204, 17)
Me.Label2.TabIndex = 4
Me.Label2.Text = "Number of Dex entries in ROM:"
'
'Label1
'
Me.Label1.AutoSize = True
- Me.Label1.Location = New System.Drawing.Point(11, 15)
+ Me.Label1.Location = New System.Drawing.Point(15, 18)
+ Me.Label1.Margin = New System.Windows.Forms.Padding(4, 0, 4, 0)
Me.Label1.Name = "Label1"
- Me.Label1.Size = New System.Drawing.Size(146, 13)
+ Me.Label1.Size = New System.Drawing.Size(192, 17)
Me.Label1.TabIndex = 3
Me.Label1.Text = "Number of Pokemon in ROM:"
'
'Button1
'
- Me.Button1.Location = New System.Drawing.Point(202, 248)
+ Me.Button1.Location = New System.Drawing.Point(269, 305)
+ Me.Button1.Margin = New System.Windows.Forms.Padding(4, 4, 4, 4)
Me.Button1.Name = "Button1"
- Me.Button1.Size = New System.Drawing.Size(75, 23)
+ Me.Button1.Size = New System.Drawing.Size(100, 28)
Me.Button1.TabIndex = 2
Me.Button1.Text = "Add"
Me.Button1.UseVisualStyleBackColor = True
'
'LinkLabel1
'
- Me.LinkLabel1.Location = New System.Drawing.Point(12, 274)
+ Me.LinkLabel1.Location = New System.Drawing.Point(16, 337)
+ Me.LinkLabel1.Margin = New System.Windows.Forms.Padding(4, 0, 4, 0)
Me.LinkLabel1.Name = "LinkLabel1"
- Me.LinkLabel1.Size = New System.Drawing.Size(265, 69)
+ Me.LinkLabel1.Size = New System.Drawing.Size(353, 85)
Me.LinkLabel1.TabIndex = 1
Me.LinkLabel1.TabStop = True
Me.LinkLabel1.Text = "To remain consistent with what other people may have already done this tool uses " & _
@@ -208,24 +224,27 @@ Partial Class PokemonAdder
Me.CheckBox1.AutoSize = True
Me.CheckBox1.Checked = True
Me.CheckBox1.CheckState = System.Windows.Forms.CheckState.Checked
- Me.CheckBox1.Location = New System.Drawing.Point(14, 140)
+ Me.CheckBox1.Location = New System.Drawing.Point(19, 172)
+ Me.CheckBox1.Margin = New System.Windows.Forms.Padding(4, 4, 4, 4)
Me.CheckBox1.Name = "CheckBox1"
- Me.CheckBox1.Size = New System.Drawing.Size(185, 17)
+ Me.CheckBox1.Size = New System.Drawing.Size(239, 21)
Me.CheckBox1.TabIndex = 0
Me.CheckBox1.Text = "Install JPAN's " & Global.Microsoft.VisualBasic.ChrW(9) & "save block recycle"
Me.CheckBox1.UseVisualStyleBackColor = True
'
'TabPage2
'
+ Me.TabPage2.Controls.Add(Me.LinkLabel2)
Me.TabPage2.Controls.Add(Me.CheckBox3)
Me.TabPage2.Controls.Add(Me.TextBox4)
Me.TabPage2.Controls.Add(Me.Label8)
Me.TabPage2.Controls.Add(Me.Label9)
Me.TabPage2.Controls.Add(Me.Button2)
- Me.TabPage2.Location = New System.Drawing.Point(4, 22)
+ Me.TabPage2.Location = New System.Drawing.Point(4, 25)
+ Me.TabPage2.Margin = New System.Windows.Forms.Padding(4, 4, 4, 4)
Me.TabPage2.Name = "TabPage2"
- Me.TabPage2.Padding = New System.Windows.Forms.Padding(3)
- Me.TabPage2.Size = New System.Drawing.Size(294, 355)
+ Me.TabPage2.Padding = New System.Windows.Forms.Padding(4, 4, 4, 4)
+ Me.TabPage2.Size = New System.Drawing.Size(395, 440)
Me.TabPage2.TabIndex = 1
Me.TabPage2.Text = "Emerald"
Me.TabPage2.UseVisualStyleBackColor = True
@@ -235,56 +254,77 @@ Partial Class PokemonAdder
Me.CheckBox3.AutoSize = True
Me.CheckBox3.Checked = True
Me.CheckBox3.CheckState = System.Windows.Forms.CheckState.Checked
- Me.CheckBox3.Location = New System.Drawing.Point(18, 110)
+ Me.CheckBox3.Location = New System.Drawing.Point(22, 360)
+ Me.CheckBox3.Margin = New System.Windows.Forms.Padding(4, 4, 4, 4)
Me.CheckBox3.Name = "CheckBox3"
- Me.CheckBox3.Size = New System.Drawing.Size(100, 17)
+ Me.CheckBox3.Size = New System.Drawing.Size(129, 21)
Me.CheckBox3.TabIndex = 18
Me.CheckBox3.Text = "Delete Old data"
Me.CheckBox3.UseVisualStyleBackColor = True
+ Me.CheckBox3.Visible = False
'
'TextBox4
'
- Me.TextBox4.Location = New System.Drawing.Point(171, 38)
+ Me.TextBox4.Location = New System.Drawing.Point(227, 333)
+ Me.TextBox4.Margin = New System.Windows.Forms.Padding(4, 4, 4, 4)
Me.TextBox4.Name = "TextBox4"
- Me.TextBox4.Size = New System.Drawing.Size(48, 20)
+ Me.TextBox4.Size = New System.Drawing.Size(63, 22)
Me.TextBox4.TabIndex = 17
Me.TextBox4.Text = "335"
+ Me.TextBox4.Visible = False
'
'Label8
'
Me.Label8.AutoSize = True
- Me.Label8.Location = New System.Drawing.Point(15, 41)
+ Me.Label8.Location = New System.Drawing.Point(19, 336)
+ Me.Label8.Margin = New System.Windows.Forms.Padding(4, 0, 4, 0)
Me.Label8.Name = "Label8"
- Me.Label8.Size = New System.Drawing.Size(140, 13)
+ Me.Label8.Size = New System.Drawing.Size(185, 17)
Me.Label8.TabIndex = 16
Me.Label8.Text = "Number of Pokemon to add:"
+ Me.Label8.Visible = False
'
'Label9
'
Me.Label9.AutoSize = True
- Me.Label9.Location = New System.Drawing.Point(15, 16)
+ Me.Label9.Location = New System.Drawing.Point(19, 306)
+ Me.Label9.Margin = New System.Windows.Forms.Padding(4, 0, 4, 0)
Me.Label9.Name = "Label9"
- Me.Label9.Size = New System.Drawing.Size(146, 13)
+ Me.Label9.Size = New System.Drawing.Size(192, 17)
Me.Label9.TabIndex = 15
Me.Label9.Text = "Number of Pokemon in ROM:"
+ Me.Label9.Visible = False
'
'Button2
'
- Me.Button2.Location = New System.Drawing.Point(206, 249)
+ Me.Button2.Location = New System.Drawing.Point(275, 306)
+ Me.Button2.Margin = New System.Windows.Forms.Padding(4, 4, 4, 4)
Me.Button2.Name = "Button2"
- Me.Button2.Size = New System.Drawing.Size(75, 23)
+ Me.Button2.Size = New System.Drawing.Size(100, 28)
Me.Button2.TabIndex = 14
Me.Button2.Text = "Add"
Me.Button2.UseVisualStyleBackColor = True
+ Me.Button2.Visible = False
+ '
+ 'LinkLabel2
+ '
+ Me.LinkLabel2.AutoSize = True
+ Me.LinkLabel2.Location = New System.Drawing.Point(7, 113)
+ Me.LinkLabel2.Name = "LinkLabel2"
+ Me.LinkLabel2.Size = New System.Drawing.Size(370, 17)
+ Me.LinkLabel2.TabIndex = 19
+ Me.LinkLabel2.TabStop = True
+ Me.LinkLabel2.Text = "Please use: https://github.com/DizzyEggg/PokeExpansion"
'
'PokemonAdder
'
- Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
+ Me.AutoScaleDimensions = New System.Drawing.SizeF(8.0!, 16.0!)
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
- Me.ClientSize = New System.Drawing.Size(323, 414)
+ Me.ClientSize = New System.Drawing.Size(431, 510)
Me.Controls.Add(Me.TabControl1)
Me.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle
Me.Icon = CType(resources.GetObject("$this.Icon"), System.Drawing.Icon)
+ Me.Margin = New System.Windows.Forms.Padding(4, 4, 4, 4)
Me.MaximizeBox = False
Me.Name = "PokemonAdder"
Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
@@ -320,4 +360,5 @@ Partial Class PokemonAdder
Friend WithEvents Label8 As System.Windows.Forms.Label
Friend WithEvents Label9 As System.Windows.Forms.Label
Friend WithEvents Button2 As System.Windows.Forms.Button
+ Friend WithEvents LinkLabel2 As System.Windows.Forms.LinkLabel
End Class
diff --git a/GBAPokemonGameEditor/PokemonAdder.vb b/GBAPokemonGameEditor/PokemonAdder.vb
index d1e5672..4a3a721 100644
--- a/GBAPokemonGameEditor/PokemonAdder.vb
+++ b/GBAPokemonGameEditor/PokemonAdder.vb
@@ -10,7 +10,8 @@ Public Class PokemonAdder
TabControl1.TabPages(1).Enabled = True
TabControl1.SelectedIndex = 1
- MsgBox("Not implemented yet!")
+ MsgBox("Please use: https://github.com/DizzyEggg/PokeExpansion The webpage will open once you click ok.")
+ Process.Start("https://github.com/DizzyEggg/PokeExpansion")
End
ElseIf header = "BPRE" Then
@@ -1594,95 +1595,99 @@ Public Class PokemonAdder
Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click
- 'Declare buffers I will use for adding stuff.
+ ''Declare buffers I will use for adding stuff.
- Dim countervar As Integer
+ 'Dim countervar As Integer
- Dim PokemonNamesBuffer As String
- Dim PokemonNamesNewOffset As String
+ 'Dim PokemonNamesBuffer As String
+ 'Dim PokemonNamesNewOffset As String
- Dim PokemonDataBuffer As String
- Dim PokemonDataNewOffset As String
+ 'Dim PokemonDataBuffer As String
+ 'Dim PokemonDataNewOffset As String
- Dim PokemonAttackDataBuffer As String
- Dim PokemonAttackDataNewOffset As String
+ 'Dim PokemonAttackDataBuffer As String
+ 'Dim PokemonAttackDataNewOffset As String
- Dim PokemonFrontSpriteTableBuffer As String
- Dim PokemonFrontSpriteTableNewOffset As String
+ 'Dim PokemonFrontSpriteTableBuffer As String
+ 'Dim PokemonFrontSpriteTableNewOffset As String
- Dim PokemonBackSpriteTableBuffer As String
- Dim PokemonBackSpriteTableNewOffset As String
+ 'Dim PokemonBackSpriteTableBuffer As String
+ 'Dim PokemonBackSpriteTableNewOffset As String
- Dim PokemonNormalPalTableBuffer As String
- Dim PokemonNormalPalTableNewOffset As String
+ 'Dim PokemonNormalPalTableBuffer As String
+ 'Dim PokemonNormalPalTableNewOffset As String
- Dim PokemonShinyPalTableBuffer As String
- Dim PokemonShinyPalTableNewOffset As String
+ 'Dim PokemonShinyPalTableBuffer As String
+ 'Dim PokemonShinyPalTableNewOffset As String
- Dim PokemonPlayerYTableBuffer As String
- Dim PokemonPlayerYTableNewOffset As String
+ 'Dim PokemonPlayerYTableBuffer As String
+ 'Dim PokemonPlayerYTableNewOffset As String
- Dim PokemonEnemyYTableBuffer As String
- Dim PokemonEnemyYTableNewOffset As String
+ 'Dim PokemonEnemyYTableBuffer As String
+ 'Dim PokemonEnemyYTableNewOffset As String
- Dim PokemonAltitudeTableBuffer As String
- Dim PokemonAltitudeTableNewOffset As String
+ 'Dim PokemonAltitudeTableBuffer As String
+ 'Dim PokemonAltitudeTableNewOffset As String
- Dim PokemonIconTableBuffer As String
- Dim PokemonIconTableNewOffset As String
+ 'Dim PokemonIconTableBuffer As String
+ 'Dim PokemonIconTableNewOffset As String
- Dim PokemonIconPalTableBuffer As String
- Dim PokemonIconPalTableNewOffset As String
+ 'Dim PokemonIconPalTableBuffer As String
+ 'Dim PokemonIconPalTableNewOffset As String
- Dim PokemonNatDexTableBuffer As String
- Dim PokemonNatDexTableNewOffset As String
+ 'Dim PokemonNatDexTableBuffer As String
+ 'Dim PokemonNatDexTableNewOffset As String
- Dim PokemonSecDexTableBuffer As String
- Dim PokemonSecDexTableNewOffset As String
+ 'Dim PokemonSecDexTableBuffer As String
+ 'Dim PokemonSecDexTableNewOffset As String
- Dim PokedexDataBuffer As String
- Dim PokedexDataNewOffset As String
+ 'Dim PokedexDataBuffer As String
+ 'Dim PokedexDataNewOffset As String
- Dim TMCompatabilityBuffer As String
- Dim TMCompatabilityBufferNewOffset As String
+ 'Dim TMCompatabilityBuffer As String
+ 'Dim TMCompatabilityBufferNewOffset As String
- Dim MoveTutorCompatabilityBuffer As String
- Dim MoveTutorCompatabilityBufferNewOffset As String
+ 'Dim MoveTutorCompatabilityBuffer As String
+ 'Dim MoveTutorCompatabilityBufferNewOffset As String
- Dim EvolutionDataBuffer As String
- Dim EvolutionDataNewOffset As String
+ 'Dim EvolutionDataBuffer As String
+ 'Dim EvolutionDataNewOffset As String
- Dim PokemonItemAnimationTableBuffer As String
- Dim PokemonItemAnimationTableNewOffset As String
+ 'Dim PokemonItemAnimationTableBuffer As String
+ 'Dim PokemonItemAnimationTableNewOffset As String
- Dim CryTableBuffer As String
- Dim CryTableNewOffset As String
+ 'Dim CryTableBuffer As String
+ 'Dim CryTableNewOffset As String
- Dim CryTable2Buffer As String
- Dim CryTable2NewOffset As String
+ 'Dim CryTable2Buffer As String
+ 'Dim CryTable2NewOffset As String
- Dim CryConversionTableBuffer As String
- Dim CryConversionTableNewOffset As String
+ 'Dim CryConversionTableBuffer As String
+ 'Dim CryConversionTableNewOffset As String
- Dim PokemonFootPrintTableBuffer As String
- Dim PokemonFootPrintTableNewOffset As String
+ 'Dim PokemonFootPrintTableBuffer As String
+ 'Dim PokemonFootPrintTableNewOffset As String
- If System.IO.File.Exists((LoadedROM).Substring(0, LoadedROM.Length - 4) & ".ini") = True Then
+ 'If System.IO.File.Exists((LoadedROM).Substring(0, LoadedROM.Length - 4) & ".ini") = True Then
- MsgBox("An INI for this ROM has been detected! Values will be updated as needed.")
+ ' MsgBox("An INI for this ROM has been detected! Values will be updated as needed.")
- Else
+ 'Else
- MsgBox("INI not found! One will now be created for this ROM in the same location as the ROM. Keep the ini with the ROM so that PGE can know the location of the data.")
+ ' MsgBox("INI not found! One will now be created for this ROM in the same location as the ROM. Keep the ini with the ROM so that PGE can know the location of the data.")
- File.Copy(AppPath & "ini\roms.ini", (LoadedROM).Substring(0, LoadedROM.Length - 4) & ".ini", True)
+ ' File.Copy(AppPath & "ini\roms.ini", (LoadedROM).Substring(0, LoadedROM.Length - 4) & ".ini", True)
- End If
+ 'End If
- Me.Cursor = Cursors.WaitCursor
- Me.Text = "Please Wait..."
- Me.Refresh()
+ 'Me.Cursor = Cursors.WaitCursor
+ 'Me.Text = "Please Wait..."
+ 'Me.Refresh()
End Sub
+
+ Private Sub LinkLabel2_LinkClicked(sender As Object, e As LinkLabelLinkClickedEventArgs) Handles LinkLabel2.LinkClicked
+ Process.Start("https://github.com/DizzyEggg/PokeExpansion")
+ End Sub
End Class
\ No newline at end of file
diff --git a/GBAPokemonGameEditor/TrainerEditor.Designer.vb b/GBAPokemonGameEditor/TrainerEditor.Designer.vb
index 91db65b..bb56580 100644
--- a/GBAPokemonGameEditor/TrainerEditor.Designer.vb
+++ b/GBAPokemonGameEditor/TrainerEditor.Designer.vb
@@ -28,11 +28,11 @@ Partial Class TrainerEditor
Me.Label1 = New System.Windows.Forms.Label()
Me.TrainerListComboBox = New System.Windows.Forms.ComboBox()
Me.GroupBox2 = New System.Windows.Forms.GroupBox()
+ Me.RnmBttn = New System.Windows.Forms.Button()
+ Me.TNameTextBox = New System.Windows.Forms.TextBox()
+ Me.Label2 = New System.Windows.Forms.Label()
Me.PicNumericUpDown = New System.Windows.Forms.NumericUpDown()
Me.TrainerPic = New System.Windows.Forms.PictureBox()
- Me.Label2 = New System.Windows.Forms.Label()
- Me.TNameTextBox = New System.Windows.Forms.TextBox()
- Me.RnmBttn = New System.Windows.Forms.Button()
Me.GroupBox1.SuspendLayout()
Me.GroupBox2.SuspendLayout()
CType(Me.PicNumericUpDown, System.ComponentModel.ISupportInitialize).BeginInit()
@@ -91,6 +91,31 @@ Partial Class TrainerEditor
Me.GroupBox2.TabStop = False
Me.GroupBox2.Text = "Trainer Data"
'
+ 'RnmBttn
+ '
+ Me.RnmBttn.Location = New System.Drawing.Point(269, 22)
+ Me.RnmBttn.Name = "RnmBttn"
+ Me.RnmBttn.Size = New System.Drawing.Size(75, 23)
+ Me.RnmBttn.TabIndex = 14
+ Me.RnmBttn.Text = "Rename"
+ Me.RnmBttn.UseVisualStyleBackColor = True
+ '
+ 'TNameTextBox
+ '
+ Me.TNameTextBox.Location = New System.Drawing.Point(163, 21)
+ Me.TNameTextBox.Name = "TNameTextBox"
+ Me.TNameTextBox.Size = New System.Drawing.Size(100, 22)
+ Me.TNameTextBox.TabIndex = 13
+ '
+ 'Label2
+ '
+ Me.Label2.AutoSize = True
+ Me.Label2.Location = New System.Drawing.Point(108, 24)
+ Me.Label2.Name = "Label2"
+ Me.Label2.Size = New System.Drawing.Size(49, 17)
+ Me.Label2.TabIndex = 12
+ Me.Label2.Text = "Name:"
+ '
'PicNumericUpDown
'
Me.PicNumericUpDown.Location = New System.Drawing.Point(16, 107)
@@ -107,31 +132,6 @@ Partial Class TrainerEditor
Me.TrainerPic.TabIndex = 10
Me.TrainerPic.TabStop = False
'
- 'Label2
- '
- Me.Label2.AutoSize = True
- Me.Label2.Location = New System.Drawing.Point(108, 24)
- Me.Label2.Name = "Label2"
- Me.Label2.Size = New System.Drawing.Size(49, 17)
- Me.Label2.TabIndex = 12
- Me.Label2.Text = "Name:"
- '
- 'TNameTextBox
- '
- Me.TNameTextBox.Location = New System.Drawing.Point(163, 21)
- Me.TNameTextBox.Name = "TNameTextBox"
- Me.TNameTextBox.Size = New System.Drawing.Size(100, 22)
- Me.TNameTextBox.TabIndex = 13
- '
- 'RnmBttn
- '
- Me.RnmBttn.Location = New System.Drawing.Point(269, 22)
- Me.RnmBttn.Name = "RnmBttn"
- Me.RnmBttn.Size = New System.Drawing.Size(75, 23)
- Me.RnmBttn.TabIndex = 14
- Me.RnmBttn.Text = "Rename"
- Me.RnmBttn.UseVisualStyleBackColor = True
- '
'TrainerEditor
'
Me.AutoScaleDimensions = New System.Drawing.SizeF(8.0!, 16.0!)
diff --git a/GBAPokemonGameEditor/TrainerEditor.vb b/GBAPokemonGameEditor/TrainerEditor.vb
index cc343b8..372e372 100644
--- a/GBAPokemonGameEditor/TrainerEditor.vb
+++ b/GBAPokemonGameEditor/TrainerEditor.vb
@@ -55,4 +55,29 @@
Private Sub PicNumericUpDown_ValueChanged(sender As Object, e As EventArgs) Handles PicNumericUpDown.ValueChanged
GetAndDrawTrainerPic(TrainerPic, PicNumericUpDown.Value)
End Sub
+
+ Private Sub RnmBttn_Click(sender As Object, e As EventArgs) Handles RnmBttn.Click
+ Dim savevar As Integer = TrainerListComboBox.SelectedIndex
+
+ ChangeTrainerName(TrainerListComboBox.SelectedIndex + 1, TNameTextBox.Text)
+
+ Dim LoopVar As Integer
+
+ LoopVar = 0
+
+ TrainerListComboBox.Items.Clear()
+
+ While LoopVar < (GetString(GetINIFileLocation(), header, "NumberOfTrainers", "")) = True
+
+ LoopVar = LoopVar + 1
+
+ TrainerListComboBox.Items.Add(GetTrainerName(LoopVar))
+
+
+
+ End While
+
+ TrainerListComboBox.SelectedIndex = savevar
+
+ End Sub
End Class
\ No newline at end of file
diff --git a/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.application b/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.application
index 2386f6a..284b765 100644
--- a/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.application
+++ b/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.application
@@ -16,7 +16,7 @@
- BrhFZxIm/MtXiBKMf4panZj2RiXMDIKhiHKrXlGKAyM=
+ XGqTulgoELPF22/UZU2bagW8kSomHsux2+bnQ02mjNk=
diff --git a/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.exe b/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.exe
index ca3d940..4d5a67e 100644
Binary files a/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.exe and b/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.exe differ
diff --git a/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.exe.manifest b/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.exe.manifest
index 9018a99..f5eaf78 100644
--- a/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.exe.manifest
+++ b/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.exe.manifest
@@ -43,14 +43,14 @@
-
+
- xlHzMOYz6QhuaFQ3oa3C0BeCRr0E/MyIvgvEpq21uAI=
+ HyMBI3PSUeJNY6B+gaqDYTMhaUKOa7GNaupd57lK66M=
diff --git a/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.pdb b/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.pdb
index a382d46..2b84bf5 100644
Binary files a/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.pdb and b/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.pdb differ
diff --git a/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.vshost.application b/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.vshost.application
index 2386f6a..284b765 100644
--- a/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.vshost.application
+++ b/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.vshost.application
@@ -16,7 +16,7 @@
- BrhFZxIm/MtXiBKMf4panZj2RiXMDIKhiHKrXlGKAyM=
+ XGqTulgoELPF22/UZU2bagW8kSomHsux2+bnQ02mjNk=
diff --git a/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.vshost.exe.manifest b/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.vshost.exe.manifest
index 9018a99..f5eaf78 100644
--- a/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.vshost.exe.manifest
+++ b/GBAPokemonGameEditor/bin/Debug/PokemonGameEditor.vshost.exe.manifest
@@ -43,14 +43,14 @@
-
+
- xlHzMOYz6QhuaFQ3oa3C0BeCRr0E/MyIvgvEpq21uAI=
+ HyMBI3PSUeJNY6B+gaqDYTMhaUKOa7GNaupd57lK66M=
diff --git a/GBAPokemonGameEditor/obj/x86/Debug/GBAPokemonGameEditor.vbproj.GenerateResource.Cache b/GBAPokemonGameEditor/obj/x86/Debug/GBAPokemonGameEditor.vbproj.GenerateResource.Cache
index c5be537..9ab9903 100644
Binary files a/GBAPokemonGameEditor/obj/x86/Debug/GBAPokemonGameEditor.vbproj.GenerateResource.Cache and b/GBAPokemonGameEditor/obj/x86/Debug/GBAPokemonGameEditor.vbproj.GenerateResource.Cache differ
diff --git a/GBAPokemonGameEditor/obj/x86/Debug/PokemonGameEditor.application b/GBAPokemonGameEditor/obj/x86/Debug/PokemonGameEditor.application
index 2386f6a..284b765 100644
--- a/GBAPokemonGameEditor/obj/x86/Debug/PokemonGameEditor.application
+++ b/GBAPokemonGameEditor/obj/x86/Debug/PokemonGameEditor.application
@@ -16,7 +16,7 @@
- BrhFZxIm/MtXiBKMf4panZj2RiXMDIKhiHKrXlGKAyM=
+ XGqTulgoELPF22/UZU2bagW8kSomHsux2+bnQ02mjNk=
diff --git a/GBAPokemonGameEditor/obj/x86/Debug/PokemonGameEditor.exe b/GBAPokemonGameEditor/obj/x86/Debug/PokemonGameEditor.exe
index ca3d940..4d5a67e 100644
Binary files a/GBAPokemonGameEditor/obj/x86/Debug/PokemonGameEditor.exe and b/GBAPokemonGameEditor/obj/x86/Debug/PokemonGameEditor.exe differ
diff --git a/GBAPokemonGameEditor/obj/x86/Debug/PokemonGameEditor.exe.manifest b/GBAPokemonGameEditor/obj/x86/Debug/PokemonGameEditor.exe.manifest
index 9018a99..f5eaf78 100644
--- a/GBAPokemonGameEditor/obj/x86/Debug/PokemonGameEditor.exe.manifest
+++ b/GBAPokemonGameEditor/obj/x86/Debug/PokemonGameEditor.exe.manifest
@@ -43,14 +43,14 @@
-
+
- xlHzMOYz6QhuaFQ3oa3C0BeCRr0E/MyIvgvEpq21uAI=
+ HyMBI3PSUeJNY6B+gaqDYTMhaUKOa7GNaupd57lK66M=
diff --git a/GBAPokemonGameEditor/obj/x86/Debug/PokemonGameEditor.pdb b/GBAPokemonGameEditor/obj/x86/Debug/PokemonGameEditor.pdb
index a382d46..2b84bf5 100644
Binary files a/GBAPokemonGameEditor/obj/x86/Debug/PokemonGameEditor.pdb and b/GBAPokemonGameEditor/obj/x86/Debug/PokemonGameEditor.pdb differ