Closed nfitch closed 10 years ago
So it turns out there isn't a good programmatic way to get the seed. Seem that on multiplayer servers you have to do one of the following:
There also isn't a good programmatic way to get the version. The only real suggestion that I found was:
The server type is already set up in the server.config (the config we generate). We could simply poll the logs until we get the version and the seed. But modded minecraft servers may not have the same output as the vanilla server. Need to go spin up different versions and see what they generate.
Details on investigation:
vanilla:
/opt/minecraft/server/logs]# cat latest.log
[04:15:22] [Server thread/INFO]: Starting minecraft server version 1.7.2
Note that there is no seed in the logs. Sigh...
craftbukkit (log is in a different location):
/opt/minecraft/server]# cat server.log
2013-11-27 04:07:29 [INFO] Starting minecraft server version 1.6.4
2013-11-27 04:07:29 [INFO] Preparing start region for level 0 (Seed: -6792647903155132695)
ftb-ultimate:
/opt/minecraft/server]# cat server.log
2013-11-27 05:02:33 [INFO] Starting minecraft server version 1.4.7
Also no seed.
voltz:
/opt/minecraft/server]# cat server.log
2013-11-27 04:31:52 [INFO] Starting minecraft server version 1.5.2
Also, no seed here.
So it looks like we can really only reliably get the minecraft version from the logs. So I guess we'll go with that.
So now that we have all the information in public we need, it's just a matter of fetching and slapping in the ui.
Along with the ip address of the server, like: