Posts: 52
Threads: 5
Joined: May 2015
Thanks: 6
Given 7 thank(s) in 4 post(s)
Hello everyone! I've been a long time Minecraft player since BETA 1.6.6, but I only recently got back into it after a hiatus. I hosted a few servers back in my time, but a big drawback was that I didn't know Java. MCServer uses Lua to develop plugins for. It so happens that over the past year I've been using Lua and I'm fairly good at working with it. C++ is next on my list which makes MCServer a miracle for me.
I wanted to request information on the current status of MCServer.
-Up to date information on what MCServer has and is missing compared to the Java variant.
-Status on the API and if the API is still missing useful/core functions.
overall I want to ask this: Is MCServer a viable and reliable option to host Minecraft Servers that could potentially grow and become fairly large?
Does the plugin coder have enough access to develop whatever he could think of within reasonable limits?
Any replies would be greatly appreciated. my main concern is flexibility, and stability.
Posts: 4,634
Threads: 115
Joined: Dec 2011
Thanks: 695
Given 495 thank(s) in 424 post(s)
05-06-2015, 08:43 AM
(This post was last modified: 05-06-2015, 08:43 AM by NiLSPACE.)
Hello and welcome to the forum.
We have a post where we roughly keep track of what MCServer has implemented and what it's missing compared to Vanilla/Bukkit/Spigot. You can find it here: https://forum.cuberite.org/showthread.ph...53#pid3553
Our API is good enough for most cases. The thing we're probably mostly missing is an API to control mobs. (not entities, just mobs) We probably miss some other stuff. For example if I remember correctly we do support scoreboards, but it's per-world, not per-player, so you can't use it in for example mini-games. Here is the documentation about the API: http://mc-server.xoft.cz/LuaAPI/
MCServer misses some survival features, and it sometimes is a bit unstable (especially if entities are enabled), but if you want for example a creative/plot server then MCServer works fine. We currently have a plot server running on a Rasberri Pi 1 where we build structures for our world generator.
I hope this answers most of your questions If you have any more don't hesitate to ask them. ^^
Posts: 52
Threads: 5
Joined: May 2015
Thanks: 6
Given 7 thank(s) in 4 post(s)
05-06-2015, 08:51 AM
(This post was last modified: 05-06-2015, 08:54 AM by Shadowraix.)
(05-06-2015, 08:43 AM)NiLSPACE Wrote: Hello and welcome to the forum.
We have a post where we roughly keep track of what MCServer has implemented and what it's missing compared to Vanilla/Bukkit/Spigot. You can find it here: https://forum.cuberite.org/showthread.ph...53#pid3553
Our API is good enough for most cases. The thing we're probably mostly missing is an API to control mobs. (not entities, just mobs) We probably miss some other stuff. For example if I remember correctly we do support scoreboards, but it's per-world, not per-player, so you can't use it in for example mini-games. Here is the documentation about the API: http://mc-server.xoft.cz/LuaAPI/
MCServer misses some survival features, and it sometimes is a bit unstable (especially if entities are enabled), but if you want for example a creative/plot server then MCServer works fine. We currently have a plot server running on a Rasberri Pi 1 where we build structures for our world generator.
I hope this answers most of your questions If you have any more don't hesitate to ask them. ^^
I would like to say thank you for the greetings and for making a very well-written reply!
I'm more interested in multi-purpose servers which does includes all kinds of variants such as survival, creative and any other world type I can think of.
This is kind of a downer because I would really like to use MCServer. I'll probably experiment with the API here and there. I'll keep track of the development of the server software. Once it reaches a more reliable and feature-complete state I'll jump in to make a full-fledged server.
I would like to ask a few questions Lua-side:
1. Are there any features stripped from the MCServer implementation?
2. What version is it running?
3. If 5.1, is it using LuaJit?
Posts: 4,634
Threads: 115
Joined: Dec 2011
Thanks: 695
Given 495 thank(s) in 424 post(s)
1) Not that I know of. You can use all the features that are included by default.
2) We use Lua 5.1
3) We're using the normal Lua 5.1. We did try LuaJit (in a hackish way), but the performance increase was minimal.
Also, before you think too bad about MCServer survival I have to say that you can still get a pretty good survival experience. It's just that you sometimes might notice some differences that you wouldn't expect.
Posts: 52
Threads: 5
Joined: May 2015
Thanks: 6
Given 7 thank(s) in 4 post(s)
(05-06-2015, 09:26 AM)NiLSPACE Wrote: 1) Not that I know of. You can use all the features that are included by default.
2) We use Lua 5.1
3) We're using the normal Lua 5.1. We did try LuaJit (in a hackish way), but the performance increase was minimal.
Also, before you think too bad about MCServer survival I have to say that you can still get a pretty good survival experience. It's just that you sometimes might notice some differences that you wouldn't expect.
That gets my hopes back up, haha. I'll definitely check around the API and see what I can do.
If you wouldn't mind answering these two questions, I'd appreciate it.
1. Are plugins likely to break often? In update logs it would be handy to suggest when plugins could break.
2. When updating the MCServer version, is it simply just replacing the old files? Will there be any complicated processes to preserve server data?
Posts: 350
Threads: 18
Joined: Oct 2014
Thanks: 26
Given 54 thank(s) in 47 post(s)
Also, the LuaJIT hack I put together seems to be very circumstantial. It seems to provide a noticeable boost for ARM HF platforms, but the performance increase is mucl lower on a poorly optimized bin (x86). It actually seems to be a bit better using -ofast MinGW x64.
Thebplugin interface is actually very flexible, I have made several completely different examples of plugins with the current API, ranging from a void generator to a very large plugin recreating Super Smash Bros. implementing most of the game's original features, including a sound pack. The API is also super easy to learn, fairly well documented, and if it isn't yet documented, the function names are obvious, so it shouldn't be too hard to figure out.
Posts: 4,634
Threads: 115
Joined: Dec 2011
Thanks: 695
Given 495 thank(s) in 424 post(s)
05-06-2015, 09:54 AM
(This post was last modified: 05-07-2015, 12:27 AM by NiLSPACE.)
We rarely remove a binding. If something is deprecated we usually make the function put out a warning in the console. Only after a while we remove the actual binding.
Yes, when updating MCServer you can use your old data.
Posts: 52
Threads: 5
Joined: May 2015
Thanks: 6
Given 7 thank(s) in 4 post(s)
05-06-2015, 10:01 AM
(This post was last modified: 05-06-2015, 10:03 AM by Shadowraix.)
(05-06-2015, 09:54 AM)NiLSPACE Wrote: We rarely remove a binding. If something is depricated we usually make the function put out a warning in the console. Only after a while we remove the actual binding.
Yes, when updating MCServer you can use your old data.
Thanks for your help NiLSPACE! I appreciate your help and I hope to be a great contribution to the community. I'm working on a set of plugins right away!
(05-06-2015, 09:43 AM)DiamondToaster Wrote: Also, the LuaJIT hack I put together seems to be very circumstantial. It seems to provide a noticeable boost for ARM HF platforms, but the performance increase is mucl lower on a poorly optimized bin (x86). It actually seems to be a bit better using -ofast MinGW x64.
Thebplugin interface is actually very flexible, I have made several completely different examples of plugins with the current API, ranging from a void generator to a very large plugin recreating Super Smash Bros. implementing most of the game's original features, including a sound pack. The API is also super easy to learn, fairly well documented, and if it isn't yet documented, the function names are obvious, so it shouldn't be too hard to figure out.
Thanks for the information DiamondToaster! The API does seem fairly easy which is why I enjoy Lua. It's just easy and simple.
Oh, by the way, can I structure my plugins in any fashion I want? As in having folders inside the main plugin folder?
Posts: 4,634
Threads: 115
Joined: Dec 2011
Thanks: 695
Given 495 thank(s) in 424 post(s)
Yes, you can have any structure you want. By defaut MCServer loads all the lua files in the main folder, so if you put the source files in another folder you'll have to load them manualy with the dofile function. To read the content of a folder you can use the cFile:GetFolderContents function (or something like that it's hard to look it up on my mobile)
Posts: 350
Threads: 18
Joined: Oct 2014
Thanks: 26
Given 54 thank(s) in 47 post(s)
05-06-2015, 10:14 AM
(This post was last modified: 05-06-2015, 10:15 AM by DiamondToaster.)
(05-06-2015, 10:01 AM)Shadowraix Wrote: (05-06-2015, 09:43 AM)DiamondToaster Wrote: Also, the LuaJIT hack I put together seems to be very circumstantial. It seems to provide a noticeable boost for ARM HF platforms, but the performance increase is mucl lower on a poorly optimized bin (x86). It actually seems to be a bit better using -ofast MinGW x64.
Thebplugin interface is actually very flexible, I have made several completely different examples of plugins with the current API, ranging from a void generator to a very large plugin recreating Super Smash Bros. implementing most of the game's original features, including a sound pack. The API is also super easy to learn, fairly well documented, and if it isn't yet documented, the function names are obvious, so it shouldn't be too hard to figure out.
Thanks for the information DiamondToaster! The API does seem fairly easy which is why I enjoy Lua. It's just easy and simple.
Oh, by the way, can I structure my plugins in any fashion I want? As in having folders inside the main plugin folder?
Definitely, using the API, you can create subdirectories and write files/configs within the plugin folder. The root directory is the MCServer executable. I do this by using the Plugin object that is passed when using the Initialize function at the start of the plugin.
PluginFolder = ""
ConfigFolder = ""
function Initialize(Plugin)
Plugin:SetName("SomeName")
Plugin:SetVersion(1)
-- Returns "Plugins/<Name of Plugin Folder>"
PluginFolder = Plugin:GetLocalFolder()
-- Append /config to the end. For example, the final result will be
-- Plugins/SomePlugin/config (depending on the name of the plugin main folder)
ConfigFolder = PluginFolder .. "/config"
-- If the folder does not exist, then create one
if not cFile:IsFolder(ConfigFolder) then
LOG("Config folder does not exist! Creating directory *config*...")
cFile:CreateFolder(ConfigFolder)
end
LOG("Initialized " .. Plugin:GetName() .. " v0." .. tostring(Plugin:GetVersion()))
return true
end
|