Code:
Public Class Form1
Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
If (ProgressBar1.Value > 0 & ProgressBar1.Value < 100) Then
ProgressBar1.Value += 1
Label1.Text = "The code has been " & ProgressBar1.Value & "% generated"
End If
If (ProgressBar1.Value = 100) Then
ProgressBar1.Value = 0
Timer1.Stop()
MsgBox("The Code has been successfully generated!")
Label1.Text = "Finished!"
RichTextBox1.Text = "spawn = " + TextBox1.Text + " " + TextBox2.Text + " " + TextBox3.Text + " " + TextBox4.Text + " " + TextBox5.Text + " " + TextBox6.Text + " " + TextBox7.Text + " " + TextBox8.Text + " " + TextBox9.Text + ""
End If
End Sub
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
If (TextBox1.Text = "") Then
Label1.Text = "Please fill in the NPC Id box."
ElseIf (TextBox2.Text = "") Then
Label1.Text = "Please fill in the Spawn X box."
ElseIf (TextBox3.Text = "") Then
Label1.Text = "Please fill in the Spawn Y box."
ElseIf (TextBox4.Text = "") Then
Label1.Text = "Please fill in the Height box."
ElseIf (TextBox5.Text = "") Then
Label1.Text = "Please fill in the Walk box."
ElseIf (TextBox6.Text = "") Then
Label1.Text = "Please fill in the Max Hit box."
ElseIf (TextBox7.Text = "") Then
Label1.Text = "Please fill in the Attack box."
ElseIf (TextBox8.Text = "") Then
Label1.Text = "Please fill in the Defence box."
ElseIf (TextBox9.Text = "") Then
Label1.Text = "Please fill in the Description box."
Else
Timer1.Start()
End If
End Sub
Private Sub LinkLabel1_LinkClicked_1(ByVal sender As System.Object, ByVal e As System.Windows.Forms.LinkLabelLinkClickedEventArgs) Handles LinkLabel1.LinkClicked
If (RichTextBox1.Text = "spawn = " + TextBox1.Text + " " + TextBox2.Text + " " + TextBox3.Text + " " + TextBox4.Text + " " + TextBox5.Text + " " + TextBox6.Text + " " + TextBox7.Text + " " + TextBox8.Text + " " + TextBox9.Text + "") Then
RichTextBox1.SelectAll()
RichTextBox1.Copy()
Label12.Text = "Code successfully copied."
Else
Label12.Text = "Not Ready Yet.."
End If
End Sub
Private Sub TextBox1_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TextBox1.TextChanged
If IsNumeric(TextBox1.Text) Then
TextBox1.Enabled = True
ElseIf IsNumeric(TextBox1.Text) = False Then
Label1.Text = "You can't put letters in any box except Description.."
TextBox1.Text = ""
End If
End Sub
Private Sub TextBox2_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TextBox2.TextChanged
If IsNumeric(TextBox2.Text) Then
TextBox2.Enabled = True
ElseIf IsNumeric(TextBox2.Text) = False Then
Label1.Text = "You can't put letters in any box except Description.."
TextBox2.Text = ""
End If
End Sub
Private Sub TextBox3_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TextBox3.TextChanged
If IsNumeric(TextBox3.Text) Then
TextBox3.Enabled = True
ElseIf IsNumeric(TextBox3.Text) = False Then
Label1.Text = "You can't put letters in any box except Description.."
TextBox3.Text = ""
End If
End Sub
Private Sub TextBox4_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TextBox4.TextChanged
If IsNumeric(TextBox4.Text) Then
TextBox4.Enabled = True
ElseIf IsNumeric(TextBox4.Text) = False Then
Label1.Text = "You can't put letters in any box except Description.."
TextBox4.Text = ""
End If
End Sub
Private Sub TextBox5_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TextBox5.TextChanged
If IsNumeric(TextBox5.Text) Then
TextBox5.Enabled = True
ElseIf IsNumeric(TextBox5.Text) = False Then
Label1.Text = "You can't put letters in any box except Description.."
TextBox5.Text = ""
End If
End Sub
Private Sub TextBox6_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TextBox6.TextChanged
If IsNumeric(TextBox6.Text) Then
TextBox6.Enabled = True
ElseIf IsNumeric(TextBox6.Text) = False Then
Label1.Text = "You can't put letters in any box except Description.."
TextBox6.Text = ""
End If
End Sub
Private Sub TextBox7_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TextBox7.TextChanged
If IsNumeric(TextBox7.Text) Then
TextBox7.Enabled = True
ElseIf IsNumeric(TextBox7.Text) = False Then
Label1.Text = "You can't put letters in any box except Description.."
TextBox7.Text = ""
End If
End Sub
Private Sub TextBox8_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TextBox8.TextChanged
If IsNumeric(TextBox8.Text) Then
TextBox8.Enabled = True
ElseIf IsNumeric(TextBox8.Text) = False Then
Label1.Text = "You can't put letters in any box except Description.."
TextBox8.Text = ""
End If
End Sub
Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
If (TextBox11.Text = "") Then
Label34.Text = "Please fill in the Item Id box."
ElseIf (TextBox12.Text = "") Then
Label34.Text = "Please fill in the Name box."
ElseIf (TextBox13.Text = "") Then
Label34.Text = "Please fill in the examine box."
ElseIf (TextBox14.Text = "") Then
Label34.Text = "Please fill in the Shop Value box."
ElseIf (TextBox16.Text = "") Then
Label34.Text = "Please fill in the Low Alch box."
ElseIf (TextBox15.Text = "") Then
Label34.Text = "Please fill in the High Alch box."
ElseIf (TextBox10.Text = "" Or TextBox18.Text = "" Or TextBox19.Text = "" Or TextBox20.Text = "" Or TextBox21.Text = "" Or TextBox17.Text = "" Or TextBox22.Text = "" Or TextBox23.Text = "" Or TextBox24.Text = "" Or TextBox25.Text = "" Or TextBox26.Text = "" Or TextBox27.Text = "") Then
Label34.Text = "Please fill in all of the bonuses boxes."
Else
If (Button2.Text = "Stop") Then
Timer2.Stop()
Button2.Text = "Start"
Else
Timer2.Start()
End If
TextBox12.Text = Replace(TextBox12.Text, " ", "_")
TextBox13.Text = Replace(TextBox13.Text, " ", "_")
End If
End Sub
Private Sub Timer2_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer2.Tick
If (ProgressBar2.Value > 0 & ProgressBar2.Value < 100) Then
ProgressBar2.Value += 1
Label34.Text = "The code has been " & ProgressBar2.Value & "% generated"
Button2.Text = "Stop"
End If
If (ProgressBar2.Value = 100) Then
ProgressBar2.Value = 0
Timer2.Stop()
MsgBox("The Code has been successfully generated!")
Label34.Text = "Finished!"
Button2.Text = "Start"
RichTextBox2.Text = "item = " + TextBox11.Text + " " + TextBox12.Text + " " + TextBox13.Text + " " + TextBox14.Text + " " + TextBox16.Text + " " + TextBox15.Text + " " + TextBox10.Text + " " + TextBox18.Text + " " + TextBox19.Text + " " + TextBox20.Text + " " + TextBox21.Text + " " + TextBox17.Text + " " + TextBox22.Text + " " + TextBox23.Text + " " + TextBox24.Text + " " + TextBox25.Text + " " + TextBox26.Text + " " + TextBox27.Text + ""
End If
End Sub
Private Sub LinkLabel2_LinkClicked(ByVal sender As System.Object, ByVal e As System.Windows.Forms.LinkLabelLinkClickedEventArgs) Handles LinkLabel2.LinkClicked
If (RichTextBox2.Text = "item = " + TextBox11.Text + " " + TextBox12.Text + " " + TextBox13.Text + " " + TextBox14.Text + " " + TextBox16.Text + " " + TextBox15.Text + " " + TextBox10.Text + " " + TextBox18.Text + " " + TextBox19.Text + " " + TextBox20.Text + " " + TextBox21.Text + " " + TextBox17.Text + " " + TextBox22.Text + " " + TextBox23.Text + " " + TextBox24.Text + " " + TextBox25.Text + " " + TextBox26.Text + " " + TextBox27.Text + "") Then
RichTextBox2.SelectAll()
RichTextBox2.Copy()
MsgBox("All of this code goes into the Data/Cfg/item.cfg.")
Label34.Text = "Code successfully copied."
Else
Label34.Text = "Not Ready Yet.."
End If
End Sub
Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
If (TextBox28.Text = "") Then
Label44.Text = "Please fill out the Object Id box."
ElseIf (TextBox29.Text = "") Then
Label44.Text = "Please fill out the Spawn X box."
ElseIf (TextBox30.Text = "") Then
Label44.Text = "Please fill out the Spawn Y box."
ElseIf (TextBox31.Text = "") Then
Label44.Text = "Please fill out the Object Face box."
ElseIf (TextBox32.Text = "") Then
Label44.Text = "Please fill out the Object Type box."
ElseIf (TextBox33.Text = "") Then
Label44.Text = "Please enter a name for the object in the Object Name box."
Else
Timer3.Start()
End If
End Sub
Private Sub Timer3_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer3.Tick
If (ProgressBar3.Value > 0 & ProgressBar3.Value < 100) Then
ProgressBar3.Value += 1
Label44.Text = "The code has been " & ProgressBar3.Value & "% generated"
End If
If (ProgressBar3.Value = 100) Then
ProgressBar3.Value = 0
Timer3.Stop()
Label44.Text = "Finished and the code is automatically copied."
RichTextBox3.Text = "c.getPA().checkObjectSpawn(" + TextBox28.Text + ", " + TextBox29.Text + ", " + TextBox30.Text + ", " + TextBox31.Text + ", " + TextBox32.Text + "); // " + TextBox33.Text + " "
RichTextBox3.SelectAll()
RichTextBox3.Copy()
MsgBox("The code has been created and also copied to your clipboard ready to paste in src.server.world.ObjectManager.java")
End If
End Sub
End Class