knew there'd be a nms update

This commit is contained in:
Telesphoreo 2020-11-02 23:33:04 -06:00
parent d0acfcf674
commit 43c2df58c7
5 changed files with 19 additions and 19 deletions

View File

@ -167,7 +167,7 @@
<dependency> <dependency>
<groupId>org.spigotmc</groupId> <groupId>org.spigotmc</groupId>
<artifactId>spigot</artifactId> <artifactId>spigot</artifactId>
<version>1.16.3-R0.1-SNAPSHOT</version> <version>1.16.4-R0.1-SNAPSHOT</version>
<scope>provided</scope> <scope>provided</scope>
</dependency> </dependency>
@ -188,7 +188,7 @@
<dependency> <dependency>
<groupId>com.sk89q.worldedit</groupId> <groupId>com.sk89q.worldedit</groupId>
<artifactId>worldedit-bukkit</artifactId> <artifactId>worldedit-bukkit</artifactId>
<version>7.2.0-SNAPSHOT</version> <version>7.3.0-SNAPSHOT</version>
<scope>provided</scope> <scope>provided</scope>
</dependency> </dependency>

View File

@ -6,12 +6,12 @@ import ca.momothereal.mojangson.value.MojangsonValue;
import io.papermc.lib.PaperLib; import io.papermc.lib.PaperLib;
import java.util.List; import java.util.List;
import java.util.Objects; import java.util.Objects;
import net.minecraft.server.v1_16_R2.NBTTagCompound; import net.minecraft.server.v1_16_R3.NBTTagCompound;
import net.minecraft.server.v1_16_R2.NBTTagList; import net.minecraft.server.v1_16_R3.NBTTagList;
import org.bukkit.ChatColor; import org.bukkit.ChatColor;
import org.bukkit.Location; import org.bukkit.Location;
import org.bukkit.Material; import org.bukkit.Material;
import org.bukkit.craftbukkit.v1_16_R2.inventory.CraftItemStack; import org.bukkit.craftbukkit.v1_16_R3.inventory.CraftItemStack;
import org.bukkit.entity.Player; import org.bukkit.entity.Player;
import org.bukkit.event.EventHandler; import org.bukkit.event.EventHandler;
import org.bukkit.event.EventPriority; import org.bukkit.event.EventPriority;
@ -132,7 +132,7 @@ public class MovementValidator extends FreedomService
private Boolean exploitItem(ItemStack item) private Boolean exploitItem(ItemStack item)
{ {
net.minecraft.server.v1_16_R2.ItemStack nmsStack = CraftItemStack.asNMSCopy(item); net.minecraft.server.v1_16_R3.ItemStack nmsStack = CraftItemStack.asNMSCopy(item);
NBTTagList modifiers = getAttributeList(nmsStack); NBTTagList modifiers = getAttributeList(nmsStack);
MojangsonCompound compound = new MojangsonCompound(); MojangsonCompound compound = new MojangsonCompound();
boolean foundNegative = false; boolean foundNegative = false;
@ -169,7 +169,7 @@ public class MovementValidator extends FreedomService
} }
private NBTTagList getAttributeList(net.minecraft.server.v1_16_R2.ItemStack stack) private NBTTagList getAttributeList(net.minecraft.server.v1_16_R3.ItemStack stack)
{ {
if (stack.getTag() == null) if (stack.getTag() == null)
{ {

View File

@ -4,14 +4,14 @@ import java.util.Arrays;
import java.util.List; import java.util.List;
import me.totalfreedom.totalfreedommod.util.FLog; import me.totalfreedom.totalfreedommod.util.FLog;
import me.totalfreedom.totalfreedommod.util.FUtil; import me.totalfreedom.totalfreedommod.util.FUtil;
import net.minecraft.server.v1_16_R2.EntityPlayer; import net.minecraft.server.v1_16_R3.EntityPlayer;
import net.minecraft.server.v1_16_R2.MinecraftServer; import net.minecraft.server.v1_16_R3.MinecraftServer;
import org.bukkit.Bukkit; import org.bukkit.Bukkit;
import org.bukkit.craftbukkit.v1_16_R2.CraftServer; import org.bukkit.craftbukkit.v1_16_R3.CraftServer;
public class ServerInterface extends FreedomService public class ServerInterface extends FreedomService
{ {
public static final String COMPILE_NMS_VERSION = "v1_16_R2"; public static final String COMPILE_NMS_VERSION = "v1_16_R3";
@Override @Override
public void onStart() public void onStart()

View File

@ -1,10 +1,10 @@
package me.totalfreedom.totalfreedommod.blocking; package me.totalfreedom.totalfreedommod.blocking;
import me.totalfreedom.totalfreedommod.FreedomService; import me.totalfreedom.totalfreedommod.FreedomService;
import net.minecraft.server.v1_16_R2.NBTTagCompound; import net.minecraft.server.v1_16_R3.NBTTagCompound;
import org.bukkit.ChatColor; import org.bukkit.ChatColor;
import org.bukkit.Tag; import org.bukkit.Tag;
import org.bukkit.craftbukkit.v1_16_R2.inventory.CraftItemStack; import org.bukkit.craftbukkit.v1_16_R3.inventory.CraftItemStack;
import org.bukkit.entity.Player; import org.bukkit.entity.Player;
import org.bukkit.event.EventHandler; import org.bukkit.event.EventHandler;
import org.bukkit.event.EventPriority; import org.bukkit.event.EventPriority;
@ -35,7 +35,7 @@ public class SignBlocker extends FreedomService
if (Tag.SIGNS.getValues().contains(event.getBlock().getType())) if (Tag.SIGNS.getValues().contains(event.getBlock().getType()))
{ {
ItemStack sign = event.getItemInHand(); ItemStack sign = event.getItemInHand();
net.minecraft.server.v1_16_R2.ItemStack nmsSign = CraftItemStack.asNMSCopy(sign); net.minecraft.server.v1_16_R3.ItemStack nmsSign = CraftItemStack.asNMSCopy(sign);
NBTTagCompound compound = (nmsSign.hasTag()) ? nmsSign.getTag() : new NBTTagCompound(); NBTTagCompound compound = (nmsSign.hasTag()) ? nmsSign.getTag() : new NBTTagCompound();
NBTTagCompound bet = compound.getCompound("BlockEntityTag"); NBTTagCompound bet = compound.getCompound("BlockEntityTag");
String line1 = bet.getString("Text1"); String line1 = bet.getString("Text1");

View File

@ -5,13 +5,13 @@ import java.util.List;
import java.util.Random; import java.util.Random;
import me.totalfreedom.totalfreedommod.rank.Rank; import me.totalfreedom.totalfreedommod.rank.Rank;
import me.totalfreedom.totalfreedommod.util.FUtil; import me.totalfreedom.totalfreedommod.util.FUtil;
import net.minecraft.server.v1_16_R2.NBTTagCompound; import net.minecraft.server.v1_16_R3.NBTTagCompound;
import net.minecraft.server.v1_16_R2.NBTTagList; import net.minecraft.server.v1_16_R3.NBTTagList;
import org.apache.commons.lang.StringUtils; import org.apache.commons.lang.StringUtils;
import org.bukkit.Material; import org.bukkit.Material;
import org.bukkit.command.Command; import org.bukkit.command.Command;
import org.bukkit.command.CommandSender; import org.bukkit.command.CommandSender;
import org.bukkit.craftbukkit.v1_16_R2.inventory.CraftItemStack; import org.bukkit.craftbukkit.v1_16_R3.inventory.CraftItemStack;
import org.bukkit.enchantments.Enchantment; import org.bukkit.enchantments.Enchantment;
import org.bukkit.entity.Player; import org.bukkit.entity.Player;
import org.bukkit.inventory.ItemStack; import org.bukkit.inventory.ItemStack;
@ -149,7 +149,7 @@ public class Command_modifyitem extends FreedomCommand
{ {
return false; return false;
} }
net.minecraft.server.v1_16_R2.ItemStack nmsStack = CraftItemStack.asNMSCopy(item); net.minecraft.server.v1_16_R3.ItemStack nmsStack = CraftItemStack.asNMSCopy(item);
NBTTagCompound compound = (nmsStack.hasTag()) ? nmsStack.getTag() : new NBTTagCompound(); NBTTagCompound compound = (nmsStack.hasTag()) ? nmsStack.getTag() : new NBTTagCompound();
NBTTagList modifiers = getAttributeList(nmsStack); NBTTagList modifiers = getAttributeList(nmsStack);
NBTTagCompound cmpnd = new NBTTagCompound(); NBTTagCompound cmpnd = new NBTTagCompound();
@ -199,7 +199,7 @@ public class Command_modifyitem extends FreedomCommand
return true; return true;
} }
private NBTTagList getAttributeList(net.minecraft.server.v1_16_R2.ItemStack stack) private NBTTagList getAttributeList(net.minecraft.server.v1_16_R3.ItemStack stack)
{ {
if (stack.getTag() == null) if (stack.getTag() == null)
{ {