Initiating Suicide Protocol:
> Fixed unit leveling being broken
- future be ready for banner bearers to be modified
> Added 12 Ingredients to create spices with
- Morgul Caps from Mordor/Isengard traders
- Fine Bone Dust from Gundabad/Half Troll traders
- Blighted Roots from Dol Guldur/Angmar traders
- Curing salts from Dwarven Merchants
- Miners Lichen from Blue dwarf miners
- underroot from Durins folk miners
- Willowbark from every florist/shaman ever to exist
- brambleberry from any butcher/hunter ever to exist
- coldbreath leaf from any brewer or innkeeper ever to exist
- Dried mallorn leaves from lothlorien merchants
- niphredil seeds from wood elf smiths, dorwinion vintner elves, dorwinion merchants
- seregon from rivendell merchants
> Made textures for all 12 ingredients, and the 4 final spice products
- Gave the spices new names
> Orc traders will gladly buy your maggoty bread for very bad rates (bad for you)
> Bladorthin and red dwarf smiths now know what repair and upgrade kits are
> Crafting two of these kits together will make a field repair kit
> added field repair kits, they take 10 seconds to apply, but repair 5% of your current armor durability
> Orcs no longer should be nerfed by mevans more than they already are
> added some achievements
> Shinare why did the developer break up with their Enum?
Because it just wasn’t their type. 😎
main
@ -0,0 +1,62 @@
|
|||||||
|
package com.zivilon.cinder_loe.items;
|
||||||
|
|
||||||
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
|
import net.minecraft.item.Item;
|
||||||
|
import net.minecraft.item.ItemArmor;
|
||||||
|
import net.minecraft.item.ItemFood;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
public class FieldRepairKit extends ItemFood {
|
||||||
|
|
||||||
|
private int damageAmount;
|
||||||
|
public FieldRepairKit() {
|
||||||
|
super(0, 0.0F, false); // No hunger, no saturation
|
||||||
|
this.setAlwaysEdible(); // Allow eating even at full hunger
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int getItemStackLimit() {
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ItemStack onEaten(ItemStack stack, World world, EntityPlayer player) {
|
||||||
|
if (!world.isRemote) {
|
||||||
|
world.playSoundAtEntity(player, "random.anvil_break", 1.0F, 1.0F);
|
||||||
|
}
|
||||||
|
return super.onEaten(stack, world, player);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void onFoodEaten(ItemStack stack, World world, EntityPlayer player) {
|
||||||
|
if (!world.isRemote) {
|
||||||
|
for (int i = 0; i < 4; i++) {
|
||||||
|
ItemStack armor = player.getCurrentArmor(i);
|
||||||
|
if (armor != null && armor.getItem() instanceof ItemArmor && armor.isItemDamaged()) {
|
||||||
|
int maxDamage = armor.getMaxDamage();
|
||||||
|
int repairAmount = Math.max(1, (int)(maxDamage * 0.05));
|
||||||
|
armor.setItemDamage(Math.max(0, armor.getItemDamage() - repairAmount));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onUsingTick(ItemStack stack, EntityPlayer player, int count) {
|
||||||
|
if (!player.worldObj.isRemote && count % 20 == 0) {
|
||||||
|
player.worldObj.playSoundAtEntity(player, "random.anvil_use", 0.7F, 1.0F);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ItemStack onItemRightClick(ItemStack stack, World world, EntityPlayer player) {
|
||||||
|
player.setItemInUse(stack, this.getMaxItemUseDuration(stack));
|
||||||
|
return stack;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int getMaxItemUseDuration(ItemStack stack) {
|
||||||
|
return 200;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,85 @@
|
|||||||
|
package com.zivilon.cinder_loe.items;
|
||||||
|
|
||||||
|
import com.zivilon.cinder_loe.LoECreativeTabs;
|
||||||
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
|
import net.minecraft.creativetab.CreativeTabs;
|
||||||
|
import net.minecraft.item.Item;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.util.IIcon;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public class spiceIngredient extends Item {
|
||||||
|
public IIcon[] icons;
|
||||||
|
|
||||||
|
public spiceIngredient() {
|
||||||
|
this.setHasSubtypes(true);
|
||||||
|
setMaxStackSize(64);
|
||||||
|
this.setMaxDamage(0);
|
||||||
|
setCreativeTab(LoECreativeTabs.tabMiscLoE);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public IIcon getIconFromDamage(int damage) {
|
||||||
|
if (damage < 0 || damage >= icons.length) {
|
||||||
|
damage = 0;
|
||||||
|
}
|
||||||
|
return this.icons[damage];
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void registerIcons(IIconRegister iconRegister) {
|
||||||
|
this.icons = new IIcon[12];
|
||||||
|
this.icons[0] = iconRegister.registerIcon("lotr:fine_bone_dust");
|
||||||
|
this.icons[1] = iconRegister.registerIcon("lotr:dried_morgul_caps");
|
||||||
|
this.icons[2] = iconRegister.registerIcon("lotr:blighted_root");
|
||||||
|
this.icons[3] = iconRegister.registerIcon("lotr:coldbreath_leaf");
|
||||||
|
this.icons[4] = iconRegister.registerIcon("lotr:brambleberry");
|
||||||
|
this.icons[5] = iconRegister.registerIcon("lotr:willow_bark");
|
||||||
|
this.icons[6] = iconRegister.registerIcon("lotr:seregon");
|
||||||
|
this.icons[7] = iconRegister.registerIcon("lotr:niphredil_seeds");
|
||||||
|
this.icons[8] = iconRegister.registerIcon("lotr:dried_mallorn");
|
||||||
|
this.icons[9] = iconRegister.registerIcon("lotr:curing_salts");
|
||||||
|
this.icons[10] = iconRegister.registerIcon("lotr:underroot");
|
||||||
|
this.icons[11] = iconRegister.registerIcon("lotr:miners_lichen");
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String getUnlocalizedName(ItemStack item) {
|
||||||
|
switch(item.getItemDamage()) {
|
||||||
|
case 0:
|
||||||
|
return "item.fine_bone_dust";
|
||||||
|
case 1:
|
||||||
|
return "item.dried_morgul_caps";
|
||||||
|
case 2:
|
||||||
|
return "item.blighted_root";
|
||||||
|
case 3:
|
||||||
|
return "item.coldbreath_leaf";
|
||||||
|
case 4:
|
||||||
|
return "item.brambleberry";
|
||||||
|
case 5:
|
||||||
|
return "item.willow_bark";
|
||||||
|
case 6:
|
||||||
|
return "item.seregon";
|
||||||
|
case 7:
|
||||||
|
return "item.niphredil_seeds";
|
||||||
|
case 8:
|
||||||
|
return "item.dried_mallorn";
|
||||||
|
case 9:
|
||||||
|
return "item.curing_salts";
|
||||||
|
case 10:
|
||||||
|
return "item.underroot";
|
||||||
|
case 11:
|
||||||
|
return "item.miners_lichen";
|
||||||
|
default:
|
||||||
|
return "item.fine_bone_dust";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void getSubItems(Item item, CreativeTabs tab, List list) {
|
||||||
|
for (int i = 0; i < icons.length; i++) {
|
||||||
|
list.add(new ItemStack(item, 1, i));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,43 @@
|
|||||||
|
package com.zivilon.cinder_loe.mixins;
|
||||||
|
|
||||||
|
import com.zivilon.cinder_loe.CinderLoE;
|
||||||
|
import lotr.common.LOTRMod;
|
||||||
|
import lotr.common.enchant.LOTREnchantment;
|
||||||
|
import lotr.common.enchant.LOTREnchantmentHelper;
|
||||||
|
import lotr.common.entity.npc.LOTREntityNPC;
|
||||||
|
import lotr.common.entity.npc.LOTREntityOrc;
|
||||||
|
import lotr.common.entity.npc.LOTREntityWarg;
|
||||||
|
import net.minecraft.entity.Entity;
|
||||||
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
|
import net.minecraft.item.Item;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.util.MathHelper;
|
||||||
|
import net.minecraft.world.World;
|
||||||
|
import org.spongepowered.asm.mixin.Mixin;
|
||||||
|
import org.spongepowered.asm.mixin.Overwrite;
|
||||||
|
import org.spongepowered.asm.mixin.Shadow;
|
||||||
|
import org.spongepowered.asm.mixin.injection.At;
|
||||||
|
import org.spongepowered.asm.mixin.injection.Inject;
|
||||||
|
import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable;
|
||||||
|
|
||||||
|
|
||||||
|
@Mixin(LOTREntityOrc.class)
|
||||||
|
public abstract class MixinLOTREntityOrc extends LOTREntityNPC {
|
||||||
|
public boolean isWeakOrc = true;
|
||||||
|
|
||||||
|
public MixinLOTREntityOrc(World worldIn) {
|
||||||
|
super(worldIn);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author KeyLime17
|
||||||
|
* @reason Mevans
|
||||||
|
*/
|
||||||
|
@Overwrite(remap = false)
|
||||||
|
public int getTotalArmorValue() {
|
||||||
|
if (this.isWeakOrc) {
|
||||||
|
return MathHelper.floor_double((double)((double)super.getTotalArmorValue() * 1));
|
||||||
|
}
|
||||||
|
return super.getTotalArmorValue();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
After Width: | Height: | Size: 588 B |
|
After Width: | Height: | Size: 418 B |
|
After Width: | Height: | Size: 419 B |
|
After Width: | Height: | Size: 462 B |
|
After Width: | Height: | Size: 412 B |
|
After Width: | Height: | Size: 440 B |
|
After Width: | Height: | Size: 5.8 KiB |
|
After Width: | Height: | Size: 529 B |
|
After Width: | Height: | Size: 385 B |
|
After Width: | Height: | Size: 542 B |
|
Before Width: | Height: | Size: 5.8 KiB After Width: | Height: | Size: 858 B |
|
After Width: | Height: | Size: 442 B |
|
Before Width: | Height: | Size: 4.3 KiB After Width: | Height: | Size: 579 B |
|
Before Width: | Height: | Size: 4.3 KiB After Width: | Height: | Size: 594 B |
|
Before Width: | Height: | Size: 4.5 KiB After Width: | Height: | Size: 525 B |
|
Before Width: | Height: | Size: 4.5 KiB After Width: | Height: | Size: 527 B |
|
After Width: | Height: | Size: 731 B |
|
Before Width: | Height: | Size: 858 B After Width: | Height: | Size: 5.8 KiB |
|
After Width: | Height: | Size: 511 B |