Move config to annotation system
All old configs must be deleted for this to work properly. Since the rest of the update is filled with world breaking changes, this should be fine.
This commit is contained in:
parent
b0404599c2
commit
d587a8c96f
19 changed files with 251 additions and 494 deletions
|
@ -311,7 +311,7 @@ public class ClientHandler {
|
|||
|
||||
public static void cycleSigil(ItemStack stack, EntityPlayer player, int dWheel) {
|
||||
int mode = dWheel;
|
||||
if (!ConfigHandler.sigilHoldingSkipsEmptySlots) {
|
||||
if (!ConfigHandler.client.sigilHoldingSkipsEmptySlots) {
|
||||
mode = ItemSigilHolding.getCurrentItemOrdinal(stack);
|
||||
mode = dWheel < 0 ? ItemSigilHolding.next(mode) : ItemSigilHolding.prev(mode);
|
||||
}
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
package WayofTime.bloodmagic.util.handler.event;
|
||||
|
||||
import WayofTime.bloodmagic.BloodMagic;
|
||||
import WayofTime.bloodmagic.ConfigHandler;
|
||||
import WayofTime.bloodmagic.annot.Handler;
|
||||
import WayofTime.bloodmagic.api.Constants;
|
||||
import WayofTime.bloodmagic.api.event.AltarCraftedEvent;
|
||||
|
@ -51,19 +50,20 @@ public class CraftingHandler {
|
|||
// Handles crafting of: Revealing Upgrade Tome, Elytra Upgrade Tome, Combining Upgrade Tomes, Setting Upgrade for Trainer
|
||||
@SubscribeEvent
|
||||
public void onAnvil(AnvilUpdateEvent event) {
|
||||
if (ConfigHandler.thaumcraftGogglesUpgrade) {
|
||||
if (event.getLeft().getItem() == RegistrarBloodMagicItems.LIVING_ARMOUR_HELMET && event.getRight().getItem() == Constants.Compat.THAUMCRAFT_GOGGLES && !event.getRight().isItemDamaged()) {
|
||||
ItemStack output = new ItemStack(RegistrarBloodMagicItems.UPGRADE_TOME);
|
||||
output = NBTHelper.checkNBT(output);
|
||||
ItemHelper.LivingUpgrades.setKey(output, BloodMagic.MODID + ".upgrade.revealing");
|
||||
ItemHelper.LivingUpgrades.setLevel(output, 1);
|
||||
event.setCost(1);
|
||||
|
||||
event.setOutput(output);
|
||||
|
||||
return;
|
||||
}
|
||||
}
|
||||
// TODO - Azanor come back :(
|
||||
// if (ConfigHandler.thaumcraftGogglesUpgrade) {
|
||||
// if (event.getLeft().getItem() == RegistrarBloodMagicItems.LIVING_ARMOUR_HELMET && event.getRight().getItem() == Constants.Compat.THAUMCRAFT_GOGGLES && !event.getRight().isItemDamaged()) {
|
||||
// ItemStack output = new ItemStack(RegistrarBloodMagicItems.UPGRADE_TOME);
|
||||
// output = NBTHelper.checkNBT(output);
|
||||
// ItemHelper.LivingUpgrades.setKey(output, BloodMagic.MODID + ".upgrade.revealing");
|
||||
// ItemHelper.LivingUpgrades.setLevel(output, 1);
|
||||
// event.setCost(1);
|
||||
//
|
||||
// event.setOutput(output);
|
||||
//
|
||||
// return;
|
||||
// }
|
||||
// }
|
||||
|
||||
if (event.getLeft().getItem() == RegistrarBloodMagicItems.SIGIL_HOLDING) {
|
||||
if (event.getRight().getItem() == Items.NAME_TAG) {
|
||||
|
|
|
@ -186,7 +186,7 @@ public class GenericHandler {
|
|||
|
||||
boolean shouldSyphon = pack.getStoredLP(player.getItemStackFromSlot(EntityEquipmentSlot.CHEST)) < pack.CAPACITY;
|
||||
float damageDone = event.getEntityLiving().getHealth() < event.getAmount() ? event.getAmount() - event.getEntityLiving().getHealth() : event.getAmount();
|
||||
int totalLP = Math.round(damageDone * ConfigHandler.sacrificialPackConversion);
|
||||
int totalLP = Math.round(damageDone * ConfigHandler.values.coatOfArmsConversion);
|
||||
|
||||
if (shouldSyphon)
|
||||
ItemHelper.LPContainer.addLPToItem(player.getItemStackFromSlot(EntityEquipmentSlot.CHEST), totalLP, pack.CAPACITY);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue