GotoLink
Members-
Posts
2012 -
Joined
-
Last visited
-
Days Won
1
Everything posted by GotoLink
-
Right click/clicked block not working
GotoLink replied to Alix_The_Alicorn's topic in Modder Support
You should check if that is working as you expect. this == this.grownBlock -
I'd say Blocks.wooden_slab isn't the one you'd want.
-
1.7.2 Spritenumber error when starting up minecraft
GotoLink replied to Kakarotvg's topic in Modder Support
Setup breakpoints in your client proxy then. -
Then if you did nothing wrong, this is working as expected. Seriously. Details.
-
I can't see any obvious mistake in that code. What values do you call this with ? Bear in mind that in World#setBlockToAir(int,int,int), the middle parameter is the height value. (Just saying this because your "clearColumn" is clearing horizontally) It might also be worth making your world instance a field of this class, so you don't have to pass it through all those methods.
-
You obviously did something wrong with your build. Man, if you can't provide any detail about what you did, noone can help.
-
[1.7.2] - No damage when spawning lightning
GotoLink replied to AppliedOnce's topic in Modder Support
Minecraft mc = Minecraft.getMinecraft(); This is client side only. -
[1.7.2] Randomizing works, with one minor flaw.
GotoLink replied to Godson's topic in Modder Support
You are not keeping the value returned, you keep calling the method, which does what it says. (=Returns a random value each time you call it.) -
isItemInInventory doesn't exist. Try onUpdate(ItemStack, World, Entity,..)
-
EntityJoinWorldEvent will fire for mob spawners, egg, natural spawning, etc. The "name plate" is probably called customNameTag in the code.
-
Make a class to extend Event. Use an EventBus then #post(event) when the event needs to be sent. Use @Cancelable or @HasResult depending on what you want the event effect to be...
-
When you throw it, it is a entity. The "Ball". It needs its own renderer too.
-
patching vanilla method to be able to place saplings on block
GotoLink replied to mlewelt's topic in Modder Support
If you extend Block, you can override any (non-private or final) method in Block. If you extend BlockFlower.... -
I made an example, and it worked. Optional removal - found optionals for class com.example.examplemod.TestItem - processing Optional on com.example.examplemod.TestItem triggered - mod missing battlegear2 Optional removal - interface mods.battlegear2.api.weapons.IBattlegearWeapon removed Optional removal - interface mods.battlegear2.api.weapons.IBattlegearWeapon - stripping method signature references Optional removal - interface mods.battlegear2.api.weapons.IBattlegearWeapon - all method signature references @Optional.Interface(iface = "mods.battlegear2.api.weapons.IBattlegearWeapon", modid = "battlegear2", striprefs = true) public class TestItem extends Item implements IBattlegearWeapon{ public TestItem(int id){ super(id); setUnlocalizedName("test:example"); setTextureName("test:example"); } @Override public boolean allowOffhand(ItemStack stack, ItemStack stack2) { return false; } @Override public boolean isOffhandHandDual(ItemStack stack) { return false; } @Override public boolean offhandAttackEntity(PlayerEventChild.OffhandAttackEvent offhandAttackEvent, ItemStack stack, ItemStack stack2) { return false; } @Override public boolean offhandClickAir(PlayerInteractEvent playerInteractEvent, ItemStack stack, ItemStack stack2) { return false; } @Override public boolean offhandClickBlock(PlayerInteractEvent playerInteractEvent, ItemStack stack, ItemStack stack2) { return false; } @Override public void performPassiveEffects(Side side, ItemStack stack, ItemStack stack2) { } @Override public boolean sheatheOnBack(ItemStack stack) { return false; } } Maybe you have a typo somewhere ?
-
switch(0){ What does that mean to you ?
-
ItemStack#getItem() == itemToCompare Items are initialized only once, you can compare with identity.
-
setResult(DENY)
-
Checking to see if the owner of (x) is logged in?
GotoLink replied to Cyan's topic in Modder Support
You should use PlayerLoggedInEvent / PlayerLoggedOutEvent. -
See /build/libs. That is the default output place.
-
With PopulateChunkEvent.Post you can tell if a village has been created and then search for the structure you want in this area, then place block where you want. See an example.
-
Yes, you can. You need to implement IModGuiFactory. See FMLConfigGuiFactory for an example. Then pass its class name to ModContainer#getGuiClassName() It can replace the config file, since you can't access this menu inside a world. See @Mod guiFactory @Mod canBeDeactivated
-
owner= modid of the mod making sense of the API provides= name of the API -You might want to use a meaningful name, not a modid