mirror of
https://github.com/MinecraftForge/MinecraftForge.git
synced 2026-11-24 22:14:32 +00:00
Update MCP mappings to snapshot_nodoc_20161220 (#3551)
This commit is contained in:
1 parent
1f4007e5d8
commit
5165dc52bf
88 files changed
+445
-436
No files matched your search
@@ -49,7 +49,7 @@ public class AnvilUpdateEvent extends Event
|
||||
{
|
||||
this.left = left;
|
||||
this.right = right;
|
||||
this.output = ItemStack.field_190927_a;
|
||||
this.output = ItemStack.EMPTY;
|
||||
this.name = name;
|
||||
this.setCost(cost);
|
||||
this.setMaterialCost(0);
|
||||
|
||||
@@ -356,7 +356,7 @@ public class ForgeEventFactory
|
||||
if (event.getResult() == Result.ALLOW)
|
||||
{
|
||||
if (!world.isRemote)
|
||||
stack.func_190918_g(1);
|
||||
stack.shrink(1);
|
||||
return 1;
|
||||
}
|
||||
return 0;
|
||||
@@ -372,8 +372,8 @@ public class ForgeEventFactory
|
||||
if (player.capabilities.isCreativeMode)
|
||||
return new ActionResult<ItemStack>(EnumActionResult.SUCCESS, stack);
|
||||
|
||||
stack.func_190918_g(1);
|
||||
if (stack.func_190926_b())
|
||||
stack.shrink(1);
|
||||
if (stack.isEmpty())
|
||||
return new ActionResult<ItemStack>(EnumActionResult.SUCCESS, event.getFilledBucket());
|
||||
|
||||
if (!player.inventory.addItemStackToInventory(event.getFilledBucket()))
|
||||
@@ -400,8 +400,8 @@ public class ForgeEventFactory
|
||||
|
||||
public static int onItemExpire(EntityItem entity, @Nonnull ItemStack item)
|
||||
{
|
||||
if (item.func_190926_b()) return -1;
|
||||
ItemExpireEvent event = new ItemExpireEvent(entity, (item.func_190926_b() ? 6000 : item.getItem().getEntityLifespan(item, entity.worldObj)));
|
||||
if (item.isEmpty()) return -1;
|
||||
ItemExpireEvent event = new ItemExpireEvent(entity, (item.isEmpty() ? 6000 : item.getItem().getEntityLifespan(item, entity.world)));
|
||||
if (!MinecraftForge.EVENT_BUS.post(event)) return -1;
|
||||
return event.getExtraLife();
|
||||
}
|
||||
@@ -427,7 +427,7 @@ public class ForgeEventFactory
|
||||
|
||||
public static boolean canMountEntity(Entity entityMounting, Entity entityBeingMounted, boolean isMounting)
|
||||
{
|
||||
boolean isCanceled = MinecraftForge.EVENT_BUS.post(new EntityMountEvent(entityMounting, entityBeingMounted, entityMounting.worldObj, isMounting));
|
||||
boolean isCanceled = MinecraftForge.EVENT_BUS.post(new EntityMountEvent(entityMounting, entityBeingMounted, entityMounting.world, isMounting));
|
||||
|
||||
if(isCanceled)
|
||||
{
|
||||
@@ -498,7 +498,7 @@ public class ForgeEventFactory
|
||||
|
||||
public static boolean onPotionAttemptBrew(NonNullList<ItemStack> stacks)
|
||||
{
|
||||
NonNullList<ItemStack> tmp = NonNullList.func_191197_a(stacks.size(), ItemStack.field_190927_a);
|
||||
NonNullList<ItemStack> tmp = NonNullList.withSize(stacks.size(), ItemStack.EMPTY);
|
||||
for (int x = 0; x < tmp.size(); x++)
|
||||
tmp.set(x, stacks.get(x).copy());
|
||||
|
||||
@@ -577,8 +577,8 @@ public class ForgeEventFactory
|
||||
Result canContinueSleep = evt.getResult();
|
||||
if (canContinueSleep == Result.DEFAULT)
|
||||
{
|
||||
IBlockState state = player.worldObj.getBlockState(player.bedLocation);
|
||||
return state.getBlock().isBed(state, player.worldObj, player.bedLocation, player);
|
||||
IBlockState state = player.world.getBlockState(player.bedLocation);
|
||||
return state.getBlock().isBed(state, player.world, player.bedLocation, player);
|
||||
}
|
||||
else
|
||||
return canContinueSleep == Result.ALLOW;
|
||||
|
||||
@@ -42,7 +42,7 @@ public class PotionBrewEvent extends Event
|
||||
@Nonnull
|
||||
public ItemStack getItem(int index)
|
||||
{
|
||||
if (index >= stacks.size()) return ItemStack.field_190927_a;
|
||||
if (index >= stacks.size()) return ItemStack.EMPTY;
|
||||
return stacks.get(index);
|
||||
}
|
||||
|
||||
|
||||
@@ -28,8 +28,8 @@ import net.minecraftforge.fml.common.eventhandler.Event;
|
||||
* Fired when the enchantment level is set for each of the three potential enchantments in the enchanting table.
|
||||
* The {@link #level} is set to the vanilla value and can be modified by this event handler.
|
||||
*
|
||||
* The {@link #enchantRow} is used to determine which enchantment level is being set, 1, 2, or 3. The {@link power} is a number
|
||||
* from 0-15 and indicates how many bookshelves surround the enchanting table. The {@link itemStack} representing the item being
|
||||
* The {@link #enchantRow} is used to determine which enchantment level is being set, 1, 2, or 3. The {@link #power} is a number
|
||||
* from 0-15 and indicates how many bookshelves surround the enchanting table. The {@link #itemStack} representing the item being
|
||||
* enchanted is also available.
|
||||
*/
|
||||
public class EnchantmentLevelSetEvent extends Event
|
||||
@@ -126,7 +126,7 @@ public class EnchantmentLevelSetEvent extends Event
|
||||
/**
|
||||
* Set the new level of the enchantment (0-30)
|
||||
*
|
||||
* @param the new level of the enchantment (0-30)
|
||||
* @param level the new level of the enchantment (0-30)
|
||||
*/
|
||||
public void setLevel(int level)
|
||||
{
|
||||
|
||||
@@ -30,7 +30,7 @@ import java.util.Collection;
|
||||
/**
|
||||
* EntityJoinWorldEvent is fired when an Entity joins the world. <br>
|
||||
* This event is fired whenever an Entity is added to the world in
|
||||
* {@link World#loadEntities(Collection)}, {@link WorldServer#loadEntities(Collection)} {@link World#joinEntityInSurroundings(Entity)}, and {@link World#spawnEntityInWorld(Entity)}. <br>
|
||||
* {@link World#loadEntities(Collection)}, {@link WorldServer#loadEntities(Collection)} {@link World#joinEntityInSurroundings(Entity)}, and {@link World#spawnEntity(Entity)}. <br>
|
||||
* <br>
|
||||
* {@link #world} contains the world in which the entity is to join.<br>
|
||||
* <br>
|
||||
|
||||
@@ -118,7 +118,7 @@ public class LivingSpawnEvent extends LivingEvent
|
||||
{
|
||||
public AllowDespawn(EntityLiving entity)
|
||||
{
|
||||
super(entity, entity.worldObj, (float)entity.posX, (float)entity.posY, (float)entity.posZ);
|
||||
super(entity, entity.world, (float)entity.posX, (float)entity.posY, (float)entity.posZ);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -35,10 +35,10 @@ import javax.annotation.Nonnull;
|
||||
/**
|
||||
* MinecartInteractEvent is fired when a player interacts with a minecart. <br>
|
||||
* This event is fired whenever a player interacts with a minecart in
|
||||
* {@link EntityMinecartContainer#processInitialInteract(EntityPlayer, ItemStack, EnumHand)},
|
||||
* {@link EntityMinecartEmpty#processInitialInteract(EntityPlayer, ItemStack, EnumHand)},
|
||||
* {@link EntityMinecartFurnace#processInitialInteract(EntityPlayer, ItemStack, EnumHand)},
|
||||
* {@link EntityMinecartHopper#processInitialInteract(EntityPlayer, ItemStack, EnumHand)},
|
||||
* {@link EntityMinecartContainer#processInitialInteract(EntityPlayer, EnumHand)},
|
||||
* {@link EntityMinecartEmpty#processInitialInteract(EntityPlayer, EnumHand)},
|
||||
* {@link EntityMinecartFurnace#processInitialInteract(EntityPlayer, EnumHand)},
|
||||
* {@link EntityMinecartHopper#processInitialInteract(EntityPlayer, EnumHand)},
|
||||
* etc.<br>
|
||||
* <br>
|
||||
* {@link #player} contains the EntityPlayer that is involved with this minecart interaction.<br>
|
||||
|
||||
@@ -32,7 +32,7 @@ import javax.annotation.Nonnull;
|
||||
/**
|
||||
* ArrowNockEvent is fired when a player begins using a bow.<br>
|
||||
* This event is fired whenever a player begins using a bow in
|
||||
* {@link ItemBow#onItemRightClick(ItemStack, World, EntityPlayer, EnumHand)}.<br>
|
||||
* {@link ItemBow#onItemRightClick(World, EntityPlayer, EnumHand)}.<br>
|
||||
* <br>
|
||||
* This event is fired on the {@link MinecraftForge#EVENT_BUS}.
|
||||
**/
|
||||
|
||||
@@ -51,7 +51,7 @@ public class BiomeEvent extends Event
|
||||
/**
|
||||
* CreateDecorator is fired when a BiomeDecorator is created.<br>
|
||||
* This event is fired whenever a BiomeDecorator is created in
|
||||
* {@link DeferredBiomeDecorator#fireCreateEventAndReplace(BiomeGenBase)}.<br>
|
||||
* {@link DeferredBiomeDecorator#fireCreateEventAndReplace(Biome)}.<br>
|
||||
* <br>
|
||||
* {@link #originalBiomeDecorator} contains the original BiomeDecorator that would be used in vanilla.
|
||||
* {@link #newBiomeDecorator} contains the new BiomeDecoration to be used by Minecraft.
|
||||
|
||||
@@ -20,6 +20,7 @@
|
||||
package net.minecraftforge.event.terraingen;
|
||||
|
||||
import net.minecraft.world.biome.BiomeProvider;
|
||||
import net.minecraft.world.gen.ChunkProviderSettings;
|
||||
import net.minecraftforge.common.MinecraftForge;
|
||||
import net.minecraftforge.fml.common.eventhandler.Cancelable;
|
||||
import net.minecraftforge.fml.common.eventhandler.Event;
|
||||
@@ -52,7 +53,7 @@ public class WorldTypeEvent extends Event
|
||||
/**
|
||||
* BiomeSize is fired when vanilla Minecraft attempts to generate biomes.<br>
|
||||
* This event is fired during biome generation in
|
||||
* {@link GenLayer#initializeAllBiomeGenerators(long, WorldType, String)}. <br>
|
||||
* {@link GenLayer#initializeAllBiomeGenerators(long, WorldType, ChunkProviderSettings)}. <br>
|
||||
* <br>
|
||||
* {@link #originalSize} the original size of the Biome. <br>
|
||||
* {@link #newSize} the new size of the biome. Initially set to the {@link #originalSize}. <br>
|
||||
|
||||
@@ -60,7 +60,7 @@ public class ChunkWatchEvent extends Event
|
||||
/**
|
||||
* ChunkWatchEvent.Watch is fired when an EntityPlayer begins watching a chunk.<br>
|
||||
* This event is fired when a chunk is added to the watched chunks of an EntityPlayer in
|
||||
* {@link PlayerChunkMapEntry#addPlayer(EntityPlayerMP)} and {@link PlayerChunkMapEntry#sentToPlayers()}. <br>
|
||||
* {@link PlayerChunkMapEntry#addPlayer(EntityPlayerMP)} and {@link PlayerChunkMapEntry#sendToPlayers()}. <br>
|
||||
* <br>
|
||||
* This event is not {@link Cancelable}.<br>
|
||||
* <br>
|
||||
|
||||
Reference in new issue
Block a user