diff --git a/src/main/java/dev/koifysh/archipelago/Client.java b/src/main/java/dev/koifysh/archipelago/Client.java index 5e45a40..098ead8 100644 --- a/src/main/java/dev/koifysh/archipelago/Client.java +++ b/src/main/java/dev/koifysh/archipelago/Client.java @@ -1,6 +1,7 @@ package dev.koifysh.archipelago; import dev.koifysh.archipelago.events.RetrievedEvent; +import dev.koifysh.archipelago.flags.ItemsHandling; import dev.koifysh.archipelago.network.server.ConnectUpdatePacket; import dev.koifysh.archipelago.network.server.RoomInfoPacket; import dev.koifysh.archipelago.parts.DataPackage; @@ -448,7 +449,7 @@ public Set getTags() { } /** - * fetch the itemflags that have been set, bitwise Or against {@link ItemsHandlingFlags} to read. + * fetch the itemflags that have been set, bitwise Or against {@link ItemsHandling} to read. * @return items handling int. */ public int getItemsHandlingFlags() { @@ -456,7 +457,7 @@ public int getItemsHandlingFlags() { } /** - * fetch the itemflags that have been set, bitwise Or against {@link ItemsHandlingFlags} to read. + * fetch the itemflags that have been set, bitwise Or against {@link ItemsHandling} to read. */ public void setItemsHandlingFlags(int itemsHandlingFlags) { this.itemsHandlingFlags = itemsHandlingFlags; diff --git a/src/main/java/dev/koifysh/archipelago/WebSocket.java b/src/main/java/dev/koifysh/archipelago/WebSocket.java index 40f9142..16f7aa9 100644 --- a/src/main/java/dev/koifysh/archipelago/WebSocket.java +++ b/src/main/java/dev/koifysh/archipelago/WebSocket.java @@ -8,6 +8,7 @@ import dev.koifysh.archipelago.Print.APPrintJsonType; import dev.koifysh.archipelago.Print.APPrintPart; import dev.koifysh.archipelago.Print.APPrintType; +import dev.koifysh.archipelago.flags.NetworkPlayer; import dev.koifysh.archipelago.helper.DeathLink; import dev.koifysh.archipelago.network.APPacket; import dev.koifysh.archipelago.network.ConnectionResult; @@ -17,7 +18,6 @@ import dev.koifysh.archipelago.network.client.SayPacket; import dev.koifysh.archipelago.parts.DataPackage; import dev.koifysh.archipelago.parts.NetworkItem; -import dev.koifysh.archipelago.parts.NetworkPlayer; import dev.koifysh.archipelago.events.*; import dev.koifysh.archipelago.network.server.*; @@ -105,7 +105,7 @@ public void onMessage(String message) { client.setTeam(connectedPacket.team); client.setSlot(connectedPacket.slot); - connectedPacket.slotInfo.put(0, new NetworkSlot("Archipelago", "Archipelago", NetworkPlayerFlags.SPECTATOR)); + connectedPacket.slotInfo.put(0, new NetworkSlot("Archipelago", "Archipelago", NetworkPlayer.SPECTATOR)); client.setSlotInfo(connectedPacket.slotInfo); client.getRoomInfo().networkPlayers.addAll(connectedPacket.players); @@ -115,7 +115,7 @@ public void onMessage(String message) { teams = teamsOptional.getAsInt() + 1; } for (int i = 0; i < teams; i++) { - client.getRoomInfo().networkPlayers.add( new NetworkPlayer(i, 0, "Archipelago")); + client.getRoomInfo().networkPlayers.add( new dev.koifysh.archipelago.parts.NetworkPlayer(i, 0, "Archipelago")); } client.setAlias(client.getRoomInfo().getPlayer(connectedPacket.team, connectedPacket.slot).alias); @@ -161,7 +161,7 @@ public void onMessage(String message) { if (part.type == APPrintType.playerID) { int playerID = Integer.parseInt(part.text); - NetworkPlayer player = client.getRoomInfo().getPlayer(client.getTeam(), playerID); + dev.koifysh.archipelago.parts.NetworkPlayer player = client.getRoomInfo().getPlayer(client.getTeam(), playerID); part.text = player.alias; } else if (part.type == APPrintType.itemID) { diff --git a/src/main/java/dev/koifysh/archipelago/ItemsHandlingFlags.java b/src/main/java/dev/koifysh/archipelago/flags/ItemsHandling.java similarity index 87% rename from src/main/java/dev/koifysh/archipelago/ItemsHandlingFlags.java rename to src/main/java/dev/koifysh/archipelago/flags/ItemsHandling.java index d634c1c..40ee06d 100644 --- a/src/main/java/dev/koifysh/archipelago/ItemsHandlingFlags.java +++ b/src/main/java/dev/koifysh/archipelago/flags/ItemsHandling.java @@ -1,11 +1,13 @@ -package dev.koifysh.archipelago; +package dev.koifysh.archipelago.flags; + +import dev.koifysh.archipelago.Client; /** * Item Flag variables to read {@link Client#getItemsHandlingFlags()} and set {@link Client#setItemsHandlingFlags(int)} *
* Current item flags: {@link #SEND_ITEMS} {@link #SEND_OWN_ITEMS} {@link #SEND_STARTING_INVENTORY} */ -public class ItemsHandlingFlags { +public class ItemsHandling { /** * Tells the server to send you items from other worlds. diff --git a/src/main/java/dev/koifysh/archipelago/NetworkItemFlags.java b/src/main/java/dev/koifysh/archipelago/flags/NetworkItem.java similarity index 88% rename from src/main/java/dev/koifysh/archipelago/NetworkItemFlags.java rename to src/main/java/dev/koifysh/archipelago/flags/NetworkItem.java index f9c7a42..3a2f23c 100644 --- a/src/main/java/dev/koifysh/archipelago/NetworkItemFlags.java +++ b/src/main/java/dev/koifysh/archipelago/flags/NetworkItem.java @@ -1,4 +1,4 @@ -package dev.koifysh.archipelago; +package dev.koifysh.archipelago.flags; /** * Flags that will tell you more about the item that was sent.
@@ -6,7 +6,7 @@ * {@link #USEFUL}, * {@link #TRAP} */ -public class NetworkItemFlags { +public class NetworkItem { /** * If set, indicates the item can unlock logical advancement */ diff --git a/src/main/java/dev/koifysh/archipelago/NetworkPlayerFlags.java b/src/main/java/dev/koifysh/archipelago/flags/NetworkPlayer.java similarity index 86% rename from src/main/java/dev/koifysh/archipelago/NetworkPlayerFlags.java rename to src/main/java/dev/koifysh/archipelago/flags/NetworkPlayer.java index 812b07f..aec898d 100644 --- a/src/main/java/dev/koifysh/archipelago/NetworkPlayerFlags.java +++ b/src/main/java/dev/koifysh/archipelago/flags/NetworkPlayer.java @@ -1,4 +1,4 @@ -package dev.koifysh.archipelago; +package dev.koifysh.archipelago.flags; /** * Flags that will tell you more about the slot type.
@@ -6,7 +6,7 @@ * {@link #PLAYER}, * {@link #GROUP} */ -public class NetworkPlayerFlags { +public class NetworkPlayer { /** * If set, indicates the slot is a spectator */ diff --git a/src/main/java/dev/koifysh/archipelago/parts/NetworkItem.java b/src/main/java/dev/koifysh/archipelago/parts/NetworkItem.java index 64cd972..0031adb 100644 --- a/src/main/java/dev/koifysh/archipelago/parts/NetworkItem.java +++ b/src/main/java/dev/koifysh/archipelago/parts/NetworkItem.java @@ -1,7 +1,6 @@ package dev.koifysh.archipelago.parts; import com.google.gson.annotations.SerializedName; -import dev.koifysh.archipelago.NetworkItemFlags; public class NetworkItem { @@ -15,7 +14,7 @@ public class NetworkItem { public int playerID; /** - * Bit flags that tell you information about the item. bitwise AND them with {@link NetworkItemFlags} to read. + * Bit flags that tell you information about the item. bitwise AND them with {@link dev.koifysh.archipelago.flags.NetworkItem} to read. */ @SerializedName("flags") public int flags;