Лабораторная работа: Greating game on visual basic with multiplayer system
Else
Y = 0
For Y = 0 To 8
Layer_A (Y). MouseIcon = LoadResPicture ("o", vbResIcon)
Next Y
Out_Box. Caption = "O's Turn"
End If
End If
LoadComputer
If multiplayermode = True And MyTurn = True Then
'Same as above packs message and sends move to other player
Dim dpmsg2 As DirectPlayMessage
Set dpmsg2 = dxplay. CreateMessage
Call dpmsg2. WriteLong (MSG_MOVE)
Call dpmsg2. WriteByte (Index)
Call dxplay. Send (MyPlayer, DPID_ALLPLAYERS, DPSEND_GUARANTEED, dpmsg2)
End If
End If
Sq_Left = Sq_Left - 1
EvalNextMove
MyTurn = False
End Sub
Public Function layer_A_online (Index As Integer)
playerdisplaylabel. Caption = ""
'This routine is called to mark sqares when remote computer
'sends a move made command.
'Same as above with some redundant routines removed
If Sq_Left Mod 2 = 1 Then
If sw = True Then