Archived
Fix ItemStack-to-Item type mismatch in ToyakoBokutou
This commit is contained in:
1 parent
83432ac5c3
commit
f346ce0a1e
32 files changed
+13
-26
No files matched your search
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -1,4 +1,9 @@
|
||||
// Add your dependencies here
|
||||
|
||||
dependencies {
|
||||
compileOnlyApi('mods.flammpfeil.slashblade:SlashBlade:1.0.0-stub')
|
||||
}
|
||||
|
||||
repositories {
|
||||
mavenLocal()
|
||||
}
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -13,6 +13,7 @@ import cpw.mods.fml.common.Mod;
|
||||
import cpw.mods.fml.common.event.FMLPreInitializationEvent;
|
||||
import mods.flammpfeil.slashblade.SlashBlade;
|
||||
import mods.flammpfeil.toyako.named.ToyakoBokutou;
|
||||
import net.minecraftforge.common.MinecraftForge;
|
||||
|
||||
@Mod(name="toyako", modid="flammpfeil.toyako", version="mc1.7.2-r1")
|
||||
public class Toyako {
|
||||
@@ -22,7 +23,7 @@ public class Toyako {
|
||||
|
||||
@Mod.EventHandler
|
||||
public void preInit(FMLPreInitializationEvent evt) {
|
||||
SlashBlade.InitEventBus.register((Object)new ToyakoBokutou());
|
||||
MinecraftForge.EVENT_BUS.register((Object)new ToyakoBokutou());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -44,12 +44,12 @@ implements VillagerRegistry.IVillageTradeHandler {
|
||||
|
||||
@SubscribeEvent
|
||||
public void init(LoadEvent.InitEvent event) {
|
||||
ItemStack customblade = new ItemStack((Item)SlashBlade.bladeNamed, 1, 0);
|
||||
ItemStack customblade = new ItemStack(SlashBlade.bladeNamed.getItem(), 1, 0);
|
||||
NBTTagCompound tag = new NBTTagCompound();
|
||||
customblade.func_77982_d(tag);
|
||||
customblade.writeToNBT(tag);
|
||||
ItemSlashBladeNamed.CurrentItemName.set(tag, this.name);
|
||||
ItemSlashBladeNamed.CustomMaxDamage.set(tag, Integer.valueOf(70));
|
||||
ItemSlashBlade.setBaseAttackModifier((NBTTagCompound)tag, (float)(4.0f + Item.ToolMaterial.STONE.func_78000_c()));
|
||||
ItemSlashBlade.setBaseAttackModifier((NBTTagCompound)tag, (float)(4.0f + Item.ToolMaterial.STONE.getDamageVsEntity()));
|
||||
ItemSlashBlade.TextureName.set(tag, "named/toyako/toyako");
|
||||
ItemSlashBlade.ModelName.set(tag, "named/toyako/toyako");
|
||||
ItemSlashBlade.SpecialAttackType.set(tag, Integer.valueOf(4));
|
||||
@@ -64,9 +64,9 @@ implements VillagerRegistry.IVillageTradeHandler {
|
||||
}
|
||||
|
||||
public void manipulateTradesForVillager(EntityVillager villager, MerchantRecipeList recipeList, Random random) {
|
||||
if (villager.func_70946_n() == 3) {
|
||||
ItemStack blade = SlashBlade.getCustomBlade((String)"flammpfeil.slashblade", (String)this.name);
|
||||
recipeList.add((Object)new MerchantRecipe(new ItemStack(Items.field_151166_bC, 3 + random.nextInt(5)), blade));
|
||||
if (villager.getProfession() == 3) {
|
||||
ItemStack blade = (ItemStack)SlashBlade.getCustomBlade((String)"flammpfeil.slashblade", (String)this.name);
|
||||
recipeList.add((Object)new MerchantRecipe(new ItemStack(Items.emerald, 3 + random.nextInt(5)), blade));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
-19
@@ -1,19 +0,0 @@
|
||||
pluginManagement {
|
||||
repositories {
|
||||
maven {
|
||||
name "GTNH Maven"
|
||||
url "https://nexus.gtnewhorizons.com/repository/public/"
|
||||
mavenContent {
|
||||
includeGroup("com.gtnewhorizons")
|
||||
includeGroupByRegex("com\.gtnewhorizons\..+")
|
||||
}
|
||||
}
|
||||
gradlePluginPortal()
|
||||
mavenCentral()
|
||||
mavenLocal()
|
||||
}
|
||||
}
|
||||
|
||||
plugins {
|
||||
id 'com.gtnewhorizons.gtnhsettingsconvention' version '2.0.24'
|
||||
}
|
||||
Reference in new issue
Block a user