public class ScriptableMod
extends java.lang.Object
| Constructor and Description |
|---|
ScriptableMod(cubex2.cs2.Mod mod,
org.mozilla.javascript.Context cx,
org.mozilla.javascript.Scriptable scope) |
| Modifier and Type | Method and Description |
|---|---|
void |
addAlias(java.lang.String itemName,
java.lang.String name)
Adds an alias for an item with the wildcard metadata of 32767.
|
void |
addAliasWithMetadata(java.lang.String itemName,
int metadata,
java.lang.String name)
Adds an alias for an item
|
void |
addBlock(java.lang.String blockFile,
java.lang.String blockType)
Adds a block with the given type to the game
|
void |
addChestItem(java.lang.String chest,
java.lang.String itemName,
int dv,
int rarity)
Adds an item to a generated chest with a stack size of 1
|
void |
addChestItem(java.lang.String chest,
java.lang.String itemName,
int dv,
int minCount,
int maxCount,
int rarity)
Adds an item to a generated chest.
|
void |
addCreativeTab(java.lang.String name,
java.lang.String itemName,
int meta)
Adds a creative tab.
|
void |
addDungeonLoot(java.lang.String itemName,
int dv,
int rarity)
Adds a item stack to the dungeon loot list with a stack size of 1.
|
void |
addDungeonLoot(java.lang.String itemName,
int dv,
int minCount,
int maxCount,
int rarity)
Adds a item stack, with a range of sizes, to the dungeon loot list.
|
void |
addDungeonMob(java.lang.String name,
int rarity)
Adds a mob to the possible list of creatures the spawner will create.
|
void |
addFuel(java.lang.String item,
int duration)
Adds a fuel to the vanilla fuel list
|
void |
addFuelFor(java.lang.String fuelLists,
java.lang.String item,
int duration)
Adds a fuel to the given fuel lists.
|
void |
addGrassPlant(java.lang.String blockName,
int dv,
int prob)
Register a new plant to be planted when bonemeal is used on grass.
|
void |
addGrassSeed(java.lang.String itemName,
int dv,
int quantity,
int prob)
Register a new seed to be dropped when breaking tall grass.
|
void |
addGui(java.lang.String guiFile,
java.lang.String guiType)
Adds a GUI with the given type to the game
|
void |
addItem(java.lang.String itemFile,
java.lang.String itemType)
Adds an item with the given type to the game
|
void |
addMobDrop(java.lang.String mob,
java.lang.String itemName,
int meta,
int amount)
Adds an item to a mob's drops
|
void |
addMobDrop(java.lang.String mob,
java.lang.String itemName,
int meta,
int amount,
float rate)
Adds an item to a mob's drops
|
void |
addRareMobDrop(java.lang.String mob,
java.lang.String itemName,
int meta,
int amount)
Adds an item to a mob's rare drops.
|
void |
addRareMobDrop(java.lang.String mob,
java.lang.String itemName,
int meta,
int amount,
float rate)
Adds an item to a mob's rare drops.
|
void |
addRecipe(java.lang.String result,
int width,
int height,
java.lang.String... recipeItems)
Adds a crafting recipe to the vanilla recipe list.
|
void |
addRecipeFor(java.lang.String recipeLists,
java.lang.String result,
int width,
int height,
java.lang.String... recipeItems)
Adds a crafting recipe to the given recipeLists.
|
void |
addShapelessRecipe(java.lang.String result,
java.lang.String... recipeItems)
Adds a shapeless crafting recipe to the vanilla recipe list.
|
void |
addShapelessRecipeFor(java.lang.String recipeLists,
java.lang.String result,
java.lang.String... recipeItems)
Adds a shapeless crafting recipe to the given recipe lists.
|
void |
addSmeltingRecipe(java.lang.String result,
java.lang.String input)
Adds a smelting recipe to the vanilla recipe list
|
void |
addSmeltingRecipeFor(java.lang.String recipeLists,
java.lang.String result,
java.lang.String input)
Adds a smelting recipe to the given recipe lists.
|
void |
addSpawn(java.lang.String name,
int rate,
int min,
int max,
java.lang.String type)
Adds a mob to the spawn list for all biomes except hell
|
void |
addSpawn(java.lang.String name,
int rate,
int min,
int max,
java.lang.String type,
java.lang.String... biome)
Adds a mob to the spawn list for selected biomes
|
void |
addTileEntity(java.lang.String tileEntityFile,
java.lang.String tileEntityType)
Adds a tile entity with the given type to the game
|
void |
addToOreDictionary(java.lang.String oreClass,
java.lang.String itemName,
int dv)
Adds an item to the ore dictionary
|
void |
addTradeRecipe(int profession,
java.lang.String itemToBuy,
java.lang.String itemToSell,
float chance)
Adds a trade recipe for villagers.
|
void |
addTradeRecipe(int profession,
java.lang.String itemToBuy,
java.lang.String secondItemToBuy,
java.lang.String itemToSell,
float chance)
Adds a trade recipe for villagers.
|
void |
addWorldGen(java.lang.String worldGenFile,
java.lang.String worldGenType)
Adds a world generator with the given type to the game
|
void |
appendFile(java.lang.String file,
java.lang.String content)
Appends a string to a file.
|
void |
disableAirRendering()
Disables rendering of the air bar
|
void |
disableArmorRendering()
Disables rendering of the player's armor bar
|
void |
disableBossHealthRendering()
Disables rendering of the boss health
|
void |
disableCrosshairsRendering()
Disables rendering of the crosshairs
|
void |
disableExperienceRendering()
Disables rendering of the experience bar
|
void |
disableFoodRendering()
Disables rendering of the food bar
|
void |
disableHealthRendering()
Disables rendering of the player's health
|
void |
disableHelmetRendering()
Disables rendering of helmet overlay (i.e. the pumpkin overlay)
|
void |
disableHotbarRendering()
Disables rendering of the hotbar
|
void |
disableObjectiveRendering()
Disables rendering of the objective
|
void |
disablePortalRendering()
Disables rendering of the portal overlay
|
void |
enableAirRendering()
Enables rendering of the air bar
|
void |
enableArmorRendering()
Enables rendering of the player's armor bar
|
void |
enableBossHealthRendering()
Enables rendering of the boss health
|
void |
enableCrosshairsRendering()
Enables rendering of the crosshairs
|
void |
enableExperienceRendering()
Enables rendering of the experience bar
|
void |
enableFoodRendering()
Enables rendering of the food bar
|
void |
enableHealthRendering()
Enables rendering of the player's health
|
void |
enableHelmetRendering()
Enables rendering of helmet overlay (i.e. the pumpkin overlay)
|
void |
enableHotbarRendering()
Enables rendering of the hotbar
|
void |
enableObjectiveRendering()
Enables rendering of the objective
|
void |
enablePortalRendering()
Enables rendering of the portal overlay
|
java.lang.String |
getAliasItemName(java.lang.String name)
Gets the item name of an alias
|
int |
getAliasMetadata(java.lang.String name)
Gets the metadata of an alias
|
java.lang.String |
getBlockType(java.lang.String blockName)
Gets the type of the block with the given id.
|
java.lang.String |
getModName()
Gets the mod's name.
|
java.lang.String[] |
getOreDictClasses()
Gets all registered ore dictionary classes.
|
java.lang.String[] |
getOreDictClassItems(java.lang.String clazz)
Gets all items in a ore dictionary class.
|
boolean |
isItemInOreDictClass(java.lang.String itemName,
int meta,
java.lang.String clazz)
Checks if the given item is registered for the given ore dictionary class.
|
void |
loadScript(java.lang.String file)
Executes a javascript file.
|
void |
printLine(java.lang.String s)
Prints a line in the console.
|
java.lang.String |
readFile(java.lang.String file)
Reads the content of a file.
|
void |
registerBonemealHandler(java.lang.String file)
Registers a file for a bonemeal handler.
|
void |
registerCraftingHandler(java.lang.String file)
Registers a file for a crafting handler.
|
void |
registerDestroyItemHandler(java.lang.String file)
Registers a file for a destroyitem handler.
|
void |
registerIngameRenderer(java.lang.String file)
Registers a file for the ingame renderer.
|
void |
registerPickupHandler(java.lang.String file)
Registers a file for a pickup handler.
|
void |
removeAllBiomesExcept(java.lang.String biome)
Removes all biomes except the selected one.
|
void |
removeAllRecipes()
Removes all recipes that can be used in the vanilla crafting table.
|
void |
removeBiome(java.lang.String biome)
Remove a biome from the terrain generator.
|
void |
removeBiomeDecoration(java.lang.String name)
Removes a vanilla biome decorator.
|
void |
removeChestItem(java.lang.String chest,
java.lang.String itemName,
int dv)
Removes and item from the list of items in a generated chest.
|
void |
removeDungeonLoot(java.lang.String itemName,
int dv)
Removes a item stack from the dungeon loot list, this will remove all items as long as the item stack matches, it will not care about
matching the stack size ranges perfectly.
|
void |
removeDungeonLoot(java.lang.String itemName,
int dv,
int minCount,
int maxCount)
Removes a item stack from the dungeon loot list.
|
void |
removeDungeonMob(java.lang.String name)
Will completely remove a Mob from the dungeon spawn list.
|
void |
removeMinable(java.lang.String name)
Removes a vanilla minable world generator.
|
void |
removeRecipe(java.lang.String result,
int width,
int height,
java.lang.String... recipeItems)
Removes a crafting recipe from the vanilla recipe list.
|
void |
removeRecipeFrom(java.lang.String recipeLists,
java.lang.String result,
int width,
int height,
java.lang.String... recipeItems)
Removes a crafting recipe from the given recipe lists.
|
void |
removeRecipesByResult(java.lang.String result)
Removes all recipes that have the given result and can be used in the vanilla crafting table.
|
void |
removeShapelessRecipe(java.lang.String result,
java.lang.String... recipeItems)
Removes a shapeless crafting recipe from the vanilla recipe list
|
void |
removeShapelessRecipeFrom(java.lang.String recipeLists,
java.lang.String result,
java.lang.String... recipeItems)
Removes a shapeless crafting recipe from the given recipe lists.
|
void |
removeSmeltingRecipe(java.lang.String input)
Removes a smelting recipe from the vanilla recipe list
|
void |
removeSmeltingRecipeFrom(java.lang.String recipeLists,
java.lang.String input)
Removes a smelting recipe from the given recipe lists.
|
void |
removeSpawn(java.lang.String name,
java.lang.String type)
Remove a mob from the spawn list for all biomes except hell
|
void |
removeSpawn(java.lang.String name,
java.lang.String type,
java.lang.String... biome)
Remove a mob from spawn list for selected biomes.
|
void |
removeTradeRecipe(int profession,
java.lang.String itemToBuy,
java.lang.String itemToSell)
Removes a trade recipe from villagers
|
void |
removeTradeRecipe(int profession,
java.lang.String itemToBuy,
java.lang.String secondItemToBuy,
java.lang.String itemToSell)
Removes a trade recipe from villagers
|
void |
writeFile(java.lang.String file,
java.lang.String content)
Writes a string to a file.
|
public ScriptableMod(cubex2.cs2.Mod mod,
org.mozilla.javascript.Context cx,
org.mozilla.javascript.Scriptable scope)
public void printLine(java.lang.String s)
s - The text to displaypublic void loadScript(java.lang.String file)
throws java.lang.Exception
file - The path to a script file. The path is relative to the scripts directory (for example aFile.js or aDirectory/aFile.js).java.lang.Exceptionpublic void addAlias(java.lang.String itemName,
java.lang.String name)
itemName - The item's namename - The name for the aliaspublic void addAliasWithMetadata(java.lang.String itemName,
int metadata,
java.lang.String name)
itemName - The item's namemetadata - The item's metadataname - The name for the aliaspublic java.lang.String getAliasItemName(java.lang.String name)
name - The name of the aliaspublic int getAliasMetadata(java.lang.String name)
name - The name of the aliaspublic void registerCraftingHandler(java.lang.String file)
throws java.lang.Exception
file - The path to the script file relative to the mod's scripts directory.java.lang.Exceptionpublic void registerPickupHandler(java.lang.String file)
throws java.lang.Exception
file - The path to the script file relative to the mod's scripts directory.java.lang.Exceptionpublic void registerBonemealHandler(java.lang.String file)
throws java.lang.Exception
file - The path to the script file relative to the mod's scripts directory.java.lang.Exceptionpublic void registerDestroyItemHandler(java.lang.String file)
throws java.lang.Exception
file - The path to the script file relative to the mod's scripts directory.java.lang.Exceptionpublic void registerIngameRenderer(java.lang.String file)
throws java.lang.Exception
file - The path to the script file relative to the mod's scripts directory.java.lang.Exceptionpublic void addRecipe(java.lang.String result,
int width,
int height,
java.lang.String... recipeItems)
throws java.lang.Exception
public void addRecipeFor(java.lang.String recipeLists,
java.lang.String result,
int width,
int height,
java.lang.String... recipeItems)
throws java.lang.Exception
recipeLists - The recipe lists in which the recipe is added separated with ','. For example 'vanilla,myOwn' or 'myOwn'result - The result item. Input Format #1 is used for this parameter (see here)width - The recipe's widthheight - The recipe's heightrecipeItems - The recipe ingredients. Input Format #2 is used for this parameter (see here)java.lang.Exceptionpublic void addShapelessRecipe(java.lang.String result,
java.lang.String... recipeItems)
throws java.lang.Exception
public void addShapelessRecipeFor(java.lang.String recipeLists,
java.lang.String result,
java.lang.String... recipeItems)
throws java.lang.Exception
recipeLists - The recipe lists in which the recipe is added separated with ','. For example 'vanilla,myOwn' or 'myOwn'result - The result item. Input Format #1 is used for this parameter (see here)recipeItems - The recipe ingredients. Input Format #2 is used for this parameter (see here)java.lang.Exceptionpublic void removeAllRecipes()
public void removeRecipesByResult(java.lang.String result)
result - The result item. Input Format #3 is used for this parameter (see here)public void removeRecipe(java.lang.String result,
int width,
int height,
java.lang.String... recipeItems)
throws java.lang.Exception
public void removeRecipeFrom(java.lang.String recipeLists,
java.lang.String result,
int width,
int height,
java.lang.String... recipeItems)
throws java.lang.Exception
recipeLists - The recipe lists to remove the recipe from. For example 'vanilla,myOwn' or 'myOwn'result - The result item. Input Format #3 is used for this parameter (see here)width - The recipe's widthheight - The recipe's heightrecipeItems - The recipe items. Input Format #2 is used for this parameter (see here)java.lang.Exceptionpublic void removeShapelessRecipe(java.lang.String result,
java.lang.String... recipeItems)
throws java.lang.Exception
public void removeShapelessRecipeFrom(java.lang.String recipeLists,
java.lang.String result,
java.lang.String... recipeItems)
throws java.lang.Exception
public void addSmeltingRecipe(java.lang.String result,
java.lang.String input)
throws java.lang.Exception
public void addSmeltingRecipeFor(java.lang.String recipeLists,
java.lang.String result,
java.lang.String input)
throws java.lang.Exception
public void removeSmeltingRecipe(java.lang.String input)
input - The input of the smelting recipe. Input Format #3 is used for this parameter (see here)public void removeSmeltingRecipeFrom(java.lang.String recipeLists,
java.lang.String input)
recipeLists - The recipe lists separated with ','input - The input of the smelting recipe. Input Format #3 is used for this parameter (see here)public void addTradeRecipe(int profession,
java.lang.String itemToBuy,
java.lang.String itemToSell,
float chance)
throws java.lang.Exception
profession - The profession of the villageritemToBuy - The item that the villager buys. Input Format #1 is used for this parameter (see here)itemToSell - The item that the villager sells. Input Format #1 is used for this parameter (see here)chance - The chance of the recipe (0.0 to 1.0)java.lang.Exceptionpublic void addTradeRecipe(int profession,
java.lang.String itemToBuy,
java.lang.String secondItemToBuy,
java.lang.String itemToSell,
float chance)
throws java.lang.Exception
profession - The profession of the villageritemToBuy - The item that the villager buys. Input Format #1 is used for this parameter (see here)secondItemToBuy - The second item that the villager buys. Input Format #1 is used for this parameter (see here)itemToSell - The item that the villager sells. Input Format #1 is used for this parameter (see here)chance - The chance of the recipe (0.0 to 1.0)java.lang.Exceptionpublic void removeTradeRecipe(int profession,
java.lang.String itemToBuy,
java.lang.String itemToSell)
public void removeTradeRecipe(int profession,
java.lang.String itemToBuy,
java.lang.String secondItemToBuy,
java.lang.String itemToSell)
profession - The profession of the villageritemToBuy - The item that the villager buys. Input Format #1 is used for this parameter (see here)secondItemToBuy - The second item that the villager buys. Input Format #1 is used for this parameter (see here)itemToSell - The item that the villager sells. Input Format #1 is used for this parameter (see here)public void addFuel(java.lang.String item,
int duration)
throws java.lang.Exception
item - The item. Input Format #3 is used for this parameter (see here)duration - The duration in ticksjava.lang.Exceptionpublic void addFuelFor(java.lang.String fuelLists,
java.lang.String item,
int duration)
throws java.lang.Exception
fuelLists - The fuel lists to add the fuel for separated by ','.item - The item. Input Format #3 is used for this parameter (see here)duration - The duration in ticksjava.lang.Exceptionpublic void addSpawn(java.lang.String name,
int rate,
int min,
int max,
java.lang.String type)
throws java.lang.Exception
name - The name of the mobrate - The rate (higher rate -> mob is more common)min - The minimum count of the mob for one spawnmax - The maximum count of the mob for one spawntype - The type of the spawn (monster, creature or water)java.lang.Exceptionpublic void addSpawn(java.lang.String name,
int rate,
int min,
int max,
java.lang.String type,
java.lang.String... biome)
throws java.lang.Exception
name - The name of the mobrate - The rate (higher rate -> mob is more common)min - The minimum count of the mob for one spawnmax - The maximum count of the mob for one spawntype - The type of the spawn (monster, creature or water)biome - The biomes where the mob is spawned. See the CS2InformationFile.txt for all list of all biomes available
in your minecraft setup.java.lang.Exceptionpublic void removeSpawn(java.lang.String name,
java.lang.String type)
throws java.lang.Exception
name - The name of the mobtype - The type of the spawn (monster, creature or water)java.lang.Exceptionpublic void removeSpawn(java.lang.String name,
java.lang.String type,
java.lang.String... biome)
throws java.lang.Exception
name - The name of the mobtype - The type of the spawn (monster, creature or water)biome - The biomes to remove the mob from. See the CS2InformationFile.txt for all list of all biomes available
in your minecraft setup.java.lang.Exceptionpublic void removeBiome(java.lang.String biome)
throws java.lang.Exception
biome - The biome to remove See the CS2InformationFile.txt for all list of all biomes available
in your minecraft setup.java.lang.Exceptionpublic void removeAllBiomesExcept(java.lang.String biome)
throws java.lang.Exception
biome - The biome to remove See the CS2InformationFile.txt for all list of all biomes available
in your minecraft setup.java.lang.Exceptionpublic void addToOreDictionary(java.lang.String oreClass,
java.lang.String itemName,
int dv)
throws java.lang.Exception
oreClass - The ore class. See the CS2InformationFile.txt for all list of all ore classes available
in your minecraft setup. You can also use a new ore class that isn't listed their.itemName - The item's namedv - The item's damage valuejava.lang.Exceptionpublic void addGrassPlant(java.lang.String blockName,
int dv,
int prob)
throws java.lang.Exception
blockName - The block's namedv - The block's damage valueprob - The relative probability of the plant, where red flowers are 10 and yellow flowers are 20.java.lang.Exceptionpublic void addGrassSeed(java.lang.String itemName,
int dv,
int quantity,
int prob)
throws java.lang.Exception
itemName - The item's namedv - The item's damage valuequantity - The quantity of seeds to drop.prob - The relative probability of the seeds, where wheat seeds are 10.java.lang.Exceptionpublic void addDungeonMob(java.lang.String name,
int rarity)
throws java.lang.Exception
name - The name of the mobrarity - The rarity of selecting this mob over others. Must be greater then 0.java.lang.Exceptionpublic void removeDungeonMob(java.lang.String name)
throws java.lang.Exception
name - The name of the mobjava.lang.Exceptionpublic void addDungeonLoot(java.lang.String itemName,
int dv,
int rarity)
throws java.lang.Exception
itemName - The item's namedv - The item's damage valuerarity - The relative chance that this item will spawnjava.lang.Exceptionpublic void addDungeonLoot(java.lang.String itemName,
int dv,
int minCount,
int maxCount,
int rarity)
throws java.lang.Exception
itemName - The item's namedv - The item's damage valueminCount - When this item does generate, the minimum number that is in the stackmaxCount - When this item does generate, the maximum number that can bein the stackrarity - The relative chance that this item will spawn.java.lang.Exceptionpublic void addChestItem(java.lang.String chest,
java.lang.String itemName,
int dv,
int rarity)
chest - The name of the chest. Possible values are mineshaftCorridor, pyramidDesertyChest, pyramidJungleChest,
pyramidJungleDispenser, strongholdCorridor, strongholdLibrary, strongholdCrossing, villageBlacksmith, bonusChest,
dungeonChestitemName - The item's namedv - The item's damage valuerarity - The rarity of the item. Higher rarity means higher chance that the item is added to the chest.public void addChestItem(java.lang.String chest,
java.lang.String itemName,
int dv,
int minCount,
int maxCount,
int rarity)
chest - The name of the chest. Possible values are mineshaftCorridor, pyramidDesertyChest, pyramidJungleChest,
pyramidJungleDispenser, strongholdCorridor, strongholdLibrary, strongholdCrossing, villageBlacksmith, bonusChest,
dungeonChestitemName - The item's namedv - The item's damage valueminCount - When this item does generate, the minimum number that is in the stackmaxCount - When this item does generate, the maximum number that can bein the stackrarity - The rarity of the item. Higher rarity means higher chance that the item is added to the chest.public void removeChestItem(java.lang.String chest,
java.lang.String itemName,
int dv)
chest - The name of the chest. Possible values are mineshaftCorridor, pyramidDesertyChest, pyramidJungleChest,
pyramidJungleDispenser, strongholdCorridor, strongholdLibrary, strongholdCrossing, villageBlacksmith, bonusChest,
dungeonChestitemName - The item's namedv - The item's damage valuepublic void removeDungeonLoot(java.lang.String itemName,
int dv)
throws java.lang.Exception
itemName - The item's namedv - The item's damage valuejava.lang.Exceptionpublic void removeDungeonLoot(java.lang.String itemName,
int dv,
int minCount,
int maxCount)
throws java.lang.Exception
itemName - The item's namedv - The item's damage valueminCount - The minimum count for the match check, if less then 0, the size check is skippedmaxCount - The max count used in match check when 'minCount' is >= 0java.lang.Exceptionpublic void addItem(java.lang.String itemFile,
java.lang.String itemType)
throws java.lang.Exception
itemFile - The path to an item file. The path is relative to the items directory of your mod.itemType - The item's type. See a list of all item types herejava.lang.Exceptionpublic void addBlock(java.lang.String blockFile,
java.lang.String blockType)
throws java.lang.Exception
blockFile - The path to a block file. The path is relative to the blocks directory of your mod.blockType - The block's type. See a list of all block types herejava.lang.Exceptionpublic void addTileEntity(java.lang.String tileEntityFile,
java.lang.String tileEntityType)
throws java.lang.Exception
tileEntityFile - The path to an tile entity file. The path is relative to the tileEntity directory of your mod.tileEntityType - The tile entity's type. See a list of all tile entity types herejava.lang.Exceptionpublic void addGui(java.lang.String guiFile,
java.lang.String guiType)
throws java.lang.Exception
guiFile - The path to an GUI file. The path is relative to the guis directory of your mod.guiType - The GUI's type. See a list of all GUI types herejava.lang.Exceptionpublic void addWorldGen(java.lang.String worldGenFile,
java.lang.String worldGenType)
throws java.lang.Exception
worldGenFile - The path to a world generation file. The path is relative to the worldGeneration directory of your mod.worldGenType - The world generator's type. See a list of all world generation types herejava.lang.Exceptionpublic void removeMinable(java.lang.String name)
name - The name of the minable. Possible values are coal, diamond, iron, lapis, redstone, gold, dirt and gravel.public void removeBiomeDecoration(java.lang.String name)
name - The name of the decorator. Possible values are bigShroom, cactus, clay, deadBush, lilypad, flowers, grass, lake, pumpkin,
reed, sand, sandPass2, shroom, treepublic java.lang.String[] getOreDictClasses()
public java.lang.String[] getOreDictClassItems(java.lang.String clazz)
clazz - The ore dictionary class.public boolean isItemInOreDictClass(java.lang.String itemName,
int meta,
java.lang.String clazz)
itemName - The item's namemeta - The metadata of the itemclazz - The ore dictionary classpublic void addMobDrop(java.lang.String mob,
java.lang.String itemName,
int meta,
int amount)
mob - The id or name of the mobitemName - The name of the itemmeta - The metadata of the itemamount - The amount of the itempublic void addMobDrop(java.lang.String mob,
java.lang.String itemName,
int meta,
int amount,
float rate)
mob - The id or name of the mobitemName - The name of the itemmeta - The metadata of the itemamount - The amount of the itemrate - The rate of the drop where 0.0 is 0% and 1.0 is 100%public void addRareMobDrop(java.lang.String mob,
java.lang.String itemName,
int meta,
int amount)
mob - The id or name of the mobitemName - The name of the itemmeta - The metadata of the itemamount - The amount of the itempublic void addRareMobDrop(java.lang.String mob,
java.lang.String itemName,
int meta,
int amount,
float rate)
mob - The id or name of the mobitemName - The name of the itemmeta - The metadata of the itemamount - The amount of the itemrate - The rate of the drop where 0.0 is 0% and 1.0 is 100%public void addCreativeTab(java.lang.String name,
java.lang.String itemName,
int meta)
name - The name of the tabitemName - The name of the tab icon itemmeta - The metadata of the tab icon itempublic void enableHelmetRendering()
public void disableHelmetRendering()
public void enablePortalRendering()
public void disablePortalRendering()
public void enableHotbarRendering()
public void disableHotbarRendering()
public void enableCrosshairsRendering()
public void disableCrosshairsRendering()
public void enableBossHealthRendering()
public void disableBossHealthRendering()
public void enableHealthRendering()
public void disableHealthRendering()
public void enableArmorRendering()
public void disableArmorRendering()
public void enableFoodRendering()
public void disableFoodRendering()
public void enableAirRendering()
public void disableAirRendering()
public void enableExperienceRendering()
public void disableExperienceRendering()
public void enableObjectiveRendering()
public void disableObjectiveRendering()
public java.lang.String getBlockType(java.lang.String blockName)
blockName - The name of the block.public java.lang.String getModName()
public java.lang.String readFile(java.lang.String file)
throws java.io.IOException
file - The path of the file to be read. If the path starts with a '/', the path is relative to the .minecraft directory. If it
doesn't start with '/', the path is relative to the mod's data directory.java.io.IOExceptionpublic void writeFile(java.lang.String file,
java.lang.String content)
throws java.io.IOException
file - The path of the file. If the path starts with a '/', the path is relative to the .minecraft directory. If it doesn't start
with '/', the path is relative to the mod's data directory.content - The content to write to the file.java.io.IOExceptionpublic void appendFile(java.lang.String file,
java.lang.String content)
throws java.io.IOException
file - The path of the file. If the path starts with a '/', the path is relative to the .minecraft directory. If it doesn't start
with '/', the path is relative to the mod's data directory.content - The content to append to the file.java.io.IOException