VERSION 5.00
Begin VB.Form Form1 
   Caption         =   "Tris By PiratEnzo"
   ClientHeight    =   5070
   ClientLeft      =   60
   ClientTop       =   345
   ClientWidth     =   2775
   LinkTopic       =   "Form1"
   MaxButton       =   0   'False
   ScaleHeight     =   5070
   ScaleWidth      =   2775
   StartUpPosition =   2  'CenterScreen
   Begin VB.Timer Timer3 
      Interval        =   300
      Left            =   1320
      Top             =   2640
   End
   Begin VB.CommandButton Command2 
      Caption         =   "Resetta Punteggi"
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   9.75
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   495
      Left            =   0
      TabIndex        =   13
      Top             =   4560
      Width           =   2775
   End
   Begin VB.Timer Timer2 
      Interval        =   100
      Left            =   1800
      Top             =   2640
   End
   Begin VB.CommandButton Command1 
      Caption         =   "RESET"
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   13.5
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   -1  'True
         Strikethrough   =   0   'False
      EndProperty
      Height          =   495
      Left            =   0
      TabIndex        =   10
      Top             =   3960
      Width           =   2775
   End
   Begin VB.Timer Timer1 
      Interval        =   100
      Left            =   2280
      Top             =   2640
   End
   Begin VB.Label Label14 
      Caption         =   "0"
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   9.75
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   2160
      TabIndex        =   15
      Top             =   3600
      Width           =   615
   End
   Begin VB.Label Label13 
      Caption         =   "0"
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   9.75
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   2160
      TabIndex        =   14
      Top             =   3120
      Width           =   615
   End
   Begin VB.Label Label12 
      Alignment       =   1  'Right Justify
      Caption         =   "Giocatore o --->"
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   9.75
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   120
      TabIndex        =   12
      Top             =   3600
      Width           =   1935
   End
   Begin VB.Label Label11 
      Alignment       =   1  'Right Justify
      Caption         =   "Giocatore x --->"
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   9.75
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   120
      TabIndex        =   11
      Top             =   3120
      Width           =   1935
   End
   Begin VB.Label Label10 
      Alignment       =   2  'Center
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   12
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   615
      Left            =   0
      TabIndex        =   9
      Top             =   2400
      Width           =   2775
   End
   Begin VB.Label Label9 
      Alignment       =   2  'Center
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   24
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   615
      Left            =   1920
      TabIndex        =   8
      Top             =   1680
      Width           =   855
   End
   Begin VB.Label Label8 
      Alignment       =   2  'Center
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   24
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   615
      Left            =   960
      TabIndex        =   7
      Top             =   1680
      Width           =   735
   End
   Begin VB.Label Label7 
      Alignment       =   2  'Center
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   24
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   615
      Left            =   0
      TabIndex        =   6
      Top             =   1680
      Width           =   735
   End
   Begin VB.Label Label6 
      Alignment       =   2  'Center
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   24
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   615
      Left            =   1920
      TabIndex        =   5
      Top             =   840
      Width           =   855
   End
   Begin VB.Label Label5 
      Alignment       =   2  'Center
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   24
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   615
      Left            =   960
      TabIndex        =   4
      Top             =   840
      Width           =   735
   End
   Begin VB.Label Label4 
      Alignment       =   2  'Center
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   24
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   615
      Left            =   0
      TabIndex        =   3
      Top             =   840
      Width           =   735
   End
   Begin VB.Label Label3 
      Alignment       =   2  'Center
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   24
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   615
      Left            =   1920
      TabIndex        =   2
      Top             =   0
      Width           =   855
   End
   Begin VB.Label Label2 
      Alignment       =   2  'Center
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   24
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   615
      Left            =   960
      TabIndex        =   1
      Top             =   0
      Width           =   735
   End
   Begin VB.Label Label1 
      Alignment       =   2  'Center
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   24
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   615
      Left            =   0
      TabIndex        =   0
      Top             =   0
      Width           =   735
   End
   Begin VB.Line Line4 
      BorderWidth     =   3
      X1              =   1800
      X2              =   1800
      Y1              =   0
      Y2              =   2400
   End
   Begin VB.Line Line3 
      BorderWidth     =   3
      X1              =   840
      X2              =   840
      Y1              =   0
      Y2              =   2400
   End
   Begin VB.Line Line2 
      BorderWidth     =   3
      X1              =   0
      X2              =   2760
      Y1              =   1560
      Y2              =   1560
   End
   Begin VB.Line Line1 
      BorderWidth     =   3
      X1              =   0
      X2              =   2760
      Y1              =   720
      Y2              =   720
   End
End
Attribute VB_Name = "Form1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Dim a, b, c As Double



Private Sub Command1_Click()
a = 0
Label1.Caption = ""
Label2.Caption = ""
Label3.Caption = ""
Label4.Caption = ""
Label5.Caption = ""
Label6.Caption = ""
Label7.Caption = ""
Label8.Caption = ""
Label9.Caption = ""
Label1.Enabled = True
Label2.Enabled = True
Label3.Enabled = True
Label4.Enabled = True
Label5.Enabled = True
Label6.Enabled = True
Label7.Enabled = True
Label8.Enabled = True
Label9.Enabled = True
Timer1.Enabled = True
Timer3.Enabled = True


End Sub

Private Sub Command2_Click()
b = 0
c = 0
Label13.Caption = "0"
Label14.Caption = "0"
End Sub

Private Sub Form_Load()
c = 0
b = 0
End Sub

Private Sub Label1_Click()

If Label1.Caption = "" Then
a = a + 1
End If
If a = 2 Then
Label1.Caption = "o"
Else
Label1.Caption = "x"
If a = 4 Then
Label1.Caption = "o"
Else
Label1.Caption = "x"
If a = 6 Then
Label1.Caption = "o"
Else
Label1.Caption = "x"
If a = 8 Then
Label1.Caption = "o"
Else
Label1.Caption = "x"
End If
End If
End If
End If
Label1.Enabled = False

End Sub

Private Sub Label2_Click()

If Label2.Caption = "" Then
a = a + 1
End If
If a = 2 Then
Label2.Caption = "o"
Else
Label2.Caption = "x"
If a = 4 Then
Label2.Caption = "o"
Else
Label2.Caption = "x"
If a = 6 Then
Label2.Caption = "o"
Else
Label2.Caption = "x"
If a = 8 Then
Label2.Caption = "o"
Else
Label2.Caption = "x"
End If
End If
End If
End If
Label2.Enabled = False
End Sub

Private Sub Label3_Click()

If Label3.Caption = "" Then
a = a + 1
End If
If a = 2 Then
Label3.Caption = "o"
Else
Label3.Caption = "x"
If a = 4 Then
Label3.Caption = "o"
Else
Label3.Caption = "x"
If a = 6 Then
Label3.Caption = "o"
Else
Label3.Caption = "x"
If a = 8 Then
Label3.Caption = "o"
Else
Label3.Caption = "x"
End If
End If
End If
End If
Label3.Enabled = False
End Sub

Private Sub Label4_Click()

If Label4.Caption = "" Then
a = a + 1
End If
If a = 2 Then
Label4.Caption = "o"
Else
Label4.Caption = "x"
If a = 4 Then
Label4.Caption = "o"
Else
Label4.Caption = "x"
If a = 6 Then
Label4.Caption = "o"
Else
Label4.Caption = "x"
If a = 8 Then
Label4.Caption = "o"
Else
Label4.Caption = "x"
End If
End If
End If
End If
Label4.Enabled = False
End Sub
Private Sub Label5_Click()

If Label5.Caption = "" Then
a = a + 1
End If
If a = 2 Then
Label5.Caption = "o"
Else
Label5.Caption = "x"
If a = 4 Then
Label5.Caption = "o"
Else
Label5.Caption = "x"
If a = 6 Then
Label5.Caption = "o"
Else
Label5.Caption = "x"
If a = 8 Then
Label5.Caption = "o"
Else
Label5.Caption = "x"
End If
End If
End If
End If
Label5.Enabled = False
End Sub

Private Sub Label6_Click()

If Label6.Caption = "" Then
a = a + 1
End If
If a = 2 Then
Label6.Caption = "o"
Else
Label6.Caption = "x"
If a = 4 Then
Label6.Caption = "o"
Else
Label6.Caption = "x"
If a = 6 Then
Label6.Caption = "o"
Else
Label6.Caption = "x"
If a = 8 Then
Label6.Caption = "o"
Else
Label6.Caption = "x"
End If
End If
End If
End If
Label6.Enabled = False
End Sub

Private Sub Label7_Click()

If Label7.Caption = "" Then
a = a + 1
End If
If a = 2 Then
Label7.Caption = "o"
Else
Label7.Caption = "x"
If a = 4 Then
Label7.Caption = "o"
Else
Label7.Caption = "x"
If a = 6 Then
Label7.Caption = "o"
Else
Label7.Caption = "x"
If a = 8 Then
Label7.Caption = "o"
Else
Label7.Caption = "x"
End If
End If
End If
End If
Label7.Enabled = False
End Sub

Private Sub Label8_Click()

If Label8.Caption = "" Then
a = a + 1
End If
If a = 2 Then
Label8.Caption = "o"
Else
Label8.Caption = "x"
If a = 4 Then
Label8.Caption = "o"
Else
Label8.Caption = "x"
If a = 6 Then
Label8.Caption = "o"
Else
Label8.Caption = "x"
If a = 8 Then
Label8.Caption = "o"
Else
Label8.Caption = "x"
End If
End If
End If
End If
Label8.Enabled = False
End Sub

Private Sub Label9_Click()

If Label9.Caption = "" Then
a = a + 1
End If
If a = 2 Then
Label9.Caption = "o"
Else
Label9.Caption = "x"
If a = 4 Then
Label9.Caption = "o"
Else
Label9.Caption = "x"
If a = 6 Then
Label9.Caption = "o"
Else
Label9.Caption = "x"
If a = 8 Then
Label9.Caption = "o"
Else
Label9.Caption = "x"
End If
End If
End If
End If
Label9.Enabled = False
End Sub

Private Sub Timer1_Timer()
If a = 0 Then
Label10.Caption = "Giocatore x è il tuo turno"
End If
If a = 1 Then
Label10.Caption = "Giocatore o è il tuo turno"
End If
If a = 2 Then
Label10.Caption = "Giocatore x è il tuo turno"
End If
If a = 3 Then
Label10.Caption = "Giocatore o è il tuo turno"
End If
If a = 4 Then
Label10.Caption = "Giocatore x è il tuo turno"
End If
If a = 5 Then
Label10.Caption = "Giocatore o è il tuo turno"
End If
If a = 6 Then
Label10.Caption = "Giocatore x è il tuo turno"
End If
If a = 7 Then
Label10.Caption = "Giocatore o è il tuo turno"
End If
If a = 8 Then
Label10.Caption = "Giocatore x è il tuo turno"
End If


End Sub

Private Sub Timer2_Timer()
If Label1.Caption = "x" And Label2.Caption = "x" And Label3.Caption = "x" Then
Label10.Caption = "Giocatore x HAI VINTO!!!"
Timer1.Enabled = False
Label2.Enabled = False
Label3.Enabled = False
Label4.Enabled = False
Label5.Enabled = False
Label6.Enabled = False
Label7.Enabled = False
Label8.Enabled = False
Label9.Enabled = False
Label1.Enabled = False
Else
If Label4.Caption = "x" And Label5.Caption = "x" And Label6.Caption = "x" Then
Label10.Caption = "Giocatore x HAI VINTO!!!"
Timer1.Enabled = False
Label2.Enabled = False
Label3.Enabled = False
Label4.Enabled = False
Label5.Enabled = False
Label6.Enabled = False
Label7.Enabled = False
Label8.Enabled = False
Label9.Enabled = False
Label1.Enabled = False
Else
If Label7.Caption = "x" And Label8.Caption = "x" And Label9.Caption = "x" Then
Label10.Caption = "Giocatore x HAI VINTO!!!"
Timer1.Enabled = False
Label2.Enabled = False
Label3.Enabled = False
Label4.Enabled = False
Label5.Enabled = False
Label6.Enabled = False
Label7.Enabled = False
Label8.Enabled = False
Label9.Enabled = False
Label1.Enabled = False
Else
If Label1.Caption = "x" And Label4.Caption = "x" And Label7.Caption = "x" Then
Label10.Caption = "Giocatore x HAI VINTO!!!"
Timer1.Enabled = False
Label2.Enabled = False
Label3.Enabled = False
Label4.Enabled = False
Label5.Enabled = False
Label6.Enabled = False
Label7.Enabled = False
Label8.Enabled = False
Label9.Enabled = False
Label1.Enabled = False
Else
If Label2.Caption = "x" And Label5.Caption = "x" And Label8.Caption = "x" Then
Label10.Caption = "Giocatore x HAI VINTO!!!"
Timer1.Enabled = False
Label2.Enabled = False
Label3.Enabled = False
Label4.Enabled = False
Label5.Enabled = False
Label6.Enabled = False
Label7.Enabled = False
Label8.Enabled = False
Label9.Enabled = False
Label1.Enabled = False
Else
If Label3.Caption = "x" And Label6.Caption = "x" And Label9.Caption = "x" Then
Label10.Caption = "Giocatore x HAI VINTO!!!"
Timer1.Enabled = False
Label2.Enabled = False
Label3.Enabled = False
Label4.Enabled = False
Label5.Enabled = False
Label6.Enabled = False
Label7.Enabled = False
Label8.Enabled = False
Label9.Enabled = False
Label1.Enabled = False
Else
If Label1.Caption = "x" And Label5.Caption = "x" And Label9.Caption = "x" Then
Label10.Caption = "Giocatore x HAI VINTO!!!"
Timer1.Enabled = False
Label2.Enabled = False
Label3.Enabled = False
Label4.Enabled = False
Label5.Enabled = False
Label6.Enabled = False
Label7.Enabled = False
Label8.Enabled = False
Label9.Enabled = False
Label1.Enabled = False
Else
If Label3.Caption = "x" And Label5.Caption = "x" And Label7.Caption = "x" Then
Label10.Caption = "Giocatore x HAI VINTO!!!"
Timer1.Enabled = False
Label2.Enabled = False
Label3.Enabled = False
Label4.Enabled = False
Label5.Enabled = False
Label6.Enabled = False
Label7.Enabled = False
Label8.Enabled = False
Label9.Enabled = False
Label1.Enabled = False
Else
If Label1.Caption = "o" And Label2.Caption = "o" And Label3.Caption = "o" Then
Label10.Caption = "Giocatore o HAI VINTO!!!"
Timer1.Enabled = False
Label2.Enabled = False
Label3.Enabled = False
Label4.Enabled = False
Label5.Enabled = False
Label6.Enabled = False
Label7.Enabled = False
Label8.Enabled = False
Label9.Enabled = False
Label1.Enabled = False
Else
If Label4.Caption = "o" And Label5.Caption = "o" And Label6.Caption = "o" Then
Label10.Caption = "Giocatore o HAI VINTO!!!"
Timer1.Enabled = False
Label2.Enabled = False
Label3.Enabled = False
Label4.Enabled = False
Label5.Enabled = False
Label6.Enabled = False
Label7.Enabled = False
Label8.Enabled = False
Label9.Enabled = False
Label1.Enabled = False
Else
If Label7.Caption = "o" And Label8.Caption = "o" And Label9.Caption = "o" Then
Label10.Caption = "Giocatore o HAI VINTO!!!"
Timer1.Enabled = False
Label2.Enabled = False
Label3.Enabled = False
Label4.Enabled = False
Label5.Enabled = False
Label6.Enabled = False
Label7.Enabled = False
Label8.Enabled = False
Label9.Enabled = False
Label1.Enabled = False
Else
If Label1.Caption = "o" And Label4.Caption = "o" And Label7.Caption = "o" Then
Label10.Caption = "Giocatore o HAI VINTO!!!"
Timer1.Enabled = False
Label2.Enabled = False
Label3.Enabled = False
Label4.Enabled = False
Label5.Enabled = False
Label6.Enabled = False
Label7.Enabled = False
Label8.Enabled = False
Label9.Enabled = False
Label1.Enabled = False
Else
If Label2.Caption = "o" And Label5.Caption = "o" And Label8.Caption = "o" Then
Label10.Caption = "Giocatore o HAI VINTO!!!"
Timer1.Enabled = False
Label2.Enabled = False
Label3.Enabled = False
Label4.Enabled = False
Label5.Enabled = False
Label6.Enabled = False
Label7.Enabled = False
Label8.Enabled = False
Label9.Enabled = False
Label1.Enabled = False
Else
If Label3.Caption = "o" And Label6.Caption = "o" And Label9.Caption = "o" Then
Label10.Caption = "Giocatore o HAI VINTO!!!"
Timer1.Enabled = False
Label2.Enabled = False
Label3.Enabled = False
Label4.Enabled = False
Label5.Enabled = False
Label6.Enabled = False
Label7.Enabled = False
Label8.Enabled = False
Label9.Enabled = False
Label1.Enabled = False
Else
If Label1.Caption = "o" And Label5.Caption = "o" And Label9.Caption = "o" Then
Label10.Caption = "Giocatore o HAI VINTO!!!"
Timer1.Enabled = False
Label2.Enabled = False
Label3.Enabled = False
Label4.Enabled = False
Label5.Enabled = False
Label6.Enabled = False
Label7.Enabled = False
Label8.Enabled = False
Label9.Enabled = False
Label1.Enabled = False
Else
If Label3.Caption = "o" And Label5.Caption = "o" And Label7.Caption = "o" Then
Label10.Caption = "Giocatore o HAI VINTO!!!"
Timer1.Enabled = False
Label2.Enabled = False
Label3.Enabled = False
Label4.Enabled = False
Label5.Enabled = False
Label6.Enabled = False
Label7.Enabled = False
Label8.Enabled = False
Label9.Enabled = False
Label1.Enabled = False
Else
If a = 9 Then
Label10.Caption = "Nessun Vincitore"
End If
End If
End If
End If
End If
End If
End If
End If
End If
End If
End If
End If
End If
End If
End If
End If
End If


End Sub

Private Sub Timer3_Timer()
If Label10.Caption = "Giocatore x HAI VINTO!!!" Then
b = b + 1
Timer3.Enabled = False
End If
If Label10.Caption = "Giocatore o HAI VINTO!!!" Then
c = c + 1
Timer3.Enabled = False
End If
Label13.Caption = b
Label14.Caption = c

End Sub
