Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use new RedCore import #527

Merged
merged 1 commit into from
Nov 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import com.paneedah.mwc.network.messages.BalancePackClientMessage;
import com.paneedah.weaponlib.config.BalancePackManager;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import net.minecraftforge.fml.common.network.simpleimpl.IMessage;
import net.minecraftforge.fml.common.network.simpleimpl.IMessageHandler;
import net.minecraftforge.fml.common.network.simpleimpl.MessageContext;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import com.paneedah.mwc.MWC;
import com.paneedah.mwc.network.messages.BlockHitMessage;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import io.redstudioragnarok.redcore.vectors.Vector3F;
import net.minecraft.util.EnumParticleTypes;
import net.minecraftforge.fml.common.network.simpleimpl.IMessage;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import com.paneedah.mwc.network.messages.BloodClientMessage;
import com.paneedah.weaponlib.jim.util.RandomUtil;
import com.paneedah.weaponlib.particle.ParticleBlood;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import io.redstudioragnarok.redcore.vectors.Vector3F;
import net.jafama.FastMath;
import net.minecraftforge.fml.common.network.simpleimpl.IMessage;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import com.paneedah.mwc.network.messages.CraftingClientMessage;
import com.paneedah.mwc.network.messages.CraftingServerMessage;
import com.paneedah.weaponlib.crafting.CraftingFileManager;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import lombok.NoArgsConstructor;
import net.minecraftforge.fml.common.network.simpleimpl.IMessage;
import net.minecraftforge.fml.common.network.simpleimpl.IMessageHandler;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import com.paneedah.mwc.network.messages.CraftingClientMessage;
import com.paneedah.mwc.network.messages.CraftingServerMessage;
import com.paneedah.weaponlib.crafting.CraftingFileManager;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import lombok.NoArgsConstructor;
import net.minecraft.entity.player.EntityPlayerMP;
import net.minecraftforge.fml.common.network.simpleimpl.IMessage;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import com.paneedah.mwc.equipment.inventory.EquipmentInventory;
import com.paneedah.mwc.network.messages.EntityInventorySyncMessage;
import com.paneedah.weaponlib.ModContext;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import lombok.AllArgsConstructor;
import lombok.NoArgsConstructor;
import net.minecraft.entity.Entity;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import com.paneedah.mwc.equipment.inventory.EquipmentInventory;
import com.paneedah.mwc.network.messages.EntityInventorySyncMessage;
import com.paneedah.weaponlib.ModContext;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import lombok.AllArgsConstructor;
import lombok.NoArgsConstructor;
import net.minecraft.entity.player.EntityPlayer;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import com.paneedah.weaponlib.HighIQSpawnEgg;
import com.paneedah.weaponlib.SecondaryEntityRegistry;
import com.paneedah.weaponlib.ai.EntityCustomMob;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import net.minecraft.entity.Entity;
import net.minecraft.entity.player.EntityPlayerMP;
import net.minecraft.item.ItemStack;
Expand All @@ -25,7 +25,7 @@
return;
}

final HighIQSpawnEgg highIQSpawnEgg = (HighIQSpawnEgg) SecondaryEntityRegistry.pickupMap.get(((EntityCustomMob) targetEntity).getConfiguration().getPickupItemID());

Check warning on line 28 in src/main/java/com/paneedah/mwc/network/handlers/EntityPickupMessageHandler.java

View workflow job for this annotation

GitHub Actions / Qodana for JVM

Auto-boxing

Auto-boxing `((EntityCustomMob) targetEntity).getConfiguration().getPickupItemID()`

targetPlayer.addItemStackToInventory(new ItemStack(highIQSpawnEgg));

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.paneedah.mwc.network.handlers;

import com.paneedah.mwc.network.messages.ExplosionMessage;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import io.redstudioragnarok.redcore.vectors.Vector3D;
import lombok.NoArgsConstructor;
import net.minecraft.entity.player.EntityPlayer;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import com.paneedah.mwc.network.messages.ExposureMessage;
import com.paneedah.weaponlib.compatibility.CompatibleExposureCapability;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import net.minecraftforge.fml.common.network.simpleimpl.IMessage;
import net.minecraftforge.fml.common.network.simpleimpl.IMessageHandler;
import net.minecraftforge.fml.common.network.simpleimpl.MessageContext;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import com.paneedah.mwc.network.messages.GrenadeMessage;
import com.paneedah.weaponlib.grenade.GrenadeAttackAspect;
import com.paneedah.weaponlib.grenade.ItemGrenade;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import lombok.AllArgsConstructor;
import lombok.NoArgsConstructor;
import net.minecraft.entity.player.EntityPlayer;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import com.paneedah.mwc.network.messages.LivingEntityTrackerMessage;
import com.paneedah.weaponlib.compatibility.CompatiblePlayerEntityTrackerProvider;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import lombok.NoArgsConstructor;
import net.minecraft.util.text.TextComponentString;
import net.minecraftforge.fml.common.network.simpleimpl.IMessage;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import com.paneedah.mwc.network.messages.MeleeAttackMessage;
import com.paneedah.weaponlib.melee.ItemMelee;
import com.paneedah.weaponlib.melee.MeleeAttackAspect;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import lombok.AllArgsConstructor;
import lombok.NoArgsConstructor;
import net.minecraft.entity.player.EntityPlayer;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import com.paneedah.mwc.network.messages.MuzzleFlashMessage;
import com.paneedah.weaponlib.ClientEventHandler;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import net.minecraftforge.fml.common.network.simpleimpl.IMessage;
import net.minecraftforge.fml.common.network.simpleimpl.IMessageHandler;
import net.minecraftforge.fml.common.network.simpleimpl.MessageContext;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import com.paneedah.mwc.network.messages.NightVisionToggleMessage;
import com.paneedah.weaponlib.CustomArmor;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import net.minecraft.inventory.EntityEquipmentSlot;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.paneedah.mwc.network.handlers;

import com.paneedah.mwc.network.messages.OpenCustomPlayerInventoryGuiMessage;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import lombok.AllArgsConstructor;
import lombok.NoArgsConstructor;
import net.minecraft.entity.player.EntityPlayer;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.paneedah.mwc.network.handlers;

import com.paneedah.mwc.network.messages.OpenDoorMessage;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import net.minecraft.block.state.IBlockState;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.util.EnumFacing;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import com.paneedah.weaponlib.CommonModContext;
import com.paneedah.weaponlib.PlayerItemInstance;
import com.paneedah.weaponlib.state.Permit;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import lombok.AllArgsConstructor;
import lombok.NoArgsConstructor;
import net.minecraftforge.fml.common.network.simpleimpl.IMessage;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import com.paneedah.weaponlib.CommonModContext;
import com.paneedah.weaponlib.PlayerItemInstance;
import com.paneedah.weaponlib.state.Permit;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import lombok.AllArgsConstructor;
import lombok.NoArgsConstructor;
import net.minecraftforge.fml.common.network.simpleimpl.IMessage;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import com.paneedah.mwc.network.messages.ShellMessageClient;
import com.paneedah.weaponlib.ClientEventHandler;
import com.paneedah.weaponlib.render.shells.ShellParticleSimulator.Shell;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import net.minecraft.util.math.Vec3d;
import net.minecraftforge.fml.common.network.simpleimpl.IMessage;
import net.minecraftforge.fml.common.network.simpleimpl.IMessageHandler;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import com.paneedah.mwc.network.messages.SpawnParticleMessage;
import com.paneedah.weaponlib.ModContext;
import com.paneedah.weaponlib.particle.ExplosionSmokeFX;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import io.redstudioragnarok.redcore.vectors.Vector3F;
import lombok.AllArgsConstructor;
import lombok.NoArgsConstructor;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import com.paneedah.mwc.network.messages.SpreadableExposureMessage;
import com.paneedah.weaponlib.SpreadableExposure;
import com.paneedah.weaponlib.compatibility.CompatibleExposureCapability;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import net.minecraftforge.fml.common.network.simpleimpl.IMessage;
import net.minecraftforge.fml.common.network.simpleimpl.IMessageHandler;
import net.minecraftforge.fml.common.network.simpleimpl.MessageContext;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import com.paneedah.mwc.network.messages.TryFireMessage;
import com.paneedah.weaponlib.WeaponFireAspect;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import lombok.AllArgsConstructor;
import lombok.NoArgsConstructor;
import net.minecraftforge.fml.common.network.simpleimpl.IMessage;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import com.paneedah.weaponlib.vehicle.EntityVehicle;
import com.paneedah.weaponlib.vehicle.network.VehicleDataContainer;
import com.paneedah.weaponlib.vehicle.network.VehiclePacketLatencyTracker;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import net.minecraftforge.fml.common.network.simpleimpl.IMessage;
import net.minecraftforge.fml.common.network.simpleimpl.IMessageHandler;
import net.minecraftforge.fml.common.network.simpleimpl.MessageContext;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import com.paneedah.mwc.network.messages.VehicleControlMessage;
import com.paneedah.weaponlib.vehicle.EntityVehicle;
import com.paneedah.weaponlib.vehicle.network.VehicleDataContainer;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import lombok.NoArgsConstructor;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.entity.player.EntityPlayerMP;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import com.paneedah.mwc.network.messages.VehicleInteractMessage;
import com.paneedah.weaponlib.vehicle.EntityVehicle;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraftforge.fml.common.network.simpleimpl.IMessage;
import net.minecraftforge.fml.common.network.simpleimpl.IMessageHandler;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import com.paneedah.mwc.network.messages.WorkbenchClientMessage;
import com.paneedah.weaponlib.crafting.base.TileEntityStation;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import net.minecraft.tileentity.TileEntity;
import net.minecraftforge.fml.common.network.simpleimpl.IMessage;
import net.minecraftforge.fml.common.network.simpleimpl.IMessageHandler;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
import com.paneedah.weaponlib.crafting.base.TileEntityStation;
import com.paneedah.weaponlib.crafting.workbench.TileEntityWorkbench;
import io.redstudioragnarok.redcore.utils.MathUtil;
import io.redstudioragnarok.redcore.utils.NetworkUtil;
import dev.redstudio.redcore.utils.NetworkUtil;
import lombok.NoArgsConstructor;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
Expand Down Expand Up @@ -88,11 +88,11 @@

final int iSCount = iS.getCount();
if (existingCount + iSCount >= requiredCount) {
itemRemovalList.get(stackItem).put(iS, requiredCount - existingCount);

Check warning on line 91 in src/main/java/com/paneedah/mwc/network/handlers/WorkbenchServerMessageHandler.java

View workflow job for this annotation

GitHub Actions / Qodana for JVM

Auto-boxing

Auto-boxing `requiredCount - existingCount`
break;
}

itemRemovalList.get(stackItem).put(iS, iSCount);

Check warning on line 95 in src/main/java/com/paneedah/mwc/network/handlers/WorkbenchServerMessageHandler.java

View workflow job for this annotation

GitHub Actions / Qodana for JVM

Auto-boxing

Auto-boxing `iSCount`
}
}

Expand All @@ -112,7 +112,7 @@
// Remove the items
for (Ingredient i : itemRemovalList.keySet())
for (ItemStack iS : itemRemovalList.get(i).keySet())
iS.shrink(itemRemovalList.get(i).get(iS));

Check warning on line 115 in src/main/java/com/paneedah/mwc/network/handlers/WorkbenchServerMessageHandler.java

View workflow job for this annotation

GitHub Actions / Qodana for JVM

Auto-unboxing

Auto-unboxing `itemRemovalList.get(i).get(iS)`

if (station instanceof TileEntityWorkbench) {
final TileEntityWorkbench workbench = (TileEntityWorkbench) station;
Expand Down
Loading