aboutsummaryrefslogtreecommitdiff
path: root/src/ch/epfl
diff options
context:
space:
mode:
Diffstat (limited to 'src/ch/epfl')
-rw-r--r--src/ch/epfl/xblast/client/GameStateDeserializer.java7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/ch/epfl/xblast/client/GameStateDeserializer.java b/src/ch/epfl/xblast/client/GameStateDeserializer.java
index 143641d..2c06dbc 100644
--- a/src/ch/epfl/xblast/client/GameStateDeserializer.java
+++ b/src/ch/epfl/xblast/client/GameStateDeserializer.java
@@ -190,6 +190,13 @@ public final class GameStateDeserializer {
190 .collect(Collectors.toList())); 190 .collect(Collectors.toList()));
191 } 191 }
192 192
193 /**
194 * Unserializes a byte representation of the ticks.
195 *
196 * @param serializedTicks the serialized ticks
197 * @return the ticks
198 * @throws IllegalArgumentException if the byte chunk is invalid.
199 */
193 private static int deserializeTicks(List<Byte> serializedTicks) { 200 private static int deserializeTicks(List<Byte> serializedTicks) {
194 if (Objects.isNull(serializedTicks) || serializedTicks.size() != SERIALIZED_TICKS_LENGTH) 201 if (Objects.isNull(serializedTicks) || serializedTicks.size() != SERIALIZED_TICKS_LENGTH)
195 throw new IllegalArgumentException(); 202 throw new IllegalArgumentException();