Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 05/01/19 in all areas

  1. No, he's the author of some code to unbind the TESR, not the author of Bonsai Trees. But looking at the github issue, the Bonsai Trees author is looking into the performance issues. @DavidM The unbinding code looks fine on the face of it, having looked at TileEntityRendererDispatcher, but I'd recommend testing it with Bonsai Trees and as many other mods as is feasible.
    3 points
  2. Okay, it seems one way to do it is, with this: https://github.com/PaleoCrafter/Dependency-Extraction-Example/tree/library-embedding Hope it works out, or someone else can answer this with more knowledge.
    1 point
  3. I tried a bit, both with a maven repository as a dependency, but also using a jdbc jar file in the root of the file, and it seems that neither of those solutions build the mod with the dependency included. I'm not sure how to solve this and perhaps someone else have a solution, as I couldn't find anyone with quite the same problem as you.
    1 point
  4. https://gist.github.com/williewillus/353c872bcf1a6ace9921189f6100d09a Specifically this section
    1 point
  5. I know it seems counter-intuitive but player motion must be changed on the client, the server doesn't actually control it.
    1 point
  6. DavidM IS the author edit - oops i was thinking cadiboo was talking about davidM code my bad
    1 point
  7. It’s sounds like the author should really fix their code
    1 point
  8. You need a space between -jar and the jar name
    1 point
  9. "Get the crafting result, is that object equal to the string 'minecraft'?" Almost certainly not.
    1 point
  10. Implementing client-only commands works like this: 1. Implement ICommand I created an example command that will show the current time to a user like this: public class GetTimeCommand implements ICommand { @Override public int compareTo(ICommand arg0) { return 0; } @Override public String getName() { return "realtime"; } @Override public String getUsage(ICommandSender sender) { return "/realtime"; } @Override public List<String> getAliases() { List<String> aliases = Lists.<String>newArrayList(); aliases.add("/realtime"); return aliases; } @Override public void execute(MinecraftServer server, ICommandSender sender, String[] args) throws CommandException { DateFormat dateFormat = new SimpleDateFormat("HH:mm:ss"); String time = dateFormat.format(new Date(System.currentTimeMillis())); sender.sendMessage(format(net.minecraft.util.text.TextFormatting.DARK_GREEN, time)); } @Override public boolean checkPermission(MinecraftServer server, ICommandSender sender) { return true; } @Override public List<String> getTabCompletions(MinecraftServer server, ICommandSender sender, String[] args, BlockPos targetPos) { return null; } @Override public boolean isUsernameIndex(String[] args, int index) { return false; } private TextComponentTranslation format(TextFormatting color, String str, Object... args) { TextComponentTranslation ret = new TextComponentTranslation(str, args); ret.getStyle().setColor(color); return ret; } } 2. Register your command Find a good place to register your command(s) at mod start up. I decided to first implement proxies for server and client like described in the Docs: https://mcforge.readthedocs.io/en/latest/concepts/sides/. Then, in my ClientProxy class, I put command registrations into the preInit event handler: public class ClientProxy extends CommonProxy { @Override public void preInit(FMLPreInitializationEvent e) { ClientCommandHandler.instance.registerCommand(new GetTimeCommand()); } ... } Thats it. In game, I can now input "/realtime" in chat and get the current time displayed.
    1 point
  11. Use packets. Create a custom packet with the necessary information and send it to the server when the player does something in the GUI.
    0 points
×
×
  • Create New...

Important Information

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