YATS/Forge Documentation
 All Classes Namespaces Files Functions Variables Enumerator Pages
net.minecraft.util.WeightedRandomChestContent Class Reference
Inheritance diagram for net.minecraft.util.WeightedRandomChestContent:
net.minecraft.util.WeightedRandomItem

Public Member Functions

 WeightedRandomChestContent (int par1, int par2, int par3, int par4, int par5)
 
 WeightedRandomChestContent (ItemStack par1ItemStack, int par2, int par3, int par4)
 
- Public Member Functions inherited from net.minecraft.util.WeightedRandomItem
 WeightedRandomItem (int par1)
 

Static Public Member Functions

static void generateChestContents (Random par0Random, WeightedRandomChestContent[] par1ArrayOfWeightedRandomChestContent, IInventory par2IInventory, int par3)
 
static void generateDispenserContents (Random par0Random, WeightedRandomChestContent[] par1ArrayOfWeightedRandomChestContent, TileEntityDispenser par2TileEntityDispenser, int par3)
 
static WeightedRandomChestContent[] func_92080_a (WeightedRandomChestContent[] par0ArrayOfWeightedRandomChestContent, WeightedRandomChestContent...par1ArrayOfWeightedRandomChestContent)
 

Public Attributes

ItemStack theItemId = null
 
int theMinimumChanceToGenerateItem
 
int theMaximumChanceToGenerateItem
 
- Public Attributes inherited from net.minecraft.util.WeightedRandomItem
int itemWeight
 

Protected Member Functions

ItemStack[] generateChestContent (Random random, IInventory newInventory)
 

Constructor & Destructor Documentation

net.minecraft.util.WeightedRandomChestContent.WeightedRandomChestContent ( int  par1,
int  par2,
int  par3,
int  par4,
int  par5 
)
net.minecraft.util.WeightedRandomChestContent.WeightedRandomChestContent ( ItemStack  par1ItemStack,
int  par2,
int  par3,
int  par4 
)

Member Function Documentation

static WeightedRandomChestContent [] net.minecraft.util.WeightedRandomChestContent.func_92080_a ( WeightedRandomChestContent[]  par0ArrayOfWeightedRandomChestContent,
WeightedRandomChestContent...  par1ArrayOfWeightedRandomChestContent 
)
static
ItemStack [] net.minecraft.util.WeightedRandomChestContent.generateChestContent ( Random  random,
IInventory  newInventory 
)
protected

Allow a mod to submit a custom implementation that can delegate item stack generation beyond simple stack lookup

Parameters
randomThe current random for generation
newInventoryThe inventory being generated (do not populate it, but you can refer to it)
Returns
An array of ItemStack to put into the chest
static void net.minecraft.util.WeightedRandomChestContent.generateChestContents ( Random  par0Random,
WeightedRandomChestContent[]  par1ArrayOfWeightedRandomChestContent,
IInventory  par2IInventory,
int  par3 
)
static

Generates the Chest contents.

static void net.minecraft.util.WeightedRandomChestContent.generateDispenserContents ( Random  par0Random,
WeightedRandomChestContent[]  par1ArrayOfWeightedRandomChestContent,
TileEntityDispenser  par2TileEntityDispenser,
int  par3 
)
static

Generates the Dispenser contents.

Member Data Documentation

ItemStack net.minecraft.util.WeightedRandomChestContent.theItemId = null

The Item/Block ID to generate in the Chest.

int net.minecraft.util.WeightedRandomChestContent.theMaximumChanceToGenerateItem

The maximum chance of item generating.

int net.minecraft.util.WeightedRandomChestContent.theMinimumChanceToGenerateItem

The minimum chance of item generating.


The documentation for this class was generated from the following file: