I have a question about creating a Minecraft instance.

  1. Is there a way to create a Minecraft instance with the desired version through the AMP API?

  2. When creating a Minecraft instance in the Bedrock type, a message appears saying AMP couldn’t find the Bedrock server, check that it’s installed, and I wonder where to install the Bedrock server.

  1. Yes. There’s a SetConfig API call which you use to change the Minecraft server type/version before you run Update(). You can use GetSettingSpec to get the full settings manifest including the node names. You’d create the instance first via the API and then modify that instances settings after it started.
  2. You need to update the instance (which downloads the files) before it will start.

Where can you see all the setting nodes you need to change settings for Minecraft at once?

Via the GetSettingSpec API call. You can also look at the KVP files - the node goes FileNameWithoutExtension.Section.Setting - e.g. MinecraftModule.Minecraft.SpecificSpigotVersion for the Minecraft.SpecificSpigotVersion setting in MinecraftModule.kvp.

Thank you for your answer! Even changing the version was successful. There’s another question. Do you have an API that brings in data about the type and type of version if you want to receive the type and version directly from the user?

Again the GetSettingsSpec API call has that information.

Just be mindful that if you’re selling servers, you need an Enterprise licence.

Can I change the settings for Container Memory Policy and Container Memory when creating an instance? And we looked at all the respawn values in /API/Core/GetSettingsSpec, but we couldn’t find any values for Minecraft. What’s wrong with it?

Yes, using ADSModule.UpdateInstanceInfo - again as a separate step afterwards. Add /API to the end of your panels URL to get the full API specification.

You need to send the request to the specific instance, not to ADS to get that instances available settings.

I modified the script and html in the home/amp/.ampdata/instances/ads01/webroot path, and at some point all the codes were initialized. Is the ads instance automatically initialized? Or was it initialized due to the update? If so, is there a way to customize it so that it doesn’t reset?

Customising AMP with your own branding/logos etc requires that you have an AMP Network Edition or AMP Enterprise Edition licence. In which case it’s done under Configuration → Branding. Changing style elements you can do by writing a theme. Creating and using AMP themes · CubeCoders/AMP Wiki · GitHub

1 Like