Update MCP mappings to snapshot_nodoc_20161220 (#3551)

This commit is contained in:
James Mitchell authored and LexManos committed 2016-12-21 15:52:30 -08:00
1 parent 1f4007e5d8
commit 5165dc52bf
88 files changed
+445 -436

No files matched your search

@@ -19,6 +19,6 @@ public class BreedingTest
@SubscribeEvent
public void onBabyBorn(BabyEntitySpawnEvent event) {
event.setChild(new EntityCow(event.getParentA().worldObj));
event.setChild(new EntityCow(event.getParentA().world));
}
}
@@ -268,7 +268,7 @@ public class DynBucketTest
return false;
}
if (heldItem.func_190926_b())
if (heldItem.isEmpty())
{
sendText(playerIn, tank);
return false;
@@ -290,7 +290,7 @@ public class DynBucketTest
private void sendText(EntityPlayer player, IFluidHandler tank)
{
if (player.worldObj.isRemote)
if (player.world.isRemote)
{
String text;
IFluidTankProperties[] tankProperties = tank.getTankProperties();
@@ -301,7 +301,7 @@ public class DynBucketTest
{
text = "empty";
}
player.addChatMessage(new TextComponentString(text));
player.sendMessage(new TextComponentString(text));
}
}
}
@@ -167,7 +167,7 @@ public class FluidPlacementTest
@Override
public int fill(FluidStack resource, boolean doFill)
{
if (container.func_190916_E() != 1 || resource == null || resource.amount > Fluid.BUCKET_VOLUME || container
if (container.getCount() != 1 || resource == null || resource.amount > Fluid.BUCKET_VOLUME || container
.getItem() instanceof ItemBucketMilk || getFluid() != null || !canFillFluidType(resource))
{
return 0;
@@ -96,7 +96,7 @@ public class ItemLayerModelDebug
@Override
public int getHarvestLevel(ItemStack stack, String toolClass, @Nullable EntityPlayer player, @Nullable IBlockState blockState) {
// This tool is a super pickaxe if the player is wearing a helment
if("pickaxe".equals(toolClass) && player != null && !player.getItemStackFromSlot(EntityEquipmentSlot.HEAD).func_190926_b()) {
if("pickaxe".equals(toolClass) && player != null && !player.getItemStackFromSlot(EntityEquipmentSlot.HEAD).isEmpty()) {
return 5;
}
return super.getHarvestLevel(stack, toolClass, player, blockState);
@@ -136,7 +136,7 @@ public class ItemTileDebug
public boolean isFullCube(IBlockState state) { return false; }
@Override
public boolean isVisuallyOpaque(IBlockState state) { return false; }
public boolean causesSuffocation(IBlockState state) { return false; }
@Override
public TileEntity createNewTileEntity(World world, int meta)
@@ -101,9 +101,9 @@ public class ModelAnimationDebug
public boolean isFullCube(IBlockState state) { return false; }
@Override
public IBlockState onBlockPlaced(World world, BlockPos pos, EnumFacing facing, float hitX, float hitY, float hitZ, int meta, EntityLivingBase placer)
public IBlockState getStateForPlacement(World world, BlockPos pos, EnumFacing facing, float hitX, float hitY, float hitZ, int meta, EntityLivingBase placer)
{
return this.getDefaultState().withProperty(FACING, EnumFacing.func_190914_a(pos, placer));
return this.getDefaultState().withProperty(FACING, EnumFacing.getDirectionFromEntityLiving(pos, placer));
}
@Override
@@ -383,7 +383,7 @@ public class ModelAnimationDebug
public void onEntityUpdate()
{
super.onEntityUpdate();
if(worldObj.isRemote && cycleLength != null)
if (world.isRemote && cycleLength != null)
{
cycleLength.setValue(getHealth() / 5);
}
@@ -149,7 +149,7 @@ public class ModelBakeEventDebug
public boolean isFullCube(IBlockState state) { return false; }
@Override
public boolean isVisuallyOpaque(IBlockState state) { return false; }
public boolean causesSuffocation(IBlockState state) { return false; }
@Override
public TileEntity createNewTileEntity(World world, int meta)
@@ -139,10 +139,10 @@ public class ModelLoaderRegistryDebug
public boolean isFullCube(IBlockState state) { return false; }
@Override
public boolean isVisuallyOpaque(IBlockState state) { return false; }
public boolean causesSuffocation(IBlockState state) { return false; }
@Override
public IBlockState onBlockPlaced(World world, BlockPos pos, EnumFacing facing, float hitX, float hitY, float hitZ, int meta, EntityLivingBase placer)
public IBlockState getStateForPlacement(World world, BlockPos pos, EnumFacing facing, float hitX, float hitY, float hitZ, int meta, EntityLivingBase placer)
{
return this.getDefaultState().withProperty(FACING, getFacingFromEntity(world, pos, placer));
}
@@ -244,7 +244,7 @@ public class ModelLoaderRegistryDebug
public boolean isFullCube(IBlockState state) { return false; }
@Override
public boolean isVisuallyOpaque(IBlockState state) { return false; }
public boolean causesSuffocation(IBlockState state) { return false; }
@Override
public boolean onBlockActivated(World world, BlockPos pos, IBlockState state, EntityPlayer player, EnumHand hand, EnumFacing side, float hitX, float hitY, float hitZ)
@@ -329,7 +329,7 @@ public class ModelLoaderRegistryDebug
this.counter++;
this.hidden.add(Integer.toString(this.counter));
TextComponentString text = new TextComponentString("" + this.counter);
if (this.worldObj.isRemote) Minecraft.getMinecraft().ingameGUI.getChatGUI().printChatMessage(text);
if (this.world.isRemote) Minecraft.getMinecraft().ingameGUI.getChatGUI().printChatMessage(text);
}
public void decrement()
@@ -342,7 +342,7 @@ public class ModelLoaderRegistryDebug
this.hidden.remove(Integer.toString(this.counter));
this.counter--;
TextComponentString text = new TextComponentString("" + this.counter);
if (this.worldObj.isRemote) Minecraft.getMinecraft().ingameGUI.getChatGUI().printChatMessage(text);
if (this.world.isRemote) Minecraft.getMinecraft().ingameGUI.getChatGUI().printChatMessage(text);
}
public void setMax(int max)
@@ -381,7 +381,7 @@ public class ModelLoaderRegistryDebug
public boolean isFullCube(IBlockState state) { return false; }
@Override
public boolean isVisuallyOpaque(IBlockState state) { return false; }
public boolean causesSuffocation(IBlockState state) { return false; }
}
/**
@@ -408,7 +408,7 @@ public class ModelLoaderRegistryDebug
}
@Override
public IBlockState onBlockPlaced(World world, BlockPos pos, EnumFacing facing, float hitX, float hitY, float hitZ, int meta, EntityLivingBase placer)
public IBlockState getStateForPlacement(World world, BlockPos pos, EnumFacing facing, float hitX, float hitY, float hitZ, int meta, EntityLivingBase placer)
{
return this.getDefaultState().withProperty(FACING, getFacingFromEntity(world, pos, placer));
}
@@ -438,7 +438,7 @@ public class ModelLoaderRegistryDebug
public boolean isFullCube(IBlockState state) { return false; }
@Override
public boolean isVisuallyOpaque(IBlockState state) { return false; }
public boolean causesSuffocation(IBlockState state) { return false; }
public static EnumFacing getFacingFromEntity(World worldIn, BlockPos clickedBlock, EntityLivingBase entityIn)
{
@@ -511,11 +511,11 @@ public class ModelLoaderRegistryDebug
public void cycleColors()
{
if (this.worldObj.isRemote)
if (this.world.isRemote)
{
FMLLog.info("%b", shouldIncrement);
/*
IBakedModel bakedModel = Minecraft.getMinecraft().getBlockRendererDispatcher().getModelFromBlockState(this.worldObj.getBlockState(this.pos), this.worldObj, this.pos);
IBakedModel bakedModel = Minecraft.getMinecraft().getBlockRendererDispatcher().getModelFromBlockState(this.world.getBlockState(this.pos), this.world, this.pos);
if (bakedModel != null && bakedModel instanceof OBJBakedModel)
{
OBJBakedModel objBaked = (OBJBakedModel) bakedModel;
@@ -558,7 +558,7 @@ public class ModelLoaderRegistryDebug
objBaked.scheduleRebake();
}
}
this.worldObj.markBlockRangeForRenderUpdate(this.pos, this.pos);
this.world.markBlockRangeForRenderUpdate(this.pos, this.pos);
}*/
}
}
@@ -591,10 +591,10 @@ public class ModelLoaderRegistryDebug
public boolean isFullCube(IBlockState state) { return false; }
@Override
public boolean isVisuallyOpaque(IBlockState state) { return false; }
public boolean causesSuffocation(IBlockState state) { return false; }
@Override
public IBlockState onBlockPlaced(World world, BlockPos pos, EnumFacing facing, float hitX, float hitY, float hitZ, int meta, EntityLivingBase placer)
public IBlockState getStateForPlacement(World world, BlockPos pos, EnumFacing facing, float hitX, float hitY, float hitZ, int meta, EntityLivingBase placer)
{
return this.getDefaultState().withProperty(FACING, getFacingFromEntity(world, pos, placer));
}
@@ -769,10 +769,10 @@ public class ModelLoaderRegistryDebug
@Override
public void update()
{
if (this.worldObj.isRemote)
if (this.world.isRemote)
{
Vector3d teLoc = new Vector3d(this.getPos().getX(), this.getPos().getY(), this.getPos().getZ());
EntityPlayer player = Minecraft.getMinecraft().thePlayer;
EntityPlayer player = Minecraft.getMinecraft().player;
Vector3d playerLoc = new Vector3d();
playerLoc.setX(player.posX);
playerLoc.setY(player.posY + player.getEyeHeight());
@@ -793,7 +793,7 @@ public class ModelLoaderRegistryDebug
matrix.setIdentity();
matrix.setRotation(rot);
transform = TRSRTransformation.blockCenterToCorner(new TRSRTransformation(matrix));
this.worldObj.markBlockRangeForRenderUpdate(this.pos, this.pos);
this.world.markBlockRangeForRenderUpdate(this.pos, this.pos);
}
}
}
@@ -28,13 +28,13 @@ public class ClientCommandTest {
private class TestCommand extends CommandBase {
@Override
public String getCommandName()
public String getName()
{
return "clientCommandTest";
}
@Override
public String getCommandUsage(ICommandSender sender)
public String getUsage(ICommandSender sender)
{
return "clientCommandTest <block>";
}
@@ -46,7 +46,7 @@ public class ClientCommandTest {
}
@Override
public List<String> getTabCompletionOptions(MinecraftServer server, ICommandSender sender, String[] args, @Nullable BlockPos pos)
public List<String> getTabCompletions(MinecraftServer server, ICommandSender sender, String[] args, @Nullable BlockPos pos)
{
if (args.length > 0)
{
@@ -61,11 +61,11 @@ public class ClientCommandTest {
{
if (args.length > 0)
{
sender.addChatMessage(new TextComponentString("Input: " + Arrays.toString(args)));
sender.sendMessage(new TextComponentString("Input: " + Arrays.toString(args)));
}
else
{
sender.addChatMessage(new TextComponentString("No arguments."));
sender.sendMessage(new TextComponentString("No arguments."));
}
}
}
@@ -32,13 +32,13 @@ public class CommandTreeBaseTest
}
@Override
public String getCommandName()
public String getName()
{
return "treecommand_test";
}
@Override
public String getCommandUsage(ICommandSender sender)
public String getUsage(ICommandSender sender)
{
return "commands.treecommand_test.usage";
}
@@ -46,13 +46,13 @@ public class CommandTreeBaseTest
public static class CommandPing extends CommandBase
{
@Override
public String getCommandName()
public String getName()
{
return "ping";
}
@Override
public String getCommandUsage(ICommandSender sender)
public String getUsage(ICommandSender sender)
{
return "commands.treecommand_test.ping.usage";
}
@@ -60,7 +60,7 @@ public class CommandTreeBaseTest
@Override
public void execute(MinecraftServer server, ICommandSender sender, String[] args) throws CommandException
{
sender.addChatMessage(new TextComponentString("Pong!"));
sender.sendMessage(new TextComponentString("Pong!"));
}
}
@@ -75,13 +75,13 @@ public class CommandTreeBaseTest
}
@Override
public String getCommandName()
public String getName()
{
return "value";
}
@Override
public String getCommandUsage(ICommandSender sender)
public String getUsage(ICommandSender sender)
{
return "commands.treecommand_test.value.usage";
}
@@ -89,13 +89,13 @@ public class CommandTreeBaseTest
public static class CommandSet extends CommandBase
{
@Override
public String getCommandName()
public String getName()
{
return "set";
}
@Override
public String getCommandUsage(ICommandSender sender)
public String getUsage(ICommandSender sender)
{
return "commands.treecommand_test.value.set.usage";
}
@@ -104,20 +104,20 @@ public class CommandTreeBaseTest
public void execute(MinecraftServer server, ICommandSender sender, String[] args) throws CommandException
{
value = CommandTreeTest.parseInt(args[0]);
sender.addChatMessage(new TextComponentString("Test value set to: " + value));
sender.sendMessage(new TextComponentString("Test value set to: " + value));
}
}
public static class CommandGet extends CommandBase
{
@Override
public String getCommandName()
public String getName()
{
return "get";
}
@Override
public String getCommandUsage(ICommandSender sender)
public String getUsage(ICommandSender sender)
{
return "commands.treecommand_test.value.get.usage";
}
@@ -125,7 +125,7 @@ public class CommandTreeBaseTest
@Override
public void execute(MinecraftServer server, ICommandSender sender, String[] args) throws CommandException
{
sender.addChatMessage(new TextComponentString("Test value: " + value));
sender.sendMessage(new TextComponentString("Test value: " + value));
}
}
}
@@ -98,7 +98,7 @@ public class FluidHandlerTest
private static String stackString(@Nonnull ItemStack stack)
{
if (stack.func_190926_b())
if (stack.isEmpty())
{
return "no item";
}
@@ -113,13 +113,13 @@ public class FluidHandlerTest
{
resourceDomain = stack.getItem().getRegistryName().getResourceDomain();
}
return stack.func_190916_E() + " " + stack.getDisplayName() + " (" + resourceDomain + ")";
return stack.getCount() + " " + stack.getDisplayName() + " (" + resourceDomain + ")";
}
}
private static List<ItemStack> getAllItems()
{
NonNullList<ItemStack> list = NonNullList.func_191196_a();
NonNullList<ItemStack> list = NonNullList.create();
for (Item item : ForgeRegistries.ITEMS.getValues())
{
for (CreativeTabs tab : item.getCreativeTabs())
@@ -65,13 +65,13 @@ public class PermissionTest
public static class CommandPermissionTest extends CommandBase
{
@Override
public String getCommandName()
public String getName()
{
return "permission_test";
}
@Override
public String getCommandUsage(ICommandSender sender)
public String getUsage(ICommandSender sender)
{
return "commands.permission_test.usage";
}
@@ -89,7 +89,7 @@ public class PermissionTest
if(args.length < 1)
{
sender.addChatMessage(new TextComponentString("claim, unclaim, setblock, read_tile"));
sender.sendMessage(new TextComponentString("claim, unclaim, setblock, read_tile"));
return;
}
@@ -104,12 +104,12 @@ public class PermissionTest
if(b)
{
//claim chunk
sender.addChatMessage(new TextComponentString("Chunk claimed!"));
sender.sendMessage(new TextComponentString("Chunk claimed!"));
}
else
{
//unclaim chunk
sender.addChatMessage(new TextComponentString("Chunk unclaimed!"));
sender.sendMessage(new TextComponentString("Chunk unclaimed!"));
}
}
else
@@ -134,7 +134,7 @@ public class PermissionTest
i = parseInt(args[5], 0, 15);
}
if(!player.worldObj.isBlockLoaded(blockpos))
if(!player.world.isBlockLoaded(blockpos))
{
throw new CommandException("commands.setblock.outOfWorld");
}
@@ -146,7 +146,7 @@ public class PermissionTest
{
throw new CommandException("commands.generic.permission");
}
else if(!player.worldObj.setBlockState(blockpos, state, 2))
else if(!player.world.setBlockState(blockpos, state, 2))
{
throw new CommandException("commands.setblock.noChange");
}
@@ -156,12 +156,12 @@ public class PermissionTest
else if(args[0].equals("read_tile"))
{
BlockPos blockpos = parseBlockPos(sender, args, 1, false);
TileEntity tileEntity = player.worldObj.getTileEntity(blockpos);
TileEntity tileEntity = player.world.getTileEntity(blockpos);
if(PermissionAPI.hasPermission(player.getGameProfile(), Permissions.READ_TILE, new BlockPosContext(player, blockpos, null, null).set(ContextKeys.TILE_ENTITY, tileEntity)))
{
NBTTagCompound tag = tileEntity == null ? null : tileEntity.serializeNBT();
sender.addChatMessage(new TextComponentString(String.valueOf(tag)));
sender.sendMessage(new TextComponentString(String.valueOf(tag)));
}
else
{
@@ -61,7 +61,7 @@ public class TestCapabilityMod
if (event.getWorld().getBlockState(event.getPos()).getBlock() == Blocks.DIRT && event.getItemStack().hasCapability(TEST_CAP, null))
{
IExampleCapability cap = event.getItemStack().getCapability(TEST_CAP, null);
event.getEntityPlayer().addChatMessage(new TextComponentString((cap.getVal() ? TextFormatting.GREEN : TextFormatting.RED) + "" + TextFormatting.ITALIC + "TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST"));
event.getEntityPlayer().sendMessage(new TextComponentString((cap.getVal() ? TextFormatting.GREEN : TextFormatting.RED) + "" + TextFormatting.ITALIC + "TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST"));
event.setCanceled(true);
}
}
@@ -40,7 +40,7 @@ public class WorldCapabilityRainTimerTest {
@SubscribeEvent
public void attatchTimer(AttachCapabilitiesEvent.World event)
{
if (!event.getWorld().isRemote && !event.getWorld().provider.getHasNoSky())
if (!event.getWorld().isRemote && !event.getWorld().provider.hasNoSky())
event.addCapability(new ResourceLocation(MODID, "rainTimer"), new RainTimerProvider());
}