Jump to content

zacharyjaiden

Members
  • Posts

    59
  • Joined

  • Last visited

Converted

  • Gender
    Undisclosed
  • Personal Text
    I am new!

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

zacharyjaiden's Achievements

Stone Miner

Stone Miner (3/8)

2

Reputation

  1. *facepalm* typos FTW should probably stop "CTRL - O" importing and import stuff myself i think id save myself a lot of issues thanks
  2. hey guys, im having trouble with a forge event, the event doesnt seem to be getting called at all, ill post any relevant code if needed package com.MCR.MinecraftReloaded.Event; import net.minecraft.entity.passive.EntityCow; import net.minecraft.init.Items; import net.minecraftforge.event.entity.living.LivingDeathEvent; import com.google.common.eventbus.Subscribe; public class DropsEvent { @Subscribe public void LivingDropsEvent(LivingDeathEvent event){ System.out.println("eventdrops working"); if (event.entityLiving instanceof EntityCow) { event.entityLiving.dropItem(Items.bone, 3); } } } its being registered like so in forge preinit like my other events MinecraftForge.EVENT_BUS.register(new DropsEvent()); thanks in advance
  3. thanks for the help and sorry for snapping mate
  4. Ok, i get what youre saying cool alias and i guess youre right, its just im dedicating hours of my time to read java documentation, minecraft tutorials and browsing the forums, when im getting responses of "Learn basic java" its really annoying me BIG time as i am very new to this and i am like i said dedicating quite a large portion of my time to learning all the fundamentals of java and learning the way minecraft is coded, i feel like those comments shot straight out of nowhere get to me. i owe you a bit of an apology diesie, i shouldnt of gotten angry at you, i do in fact appreciate your help, ive known the basics of java and modding minecraft for quite a while although havent done it for a couple years so i have forgotten quite a few things... i never needed to expand my knowledge of java cause i didnt need to know anything new but ive been trying to venture into new territories in modding and faced a lot of java problems and in doing so, ive spent hours recapping over the java i already knew, and have spent hours reading up on new java information when relevant issue arise, i may ask some dumb questions but like i said im new, i absolutely do not want anybody to write the mod for me but i do appreciate helpful information something like "google switch statements mate that might help" rather than "Learn basic java. use (this word) instead of (thatword)" helps a lot more and would be appreciated 100 times more if im asking a question on here its because i probably dont know what area of java to look up for the class im trying to create
  5. you do need to get off your high horse, just because somebody doesnt understand java yet to the extent that you do does not mean that they dont know "basic java", i learn the java associated with minecraft modding because im using it to MOD MINECRAFT, i learn what i can from tutorials (which im sure you read tutorials when you were starting out too) also from minecraft source code, i dont know all of the applications of the code ive learnt but i know how to use it pretty widely, what i dont know i come to this forum for help, (which is the very purpose of this forum) not for criticism on my knowledge of the language... your contribution consisted of a single word, which i already knew just didnt think to apply it and you find it necessary to downgrade my knowledge and skills when in comparison to you obviously high opinions and views on your own, i am fairly new to java and minecraft modding hence why i seek out support. again get off your high horse mate come to this forum to help people not throw out negative comments. that one word "instanceof" was all i needed not my code written for me as you seem to think
  6. thank you for your amusing arrogance diesieben but i do know basic java. you dont have to try and belittle everyone on this forum i look at quite a few posts on this forum and a great percentage of them have at least one post from you using that little phrase of yours, i have used instanceof before with items and blocks but didnt know that it would apply to an entity since the way i came about that term implied that it was something used for "things" not entities so i never looked into it too much, obviously i was wrong but i and everyone else on this forum dont need comments like those, it may very well hinder peoples ability to learn and progress their skills as you probably make a lot of people uncomfortable and or embarrassed which im sure youre quite aware of... i dont appreciate it. my attempt in thinking if the entity == entityWHATEVER isnt that far fetched.. at least gotoLink can provide help without trying to downgrade others (appreciate your help gotolink +1 karma) and its not like i was asking anyone to code the thing for me i had a general idea of what i was doing from the start
  7. thanks, but how would i appropriately reference the entity? i tried if(event.entity == EntityBunny.class); but that errors the whole line, i tried just if(event.entity == EntityBunny); that errors on entity bunny, idk how to refer to the mob
  8. override this method /** * Called whenever this item is equipped and the right mouse button is pressed. Args: itemStack, world, entityPlayer */ public ItemStack onItemRightClick(ItemStack par1ItemStack, World par2World, EntityPlayer par3EntityPlayer) { if (par3EntityPlayer.fishEntity != null) { int i = par3EntityPlayer.fishEntity.func_146034_e(); par1ItemStack.damageItem(i, par3EntityPlayer); par3EntityPlayer.swingItem(); } else { par2World.playSoundAtEntity(par3EntityPlayer, "random.bow", 0.5F, 0.4F / (itemRand.nextFloat() * 0.4F + 0.8F)); if (!par2World.isRemote) { par2World.spawnEntityInWorld(new EntityFishHook(par2World, par3EntityPlayer)); } par3EntityPlayer.swingItem(); } return par1ItemStack; } to do that add "@Override" to the line above public ItemStack onItemRightClick(ItemStack par1ItemStack, World par2World, EntityPlayer par3EntityPlayer) in your new overridden method change the line par2World.spawnEntityInWorld(new EntityFishHook(par2World, par3EntityPlayer)); >>>>>>ENTITYFISHHOOK<<<<< to your new custom entity fish hook and fix the appropriate errors if any occur
  9. lol ive never seen that before >.< thats cool i kinda want to know how you did it so i can do it you didnt change the resolution of the texture did you ?
  10. bounding boxes can move with blocks but you have to add another method to change the bound box with orientation, the bound box is done in floats i believe it starts to one side of a block, not from the middle, but you can figure out what values change what side by trial and error this is code for a cube like bounding box in the middle of a block this.setBlockBounds(A-0.170F, B-0.0F, C-0.180F, D-0.830F, E-0.80F, F-0.820F); B value when increased moves the bottom of the bounding box upwards the E value when DECREASED moves the top of the bounding box down or when Increased moves the bounding box border upwards i believe A and D are x axis, also C and F are y axis (OR THE OTHER WAY AROUND) off memory the bound box DOESNT move with entities but i may be wrong there may be a way for it
  11. ok so im making it so that my custom entities (and maybe some vanilla entities) can only spawn when condition is met, i have browsed through the forge events and found the event living spawn event, is that suited for this? i am not quite sure how to properly use this event can anybody help out with this? in sudo ive kinda thought of this way @SubscribeEvent public void LivingSpawnEvent(LivingSpawnEvent event) { EntityPlayer player = (EntityPlayer)event.getPlayer(); if(event.entity == EntityCutstomMob && StorageLevel.getPlayer().GetMasterLevel() < 5) { setCanceled{True} } } i know this event or a part of this event is cancelable but im not 100% sure how to properly set canceled so if anyone knows that aswell please let me know, but basically i need to know how to do this in the way that ive displayed but obviously not sudo properly with the correct terms and such thanks in advance +1 karma for any answers (that arent just for sake of getting karma)
  12. ive added the enchantment effect to items using, @SideOnly(Side.CLIENT) public boolean hasEffect(ItemStack par1ItemStack) { return true; } with a few items like ingots and such just inside the item class, armour is made like an item and has the ability to use the effect in standard vanilla, i dont see why you cant use the method in the armour class? have you tried it
  13. okay thats kinda what i was looking for a place to start, (what to extend) i think flowers is a good option as i dont need anything special to happen i just need these bushes to randomly spawn like flowers... but do you mean to say that event can be used in conjunction with the the generator or can be used in replace of the generator for what i need to do
  14. thanks for the link but that was a link to creating the flower block itself with i already had, i need to generate it, from what ive gathered i need to use the biome decorator, my questions are: what class should i extend to use biome decorator? should i extend biome decorator itself or IworldGenerator (like i did with my ores) or World generator like with a tree or what, BiomeGenBase im not sure where to start off my file... (Im a noob when it comes to all generation apart from ore)
×
×
  • Create New...

Important Information

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