Changeset 418ace2 in galcon-server
- Timestamp:
- Jun 24, 2010, 12:06:53 AM (14 years ago)
- Branches:
- master
- Parents:
- 34ccb37
- Location:
- src
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
src/Connection.java
r34ccb37 r418ace2 17 17 private PrintWriter out; 18 18 private BufferedReader in; 19 private String name;19 private final int ID; 20 20 21 21 22 public Connection(String ip, int port, String threadName ) {22 public Connection(String ip, int port, String threadName,int ID) { 23 23 super(threadName); 24 24 … … 28 28 this.ip = ip; 29 29 this.port = port; 30 this.ID = ID; 30 31 } 31 32 32 public Connection(Socket socket, String threadName ) {33 public Connection(Socket socket, String threadName, int ID) { 33 34 super(threadName); 34 35 … … 36 37 interrupted = false; 37 38 this.socket = socket; 39 this.ID = ID; 38 40 } 39 41 -
src/GameServer.java
r34ccb37 r418ace2 16 16 17 17 public void addConnection(Socket clientSocket) { 18 Connection temp = new Connection(clientSocket,"noob" );18 Connection temp = new Connection(clientSocket,"noob",1); 19 19 temp.start(); 20 20 connections.add(temp);
Note:
See TracChangeset
for help on using the changeset viewer.