xchow
Members-
Posts
16 -
Joined
-
Last visited
Converted
-
Gender
Undisclosed
-
Personal Text
I am new!
xchow's Achievements
Tree Puncher (2/8)
0
Reputation
-
I was testing if I could reference the item if I had his src files since it was going to be a closed non public mod but heres the full class http://pastebin.com/uNn1aXHX
-
do you want the whole class? the only lines pertaining to the block are GameRegistry.findItem(FlansMod.MODID, "ak47"); GameRegistry.registerBlock(industrialloot = new IndustrialSpawner("crate", Material.wood), "crate");
-
Removed the line it might just be how flans works items in content packs this is my current code @Override public ArrayList<ItemStack> getDrops(World world, int x, int y, int z, int metadata, int fortune) { ArrayList<ItemStack> drops = new ArrayList<ItemStack>(); drops.add(new ItemStack(Main.ak47, world.rand.nextInt(3) + 1)); drops.add(new ItemStack(Main.morphinebottle, world.rand.nextInt(2) + 1)); drops.add(new ItemStack(Main.ak47)); return drops;
-
I'm sorry but to explain i've added flans mod to it and i'm trying to get it to drop a ak47 http://pastebin.com/YztMWpmu its only dropping the morphine bottle and not the ak47. I put the GameRegistry.findItem(FlansMod.MODID, "ak47"); in my main class as well if that matters.
-
anyone? :c
-
what i'm trying to do is
-
This is hypothetical no code yet but how would I use ore dictionary or a id in a block drop. In my block I'm making it drop percentages of loot and i'm wanting to drop a flans gun. Is there a way to make it drop a ore dictionary item or how would I import the use of his mod id + the name ?
-
Villager is already registered. I'm asking about spawning the custom villager in the default componets
-
After looking about does DungeonHooks.addDungeonMob("mob", chance); this work with villages? Like spawning them at a village and chance.
-
I figured out how to register the villager and getting him to be able to trade but it only works from a spawn egg/spawner without having to make a custom building how to i make it spawn in like the default vanilla doorless hut ?
-
[1.7.10] Adding Custom Villager trades to a new Villager
xchow replied to xchow's topic in Modder Support
Ik that I can spawn the villager but how do you spawn it at a preexisting village house in the code? -
[1.7.10] Adding Custom Villager trades to a new Villager
xchow replied to xchow's topic in Modder Support
Well there was no entity class in it. VillagerRegistry.instance().registerVillagerId(; VillagerRegistry.instance().registerVillagerSkin(8, new ResourceLocation("ruffles", "textures/dealer.png")); VillagerRegistry.instance().registerVillageTradeHandler(8, new TradeHandler()); VillagerRegistry.instance().getRegisteredVillagers(); That was all needed to make the villager. Is there a way I could make it just spawn randomly around the world ? or would that require a entity class? -
[1.7.10] Adding Custom Villager trades to a new Villager
xchow replied to xchow's topic in Modder Support
To spawn in the Village, as far as I know, you can only do it with a custom house. If you already have a custom house, override the getVillagerType method in your house's class and make it return the id of your villager. if you don't, I suggest you look at some open source mods that add villager houses to get a feel of how to do it. (TConstruct helped me get mine) Could I make it spawn in a premade village building for example the normal house? -
[1.7.10] Adding Custom Villager trades to a new Villager
xchow replied to xchow's topic in Modder Support
Thanks it worked. do you know how to make it spawn default in the village? -
Recently in my mod I started working on a new villager and after doing so I could not figure out to assign new trades to this villager. Registering the villager VillagerRegistry.instance().registerVillageTradeHandler(i, new TradeHandler());} VillagerRegistry.instance().registerVillagerId(; VillagerRegistry.instance().registerVillagerSkin(8, new ResourceLocation("chow", "textures/dealer.png")); VillagerRegistry.instance().getRegisteredVillagers(); In my trade handler for vanilla villagers it goes off case 0 for instance being the farmer. I thought that it being case 8 would represent the id 8 for the custom villager but it still doesn't work. Could anyone help me out with this please?