Jump to content

CritiqualError

Members
  • Posts

    14
  • Joined

  • Last visited

Converted

  • Gender
    Undisclosed
  • Personal Text
    I am new!

CritiqualError's Achievements

Tree Puncher

Tree Puncher (2/8)

1

Reputation

  1. I have these public int quantityDropped(Random par1Random){ return 1; } public Item getItemDropped(IBlockState state, Random rand, int fortune){ return Items.apple; //Just example } But it still drops itself. And it wont let me override. it tells me to remove "@Override"
  2. How would I go about making a block not drop itself... or anything at all. I want it where when the block it broken, then it just breaks and nothing drops. EDIT: I solved it by restarting eclipse... it works now these random things not working are really making me feel dumb, bc i know i do them right, but for some reason they randomly dont work until i reset eclipse. all good now
  3. I did this, and it worked out, thanks. Though it spawns the itemstack twice. one i can pick up, the other i cant. ?
  4. I want to make it where when I activate a block, it spawns an item above the block. How would I go about doing that? I'm not too familiar with all the functions and would like to learn more of them so I wont have to ask for help so much.
  5. Okay, so I have a bock, that when you break it, it turns into another block. I want that block to then start ticking down a timer and turn back into the original block. How could I setup a block to tick, or a TileEntity to tick. I've been looking at tileentity tutorials but none seem to show me how to make a timer tick down or any sort of per tick function. i really need some help getting this to work. tileentities are still confusing to me and I'm get to get one to properly work.
  6. I said the problem already. I'm not sure whats wrong with it. It just says "ItemPickaxe" is wrong and gives no suggestions. its imported, the pickaxe_example is setup, the ExampleMaterial is setup. idk whats wrong passed that.
  7. Problem Solved?Instead of typing it out, I let it autofill and that corrected the issue? idk. its working now though. I have no idea what happened. Something little this time... and its confusing me and I'm probably just missing something little. pickaxe_example = new ItemPickaxe(ExampleMaterial).setUnlocalizedName("pickaxe_example").setCreativeTab(example.exampletab); The error im getting is about the "new ItemPickaxe..." and I'm not sure what's wrong with it. It's underlined with an error and it gives no suggestions. {ItemPickaxe is imported as well} I have these setup beforehand too public static ToolMaterial ExampleMaterial = EnumHelper.addToolMaterial("ExampleMaterial", 0, 99, 1.0f, 1.0f, 0); public static Item pickaxe_example ;
  8. CLOSED: I found the bouncing weapon bug issue. I can hopefully fix it. I think its an NBTTag change that resets the weapon position or something. I have made my own custom attack speed system that limits the speed at which you can attack mobs (no more click-spam) I created this system so i can implement new weapon types. It has gone very well so far! (I have done this with NBTTags: canAttack, attackSpeed, and coundtUp. When countUp is more than attackSpeed, canAttack enables, and causes the onLeftClickEntity to return false, instead of true which causes the weapon to not attack.) But my issue is that I would like to also change the animation speed of swinging weapon. It has this hopping animation bug when unable to attack, that I'm hoping will be hidden if the attack speed could be slowed down. Another thing which isnt as important right now is extending the reach of a weapon, or lowering the reach. if thats possible. EDIT: I'm hoping to find a solution without using the Haste or MiningFatigue potion effects to simulate animation speed
  9. Thanks a bunch. It is very nice to know that I can rely on the forums when I'm stuck on a problem. Such a swift response. I also now know new coding (i coded a bit in other programs so I kinda get how coding works, just this minecraft stuff is rather new to me) I will put this to good use and see what I can do.
  10. Did you even read it? its called converting an integer to a string.
  11. [i am using Eclipse and Forge 1.8] I was wondering how to take certain characters from a string. Example: I convert the number 123456 to a string then I want to assign every 2 characters to a variable: a="12" b="34" c="56". Like that. How would I go about doing that? Or maybe have it start from the end, so it can be like, 12345678 and end up like: a="1234" b="56" c="78". only splitting them between those 3 groups, the a group allowed to overflow as much as it wants.
  12. It's something to work with, thanks for the help, I'll see what I can do with it.
  13. This mod does exactly what it says. It makes all of the vanilla crafting recipes disappear. The perks to this could be making your own mod that redefines minecraft with new recipes and all that good stuff. Downside, you cannot rely on what you know about vanilla crafting A very simple, mod that took just moment to create. http://www.mediafire.com/download/j2o5lozd4zplpvi/VanillaRecipeRemover-1.0.jar Want to inject it strait into your own mod without needed the extra JAR file? Its only 2 class files, one being your main class. MAIN CLASS FILE: (all you need from here is to know to add "RecipeRemover.removeRecipes();" to your Init() ) package com.critiqualerror.vrr; import net.minecraftforge.fml.common.Mod; import net.minecraftforge.fml.common.Mod.EventHandler; import net.minecraftforge.fml.common.event.FMLInitializationEvent; import net.minecraftforge.fml.common.event.FMLPostInitializationEvent; import net.minecraftforge.fml.common.event.FMLPreInitializationEvent; @Mod(modid = VRR.modid, version = VRR.version) public class VRR { public static final String modid = "vrr"; public static final String version = "COMPLETE"; @EventHandler public void PreInit(FMLPreInitializationEvent preEvent){ } @EventHandler public void Init(FMLInitializationEvent event){ RecipeRemover.removeRecipes(); } @EventHandler public void PostInit(FMLPostInitializationEvent postEvent){ } } NOW THIS, this is where the magic happens. This removes crafting recipes. I don't think it touches smelting. I believe you can still smelt stuff no problem package com.critiqualerror.vrr; import java.util.List; import java.util.Iterator; import net.minecraft.init.Items; import net.minecraft.item.ItemStack; import net.minecraft.item.crafting.CraftingManager; import net.minecraft.item.crafting.IRecipe; public class RecipeRemover { public static void removeRecipes(){ List<IRecipe> recipes = CraftingManager.getInstance().getRecipeList(); Iterator<IRecipe> remove = recipes.iterator(); while (remove.hasNext()) { ItemStack itemstack = remove.next().getRecipeOutput(); if (itemstack != null);// && itemstack.getItem() == Items.book) remove.remove(); }; } } Simple wasn't it? There is a comment on one of the last lines of code. Remove the comment if you want to only remove specific items. there you go, have fun.
  14. So, I am relatively new to Forge modding... bear with me please I'm wondering how to check if a player as x amount of an item, then remove x amount of that item from their inventory. any help would be appreciated. thank you. EDIT: I know there is the consumeInventoryItem but that is only 1 at a time. is there a way to do more than 1?
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.