Restructure repository to include all source folders

Move git root from Client/ to src/ to track all source code:
- Client: Game client source (moved to Client/Client/)
- Server: Game server source
- GameTools: Development tools
- CryptoSource: Encryption utilities
- database: Database scripts
- Script: Game scripts
- rylCoder_16.02.2008_src: Legacy coder tools
- GMFont, Game: Additional resources

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
2025-11-29 20:17:20 +09:00
parent 5d3cd64a25
commit dd97ddec92
11602 changed files with 1446576 additions and 0 deletions

View File

@@ -0,0 +1,196 @@
Imports System.ComponentModel
Imports System.Drawing
Public Class CMiniMapPanel
Inherits Panel
' Fields
Private WithEvents worker As New BackgroundWorker
Public gameFld As String = ""
Private locD As Single
Private locX As Single
Private locY As Single
Public map As Bitmap = Nothing
Private mp As Panel
Private notAvailableL As Label
Private Shared npcColor As Color = Color.Violet
Private Const npcWidth As Integer = 2
Public openZone As Integer = 0
Public origArrow As Bitmap = Nothing
Private pleaseWaitL As Label
Private waitingForDraw As Boolean
Public Shadows Event Click(ByVal sender As Object, ByVal e As EventArgs)
' Nested Types
Private Structure workerArgs
Public zone As Integer
Public folder As String
Public npcs As CNpcParser.npcStruct()
Public Shared Function Create(ByVal gamefolder As String, ByVal zone As Integer, Optional ByRef npcs As CNpcParser.npcStruct() = Nothing) As workerArgs
Dim args2 As New workerArgs
args2.zone = zone
args2.folder = gamefolder
args2.npcs = npcs
Return args2
End Function
End Structure
' Methods
Public Sub New()
Me.pleaseWaitL = New Label
Me.notAvailableL = New Label
Me.waitingForDraw = False
Me.mp = New Panel
Dim size As New Size(200, 200)
Me.Size = size
Me.BorderStyle = Windows.Forms.BorderStyle.FixedSingle
Me.Visible = False
Me.mp.BackgroundImage = Nothing
Me.mp.BackColor = Color.Transparent
Me.Controls.Add(Me.mp)
Me.pleaseWaitL.AutoSize = True
Me.pleaseWaitL.Font = New Font("Comic Sans MS Bold", 18.0!, FontStyle.Italic, GraphicsUnit.Pixel)
Me.pleaseWaitL.Text = "Please wait..."
Me.pleaseWaitL.BackColor = Color.Transparent
Me.pleaseWaitL.ForeColor = Color.BlueViolet
Dim point As New Point(&H23, 40)
Me.pleaseWaitL.Location = point
Me.pleaseWaitL.Visible = False
Me.Controls.Add(Me.pleaseWaitL)
Me.notAvailableL.AutoSize = True
Me.notAvailableL.Font = New Font("Comic Sans MS Bold", 18.0!, FontStyle.Italic, GraphicsUnit.Pixel)
Me.notAvailableL.Text = "Map Not available"
Me.notAvailableL.BackColor = Color.Transparent
Me.notAvailableL.ForeColor = Color.Red
point = New Point(20, 40)
Me.notAvailableL.Location = point
Me.notAvailableL.Visible = False
Me.Controls.Add(Me.notAvailableL)
For Each c As Control In Me.Controls
AddHandler c.Click, AddressOf subClick
Next
End Sub
Private Sub subClick(ByVal sender As Object, ByVal e As EventArgs) Handles MyBase.Click
RaiseEvent Click(Me, e)
End Sub
Private Sub drawLoc()
Me.mp.Visible = True
Dim pnt As Point = MyPoint.Cord2Loc(New Point(Me.locX, Me.locY), Me.map.Width)
Dim img As New Bitmap(Me.Width, Me.Height, Me.map.PixelFormat)
Dim graphs As Graphics = Graphics.FromImage(img)
Dim destRect As New Rectangle(0, 0, Me.Width, Me.Height)
Dim srcRect As New Rectangle(pnt.X - Me.Height / 2, pnt.Y - Me.Height / 2, Me.Width, Me.Height)
graphs.DrawImage(Me.map, destRect, srcRect, GraphicsUnit.Pixel)
Me.BackgroundImage = img
End Sub
Public Sub drawLocation(ByVal x As Single, ByVal y As Single, ByVal dir As Single)
If openZone < 1 OrElse gameFld = String.Empty Then Return
If (((x <> Me.locX) OrElse (y <> Me.locY)) OrElse (Me.locD <> dir)) Then
If dir < 0.0! AndAlso Me.locD <> dir Then
Me.origArrow = Global.rylCoder.My.Resources.Xa_mark ' for teleports
ElseIf Me.locD <> dir Then
Try
Me.origArrow = FischR.Wrapper.LoadDDS(Me.gameFld & "\Texture\Interface\mmap01.dds", New Rectangle(&H80, &H15, &H16, &H30))
Catch ex As Exception
Me.origArrow = Global.rylCoder.My.Resources.Xa_mark
End Try
If Me.origArrow Is Nothing Then Me.origArrow = Global.rylCoder.My.Resources.Xa_mark
End If
If ((x = Me.locX) AndAlso (y = Me.locY)) Then
Me.locD = dir
Me.setRot()
Else
Me.Visible = True
Me.BackgroundImage = Nothing
Me.locX = x
Me.locY = y
If (dir <> Me.locD) Then
Me.locD = dir
Me.setRot()
End If
Me.locD = dir
If (Not Me.worker.IsBusy AndAlso (Not Me.map Is Nothing)) Then
Me.drawLoc()
ElseIf Not Me.worker.IsBusy Then
Me.notAvailableL.Visible = True
Else
Me.waitingForDraw = True
End If
End If
Else
Me.Visible = True
End If
End Sub
Public Sub openMap(ByVal gamefolder As String, ByVal zone As Integer, Optional ByRef npcs As CNpcParser.npcStruct() = Nothing)
If ((Me.map Is Nothing) OrElse (zone <> Me.openZone)) Then
Me.gameFld = gamefolder
Me.openZone = zone
If Me.worker.IsBusy Then
Me.worker = New BackgroundWorker
End If
If (Me.origArrow Is Nothing) Then
Try
Me.origArrow = FischR.Wrapper.LoadDDS(Me.gameFld & "\Texture\Interface\mmap01.dds", New Rectangle(&H80, &H15, &H16, &H30))
Catch ex As Exception
Me.origArrow = Global.rylCoder.My.Resources.Xa_mark
End Try
If Me.origArrow Is Nothing Then Me.origArrow = Global.rylCoder.My.Resources.Xa_mark
End If
Me.pleaseWaitL.Visible = True
Me.notAvailableL.Visible = False
Me.mp.Visible = False
Me.worker.RunWorkerAsync(workerArgs.Create(gamefolder, zone, (npcs)))
End If
End Sub
Private Sub setRot()
Dim num As Double = (locD / Math.PI) * 180.0!
If (num >= 360) Then num = (num - 360)
If num < 0 Then num = num + 360
Me.mp.BackgroundImage = Support.Imaging.RotateImage(Me.origArrow, num)
Me.mp.Size = Me.mp.BackgroundImage.Size
Dim point As New Point(CInt(Math.Round(CDbl(((CDbl(Me.Width) / 2) - (CDbl(Me.mp.Width) / 2))))), CInt(Math.Round(CDbl(((CDbl(Me.Height) / 2) - (CDbl(Me.mp.Height) / 2))))))
Me.mp.Location = point
End Sub
Private Sub worker_DoWork(ByVal sender As Object, ByVal e As DoWorkEventArgs) Handles worker.DoWork
Dim wk As workerArgs = e.Argument
Dim bmp As Bitmap = CMiniMap.CreateMap(wk.folder, wk.zone)
If Not wk.npcs Is Nothing AndAlso Not bmp Is Nothing Then
For Each npc As CNpcParser.npcStruct In wk.npcs
Dim npcPosLines As CNpcParser.NPCline() = npc.Lines(CNpcParser.NPCline.knownType.ESetPosition)
If npc.Map > 0 AndAlso npc.Map = wk.zone Then
Dim cord As New Point(npcPosLines(0).Params(2).value, npcPosLines(0).Params(4).value)
Dim loc As Point = MyPoint.Cord2Loc(cord, bmp.Width)
For i As Integer = loc.X - npcWidth / 2 To loc.X + npcWidth / 2
For j As Integer = loc.Y - npcWidth / 2 To loc.Y + npcWidth / 2
If i >= 0 AndAlso j >= 0 AndAlso i < bmp.Width AndAlso j < bmp.Height Then
bmp.SetPixel(i, j, CMiniMapPanel.npcColor)
End If
Next
Next
End If
Next
End If
e.Result = bmp
End Sub
Private Sub worker_RunWorkerCompleted(ByVal sender As Object, ByVal e As RunWorkerCompletedEventArgs) Handles worker.RunWorkerCompleted
Me.map = e.Result
Me.pleaseWaitL.Visible = False
If Me.waitingForDraw Then
If Not Me.map Is Nothing Then
Me.drawLoc()
Else
Me.notAvailableL.Visible = True
End If
End If
End Sub
End Class

View File

@@ -0,0 +1,47 @@
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> _
Partial Class cntQuestPhaseLine
Inherits System.Windows.Forms.UserControl
'UserControl overrides dispose to clean up the component list.
<System.Diagnostics.DebuggerNonUserCode()> _
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
If disposing AndAlso components IsNot Nothing Then
components.Dispose()
End If
MyBase.Dispose(disposing)
End Sub
'Required by the Windows Form Designer
Private components As System.ComponentModel.IContainer
'NOTE: The following procedure is required by the Windows Form Designer
'It can be modified using the Windows Form Designer.
'Do not modify it using the code editor.
<System.Diagnostics.DebuggerStepThrough()> _
Private Sub InitializeComponent()
Me.flowMain = New System.Windows.Forms.FlowLayoutPanel
Me.SuspendLayout()
'
'flowMain
'
Me.flowMain.Location = New System.Drawing.Point(0, 0)
Me.flowMain.Name = "flowMain"
Me.flowMain.Size = New System.Drawing.Size(279, 21)
Me.flowMain.TabIndex = 0
Me.flowMain.WrapContents = False
'
'cntQuestPhaseLine
'
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
Me.Controls.Add(Me.flowMain)
Me.DoubleBuffered = True
Me.Margin = New System.Windows.Forms.Padding(0)
Me.Name = "cntQuestPhaseLine"
Me.Size = New System.Drawing.Size(282, 21)
Me.ResumeLayout(False)
End Sub
Friend WithEvents flowMain As System.Windows.Forms.FlowLayoutPanel
End Class

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=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@@ -0,0 +1,82 @@
Public Class cntQuestPhaseLine
Public qLine As CQuestParser.QLine = Nothing
Public level As Integer = 0
Private lvl3BG As Color = Color.FromArgb(&HFFFFE9E9)
Private lvl3BGa As Color = Color.FromArgb(&HFFFFBBBB)
Private lvl4BG As Color = Color.FromArgb(&HFFE9FFE9)
Private lvl4BGa As Color = Color.FromArgb(&HFFBBFFBB)
Private mouseIsDown As Boolean = False
Public Event openQLinesForEdit(ByRef sender As cntQuestPhaseLine, ByRef line As CQuestParser.QLine)
Public Event lineWantsToMove(ByRef sender As cntQuestPhaseLine, ByRef line As CQuestParser.QLine, ByVal offset As Integer)
Private butDownLocation As Integer = 0
Public Sub New()
InitializeComponent()
End Sub
Public Sub New(ByRef line As CQuestParser.QLine)
InitializeComponent()
setQuestLine(line)
End Sub
Public Sub setQuestLine(ByRef line As CQuestParser.QLine)
qLine = line
level = IIf(Array.IndexOf(CQuestParser.QuestPhase.lvl3functions, qLine.Type) >= 0, 3, 4)
If qLine.Type = CQuestParser.QLine.KnownType.EElse Then level = 3
Me.BackColor = IIf(level = 3, lvl3BG, lvl4BG)
Me.flowMain.Controls.Add(New frmNpcEdit.namedLabel(IIf(level <> 3, StrDup(3, " "), "") & CQuestParser.QLine.Type2String(qLine.Type) & "(", True))
Dim i As Integer = 0
For Each p As CMcfBase.SParamElem In qLine.params
Me.flowMain.Controls.Add(New frmNpcEdit.namedLabel(p.value.ToString & IIf(i < qLine.params.Length - 1, ",", "")))
i += 1
Next
Me.flowMain.Controls.Add(New frmNpcEdit.namedLabel(")", True))
setHooks()
End Sub
Private Sub cntQuestPhaseLine_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
setHooks()
End Sub
Private Sub cntQuestPhaseLine_MouseClick(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs)
RaiseEvent openQLinesForEdit(Me, qLine)
End Sub
Private Sub cntQuestPhaseLine_MouseEnter(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.MouseEnter
Me.BackColor = IIf(level = 3, lvl3BGa, lvl4BGa)
End Sub
Private Sub cntQuestPhaseLine_MouseLeave(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.MouseLeave
Me.BackColor = IIf(level = 3, lvl3BG, lvl4BG)
End Sub
Private Sub setHooks(Optional ByVal cntCollec As Windows.Forms.Control.ControlCollection = Nothing)
If cntCollec Is Nothing Then cntCollec = Me.Controls
For Each c As Control In cntCollec
AddHandler c.MouseEnter, AddressOf cntQuestPhaseLine_MouseEnter
AddHandler c.MouseLeave, AddressOf cntQuestPhaseLine_MouseLeave
AddHandler c.MouseClick, AddressOf cntQuestPhaseLine_MouseClick
AddHandler c.MouseDown, AddressOf cntQuestPhaseLine_MouseDown
AddHandler c.MouseUp, AddressOf cntQuestPhaseLine_MouseUp
AddHandler c.MouseMove, AddressOf cntQuestPhaseLine_MouseMove
If Not c.Controls Is Nothing AndAlso c.Controls.Count > 0 Then
setHooks(c.Controls)
End If
Next
End Sub
Private Sub cntQuestPhaseLine_MouseDown(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs)
mouseIsDown = True
butDownLocation = e.Location.Y
End Sub
Private Sub cntQuestPhaseLine_MouseUp(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs)
If mouseIsDown Then
Me.Cursor = Cursors.Default
Dim offDiff As Integer = e.Location.Y - butDownLocation
If offDiff > 5 OrElse offDiff < -5 Then RaiseEvent lineWantsToMove(Me, qLine, offDiff + Me.Location.Y)
End If
mouseIsDown = False
End Sub
Private Sub cntQuestPhaseLine_MouseMove(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs)
If mouseIsDown Then
Me.Cursor = Cursors.SizeAll
End If
End Sub
End Class

View File

@@ -0,0 +1,141 @@
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> _
Partial Class cntQuestPhaseLineEditor
Inherits System.Windows.Forms.UserControl
'UserControl overrides dispose to clean up the component list.
<System.Diagnostics.DebuggerNonUserCode()> _
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
If disposing AndAlso components IsNot Nothing Then
components.Dispose()
End If
MyBase.Dispose(disposing)
End Sub
'Required by the Windows Form Designer
Private components As System.ComponentModel.IContainer
'NOTE: The following procedure is required by the Windows Form Designer
'It can be modified using the Windows Form Designer.
'Do not modify it using the code editor.
<System.Diagnostics.DebuggerStepThrough()> _
Private Sub InitializeComponent()
Me.GroupBox1 = New System.Windows.Forms.GroupBox
Me.lblFuncDesc = New System.Windows.Forms.Label
Me.lnkClose = New System.Windows.Forms.LinkLabel
Me.lnkSave = New System.Windows.Forms.LinkLabel
Me.flowParas = New System.Windows.Forms.FlowLayoutPanel
Me.cmbFunction = New System.Windows.Forms.ComboBox
Me.Label1 = New System.Windows.Forms.Label
Me.lnkDelete = New System.Windows.Forms.LinkLabel
Me.GroupBox1.SuspendLayout()
Me.SuspendLayout()
'
'GroupBox1
'
Me.GroupBox1.Controls.Add(Me.lnkDelete)
Me.GroupBox1.Controls.Add(Me.lblFuncDesc)
Me.GroupBox1.Controls.Add(Me.lnkClose)
Me.GroupBox1.Controls.Add(Me.lnkSave)
Me.GroupBox1.Controls.Add(Me.flowParas)
Me.GroupBox1.Controls.Add(Me.cmbFunction)
Me.GroupBox1.Controls.Add(Me.Label1)
Me.GroupBox1.FlatStyle = System.Windows.Forms.FlatStyle.System
Me.GroupBox1.ForeColor = System.Drawing.SystemColors.ControlText
Me.GroupBox1.Location = New System.Drawing.Point(0, 0)
Me.GroupBox1.Name = "GroupBox1"
Me.GroupBox1.Size = New System.Drawing.Size(289, 373)
Me.GroupBox1.TabIndex = 0
Me.GroupBox1.TabStop = False
Me.GroupBox1.Text = "Quest Phase Line Editor"
'
'lblFuncDesc
'
Me.lblFuncDesc.AutoEllipsis = True
Me.lblFuncDesc.AutoSize = True
Me.lblFuncDesc.Location = New System.Drawing.Point(6, 45)
Me.lblFuncDesc.Name = "lblFuncDesc"
Me.lblFuncDesc.Size = New System.Drawing.Size(102, 13)
Me.lblFuncDesc.TabIndex = 5
Me.lblFuncDesc.Text = "Function description"
Me.lblFuncDesc.UseMnemonic = False
'
'lnkClose
'
Me.lnkClose.AutoSize = True
Me.lnkClose.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(186, Byte))
Me.lnkClose.LinkBehavior = System.Windows.Forms.LinkBehavior.NeverUnderline
Me.lnkClose.Location = New System.Drawing.Point(274, 0)
Me.lnkClose.Name = "lnkClose"
Me.lnkClose.Size = New System.Drawing.Size(15, 13)
Me.lnkClose.TabIndex = 4
Me.lnkClose.TabStop = True
Me.lnkClose.Text = "X"
'
'lnkSave
'
Me.lnkSave.AutoSize = True
Me.lnkSave.Location = New System.Drawing.Point(250, 351)
Me.lnkSave.Name = "lnkSave"
Me.lnkSave.Size = New System.Drawing.Size(32, 13)
Me.lnkSave.TabIndex = 3
Me.lnkSave.TabStop = True
Me.lnkSave.Text = "Save"
'
'flowParas
'
Me.flowParas.AutoScroll = True
Me.flowParas.Location = New System.Drawing.Point(3, 72)
Me.flowParas.Name = "flowParas"
Me.flowParas.Size = New System.Drawing.Size(279, 276)
Me.flowParas.TabIndex = 2
'
'cmbFunction
'
Me.cmbFunction.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList
Me.cmbFunction.FormattingEnabled = True
Me.cmbFunction.Location = New System.Drawing.Point(63, 21)
Me.cmbFunction.Name = "cmbFunction"
Me.cmbFunction.Size = New System.Drawing.Size(220, 21)
Me.cmbFunction.TabIndex = 1
'
'Label1
'
Me.Label1.AutoSize = True
Me.Label1.Location = New System.Drawing.Point(6, 24)
Me.Label1.Name = "Label1"
Me.Label1.Size = New System.Drawing.Size(51, 13)
Me.Label1.TabIndex = 0
Me.Label1.Text = "Function:"
'
'lnkDelete
'
Me.lnkDelete.AutoSize = True
Me.lnkDelete.Location = New System.Drawing.Point(190, 351)
Me.lnkDelete.Name = "lnkDelete"
Me.lnkDelete.Size = New System.Drawing.Size(38, 13)
Me.lnkDelete.TabIndex = 6
Me.lnkDelete.TabStop = True
Me.lnkDelete.Text = "Delete"
'
'cntQuestPhaseLineEditor
'
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
Me.Controls.Add(Me.GroupBox1)
Me.Name = "cntQuestPhaseLineEditor"
Me.Size = New System.Drawing.Size(290, 376)
Me.GroupBox1.ResumeLayout(False)
Me.GroupBox1.PerformLayout()
Me.ResumeLayout(False)
End Sub
Friend WithEvents GroupBox1 As System.Windows.Forms.GroupBox
Friend WithEvents cmbFunction As System.Windows.Forms.ComboBox
Friend WithEvents Label1 As System.Windows.Forms.Label
Friend WithEvents flowParas As System.Windows.Forms.FlowLayoutPanel
Friend WithEvents lnkClose As System.Windows.Forms.LinkLabel
Friend WithEvents lnkSave As System.Windows.Forms.LinkLabel
Friend WithEvents lblFuncDesc As System.Windows.Forms.Label
Friend WithEvents lnkDelete As System.Windows.Forms.LinkLabel
End Class

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=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@@ -0,0 +1,204 @@
Public Class cntQuestPhaseLineEditor
Public line As CQuestParser.QLine = Nothing
Public level As Integer = 0
Private iSyntax As Xml.XmlElement = Nothing
Public Event Save(ByRef sender As cntQuestPhaseLineEditor, ByRef line As CQuestParser.QLine)
Public Event Close(ByRef sender As cntQuestPhaseLineEditor)
Public Event Delete(ByRef sender As cntQuestPhaseLineEditor, ByRef line As CQuestParser.QLine)
Public Event NeedItemName(ByRef sender As cntQuestPhaseLineEditor, ByVal id As Long, ByRef name As String)
Public Event NeedItemSelect(ByRef sender As cntQuestPhaseLineEditor, ByRef sender2 As LinkLabel)
Public Event NeedMobName(ByRef sender As cntQuestPhaseLineEditor, ByVal id As Long, ByRef name As String)
Public Event NeedMobSelect(ByRef sender As cntQuestPhaseLineEditor, ByRef sender2 As LinkLabel)
Private currentParaCount As Integer = 0
Private currentF As CQuestParser.QLine.KnownType
Public Sub New(ByRef qLine As CQuestParser.QLine, ByVal syntax As Xml.XmlElement)
line = qLine
iSyntax = syntax
' This call is required by the Windows Form Designer.
InitializeComponent()
Dim funcs() As CQuestParser.QLine.KnownType = {}
If Array.IndexOf(CQuestParser.QuestPhase.lvl3functions, line.Type) >= 0 Then level = 3
If Array.IndexOf(CQuestParser.QuestPhase.lvl4functions, line.Type) >= 0 Then level = 4
If level < 1 Then Exit Sub
If level = 3 Then funcs = CQuestParser.QuestPhase.lvl3functions
If level = 4 Then funcs = CQuestParser.QuestPhase.lvl4functions
' Add any initialization after the InitializeComponent() call.
For Each e As CQuestParser.QLine.KnownType In funcs
Me.cmbFunction.Items.Add(New frmNpcEdit.cmbItem(e, CQuestParser.QLine.Type2String(e)))
Next
End Sub
Private Sub drawProps(ByVal func As CQuestParser.QLine.KnownType)
Me.flowParas.SuspendLayout()
Me.flowParas.Controls.Clear()
Me.lblFuncDesc.Text = ""
If Not iSyntax Is Nothing Then
Dim fNodes As Xml.XmlNodeList = iSyntax.SelectNodes("func[@name='" & CQuestParser.QLine.Type2String(func) & "' and @level=" & level & "]")
If fNodes.Count = 1 Then
Me.lblFuncDesc.Text = fNodes(0).Attributes.GetNamedItem("desc").Value
currentParaCount = fNodes(0).ChildNodes.Count
currentF = func
If fNodes(0).ChildNodes.Count > 0 Then
Dim i As Integer = 0
For Each pNode As Xml.XmlNode In fNodes(0).ChildNodes
Dim type As String = pNode.Attributes.GetNamedItem("type").Value
Dim name As String = pNode.Attributes.GetNamedItem("name").Value
Dim desc As String = pNode.Attributes.GetNamedItem("desc").Value
Dim txtI As New CNpcParser.NPCTextItem
txtI.paraIndex = i
Select Case type
Case "int"
txtI.Tag = CMcfBase.DataType.EInteger
If line.Type <> func Then txtI.text = "0"
Case "string"
txtI.Tag = CMcfBase.DataType.EString
If line.Type <> func Then txtI.text = New String("")
Case "float"
txtI.Tag = CMcfBase.DataType.EFloat
If line.Type <> func Then txtI.text = "0"
Case "bool"
txtI.Tag = CMcfBase.DataType.EBool
If line.Type <> func Then txtI.text = "0"
End Select
If line.Type = func Then
txtI.text = line.params(i).value
End If
If type = "int" AndAlso name.ToLower = "item id" Then
Dim lbl As New Label
lbl.Width = Me.flowParas.Width - 6
lbl.Text = IIf(name.ToLower <> desc.ToLower, "[" & name & "] ", "") & desc
lbl.Margin = New Padding(3, 0, 3, 0)
Me.flowParas.Controls.Add(lbl)
Dim obj As New LinkLabel
Dim itemName As String = ""
Dim itemId As Long = IIf(txtI.text.Length > 0, txtI.text, 0)
RaiseEvent NeedItemName(Me, itemId, itemName)
obj.Text = "Item: " & IIf(itemId > 0, itemName, "none")
obj.Tag = txtI
obj.Width = Me.flowParas.Width - 6
obj.Margin = New Padding(3, 0, 3, 3)
AddHandler obj.LinkClicked, AddressOf linkParam_Click
Me.flowParas.Controls.Add(obj)
ElseIf type = "int" AndAlso name.ToLower = "monster id" Then
Dim lbl As New Label
lbl.Width = Me.flowParas.Width - 6
lbl.Text = IIf(name.ToLower <> desc.ToLower, "[" & name & "] ", "") & desc
lbl.Margin = New Padding(3, 0, 3, 0)
Me.flowParas.Controls.Add(lbl)
Dim obj As New LinkLabel
Dim itemName As String = ""
Dim mobId As Long = IIf(txtI.text.Length > 0, txtI.text, 0)
RaiseEvent NeedMobName(Me, mobId, itemName)
obj.Text = "Mob: " & IIf(mobId > 0, itemName, "none")
obj.Tag = txtI
obj.Width = Me.flowParas.Width - 6
obj.Margin = New Padding(3, 0, 3, 3)
AddHandler obj.LinkClicked, AddressOf linkParam2_Click
Me.flowParas.Controls.Add(obj)
Else
Dim obj As New cntTextEditItem()
AddHandler obj.NPCTextChanged, AddressOf TxtItem_NPCTextChanged
Dim wDiff As Integer = obj.Width - obj.txtText.Width
obj.Width = Me.flowParas.Width - 6
obj.txtText.Width = obj.Width - wDiff
If type <> "string" Then
obj.Small = True
End If
If type = "int" AndAlso (name.ToLower = "quest id" OrElse name.ToLower = "npc id" OrElse desc.ToLower = "npc id") Then
txtI.text = "0x" & Hex(Val(txtI.text))
End If
obj.TextItem = txtI
obj.Tag = txtI
obj.Command = IIf(name.ToLower <> desc.ToLower, "[" & name & "] ", "") & desc
Me.flowParas.Controls.Add(obj)
End If
i += 1
Next
Else
Me.flowParas.Controls.Add(New frmNpcEdit.namedLabel("Function has no parameters", True))
End If
Me.lnkSave.Enabled = True
Else
Me.lnkSave.Enabled = False
Me.flowParas.Controls.Add(New frmNpcEdit.namedLabel("Function not found in Syntax XML", True))
End If
Else
Me.lnkSave.Enabled = False
Me.flowParas.Controls.Add(New frmNpcEdit.namedLabel("Syntax XML not loaded", True))
End If
Me.flowParas.ResumeLayout()
End Sub
Private Sub linkParam_Click(ByVal sender As Object, ByVal e As LinkLabelLinkClickedEventArgs)
RaiseEvent NeedItemSelect(Me, sender)
Dim nName As String = ""
If Val(sender.tag.text) > 0 Then
RaiseEvent NeedItemName(Me, sender.tag.text, nName)
sender.text = "Item: " & nName
Else
sender.Text = "Item: none"
End If
End Sub
Private Sub linkParam2_Click(ByVal sender As Object, ByVal e As LinkLabelLinkClickedEventArgs)
RaiseEvent NeedMobSelect(Me, sender)
Dim nName As String = ""
If Val(sender.tag.text) > 0 Then
RaiseEvent NeedMobName(Me, sender.tag.text, nName)
sender.text = "Mob: " & nName
Else
sender.Text = "Mob: none"
End If
End Sub
Private Sub lnkClose_LinkClicked(ByVal sender As Object, ByVal e As System.Windows.Forms.LinkLabelLinkClickedEventArgs) Handles lnkClose.LinkClicked
RaiseEvent Close(Me)
End Sub
Private Sub lnkSave_LinkClicked(ByVal sender As Object, ByVal e As System.Windows.Forms.LinkLabelLinkClickedEventArgs) Handles lnkSave.LinkClicked
Dim paraList(currentParaCount - 1) As CMcfBase.SParamElem
Dim i As Integer = 0
For Each c As Control In Me.flowParas.Controls
If Not c.Tag Is Nothing Then
Dim val As Object = Nothing
Dim tI As CNpcParser.NPCTextItem = CType(c.Tag, CNpcParser.NPCTextItem)
Try
Select Case CType(tI.Tag, CMcfBase.DataType)
Case CMcfBase.DataType.EBool : val = IIf(val(tI.text) > 0, 1, 0)
Case CMcfBase.DataType.EFloat : val = Single.Parse(tI.text)
Case CMcfBase.DataType.EInteger
If tI.text.Length > 2 AndAlso tI.text.Substring(0, 2).ToLower = "0x" Then
val = Convert.ToUInt32(tI.text, 16)
Else
val = UInt32.Parse(tI.text)
End If
Case CMcfBase.DataType.EString : val = tI.text
End Select
Catch ex As Exception
MsgBox(ex.Message, MsgBoxStyle.Critical, "Save error on " & (i + 1) & "'th parameter")
Exit Sub
End Try
paraList(i) = CMcfBase.CreateParamElem(CType(tI.Tag, CMcfBase.DataType), val)
i += 1
End If
Next
line.Type = currentF
line.params = paraList
RaiseEvent Save(Me, line)
End Sub
Private Sub lnkDelete_LinkClicked(ByVal sender As Object, ByVal e As System.Windows.Forms.LinkLabelLinkClickedEventArgs) Handles lnkDelete.LinkClicked
RaiseEvent Delete(Me, line)
End Sub
Private Sub cmbFunction_SelectedIndexChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles cmbFunction.SelectedIndexChanged
drawProps(CType(cmbFunction.SelectedItem, frmNpcEdit.cmbItem).iItem)
End Sub
Private Sub cntQuestPhaseLineEditor_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
frmNpcEdit.cmbItem.setComboSelected(Me.cmbFunction, line.Type)
End Sub
Private Sub TxtItem_NPCTextChanged(ByRef sender As cntTextEditItem, ByVal line As CNpcParser.NPCTextItem, ByVal newText As String)
line.text = newText
sender.Tag = line
End Sub
End Class

View File

@@ -0,0 +1,153 @@
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> _
Partial Class cntShopView
Inherits System.Windows.Forms.UserControl
'UserControl overrides dispose to clean up the component list.
<System.Diagnostics.DebuggerNonUserCode()> _
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
If disposing AndAlso components IsNot Nothing Then
components.Dispose()
End If
MyBase.Dispose(disposing)
End Sub
'Required by the Windows Form Designer
Private components As System.ComponentModel.IContainer
'NOTE: The following procedure is required by the Windows Form Designer
'It can be modified using the Windows Form Designer.
'Do not modify it using the code editor.
<System.Diagnostics.DebuggerStepThrough()> _
Private Sub InitializeComponent()
Me.components = New System.ComponentModel.Container
Me.cntMnuNPCItem = New System.Windows.Forms.ContextMenuStrip(Me.components)
Me.mnuNPCItemsAdd = New System.Windows.Forms.ToolStripMenuItem
Me.mnuNPCItemsEdit = New System.Windows.Forms.ToolStripMenuItem
Me.mnuNPCItemsDelete = New System.Windows.Forms.ToolStripMenuItem
Me.lstSoldItems = New System.Windows.Forms.ListBox
Me.tipItems = New System.Windows.Forms.ToolTip(Me.components)
Me.cntMnuNPCItemEdit = New System.Windows.Forms.ContextMenuStrip(Me.components)
Me.ToolStripMenuItem1 = New System.Windows.Forms.ToolStripMenuItem
Me.ToolStripMenuItem2 = New System.Windows.Forms.ToolStripMenuItem
Me.ToolStripMenuItem3 = New System.Windows.Forms.ToolStripMenuItem
Me.cntMnuItemAdd = New System.Windows.Forms.ContextMenuStrip(Me.components)
Me.ToolStripMenuItem4 = New System.Windows.Forms.ToolStripMenuItem
Me.ToolStripMenuItem5 = New System.Windows.Forms.ToolStripMenuItem
Me.ToolStripMenuItem6 = New System.Windows.Forms.ToolStripMenuItem
Me.cntMnuNPCItemEdit.SuspendLayout()
Me.cntMnuItemAdd.SuspendLayout()
Me.SuspendLayout()
'
'cntMnuNPCItem
'
Me.cntMnuNPCItem.Name = "cntMnuNPCItem"
Me.cntMnuNPCItem.Size = New System.Drawing.Size(117, 70)
'
'mnuNPCItemsAdd
'
Me.mnuNPCItemsAdd.Name = "mnuNPCItemsAdd"
Me.mnuNPCItemsAdd.Size = New System.Drawing.Size(152, 22)
Me.mnuNPCItemsAdd.Text = "&Add"
'
'mnuNPCItemsEdit
'
Me.mnuNPCItemsEdit.Name = "mnuNPCItemsEdit"
Me.mnuNPCItemsEdit.Size = New System.Drawing.Size(116, 22)
Me.mnuNPCItemsEdit.Text = "&Edit"
'
'mnuNPCItemsDelete
'
Me.mnuNPCItemsDelete.Name = "mnuNPCItemsDelete"
Me.mnuNPCItemsDelete.Size = New System.Drawing.Size(116, 22)
Me.mnuNPCItemsDelete.Text = "&Delete"
'
'lstSoldItems
'
Me.lstSoldItems.ContextMenuStrip = Me.cntMnuNPCItem
Me.lstSoldItems.FormattingEnabled = True
Me.lstSoldItems.Location = New System.Drawing.Point(0, 0)
Me.lstSoldItems.Name = "lstSoldItems"
Me.lstSoldItems.Size = New System.Drawing.Size(290, 316)
Me.lstSoldItems.TabIndex = 3
'
'tipItems
'
Me.tipItems.AutoPopDelay = 20000
Me.tipItems.InitialDelay = 500
Me.tipItems.IsBalloon = True
Me.tipItems.ReshowDelay = 100
Me.tipItems.ToolTipIcon = System.Windows.Forms.ToolTipIcon.Info
Me.tipItems.ToolTipTitle = "Info"
'
'cntMnuNPCItemEdit
'
Me.cntMnuNPCItemEdit.Items.AddRange(New System.Windows.Forms.ToolStripItem() {Me.mnuNPCItemsEdit, Me.mnuNPCItemsDelete})
Me.cntMnuNPCItemEdit.Name = "cntMnuNPCItem"
Me.cntMnuNPCItemEdit.Size = New System.Drawing.Size(117, 48)
'
'ToolStripMenuItem1
'
Me.ToolStripMenuItem1.Name = "ToolStripMenuItem1"
Me.ToolStripMenuItem1.Size = New System.Drawing.Size(32, 19)
'
'ToolStripMenuItem2
'
Me.ToolStripMenuItem2.Name = "ToolStripMenuItem2"
Me.ToolStripMenuItem2.Size = New System.Drawing.Size(32, 19)
'
'ToolStripMenuItem3
'
Me.ToolStripMenuItem3.Name = "ToolStripMenuItem3"
Me.ToolStripMenuItem3.Size = New System.Drawing.Size(32, 19)
'
'cntMnuItemAdd
'
Me.cntMnuItemAdd.Items.AddRange(New System.Windows.Forms.ToolStripItem() {Me.mnuNPCItemsAdd})
Me.cntMnuItemAdd.Name = "cntMnuNPCItem"
Me.cntMnuItemAdd.Size = New System.Drawing.Size(153, 48)
'
'ToolStripMenuItem4
'
Me.ToolStripMenuItem4.Name = "ToolStripMenuItem4"
Me.ToolStripMenuItem4.Size = New System.Drawing.Size(32, 19)
'
'ToolStripMenuItem5
'
Me.ToolStripMenuItem5.Name = "ToolStripMenuItem5"
Me.ToolStripMenuItem5.Size = New System.Drawing.Size(32, 19)
'
'ToolStripMenuItem6
'
Me.ToolStripMenuItem6.Name = "ToolStripMenuItem6"
Me.ToolStripMenuItem6.Size = New System.Drawing.Size(32, 19)
'
'cntShopView
'
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
Me.BackgroundImage = Global.rylCoder.My.Resources.Resources.npcShopBg
Me.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None
Me.Controls.Add(Me.lstSoldItems)
Me.Name = "cntShopView"
Me.Size = New System.Drawing.Size(290, 313)
Me.cntMnuNPCItemEdit.ResumeLayout(False)
Me.cntMnuItemAdd.ResumeLayout(False)
Me.ResumeLayout(False)
End Sub
Friend WithEvents cntMnuNPCItem As System.Windows.Forms.ContextMenuStrip
Friend WithEvents mnuNPCItemsAdd As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents mnuNPCItemsEdit As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents mnuNPCItemsDelete As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents lstSoldItems As System.Windows.Forms.ListBox
Friend WithEvents tipItems As System.Windows.Forms.ToolTip
Friend WithEvents cntMnuNPCItemEdit As System.Windows.Forms.ContextMenuStrip
Friend WithEvents ToolStripMenuItem1 As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents ToolStripMenuItem2 As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents ToolStripMenuItem3 As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents cntMnuItemAdd As System.Windows.Forms.ContextMenuStrip
Friend WithEvents ToolStripMenuItem4 As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents ToolStripMenuItem5 As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents ToolStripMenuItem6 As System.Windows.Forms.ToolStripMenuItem
End Class

View File

@@ -0,0 +1,132 @@
<?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=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="cntMnuNPCItem.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
<metadata name="tipItems.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>149, 17</value>
</metadata>
<metadata name="cntMnuNPCItemEdit.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>241, 17</value>
</metadata>
<metadata name="cntMnuItemAdd.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>392, 17</value>
</metadata>
</root>

View File

@@ -0,0 +1,195 @@
Public Class cntShopView
Private gridView As Boolean = False
Private images As New List(Of PictureBox)
Private imageSlots(,) As Integer
Private iSelect As frmSelectItem = Nothing
Private Const NUM_SLOTS_HORI = 8
Private Const NUM_SLOTS_VERT = 12
Private Const WIDTH_SEPERATOR = 1
Private Const WIDTH_SLOT = 25
Private Const HEIGHT_SLOT = 25
Public Event AddItemRequest(ByVal sender As Object, ByVal e As System.EventArgs)
Public Event EditItemRequest(ByVal sender As Object, ByVal e As System.EventArgs)
Public Event DeleteRequest(ByVal sender As Object, ByVal e As System.EventArgs)
Public Event MenuOpening(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs)
Public Sub New()
' This call is required by the Windows Form Designer.
InitializeComponent()
' Add any initialization after the InitializeComponent() call.
End Sub
Public Sub updateForm(ByVal selector As frmSelectItem)
iSelect = selector
If frmNpcEdit.RylGameDir <> "" AndAlso Not selector Is Nothing Then
gridView = True
Me.lstSoldItems.Visible = False
Me.Size = Me.BackgroundImage.Size
imageSlots = New Integer(NUM_SLOTS_VERT, NUM_SLOTS_HORI) {}
Me.Location += New Point((Me.lstSoldItems.Width - Me.BackgroundImage.Width) / 2, 0)
Me.ContextMenuStrip = cntMnuItemAdd
Else
Me.lstSoldItems.Visible = True
Me.Size = Me.lstSoldItems.Size
End If
End Sub
Private Function newItemLocation(ByVal imgSlots As Size, ByVal itemID As Integer) As Point
Dim tmpSlots(NUM_SLOTS_VERT - 1)() As Boolean
For y As Integer = 0 To NUM_SLOTS_VERT - 1
For x As Integer = 0 To NUM_SLOTS_HORI - 1
Dim id As Integer = imageSlots(y, x)
If id < 1 AndAlso y + imgSlots.Height <= NUM_SLOTS_VERT AndAlso x + imgSlots.Width <= NUM_SLOTS_HORI Then
Dim gotRoom As Boolean = True
For y2 As Integer = y To y + imgSlots.Height - 1
For x2 As Integer = x To x + imgSlots.Width - 1
If gotRoom AndAlso imageSlots(y2, x2) > 0 Then gotRoom = False
Next
Next
If gotRoom Then
For y2 As Integer = y To y + imgSlots.Height - 1
For x2 As Integer = x To x + imgSlots.Width - 1
imageSlots(y2, x2) = itemID
Next
Next
Return New Point(x * (WIDTH_SEPERATOR + WIDTH_SLOT) + WIDTH_SEPERATOR, y * (WIDTH_SEPERATOR + HEIGHT_SLOT) + WIDTH_SEPERATOR)
End If
End If
Next
Next
Return New Point(-1, -1)
End Function
Public Sub AddItem(ByVal item As frmNpcEdit.ShopItem)
Me.lstSoldItems.Items.Add(item)
If gridView Then
Dim gItem As frmSelectItem.GameItem = iSelect.getGameItem(item.itemId)
Dim slots As New Size(1, 1)
Dim img As Bitmap = Nothing
If gItem.ID > 0 Then
img = frmSelectItem.bitmapForItem(gItem)
slots = New Point(gItem.slotsX, gItem.slotsY)
End If
If img Is Nothing Then img = Global.rylCoder.My.Resources.npcShopNotFound
Dim loc As Point = newItemLocation(slots, item.itemId)
If loc.X >= 0 AndAlso loc.Y >= 0 Then
img.MakeTransparent(Color.Black)
Dim pB As New PictureBox()
pB.Tag = New imageItemTag(item, Me.lstSoldItems.Items.Count - 1)
pB.BackColor = Color.Transparent
pB.Image = img
pB.Size = New Size(slots.Width * WIDTH_SLOT + (slots.Width - 1) * WIDTH_SEPERATOR, slots.Height * HEIGHT_SLOT + (slots.Height - 1) * WIDTH_SEPERATOR)
pB.Location = loc
Me.Controls.Add(pB)
images.Add(pB)
pB.ContextMenuStrip = cntMnuNPCItemEdit
AddHandler pB.MouseDown, AddressOf imageItem_Click
AddHandler pB.MouseDoubleClick, AddressOf imageItem_DoubleClick
tipItems.SetToolTip(pB, item.ToString())
End If
End If
End Sub
Public Function IndexOnList(ByVal itemID As Integer) As Integer
Dim k As Integer = 0
For Each item As frmNpcEdit.ShopItem In Me.lstSoldItems.Items
If item.itemId = itemID Then Return k
k += 1
Next
Return -1
End Function
Public Sub ClearShop()
Me.lstSoldItems.Items.Clear()
If gridView Then
Me.BackgroundImage = Global.rylCoder.My.Resources.npcShopBg
tipItems.RemoveAll()
imageSlots = New Integer(NUM_SLOTS_VERT, NUM_SLOTS_HORI) {}
For Each cnt As Control In images
Me.Controls.Remove(cnt)
cnt.Dispose()
Next
images = New List(Of PictureBox)
End If
End Sub
Public Property SelectedIndex() As Integer
Get
Return Me.lstSoldItems.SelectedIndex
End Get
Set(ByVal value As Integer)
If value >= 0 AndAlso value <= Me.lstSoldItems.Items.Count Then
Me.lstSoldItems.SelectedIndex = value
activateImageItem(images(value))
End If
End Set
End Property
Public ReadOnly Property SelectedItem() As frmNpcEdit.ShopItem
Get
Dim i As Integer = SelectedIndex
If i >= 0 AndAlso i < Me.lstSoldItems.Items.Count Then
Return Me.lstSoldItems.Items(i)
Else
Return Nothing
End If
End Get
End Property
Public ReadOnly Property Count() As Integer
Get
Return Me.lstSoldItems.Items.Count
End Get
End Property
Public Property Items(ByVal index As Integer) As frmNpcEdit.ShopItem
Get
Return Me.lstSoldItems.Items(index)
End Get
Set(ByVal value As frmNpcEdit.ShopItem)
Me.lstSoldItems.Items(index) = value
End Set
End Property
Private Sub mnuNPCItemsAdd_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mnuNPCItemsAdd.Click
RaiseEvent AddItemRequest(Me.mnuNPCItemsAdd, New EventArgs)
End Sub
Private Sub mnuNPCItemsDelete_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mnuNPCItemsDelete.Click
RaiseEvent DeleteRequest(Me.mnuNPCItemsDelete, New EventArgs)
End Sub
Private Sub mnuNPCItemsEdit_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mnuNPCItemsEdit.Click
RaiseEvent EditItemRequest(Me.mnuNPCItemsEdit, New EventArgs)
End Sub
Private Sub cntMnuNPCItem_Opening(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles cntMnuNPCItem.Opening
RaiseEvent MenuOpening(Me.cntMnuNPCItem, e)
End Sub
Private Sub imageItem_Click(ByVal sender As Object, ByVal e As MouseEventArgs)
activateImageItem(CType(sender, PictureBox))
End Sub
Private Sub imageItem_DoubleClick(ByVal sender As Object, ByVal e As MouseEventArgs)
activateImageItem(sender)
RaiseEvent EditItemRequest(sender, New EventArgs)
End Sub
Private Sub activateImageItem(ByVal imgItem As PictureBox)
Dim tag As imageItemTag = CType(imgItem.Tag, imageItemTag)
Me.BackgroundImage = Global.rylCoder.My.Resources.npcShopBg
For Each picBox As PictureBox In images
Dim pTag As imageItemTag = CType(picBox.Tag, imageItemTag)
If pTag.activated Then
pTag.activated = False
picBox.Tag = pTag
End If
Next
tag.activated = True
imgItem.Tag = tag
Me.lstSoldItems.SelectedIndex = tag.index
Dim gr As Graphics = Graphics.FromImage(Me.BackgroundImage)
gr.DrawRectangle(Pens.BlueViolet, imgItem.Location.X, imgItem.Location.Y, imgItem.Width - 1, imgItem.Height - 1)
gr.Flush()
imgItem.Refresh()
End Sub
Private Structure imageItemTag
Public sItem As frmNpcEdit.ShopItem
Public activated As Boolean
Public index As Integer
Public Sub New(ByVal item As frmNpcEdit.ShopItem, ByVal i As Integer)
sItem = item
index = i
activated = False
End Sub
End Structure
End Class

View File

@@ -0,0 +1,61 @@
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> _
Partial Class cntTextEditItem
Inherits System.Windows.Forms.UserControl
'UserControl overrides dispose to clean up the component list.
<System.Diagnostics.DebuggerNonUserCode()> _
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
If disposing AndAlso components IsNot Nothing Then
components.Dispose()
End If
MyBase.Dispose(disposing)
End Sub
'Required by the Windows Form Designer
Private components As System.ComponentModel.IContainer
'NOTE: The following procedure is required by the Windows Form Designer
'It can be modified using the Windows Form Designer.
'Do not modify it using the code editor.
<System.Diagnostics.DebuggerStepThrough()> _
Private Sub InitializeComponent()
Me.lblCommand = New System.Windows.Forms.Label
Me.txtText = New System.Windows.Forms.TextBox
Me.SuspendLayout()
'
'lblCommand
'
Me.lblCommand.AutoSize = True
Me.lblCommand.Location = New System.Drawing.Point(0, -1)
Me.lblCommand.Name = "lblCommand"
Me.lblCommand.Size = New System.Drawing.Size(74, 13)
Me.lblCommand.TabIndex = 0
Me.lblCommand.Text = "Command row"
'
'txtText
'
Me.txtText.AcceptsReturn = True
Me.txtText.Location = New System.Drawing.Point(0, 15)
Me.txtText.Multiline = True
Me.txtText.Name = "txtText"
Me.txtText.ScrollBars = System.Windows.Forms.ScrollBars.Both
Me.txtText.Size = New System.Drawing.Size(324, 113)
Me.txtText.TabIndex = 1
Me.txtText.WordWrap = False
'
'cntTextEditItem
'
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
Me.Controls.Add(Me.txtText)
Me.Controls.Add(Me.lblCommand)
Me.Name = "cntTextEditItem"
Me.Size = New System.Drawing.Size(327, 145)
Me.ResumeLayout(False)
Me.PerformLayout()
End Sub
Friend WithEvents lblCommand As System.Windows.Forms.Label
Public WithEvents txtText As System.Windows.Forms.TextBox
End Class

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=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@@ -0,0 +1,54 @@
Public Class cntTextEditItem
Private iTextitem As CNpcParser.NPCTextItem
Public Event NPCTextChanged(ByRef sender As cntTextEditItem, ByVal line As CNpcParser.NPCTextItem, ByVal newText As String)
Public Property NPCText() As String
Get
If Me.txtText.Lines.Length > 0 Then
Dim lines() As String = Me.txtText.Lines
If Trim(lines(UBound(lines))) = vbNewLine Then Array.Resize(lines, lines.Length - 1)
Return String.Join("\\", lines)
Else
Return ""
End If
End Get
Set(ByVal value As String)
Dim lines() As String = value.Split(New String() {"\\"}, StringSplitOptions.None)
Me.txtText.Lines = lines
End Set
End Property
Public Property Command() As String
Get
Return Me.lblCommand.Text
End Get
Set(ByVal value As String)
Me.lblCommand.Text = Trim(value)
End Set
End Property
Public Property TextItem() As CNpcParser.NPCTextItem
Get
Return iTextitem
End Get
Set(ByVal value As CNpcParser.NPCTextItem)
NPCText() = value.text
iTextitem = value
End Set
End Property
Public Property Small() As Boolean
Get
Return Not Me.txtText.Multiline
End Get
Set(ByVal value As Boolean)
If value Then
Dim txtheight As Integer = Me.txtText.Size.Height
Me.txtText.Multiline = False
Me.txtText.ScrollBars = ScrollBars.None
Me.Size = New Size(Me.Size.Width, Me.Size.Height - (txtheight - Me.txtText.Size.Height))
End If
End Set
End Property
Private Sub txtText_TextChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtText.TextChanged
RaiseEvent NPCTextChanged(Me, TextItem, NPCText)
End Sub
End Class