📄 frminfo.frm
字号:
VERSION 5.00
Begin VB.Form frmInfo
BackColor = &H00FFFFFF&
BorderStyle = 1 'Fixed Single
Caption = "Info"
ClientHeight = 4020
ClientLeft = 45
ClientTop = 330
ClientWidth = 2775
LinkTopic = "Form1"
MaxButton = 0 'False
MDIChild = -1 'True
MinButton = 0 'False
ScaleHeight = 4020
ScaleWidth = 2775
Begin VB.TextBox txtSongName
Alignment = 1 'Right Justify
Height = 285
Left = 1560
MaxLength = 16
TabIndex = 24
Top = 3600
Width = 1095
End
Begin VB.TextBox txtMapTitle
Alignment = 1 'Right Justify
Height = 285
Left = 1560
MaxLength = 16
TabIndex = 22
Top = 3360
Width = 1095
End
Begin VB.TextBox txtProgress
Alignment = 1 'Right Justify
Height = 285
Left = 1560
MaxLength = 16
TabIndex = 20
Top = 3000
Width = 1095
End
Begin VB.TextBox txtMonster
Alignment = 1 'Right Justify
Height = 285
Index = 3
Left = 1560
MaxLength = 16
TabIndex = 17
Text = "0"
Top = 2760
Width = 1095
End
Begin VB.TextBox txtMonster
Alignment = 1 'Right Justify
Height = 285
Index = 2
Left = 1560
MaxLength = 16
TabIndex = 16
Text = "0"
Top = 2520
Width = 1095
End
Begin VB.TextBox txtMonster
Alignment = 1 'Right Justify
Height = 285
Index = 1
Left = 1560
MaxLength = 16
TabIndex = 15
Text = "0"
Top = 2280
Width = 1095
End
Begin VB.TextBox txtMonster
Alignment = 1 'Right Justify
Height = 285
Index = 0
Left = 1560
MaxLength = 16
TabIndex = 14
Text = "0"
Top = 2040
Width = 1095
End
Begin VB.TextBox txtProbability
Alignment = 1 'Right Justify
Height = 285
Left = 1560
MaxLength = 16
TabIndex = 12
Text = "0"
Top = 1800
Width = 1095
End
Begin VB.TextBox txtPortalDestY
Alignment = 1 'Right Justify
Height = 285
Left = 1560
MaxLength = 16
TabIndex = 10
Top = 1440
Width = 1095
End
Begin VB.TextBox txtPortalDestX
Alignment = 1 'Right Justify
Height = 285
Left = 1560
MaxLength = 16
TabIndex = 8
Top = 1200
Width = 1095
End
Begin VB.TextBox txtPortalMapName
Alignment = 1 'Right Justify
Height = 285
Left = 1560
MaxLength = 16
TabIndex = 6
Top = 960
Width = 1095
End
Begin VB.CheckBox chkWalk
BackColor = &H00FFFFFF&
Caption = "Non-&Walkable?"
Height = 255
Left = 120
TabIndex = 4
Top = 600
Width = 1455
End
Begin VB.Label Label12
BackStyle = 0 'Transparent
Caption = "Song Name:"
Height = 255
Left = 120
TabIndex = 23
Top = 3675
Width = 1455
End
Begin VB.Label Label11
BackStyle = 0 'Transparent
Caption = "Map Title:"
Height = 255
Left = 120
TabIndex = 21
Top = 3435
Width = 1455
End
Begin VB.Label Label10
BackStyle = 0 'Transparent
Caption = "Progress Change:"
Height = 255
Left = 120
TabIndex = 19
Top = 3075
Width = 1455
End
Begin VB.Label Label9
BackStyle = 0 'Transparent
Caption = "Monster 4:"
Height = 255
Left = 120
TabIndex = 18
Top = 2835
Width = 1455
End
Begin VB.Label Label8
BackStyle = 0 'Transparent
Caption = "Monster 1:"
Height = 255
Left = 120
TabIndex = 13
Top = 2115
Width = 1455
End
Begin VB.Label Label7
BackStyle = 0 'Transparent
Caption = "Monster Probability:"
Height = 255
Left = 120
TabIndex = 11
Top = 1905
Width = 1455
End
Begin VB.Label Label6
BackStyle = 0 'Transparent
Caption = "Portal Dest YCoord:"
Height = 255
Left = 120
TabIndex = 9
Top = 1515
Width = 1455
End
Begin VB.Label Label5
BackStyle = 0 'Transparent
Caption = "Portal Dest XCoord:"
Height = 255
Left = 120
TabIndex = 7
Top = 1275
Width = 1455
End
Begin VB.Label Label4
BackStyle = 0 'Transparent
Caption = "Portal Map Name:"
Height = 255
Left = 120
TabIndex = 5
Top = 1035
Width = 1455
End
Begin VB.Label lblInfo
Alignment = 1 'Right Justify
BackStyle = 0 'Transparent
Height = 255
Index = 1
Left = 1560
TabIndex = 3
Top = 360
Width = 1095
End
Begin VB.Label lblInfo
Alignment = 1 'Right Justify
BackStyle = 0 'Transparent
Height = 255
Index = 0
Left = 1560
TabIndex = 2
Top = 120
Width = 1095
End
Begin VB.Label Label2
BackStyle = 0 'Transparent
Caption = "Active Tile-set Tile:"
Height = 255
Left = 120
TabIndex = 1
Top = 360
Width = 1455
End
Begin VB.Label Label1
BackStyle = 0 'Transparent
Caption = "Active Map Tile:"
Height = 255
Left = 120
TabIndex = 0
Top = 120
Width = 1455
End
End
Attribute VB_Name = "frmInfo"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub chkWalk_Click()
'Assign walkable/nonwalkable tiles
If chkWalk.Value = vbChecked Then
gudtMap(gintMapX, gintMapY).blnNonWalkable = True
Else
gudtMap(gintMapX, gintMapY).blnNonWalkable = False
End If
End Sub
Private Sub Form_Load()
'Display the correct info on load
UpdateInfo
End Sub
Public Sub UpdateInfo()
'Display current info
lblInfo(0).Caption = "(" & gintMapX & "," & gintMapY & ")"
lblInfo(1).Caption = "(" & gintTileX & "," & gintTileY & ")"
'Walkable
If gudtMap(gintMapX, gintMapY).blnNonWalkable = True Then
chkWalk.Value = vbChecked
Else
chkWalk.Value = vbUnchecked
End If
'Portal
txtPortalMapName.Text = gudtMap(gintMapX, gintMapY).udtPortal.strMapName
txtPortalDestX.Text = gudtMap(gintMapX, gintMapY).udtPortal.intX
txtPortalDestY.Text = gudtMap(gintMapX, gintMapY).udtPortal.intY
'Monster
txtProbability.Text = gudtMap(gintMapX, gintMapY).udtMonster.bytProbability
txtMonster(0).Text = gudtMap(gintMapX, gintMapY).udtMonster.bytMonster(0)
txtMonster(1).Text = gudtMap(gintMapX, gintMapY).udtMonster.bytMonster(1)
txtMonster(2).Text = gudtMap(gintMapX, gintMapY).udtMonster.bytMonster(2)
txtMonster(3).Text = gudtMap(gintMapX, gintMapY).udtMonster.bytMonster(3)
txtProgress.Text = gudtMap(gintMapX, gintMapY).udtMonster.lngProgChange
'Map title
txtMapTitle.Text = gstrMapName
'Music
txtSongName.Text = gstrMusic
End Sub
Private Sub Form_Unload(Cancel As Integer)
'Check for dirtiness before exiting
Cancel = ExitProgram()
End Sub
Private Sub txtMapTitle_Change()
gstrMapName = txtMapTitle.Text
End Sub
Private Sub txtMonster_LostFocus(Index As Integer)
On Local Error GoTo ErrOut
'If this is a valid monster value, use it
If txtMonster(Index).Text >= 0 And txtMonster(Index).Text <= 255 Then
gudtMap(gintMapX, gintMapY).udtMonster.bytMonster(Index) = txtMonster(Index).Text
Exit Sub
End If
ErrOut:
MsgBox "Enter a value between 0 and 255.", vbOKOnly, "Error"
End Sub
Private Sub txtPortalDestX_Change()
On Local Error Resume Next
gudtMap(gintMapX, gintMapY).udtPortal.intX = txtPortalDestX.Text
End Sub
Private Sub txtPortalDestY_Change()
On Local Error Resume Next
gudtMap(gintMapX, gintMapY).udtPortal.intY = txtPortalDestY.Text
End Sub
Private Sub txtPortalMapName_Change()
gudtMap(gintMapX, gintMapY).udtPortal.strMapName = txtPortalMapName.Text
End Sub
Private Sub txtProbability_LostFocus()
On Local Error GoTo ErrOut
'If this is a valid probability value, use it
If txtProbability.Text >= 0 And txtProbability.Text <= 100 Then
gudtMap(gintMapX, gintMapY).udtMonster.bytProbability = txtProbability.Text
Exit Sub
End If
ErrOut:
MsgBox "Enter a value between 0 and 100.", vbOKOnly, "Error"
End Sub
Private Sub txtProgress_Change()
On Local Error Resume Next
gudtMap(gintMapX, gintMapY).udtMonster.lngProgChange = txtProgress.Text
End Sub
Private Sub txtSongName_Change()
gstrMusic = txtSongName.Text
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -