Hello, I host a server with beastnode and I made a plugin to kick players with a kick message then shutdown the server. I dispatched command: 'stop', but every time it stops it immediately starts back up. How do I stop it from starting back up. I have this code I am going to try. Will it work: Code:java this.logger.info("Shutdown in progress."); this.plugin.getServer().savePlayers(); Server server = this.plugin.getServer(); server.savePlayers(); for (World world : server.getWorlds()) { world.save(); server.unloadWorld(world, true); } server.shutdown(); I tested that code and it did not work. EDIT by Moderator: merged posts, please use the edit button instead of double posting.
It could be that the serverbox that the server is running on has a program that makes it start right back up contact your hosting provider
vxwkillerjthewalrus A person from beastnode said that it is thinking it is a crash and starts again. How do I make it not look like a crash. Oh if the user on beastnode is the owner they can type: builtin:stop but if I dispatch that command it says it is unknown.
You could ask them too disable that feature on your server Cause there seems too be no way too get around it
Dont dispatch the command, just output it to the console in a way so it is interpreted. (p.s, I don't know how to do this)
he is already using that code inside the main post, the reason it failed was because his hosting provider thinks the server shutdown is a crash, and start it directly after it has shutdown