StickyPiston World Manager

All copyright for the World Manager and associated code remains with StickyPiston Hosting Ltd. This page is just to illustrate that Oliver worked on the system. Everything on this page has been approved for public representation.

Overview

The StickyPiston World Manager is a system that was created to help our server owners better understand and manage the Minecraft worlds that are on their server. This system consists multiple parts that allow for things such as:

  • Uploading / Downloading worlds
  • Creating / Deleting worlds
  • Changing the world on the server
  • Editing a world’s settings
  • Adding or Changing a world’s server resource pack
  • Duplicating a world
  • Renaming a world

Each of these functionalities come together within the frontend to form one cohesive tool.

The first view of the World Manager This is what the user first sees when the click “World Manager” in the left side menu.

The World Manager moves the contents of the page downwards and is inserted near the top of the page to get the user’s attention and be “above the fold”.


Development

This system is built on top of the customized Multicraft control panel that StickyPiston provides to all of the server owners. Each feature within the World Manager consists of the following:

  • A Python script that does the file and API manipulation for the feature to work
  • PHP added to the web server to accept an AJAX request with the required information to perform the request.
  • Javascript, HTML, and CSS to allow the user to control the system and to make the AJAX request to the backend server.

In this section I’ll briefly describe what each feature is and show the UI interactions for each thing.

These descriptions and video/images are accurate as of 2022/03/01 (when Oliver wrote this). Because this system is in an ever-updating environment, these may become out of date as time continues, but at the time of writing this is what the system looked like that Oliver created.

Uploading a world

Within the system there is a drag and drop interface for uploading a world to your server with no effort required. This system will also uploading multiple worlds at the same time if they are within the same ZIP folder, it checks for any level.dat files in the archive and then determines the world name from the parent directory within the archive.

The StickyPiston Multicraft drag-and-drop interface for uploading worlds with through the World Manager

This is the drag-and-drop interface that is presented to users when they go to upload a world to the server.

Downloading a world

This uploads the world to one of our file sharing services after zipping the world and any additional world folders that are produced from the server (like the world_the_end and world_nether from Spigot). This download then stays available for 72 hours for the user to download.

The StickyPiston Multicraft UI for downloading a world through the World Manager

This is the insert that is displayed to the user once their world is ready to be downloaded.

Creating a world

The World Manager enables users to create worlds directly on their server with extra options that normally are only exposed through Minecraft’s creation menu or through the server.properties. All of these settings are put into a file named world_properties.StickyPiston which allow them to be restored and saved on a per-world basis instead of on a per-server basis, allowing users to have more control over their server settings.

These are all of the options that are given to the user when they are creating a world through the Multicraft control panel.

Renaming a world

This simply changes the folder name of the world, ensuring that the user doesn’t select a name that already exists.

The modal to allow users to rename worlds

This is the modal that appears when a user is attempting to rename a world.

There are dynamic errors that appear as the user is typing if they:

  • include a special character (any non-alphanumeric character plus brackets, hyphens, and underscores)
  • try to use a name that is already taken by a world.

in both of the above cases the user is prevented from renaming the world.

Deleting a world

Allows a user to permanently delete a world. In order for the user to do this since it cannot be undone, we took inspiration from GitHub and make the user type (or copy/paste) their world name into a confirmation box before they can delete it.

The insert as it appears when the user is attempting to delete a world

This is the confirmation of world deletion that ensures the user wants to delete their world by making them take an extra action that is extremely unlikely to happen by accident.

Changing the active world

Changing the active world is what allows the user to swap what world is being used by their server. So if they have a creative mode world and a survival world, they can swap between them with a couple clicks.

The world options that are provided for each non-active world within the World Manager

This is the set of options that are provided for each world in the “List Worlds” section of the World Manager. To active the selected world the user just has to click the “Activate World” option

The world options that are provided for the active world within the World Manager

This is the set of options that are provided for each world in the “List Worlds” section of the World Manager. This is the dropdown on an already active world, so we hide the “Activate World” option to prevent users from trying to activate the same world a second time.

Editing a world’s settings

The World Manager also allows users to edit any of the settings of their worlds dynamically, meaning that if the server is currently running it will only

The world's settings that are editable through the World Manager

The world’s settings that are editable through the World Manager.

Server resource pack

Each world is allowed it’s own server resource pack, this is updated by the system when a world is activated to allow for the user to have a unique server resource pack with each of their world’s.

The World Manager insert that lets users manage the world's resource pack

This is the insert that allows that users to add, update, or remove, the server resource pack that is active when the world is active. This is primarily used by mapmakers and those who want a uniform look for everything on the server.

Adding a resource pack

Adding a resource pack can be done either through the drag and drop interface interface which utilizes the StickyPiston Resource Pack API that I also made, or by providing a direct link and sha1 hash for the resource pack.

Changing the resource pack

Changing the resource pack for the world can be done the same ways as adding a resource pack.

Removing the resource pack

Removing the world’s resource pack is as easy as clicking the “Remove Resource Pack” button.

Duplicating a world

Duplicating a world is a pretty straightforward feature, it copies everything from the one world into a new world. This includes all chunk data and player data from the world being duplicated. When the world is duplicated, a suffix is added to the end of the world name, this suffix is chosen randomly from a list of predefined suffixes and all have something to do with Minecraft.

The modal confirming that the world was duplicated successfully

The modal alerting the user that the world was successfully duplicated.


Oliver Akins © 2022. All rights reserved.