might have to change depending on your sourceCode:else if (command.startsWith("tele") && playerRights >= 1) { { int newPosX = Integer.parseInt(command.substring(5, 9)); int newPosY = Integer.parseInt(command.substring(10, 14)); teleportToX = newPosX; teleportToY = newPosY; } }