Everything posted by FLUFFY2
-
[1.7.2] Custom Entity only attack when he sees you.
Hello there, I have a problem with my custom mob AI. I try to make it so it can only attack you if he sees you. So if its too dark he can only see you if you are close enough. If its light he can only see you if he saw you. I tryed the following but its not worked: if(par1World.getLightBrightness((int)this.posX, (int)this.posY, (int)this.posZ) >= 4 && getEntitySenses().canSee(player)) this.targetTasks.addTask(2, new EntityAINearestAttackableTarget(this, EntityPlayer.class, 0, true)); if(par1World.getLightBrightness((int)this.posX, (int)this.posY, (int)this.posZ) < 4 && getEntitySenses().canSee(player) && getEntityAttribute(SharedMonsterAttributes.followRange).getAttributeValue() >= 5.0D) this.targetTasks.addTask(2, new EntityAINearestAttackableTarget(this, EntityPlayer.class, 0, true)); Thanks!
-
[1.7.9]Forge update?
Hello there. There is any news or release dates for forge 1.7.9? Coz i see forge 1.7.2 kinda stable now and a lot of mods has been updated now. Thanks!
-
[1.7.2] Add information to blocks.
Well i don't have an extend ItemBlock class. Only extend BlockContainer. And the @Override is gives an error.
-
[1.7.2] Add information to blocks.
Hello everyone! I want to add informations to my blocks. In items i found "addInformation()" and it works. But for ItemBlock what should i use? There is no "addInformation()" there. Thanks for helping!
-
[1.7.2]Shift click stacking problem
I have a battery item once its crafted it has no power(fully damaged). You recharge it in a crafting table and its powered(not damaged). You can stack up to 16 but only powered or not powered can stack because of the metadata. The proble is if the powered is in the inventory and the not powered is in the hotbar you shift click and they stuck up so the powered gets no powered. Same if you drop not powered and powered on the same spot they got stacked up again. I thik thats a bug that not damaged items stuck up with damaged items and change their metadata. The only fix is to set the item max stack size to 1.
-
[1.7.2]Damage bar as a fuel bar
Its working now! Many thanks to you!
-
[1.7.2]Damage bar as a fuel bar
Thank you for that, but even if i try with a simple: return 0.8; Its still not showing up the 80% damage bar.
-
[1.7.2]Damage bar as a fuel bar
@Override public double getDurabilityForDisplay(ItemStack stack) { return (double)getOilLevel(stack) / (double)Lantern.lanternFuelCapacity * 60; }
-
[1.7.2]Damage bar as a fuel bar
You guys don't understand me. Sorry if i wrote it down wrong. I have a fuel system saved and loaded from NBTs. I don't useing damage value as fuel storing. I only want to use it for visual not for functional reasons. I use the method what diesieben sent me. I got the fuel from the NBT and devide it by the max fuel value that the item can store. There is no metatdata used! So the resoult is a number between 0,0 and 1,0. I read 1.0 mean damage bar 100% and 0.0 means 0%; But that display method not working and there is no "visual damage bar" shown. Again there is no item damageing happening in the background. Forget my previous code.
-
How to edit minecraft.jar?
Its a realy bad idea to modify base classes because it can make compatible issuses with other mods. Forge has many hooks that you can use now. But in 1.7.2 forgegradle you can't edit because its protected.
-
[1.7.2]Damage bar as a fuel bar
Seriously, what the hell? So the method looks like this: @Override public double getDurabilityForDisplay(ItemStack stack) { return (double)stack.getItemDamageForDisplay() / (stack)stack.getMaxDamage(); } But if i get the fuel stored in NBT data and run trough a calculation that uses itemstack.setDamage(calculation(oil)) in onUpdate it still bounces when the damage bar is mooving. So please can you show me a little piace of code for me? I would apprechiate it!
-
[1.7.2]Damage bar as a fuel bar
Thank you diesieben! But how am i supposed to use this? I get the current fuel level divided by the max fuel level. In the onUpdate method i put "getDurabilityForDisplay(par1ItemStack)" to update the damage bar. But no damage bar shown. I saw 1.0 means 100% so i just simply return 1.0 but still not showing the bar. Thanks anyway!
-
[1.7.2]Damage bar as a fuel bar
Mayebe i should try out overlay gui. Its getting popular nowdays.
-
[Solved][1.7.2]Packets problem
You have to take your time and learn a bit then. Once you got it you can do realy cool stuffs.
-
[Solved][1.7.2]Packets problem
Its realy easy once you understand them. I used this and worked like a charm. http://www.minecraftforge.net/wiki/Netty_Packet_Handling
-
[1.7.2]Damage bar as a fuel bar
Hello everyone! I have an item that requires fuel saving its data to NBTs and its working. I want to use the damage bar as a fuel bar. I have already wrote a quick calculation thats updates the fuel bar. The only proble is the item is unequipping and equipping because of the update. Its updateing every 1 second and not every tick. How can i slove this problem? super.onUpdate and !par1World.isremote not help. Can i save damage value into NBT datas and display that somehow? Thanks!
-
[1.7.2]Access Transformer not working
Great new! Updated to Forge .1057 and it looks like i don't even need AT anymore. They made the field public for us. Thank you guys!
-
[1.7.2]Access Transformer not working
Wait it has to be modid_at.cfg or anything_at.cfg?
-
[1.7.2]Access Transformer not working
Yep i read that too and tryed it, but not working for me. There is any free src for a mod that uses AT?
-
[1.7.2]Access Transformer not working
Bump
-
[1.7.2]Access Transformer not working
Yes. When i start gradlew build its say that access transformer was found.
-
[1.7.2]Access Transformer not working
FML log(latest): https://gist.github.com/anonymous/10125856 And my _at.cfg is in the resources folder not in my assets.
-
[1.7.2]Access Transformer not working
Please i realy need this. I can't release my mod because the crash.
-
[1.7.2]Access Transformer not working
There is it and its tells that my mod can't access that field coz my AT isn't working.
-
[1.7.2]Access Transformer not working
Changed to: @Override public String getAccessTransformerClass() { return "com.fluffy.lantern.asm.LAFAccessTransformer"; } Still crash.
IPS spam blocked by CleanTalk.