Jump to content

DieserChris

Members
  • Posts

    4
  • Joined

  • Last visited

Everything posted by DieserChris

  1. Thanks for the tipp. Works like a charm!
  2. Hey, I'm writing a server-side mod, that has to be able to kick a player. I tried using the following code: final ServerPlayer player = event.getServer().getPlayerList().getPlayerByName(ev.getUser().getId()); Objects.requireNonNull(player).disconnect(); But, the player never get's kicked / disconnected from the server. How do I kick a player from the server? EDIT: I'm using MC Version 1.18.2
  3. Hey, I need to add a local jar file as a dependency. Currently I'm doing it the following way: build.gradle: dependencies { // [...] minecraft 'net.minecraftforge:forge:1.18.2-40.1.85' // [...] implementation files("chronos_lib/chronos-shared-1.0-SNAPSHOT-all.jar") } While developing, this seems to work, but the contained classes aren't available at runtime - ClassNotFoundException. How can I make the jar available at runtime?
  4. What would be an excellent approach to store a custom file on the server? To give some context: I'm working on a utility mod that requires me to save display names, balances & a crime stat. The data needs to be persistent, and I don't want to use a database.
×
×
  • Create New...

Important Information

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