fly command allowing anyone to fly might not work not sure

This commit is contained in:
2026-09-20 05:26:42 +01:00
parent 830633222a
commit ee56a07278
14 changed files with 61 additions and 3 deletions
@@ -29,6 +29,7 @@ public class EntityPlayer extends EntityHuman implements ICrafting {
private ItemStack[] bN = new ItemStack[]{null, null, null, null, null};
private int bO = 0;
public boolean h;
public boolean flightAllowed;
public EntityPlayer(MinecraftServer minecraftserver, World world, String s, ItemInWorldManager iteminworldmanager) {
super(world);
@@ -65,6 +66,18 @@ public class EntityPlayer extends EntityHuman implements ICrafting {
public org.bukkit.Location compassTarget;
// CraftBukkit end
@Override
public void a(NBTTagCompound nbttagcompound) {
super.a(nbttagcompound);
this.flightAllowed = nbttagcompound.m("FlightAllowed");
}
@Override
public void b(NBTTagCompound nbttagcompound) {
super.b(nbttagcompound);
nbttagcompound.a("FlightAllowed", this.flightAllowed);
}
public void spawnIn(World world) {
super.spawnIn(world);
// CraftBukkit - world fallback code, either respawn location or global spawn