ProjectE - roidrole/Roids-Tweaker GitHub Wiki
Components :
EMCManager
Import:
import mods.ctintegration.projecte.EMCManager;
| Method | Description |
|---|---|
| static void mapEMC() | ProjectE normally maps emc values when the server starts, which is way later than when CraftTweaker registers it's recipes. If you want to get the EMC value outside of an event, you will have to call this method first to force ProjectE to map the EMC values. Otherwise, you will get 0 EMC for every item. Make sure not to use this for a lot of times because mapping EMC takes a long time, especially on large modpacks. |
| static void mapEMC(IItemStack item) | Like above but matches a single item. Is between 100 and Inf times faster |
| static long getEMC(IItemStack item) | Gets the EMC value for an item. If you want to use this outside of events you will have to call mapEMC first. |
| static long getEMCSellValue(IItemStack item) | Gets the sell value for an item, depends on your ProjectE configuration. Also same as above, call mapEMC first. |
| static boolean isEMCSet(IItemStack item) | Returns if an item's EMC value has been set |
| static void setEMC(IIngredient ingredient, long value) | Sets EMC for all items in an IIngredient. Internally converts to an IItemStack list |
FuelManager
Allows setting custom ProjectE fuels (items whose EMC recharge items and can be upgraded in an EMC collector)
Import:
import mods.ctintegration.projecte.FuelManager;
| Method | Description |
|---|---|
| static void addFuel(IItemStack item) | Adds the IIngredient (must be an ItemStack) to ProjectE's fuel list |
| static void removeDefaults() | Stops ProjectE form adding its default fuels (recommended over removeFuel) |
| static void removeFuel(IItemStack item) | Removes a fuel form ProjectE's fuel list |
IItemStack Expansion
You can call these methods on an IItemStack instance.
| Method | Parameters | Return Type |
|---|---|---|
| getEMC | [None] | long |
| setEMC | amount as long | void |
| getEMCSellValue | [None] | long |
Note : the emc getters are lowercase
IPlayer Expansion
You can call these methods on an IPlayer instance.
| Method | Parameters | Return Type | Description |
|---|---|---|---|
| getPersonalEMC | [None] | long | Gets the player's personal EMC value. |
| setPersonalEMC | amount as long | void | Sets the player's personal EMC value. |