Jump to content

Choonster

Moderators
  • Posts

    5160
  • Joined

  • Last visited

  • Days Won

    76

Everything posted by Choonster

  1. Environment variables are part of your OS. Just search for "environment variables <your OS here>" and you should find plenty of websites that can tell you how to modify environment variables.
  2. To add new AI tasks you need to use EntityLiving#tasks and EntityLiving#targetTasks , yes. The earliest you can do this is EntityJoinWorldEvent . There's no way to globally add a new AI task that's automatically applied to every entity.
  3. ICapabilityProvider is something that can provide a handler for a given Capability and EnumFacing . TileEntity , Entity and ItemStack implement this so they can provide capabilities (e.g. IItemHandler for the inventory of an item, block or entity). If you want to attach capabilities to an object from vanilla or another mod using AttachCapabilitiesEvent , you need to supply an ICapabilityProvider that returns your handler object. Forge uses CapabilityDispatcher to wrap the ICapabilitiyProvider s from the event into a single ICapabilityProvider . The factory provides a new instance of the handler interface's default implementation. The doc comments of @CapabilityInject explain its purpose pretty clearly: On a field, it will set the field's value to the Capability instance for the specified handler interface when it's registered. On a method, it will call the method with the Capability instance for the specified handler interface when it's registered.
  4. Use IExtendedEntityProperties (1.7.10-1.8. or Capabilities (1.8.9+) to store how many of the item has been given to the cow. When it reaches 3, kill the cow and spawn your mob at the same position. For IEEP , you can follow coolAlias' tutorial. For Capabilities, you can read the official documentation, look at the Capabilities provided by Forge ( CapabilityItemHandler and CapabilityAnimation ), the capability test mod or my own mod's capabilities (API, implementation). I highly recommend updating to 1.8.9 or 1.9, 1.7.10 is very outdated at this point.
  5. The mention of DamageIndicatorsMod.server.DIProxy in the stacktrace made me suspect it may not be a client-only mod (since it looks like it could be the server-side @SidedProxy class), but if it's client-only it may just be a confusingly named class.
  6. If you have the _JAVA_OPTIONS environment variable set, remove it. This should allow Gradle to use the JVM arguments you've specified in gradle.properties.
  7. I suggest you use Forge's animation system for this. I can't help you with it much myself, but there's an example mod here (assets). The commit that added the system briefly explains the purpose of each animation class.
  8. Damage Indicators is trying to load a client-only class on the server. The mod is either client-only or broken, but the end result is that it can't be installed on the server. Normally I'd suggest reporting this to the author, but the mod appears to be abandoned.
  9. IExtendedEntityProperties was deprecated in favour of the Capability system in 1.8.9, it's now been removed completely in 1.9. For examples, you can look at the capabilities provided by Forge ( CapabilityItemHandler and CapabilityAnimation ), the capability test mod or my own mod's capabilities (API, implementation).
  10. There's no way to intercept chat messages on the client before they're sent to the server without some ASM or possibly messing around with Netty to intercept the packet. Why not just create an ICommand and register it with ClientCommandHandler .
  11. It's not directly related to your problem, but you may want to consider moving your inventory to the IItemHandler capability. This will allow the inventory to be stored in memory and only read from/written to NBT when needed instead of having to read/write every time you want to do something.
  12. Forge hasn't yet added support for modded SoundEvent s, see this issue.
  13. Your log is almost unreadable, but it looks like you tried to use a client-only class on the server. It also looks like you're using MCreator, which we can't help you with. These articles explain why you shouldn't use it. If you want help with MCreator, ask on its forum. If you decide to develop a mod properly and want help with an issue or want help with an issue unrelated to your own mod, use Gist or Pastebin to post logs (the full FML log from the logs folder, not the console output) and code with syntax highlighting. To get syntax highlighting on Gist, give each file the appropriate extension (.java for Java code). To get syntax highlighting on Pastebin, select the language from the dropdown at the bottom of the page. It's much easier to read code with proper formatting and syntax highlighting.
  14. You can probably use IPerspectiveAwareModel for this, but I don't know enough about it to help you much further.
  15. Most event fields were made private with public getters in 1.9-12.16.0.1805. Use the getters.
  16. Did you not read the big red text at the top of the site's home page telling you to post your FML log? We can't help you without seeing the log, so upload it to Gist and link it here. The Modder Support section is for help developing mods. The Support section is for help using mods. Your thread should be moved there shortly.
  17. AE is open source, have you tried looking at how it manages its networks?
  18. It turns out that FMLNetworkEvent.ClientConnectedToServerEvent is fired before the client player is created and the server has finished the handshake process, so you can't use Minecraft#thePlayer or send packets. What you can do is have a separate event handler for EntityJoinWorldEvent that you register from the FMLNetworkEvent.ClientConnectedToServerEvent handler. When the client player joins the world, send the chat message and then unregister the event handler. I've written an example of this here.
  19. You have two copies of Tinkers' Construct installed. The Modder Support section is for help developing mods. The Support section is for help using mods. Your thread should be moved there shortly.
  20. Unfortunately, I can't help you with that. I suggest looking at the changes in vanilla's renderers, searching for forum threads relevant to the topic and/or waiting for someone who knows the rendering system to post.
  21. The second argument of the RenderFireball constructor is the scale to render the fireball at, it's not a unique identifier of any kind.
  22. This is what the enchantment table does, so it is indeed possible. Just set the block's model to the basic cube using the standard model system and have your TESR render the hologram above it.
  23. That should work, since it's the same method used by the chat GUI to send chat messages to the server. Does it work if you send some text that isn't a slash command?
  24. It looks like this has been fixed in commit 90758f8, available as version 1.9-12.16.0.1813.
  25. Use EntityPlayerSP#sendChatMessage to send a chat message packet to the server.
×
×
  • Create New...

Important Information

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