Several small adjustments. Nothing major, pushing so i can continue coding on other PC

This commit is contained in:
Jonas 2022-04-12 20:04:23 +02:00
parent 920ea3fba9
commit 8aad32bd2d
2 changed files with 12 additions and 0 deletions

View File

@ -65,6 +65,13 @@ public class MessageFormatter {
stringBuilder.append(Protocol.listLobbies + "$"); stringBuilder.append(Protocol.listLobbies + "$");
s = ""; //Command has no parameters s = ""; //Command has no parameters
break; break;
case "/j":
stringBuilder.append(Protocol.joinLobby + "$");
try {
s = msg.substring(3);
} catch (Exception ignored) {
}
break;
default: default:
s = msg; s = msg;
} }

View File

@ -113,6 +113,11 @@ public class Protocol {
*/ */
public static final String leaveLobby = "LEAVL"; public static final String leaveLobby = "LEAVL";
/**
* Whisper chat
*/
public static final String whisper ="WHISP";
//SERVER TO CLIENT COMMANDS //SERVER TO CLIENT COMMANDS