Skip to main content

Dev Update: Armory Update

· 5 min read

Over the past couple of months, I have spent considerable time working on refactoring major parts of the main nonDB addon, which powers all of our MoronYard servers.

How major are the changes you might ask? Well, so far over 190 files have been touched and more than 55000 lines of code have been changed.

Gitlab changes

So what is this for? The main goal of the refactor is to allow for the following key objectives to be achieved:

  • Revamp and unify the User Interface
  • Rethink the inventory and storage system

Pain points

Let me address the current pain points that make the previous goals unachievable.

User Interface

The current UI is messy and patched together over the last decade:

  • There is no unified style
    • Some menus have the dark, transparent background, while other menus use a custom derma skin. Some parts of the UI are even using custom panels with image backgrounds (cough tome cough).

  • The UI does not scale
    • If you are on a 4K screen, good luck reading any text. If your resolution is smaller than 1280px, tough luck using the UI at all.

  • The UI is confusing
    • A new user might easily get overwhelmed trying to navigate the different menus. Some actions are hidden in right-click menus. Some buttons might not make sense.

  • The UI provides no feedback
    • The feedback that the user receives in gamemodes such as Smash or Slope is minimal and hidden. A user might die on Smash without ever knowing what killed them or what a certain mine did to them.

Inventory and Storage

The inventory itself also leaves some room for improvement:

  • The inventory is page-based
    • There is no reason to have pagination at this point.

  • Crafting materials take up space
    • Crafting materials and other stackable items like keys, lockpicks, gems and runes should not be taking up space in the inventory.

Solution: The Armory

With the previous points in mind, I have been working on a new UI that will address all of the above issues.

The armory replaces all inventory- and item-related menus, such as loadouts, stores, crafting, etc.

Grids everywhere

Under the hood, the armory (and all other UI elements going forward) is using a grid-based layout system. This allows for the UI to scale to any resolution and still offer a nice user experience. All UI elements will scale to fit the available screen space, and the fonts will grow or shrink accordingly.

Loadout

The underlying grid can be seen in the following screenshot. The screen is subdivided into 48x28 squares, which can be further subdivided by using fractional values.

Loadout with visible grid

Icons

To make icons scale nicely, I have implemented a custom webfont icon renderer (similar to Font Awesome). This allows for icons to be rendered at any size and still look crisp.

Webfont icon

Pageless inventory

Pagination is so 2000s. The armory uses an infinite scrolling virtual list to display all items. For best performance, only the items that are currently visible are rendered.

Pageless inventory

The new inventory also allows for easier searching, filtering and sorting of items.

Materials storage

Up until now, every item took up 1 inventory space, even if it was stackable. This is no longer the case. Stackable items, that cannot have any attributes or other item properties, will now be stored in a separate storage container, which can be accessed from the armory.

Materials storage

Item actions rather than crafting recipes

Applying a nametag shouldn't be done through a crafting recipe. Most item actions can now be found in a dedicated menu.

Item actions

What else?

Some smaller, but significant changes have been made:

  • Weapon items (such as Smash mines and tools) can be equipped and previewed in the armory. Same for Sanctuary weapons.
  • Your current loadout can be previewed in a model preview panel
  • Your active buffs and attributes (rare find, lockpick chance, ...) are summed up in a single panel

The future

Before this big update can hit the servers, there are a couple of major changes I have planned that need to be implemented first

No more +x items per day

I want to get rid of the notion of "limited items found per day". As long as you keep playing, you can find items.

The existing item per day attribute will be converted into a new "item find skill point" (name not final) attribute. Equipping items with this attribute will grant you skill points to be invested into an item find skill tree.

The skill tree will allow you to customize which items you find, and even allow you to find specific items more often. Example: Lower skills could reduce your fragment drop rate, or boost your gem find rate. Higher skills might unlock finding ancient gems or guaranteeing a drop when you do a specific action.

Making cash meaningful

Not sure how to go about this yet, but there is a hyperinflation problem in some gamemodes, and most items sold in the store are not worth the cash.

When release?!

I cannot make any promises, but I am hoping to have the first version of the armory ready for testing in early 2023.