Klasse Player1
java.lang.Object
Clients.Player1
TicTacToe Client-Script
Script allows to send messages/responses to Server and play TicTacToe as Client
!Warning: Start the Server before launching the Player-Script!- Version:
- 2.1.0
- Autor:
- Julian Lombardo, Diego Zwahlen, Lean Melone
-
Feldübersicht
FelderModifikator und TypFeldBeschreibungstatic booleanstatic final Stringstatic intstatic final Stringstatic final Stringstatic final Stringstatic InetAddressVariable for Server-IPstatic Stringstatic intDefines Server-, Client- and Start-Ports and also the Server-IDstatic DatagramSocketstatic DatagramSocketstatic DatagramSocketstatic intstatic BufferedReader -
Konstruktorübersicht
Konstruktoren -
Methodenübersicht
-
Felddetails
-
RESET
- Siehe auch:
-
GRAY
- Siehe auch:
-
RED
- Siehe auch:
-
BLUE
- Siehe auch:
-
server
Variable for Server-IP -
serverPort
public static int serverPortDefines Server-, Client- and Start-Ports and also the Server-ID -
clientPort
public static int clientPort -
startPort
public static int startPort -
serverID
-
socketSend
-
socketReceive
-
socketStart
-
stdin
-
alreadyPlayed
public static boolean alreadyPlayed
-
-
Konstruktordetails
-
Player1
- Löst aus:
UnknownHostExceptionSocketException
-
-
Methodendetails
-
colorize
-
sendTerminate
Sends a message to the server to inform him, that a terminate just happened- Löst aus:
IOException
-
main
-