I'm trying to change the join message for the Minecraft version b1.8.1. From the Stable 1.8 I know it with @Eventhandler, registerEvents etc.
But that does not seem to have been implemented at this time. I've tried it like this:
The main class:
import org.bukkit.Bukkit;
import org.bukkit.event.Event;
import org.bukkit.event.player.PlayerListener;
import org.bukkit.plugin.java.JavaPlugin;
import java.util.logging.Logger;
public class Main extends JavaPlugin {
public final Logger logger = Logger.getLogger ("Minecraft");
private PlayerListener playerListener = new JoinListener ();
public void onDisable () {
}
public void onEnable () {
logger.info ("Plugin started");
Bukkit.getServer (). GetPluginManager (). RegisterEvent (Event.Type.PLAYER_JOIN, this.playerListener, Event.Priority.Normal, this);
}
The JoinListener class:
public class JoinListener extends PlayerListener {
public void PlayerJoin (PlayerJoinEvent event) {
Player p = event.getPlayer ();
event.setJoinMessage ("Test Message");
}
Plugin.yml
name: test
version: 1.0.0
author: Julian
main: en.julian199.BetaServer.Main
commands:
If I start the server now, then the plugin will be loaded, but the events will probably not be registered because the join message is still default. An error does not come.
Does anyone know how to do that "back then"?
First of all: No, I do not know the solution to your problem.
Was there a bukkitAPI for b1.8 you could insert?
Did you already search for "Serverjoin Message Minecraft Beta 1.8" in a search engine?
Clear