Skip to content

Commit

Permalink
Fixed the atlas waypoint and issues with atlas packets on a server (#10)
Browse files Browse the repository at this point in the history
  • Loading branch information
Nuchaz committed Feb 12, 2022
1 parent 8029ad1 commit a948368
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
1 change: 1 addition & 0 deletions src/main/java/jds/bibliocraft/ClientProxy.java
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,7 @@
public class ClientProxy extends CommonProxy
{

@SuppressWarnings("unchecked")
public void registerRenderers()
{
MinecraftForge.EVENT_BUS.register(TextureStichHandler.instance);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.nbt.NBTTagList;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.EnumHand;
import net.minecraftforge.common.util.Constants;
import net.minecraftforge.fml.common.network.ByteBufUtils;
Expand Down Expand Up @@ -62,8 +63,10 @@ public IMessage onMessage(BiblioUpdateInv message, MessageContext ctx)
{
for (int i = 0; i <= list.tagCount(); i++)
{
Item testItem = new ItemStack(list.getCompoundTagAt(i)).getItem();
if (!(testItem instanceof ItemEmptyMap || testItem instanceof ItemMap || testItem instanceof ItemWaypointCompass))
ItemStack testStack = new ItemStack(list.getCompoundTagAt(i));
Item testItem = testStack.getItem();
System.out.println(testItem.getUnlocalizedName());
if (!testStack.isEmpty() && !(testItem instanceof ItemEmptyMap || testItem instanceof ItemMap || testItem instanceof ItemWaypointCompass))
{
safe = false;
}
Expand Down

0 comments on commit a948368

Please sign in to comment.