home *** CD-ROM | disk | FTP | other *** search
- VERSION 2.00
- Begin Form Myset
- BorderStyle = 3 'Fixed Double
- Caption = "Settings"
- ClientHeight = 3375
- ClientLeft = 1095
- ClientTop = 1485
- ClientWidth = 5895
- Height = 3780
- Icon = 0
- Left = 1035
- LinkMode = 1 'Source
- LinkTopic = "Form1"
- MaxButton = 0 'False
- MinButton = 0 'False
- ScaleHeight = 3375
- ScaleWidth = 5895
- Top = 1140
- Width = 6015
- Begin Frame FrameSave
- Caption = "Save Settings to:"
- Height = 975
- Left = 120
- TabIndex = 28
- Top = 2280
- Width = 5655
- Begin OptionButton OptionSaveWEP
- Caption = "Save to ENTPACK.INI"
- Height = 255
- Left = 3000
- TabIndex = 23
- Top = 600
- Width = 2295
- End
- Begin OptionButton OptionSaveMy
- Caption = "Save to MyMemory.INI"
- Height = 255
- Left = 120
- TabIndex = 21
- Top = 600
- Width = 2295
- End
- Begin OptionButton OptionSaveWIN
- Caption = "Save to WIN.INI"
- Height = 255
- Left = 3000
- TabIndex = 22
- Top = 240
- Width = 1935
- End
- Begin OptionButton OptionSaveNo
- Caption = "Don't Save"
- Height = 255
- Left = 120
- TabIndex = 20
- Top = 240
- Width = 2295
- End
- End
- Begin CheckBox CheckScore
- Caption = "Save Best Score"
- Height = 255
- Left = 3960
- TabIndex = 19
- Top = 1800
- Width = 1935
- End
- Begin Frame FrameTime
- Caption = "Unmatched Pairs Stay Visible (seconds)"
- Height = 615
- Left = 120
- TabIndex = 27
- Top = 1560
- Width = 3735
- Begin OptionButton OptionS5
- Caption = " 5"
- Height = 255
- Left = 3000
- TabIndex = 18
- Top = 240
- Width = 495
- End
- Begin OptionButton OptionS4
- Caption = " 4"
- Height = 255
- Left = 2280
- TabIndex = 17
- Top = 240
- Width = 495
- End
- Begin OptionButton OptionS3
- Caption = " 3"
- Height = 255
- Left = 1560
- TabIndex = 16
- Top = 240
- Width = 495
- End
- Begin OptionButton OptionS2
- Caption = " 2"
- Height = 255
- Left = 840
- TabIndex = 15
- Top = 240
- Width = 495
- End
- Begin OptionButton OptionS1
- Caption = " 1"
- Height = 255
- Left = 120
- TabIndex = 14
- Top = 240
- Width = 495
- End
- End
- Begin CommandButton CmdCancel
- Caption = "Cancel"
- Height = 495
- Left = 4800
- TabIndex = 1
- Top = 960
- Width = 855
- End
- Begin Frame FrameSquare
- Caption = "Square Size (pixels)"
- Height = 615
- Left = 2280
- TabIndex = 26
- Top = 840
- Width = 2295
- Begin OptionButton OptionP48
- Caption = "48"
- Height = 255
- Left = 1560
- TabIndex = 13
- Top = 240
- Width = 615
- End
- Begin OptionButton OptionP40
- Caption = "40"
- Height = 255
- Left = 840
- TabIndex = 12
- Top = 240
- Width = 615
- End
- Begin OptionButton OptionP32
- Caption = "32"
- Height = 255
- Left = 120
- TabIndex = 11
- Top = 240
- Width = 615
- End
- End
- Begin Frame FrameY
- Caption = "Vertical Squares"
- Height = 615
- Left = 120
- TabIndex = 25
- Top = 840
- Width = 2175
- Begin OptionButton OptionV10
- Caption = "10"
- Height = 255
- Left = 1560
- TabIndex = 10
- Top = 240
- Width = 495
- End
- Begin OptionButton OptionV8
- Caption = " 8"
- Height = 255
- Left = 840
- TabIndex = 9
- Top = 240
- Width = 495
- End
- Begin OptionButton OptionV6
- Caption = " 6"
- Height = 255
- Left = 120
- TabIndex = 8
- Top = 240
- Width = 495
- End
- End
- Begin CommandButton CmdOK
- Caption = "OK"
- Default = -1 'True
- Height = 495
- Left = 4800
- TabIndex = 0
- Top = 240
- Width = 855
- End
- Begin Frame FrameX
- Caption = "Horizontal Squares"
- Height = 615
- Left = 120
- TabIndex = 24
- Top = 120
- Width = 4455
- Begin OptionButton OptionH18
- Caption = "18"
- Height = 255
- Left = 3720
- TabIndex = 7
- Top = 240
- Width = 615
- End
- Begin OptionButton OptionH16
- Caption = "16"
- Height = 255
- Left = 3000
- TabIndex = 6
- Top = 240
- Width = 615
- End
- Begin OptionButton OptionH14
- Caption = "14"
- Height = 255
- Left = 2280
- TabIndex = 5
- Top = 240
- Width = 615
- End
- Begin OptionButton OptionH12
- Caption = "12"
- Height = 255
- Left = 1560
- TabIndex = 4
- Top = 240
- Width = 615
- End
- Begin OptionButton OptionH10
- Caption = "10"
- Height = 255
- Left = 840
- TabIndex = 3
- Top = 240
- Width = 615
- End
- Begin OptionButton OptionH8
- Caption = " 8"
- Height = 255
- Left = 120
- TabIndex = 2
- Top = 240
- Width = 615
- End
- End
- Dim TempX As Integer
- Dim TempY As Integer
- Dim TempTime As Single
- Dim TempFile As Integer
- Dim TempScore As Integer
- Dim TempSquare As Integer
- Sub CheckScore_Click ()
- TempScore = CheckScore.Value
- End Sub
- Sub CmdCancel_Click ()
- Unload MySet
- End Sub
- Sub CmdOK_Click ()
- 'Hide Form first so we don't paint screen twice
- ' MySet.Hide
- 'Tell player to wait
- MousePointer = HOURGLASS
- 'One or Both X and Y Values may have changed
- If (TempX <> NumberXSquares) Or (TempY <> NumberYSquares) Or (TempSquare <> SquareSize) Then
- 'see if X size has changed
- If TempX <> 0 Then NumberXSquares = TempX
- 'See if Y has changed
- If TempY <> 0 Then NumberYSquares = TempY
- 'See if Square size has changed
- If TempSquare <> SquareSize Then SquareSize = TempSquare
- 'redimension the arrays
- ReDim SquareStatusArray(NumberXSquares, NumberYSquares)
- ReDim SquareSceneArray(NumberXSquares, NumberYSquares)
- 'Resize form
- ResizeMyMemoryForm
- 'Initialize Field and display
- InitField
- 'Indicate Setup has Changed
- SaveFileChange = True
- End If
- 'see if timer value has changed
- If TempTime <> SetTimer Then
- SetTimer = TempTime
- SaveFileChange = True
- End If
- 'see if ini file has changed
- If TempFile <> SaveFile Then
- SaveFile = TempFile
- SaveFileChange = True
- If SaveFile = SelectSaveFileMy Then
- IniFile = SelectMy
- ElseIf SaveFile = SelectSaveFileWEP Then
- IniFile = SelectWEP
- ElseIf SaveFile = SelectSaveFileWIN Then
- IniFile = SelectWIN
- Else
- IniFile = ""
- End If
- End If
- 'Indicate change to save score
- If TempScore <> SaveScore Then
- SaveScore = TempScore
- SaveFileChange = True
- End If
- 'done
- MousePointer = DEFAULT
- Unload MySet
- End Sub
- Sub OptionH10_Click ()
- TempX = 10
- ReCheckValidY
- End Sub
- Sub OptionH12_Click ()
- TempX = 12
- ReCheckValidY
- End Sub
- Sub OptionH14_Click ()
- TempX = 14
- ReCheckValidY
- End Sub
- Sub OptionH16_Click ()
- TempX = 16
- ReCheckValidY
- End Sub
- Sub OptionH18_Click ()
- TempX = 18
- ReCheckValidY
- End Sub
- Sub OptionH8_Click ()
- TempX = 8
- ReCheckValidY
- End Sub
- Sub OptionP32_Click ()
- TempSquare = 32
- ReCheckValid
- End Sub
- Sub OptionP40_Click ()
- TempSquare = 40
- ReCheckValid
- End Sub
- Sub OptionP48_Click ()
- TempSquare = 48
- ReCheckValid
- End Sub
- Sub OptionS1_Click ()
- TempTime = 1
- End Sub
- Sub OptionS2_Click ()
- TempTime = 2
- End Sub
- Sub OptionS3_Click ()
- TempTime = 3
- End Sub
- Sub OptionS4_Click ()
- TempTime = 4
- End Sub
- Sub OptionS5_Click ()
- TempTime = 5
- End Sub
- Sub OptionSaveMy_Click ()
- TempFile = SelectSaveFileMy
- CheckScore.Enabled = True
- CheckScore.Value = CHECKED
- TempScore = CHECKED
- End Sub
- Sub OptionSaveNo_Click ()
- TempFile = SelectSaveFileNo
- CheckScore.Enabled = False
- CheckScore.Value = UNCHECKED
- TempScore = UNCHECKED
- End Sub
- Sub OptionSaveWEP_Click ()
- TempFile = SelectSaveFileWEP
- CheckScore.Enabled = True
- CheckScore.Value = CHECKED
- TempScore = CHECKED
- End Sub
- Sub OptionSaveWIN_Click ()
- TempFile = SelectSaveFileWIN
- CheckScore.Enabled = True
- CheckScore.Value = CHECKED
- TempScore = CHECKED
- End Sub
- Sub OptionV10_Click ()
- TempY = 10
- End Sub
- Sub OptionV6_Click ()
- TempY = 6
- End Sub
- Sub OptionV8_Click ()
- TempY = 8
- End Sub
- Sub ReCheckValid ()
- 'recheck X values to see which are valid with square size
- 'Check option for 18 squares across
- If TempSquare * 18 < ScreenPixelSizeX Then
- OptionH18.Enabled = True
- Else
- 'If item selected reduce to next lower selection
- If OptionH18.Value = True Then
- OptionH18.Value = False
- OptionH16.Value = True
- End If
- OptionH18.Enabled = False
- End If
- 'Check option for 16 squares across
- If TempSquare * 16 < ScreenPixelSizeX Then
- OptionH16.Enabled = True
- Else
- 'If item selected reduce to next lower selection
- If OptionH16.Value = True Then
- OptionH16.Value = False
- OptionH14.Value = True
- End If
- OptionH16.Enabled = False
- End If
- 'Check option for 14 squares across
- If TempSquare * 14 < ScreenPixelSizeX Then
- OptionH14.Enabled = True
- Else
- 'If item selected reduce to next lower selection
- If OptionH14.Value = True Then
- OptionH14.Value = False
- OptionH12.Value = True
- End If
- OptionH14.Enabled = False
- End If
- 'this routine assumes minimum X pixel size of 640
- 'so it doesn't check options using less than 14 squares across
- '( 12 * 48 = 576 which is less than 640)
- ReCheckValidY
- End Sub
- Sub ReCheckValidY ()
- If (TempX = 0 And NumberXSquares < 12) Or TempX = 8 Or TempX = 10 Then
- FieldY% = (FormLabel * 3) + (FormHeader / TwipsPerPixel)
- Else
- FieldY% = (FormLabel * 2) + (FormHeader / TwipsPerPixel)
- End If
- 'Check option for 10 squares down
- If TempSquare * 10 + FieldY% < ScreenPixelSizeY Then
- OptionV10.Enabled = True
- Else
- 'If item selected reduce to next lower selection
- If OptionV10.Value = True Then
- OptionV10.Value = False
- OptionV8.Value = True
- End If
- OptionV10.Enabled = False
- End If
- 'Check option for 8 squares down
- If TempSquare * 8 + FieldY% < ScreenPixelSizeY Then
- OptionV8.Enabled = True
- Else
- 'If item selected reduce to next lower selection
- If OptionV8.Value = True Then
- OptionV8.Value = False
- OptionV6.Value = True
- End If
- OptionV8.Enabled = False
- End If
- End Sub
-