public class MinecartRegistry extends Object
| Modifier and Type | Class and Description | 
|---|---|
static class  | 
MinecartRegistry.MinecartKey  | 
| Constructor and Description | 
|---|
MinecartRegistry()  | 
| Modifier and Type | Method and Description | 
|---|---|
static Set<ItemStack> | 
getAllCartItems()
Will return a set of all registered minecart items. 
 | 
static Class<? extends EntityMinecart> | 
getCartClassForItem(ItemStack item)
The function will return the cart class for a given item. 
 | 
static int | 
getCartTypeForItem(ItemStack item)
The function will return the cart type for a given item. 
 | 
static ItemStack | 
getItemForCart(Class<? extends EntityMinecart> minecart)
This function returns an ItemStack that represents this cart. 
 | 
static ItemStack | 
getItemForCart(Class<? extends EntityMinecart> minecart,
                            int type)
This function returns an ItemStack that represents this cart. 
 | 
static ItemStack | 
getItemForCart(EntityMinecart cart)
This function returns an ItemStack that represents this cart. 
 | 
static void | 
registerMinecart(Class<? extends EntityMinecart> minecart,
                                int type,
                                ItemStack item)
Registers a minecart and its corresponding item. 
 | 
static void | 
registerMinecart(Class<? extends EntityMinecart> cart,
                                ItemStack item)
Registers a custom minecart and its corresponding item. 
 | 
static void | 
removeMinecart(Class<? extends EntityMinecart> minecart,
                            int type)
Removes a previously registered Minecart. 
 | 
public MinecartRegistry()
public static void registerMinecart(Class<? extends EntityMinecart> cart, ItemStack item)
cart - The minecart.item - The item used to place the cart.public static void registerMinecart(Class<? extends EntityMinecart> minecart, int type, ItemStack item)
minecart - The minecart.type - The minecart type, used to differentiate carts that have the same class.item - The item used to place the cart.public static void removeMinecart(Class<? extends EntityMinecart> minecart, int type)
minecart - type - public static ItemStack getItemForCart(Class<? extends EntityMinecart> minecart)
minecart - The cart classpublic static ItemStack getItemForCart(Class<? extends EntityMinecart> minecart, int type)
minecart - The cart classtype - The minecartType valuepublic static ItemStack getItemForCart(EntityMinecart cart)
cart - The cart entitypublic static Class<? extends EntityMinecart> getCartClassForItem(ItemStack item)
item - The item to test.public static int getCartTypeForItem(ItemStack item)
item - The item to test.public static Set<ItemStack> getAllCartItems()