home *** CD-ROM | disk | FTP | other *** search
- VERSION 5.00
- Begin VB.Form Form1
- Caption = "Form1"
- ClientHeight = 8235
- ClientLeft = 5295
- ClientTop = 1965
- ClientWidth = 6585
- LinkTopic = "Form1"
- ScaleHeight = 8235
- ScaleWidth = 6585
- Begin VB.CommandButton Command3
- Caption = "Delete"
- Height = 255
- Left = 120
- TabIndex = 5
- Top = 3720
- Width = 855
- End
- Begin VB.ListBox List1
- Height = 2790
- Left = 120
- TabIndex = 4
- Top = 840
- Width = 2295
- End
- Begin VB.CommandButton Command2
- Caption = "Add"
- Height = 255
- Left = 2520
- TabIndex = 3
- Top = 480
- Width = 855
- End
- Begin VB.TextBox Text2
- Height = 285
- Left = 120
- TabIndex = 2
- Text = "Attribute"
- Top = 480
- Width = 2295
- End
- Begin VB.CommandButton Command1
- Caption = "Add"
- Height = 255
- Left = 2520
- TabIndex = 1
- Top = 120
- Width = 855
- End
- Begin VB.TextBox Text1
- Height = 285
- Left = 120
- TabIndex = 0
- Text = "Ability"
- Top = 120
- Width = 2295
- End
- Attribute VB_Name = "Form1"
- Attribute VB_GlobalNameSpace = False
- Attribute VB_Creatable = False
- Attribute VB_PredeclaredId = True
- Attribute VB_Exposed = False
- Private Sub Command1_Click()
- Open "Units.Dat" For Input As #1
- Open "TmpUnits.Dat" For Output As #2
- Line Input #1, a$
- If Left$(a$, 6) <> "ATTRIB" Then
- Print #2, a$
- Else
- Exit Do
- End If
- Loop
- Print #2, "ABILITY_" & UCase$(Text1.Text)
- Print #2, a$
- Line Input #1, a$
- If a$ <> "[OBJECTDEFEND]" Then
- Print #2, a$
- Else
- Print #2, a$
- Exit Do
- End If
- Loop
- Line Input #1, a$
- Print #2, a$
- If a$ = "[ENDOFFILE]" Then
- Exit Do
- End If
- Close
- End Sub
- Private Sub Command2_Click()
- Open "Units.Dat" For Input As #1
- Open "TmpUnits.Dat" For Output As #2
- Line Input #1, a$
- If a$ <> "[OBJECTDEFEND]" Then
- Print #2, a$
- Else
- Exit Do
- End If
- Loop
- Print #2, "ATTRIBUTE_" & UCase$(Text2.Text)
- Print #2, a$
- Line Input #1, a$
- Print #2, a$
- If a$ = "[ENDOFFILE]" Then
- Exit Do
- End If
- Close
- End Sub
- Private Sub Command3_Click()
- Open "ObjectFormat.Dat" For Input As #1
- Open "TmpFormat.Dat" For Output As #2
- Line Input #1, a$
- If a$ = "[ENDOFFILE]" Then Exit Do
- If a$ = "[OBJTAGDEF]" Then
- Line Input #1, a$
- If a$ <> List1.List(List1.ListIndex) Then
- Print #2, "[OBJTAGDEF]"
- Print #2, a$
- Do
- Line Input #1, a$
- If a$ <> "[ENDOBJDEF]" Then
- Print #2, a$
- Else
- Print #2, a$
- Exit Do
- End If
- Loop
- Else
- Do
- Line Input #1, a$
- If a$ = "[ENDOBJDEF]" Then
- Exit Do
- End If
- Loop
- End If
- Else
- Print #2, a$
- End If
- Print #2, "[ENDOFFILE]"
- Close
- Open "Units.Dat" For Input As #1
- Open "TmpUnits.Dat" For Output As #2
- Line Input #1, a$
- If a$ = "[ENDOFFILE]" Then Exit Do
- If Left$(a$, Len(List1.List(List1.ListIndex))) <> List1.List(List1.ListIndex) Then
- Print #2, a$
- End If
- Loop
- Print #2, "[ENDOFFILE]"
- Close
- End Sub
- Private Sub Form_Load()
- Open "ObjectFormat.Dat" For Input As #1
- Line Input #1, a$
- If a$ = "[OBJTAGDEF]" Then
- Line Input #1, a$
- List1.AddItem a$
- ElseIf a$ = "[ENDOFFILE]" Then
- Exit Do
- End If
- Close
- End Sub
-