August Update: Robot Farm World Editor & Modding

Hello there!

I’m cutting this one pretty close. I had hoped I’d have more to show before the month was over, but some things came up IRL that I’ve been dealing with lately. I’ll be going over that a bit further in though. For now, let’s just go over what we’ve been working on this month!

unknown2.png

So there are three main things I’ll be discussing:

  1. Construct/Entity support

  2. Resource importing

  3. “Magic Images”

Constructs & Entities

We’ll start with the basics, which are placeable objects we call Constructs. Right now the World Editor is still in its earliest stages of being built, and the last time we touched base, I had explained what the World Editor is, and shown some screenshots of some basic terrain editing with it. Since then, I’ve built in the ability to place objects, or “Constructs.”

What is a Construct?

Constructs are objects that contain entities inside them, and act as essentially a shell for placing objects with the World Editor. The shell is needed for two reasons: 1) to handle making copies of itself and 2) initialize the entities inside of it once placed on the world (and disposing them when removed). When the world is being played on, the Constructs won’t really be needed anymore, but for the sake of the World Editor, the constructs essentially keep the entities suspended until it’s time to run the game.

How are they loaded?

These constructs are dynamically loaded and generated from external resources, and construct Entities which will be stored inside them. These are “Construct Templates.” You can select from these within the Editor, and then place them to automatically make copies that can be edited individually.

javaw 2021-08-31 14-19-47-03.png

Resource Importing

To make a Construct Template, its resources need to be loaded from somewhere. The system right now will basically allow you to drop png and vox (voxel models) files in a folder, which the game will load and automatically set up for you. If it’s just a file (as in, simply one sprite, or simply one voxel model), settings will be configured to where it’ll work out of the box with no further tweaking required. However, things get more complicated when you begin to need animations - such as having an entire sprite sheet in the assets folder. This is where our fancy “Magic Images” function comes in.

Magic Images

The time will come when you need to fine-tune an asset that will be loaded into the game. We’ve achieved this by making an image encoder that will allow you to pack resources and metadata into a card so that all necessary data is in one elegant package that you can even preview in an image viewer of your choice.

This also has benefits when sharing them online: as long as the file isn’t compressed, it should work just fine no matter where you share it, since it doesn’t just tack metadata onto the end of the file like most encoders of this type. I still need to do proper testing on this over time so I can get some more conclusive results on what websites will support their sharing however.

As an example, here’s a “Magic Image” of our chest asset:

chest.png

The above image contains quite a bit of data about the chest. The actual image itself acts as a preview of what you’re getting: you know it contains that chest sprite sheet, and that the dimensions of the spritesheet are 32x16. Inside, it knows the frame bounding for the sprite sheet, and any set offsets for adjusting its placement on the world. It even knows that it’s sprite sheet that’s stored inside, for differentiating it in our code, and future lua code made by players.

The fact that the preview image has some of this data written on it for reference is just one example of how preview images can be used when packaging assets. But if you get more creative, you can stylize it to look cool, and even include your author-credits on it. The best part is, if someone gets the funny idea of trying to steal your work, they won’t have much luck since if they try to edit their name onto it instead, it’ll corrupt all the data in the file.

One thing I’m very excited to see someday is how creative people will get with decorating their cards/preview images. You could almost “brand” them as your own in a way, giving cards from your asset collections a unique look so people know it was made by you from a glance. Honestly, any sort of custom player-made content will be extremely fun to see.

So anyway, how does this chest look ingame once it’s loaded?

There it is! The game recognized that this PNG was a Magic Image on its own, then loaded its data and configured it automatically. You’ll also notice that it’s displaying only the first frame of the animation. The system automatically spliced the sprite sheet up for you and set it to the default frame of (0, 0).

And honestly, that’s about it! Adding new mods/assets is basically as easy as dragging and dropping them into a folder, and the game will set them up based on all the metadata that comes with the card. From there, you can begin tweaking and editing further; working towards making your very own custom Robot Farm content to share with friends or the community.

NOKORIWARE has a firm belief that modding can really help build a game’s community, and also provide hours upon hours of extra content to keep the game fresh. We truly want players to get as much bang for their dollar as they possibly can, and hopefully our title will leave a lasting positive impact on our players that will be fondly remembered for years to come.

So where’s the tech demo?

I know in our last blog post I had said we should’ve been able to get a tech demo out this month. Unfortunately I’ll be taking a rain check on that for now, but with good reason!

My real life situation regarding my illness can sometimes throw me curveballs. In this month’s case, I had received my first vaccine shot, and a wisdom tooth also started giving me trouble on top of my existing chronic illness. So I’ve been a bit out of it and have needed some rest. On top of that, juggling all these doctors appointments has been taxing, but I’m determined to see this through and win my battle against this disease!

I have managed to get all of the above finished in the meantime, which was some of the hardest aspects to cover so far. But honestly, most of the time was simply spent thinking about how I should set up World Editor’s architecture, and my fellow programmers will probably understand that setting up a good architecture that’s well thought out from the beginning is just as important as actually writing the code.

Anyway, there was a lot of progress that I didn’t show in this blog post. I’m wanting to keep those cards close for when we drop our first tech demo soon! There’s not much left too much left to do before I can finally put that together, so I’m really excited to show it to you guys! Let’s just see how it goes, shall we?

Opening up a community Discord

We’ve been getting some good feedback on our Twitter from you lovely folks. We’ve been doing our best to keep everyone up to date. First of all, I sincerely want to thank all of you that have been following our updates and having shown interest this early in. I really want to make something we can proud of and deliver something that you all will really enjoy! So every little pat on the back, retweet, or kind comment does so much for our morale, and for me personally. You guys really are the best. I’m looking forward to growing our little family more and more as we go on.

One of the big requests we’ve had for awhile now is that we make a Discord channel for Robot Farm. We actually have had one for years, but it’s been closed off to developers and testers only. But we hear you! So our plan is to finally open it up and let people start joining once we release this next tech demo. People who join will be able to potentially opt-in to testing when it’s ready, as well as have a chance to win free copies of Robot Farm when it comes out.

And more than anything, I’d simply just love to have the opportunity to get to know you all and know what kind of stuff you’d want in our game. The players are the lifeblood of any game project, and I truly just want to make something that people can enjoy and find some solace in during these trying times.

See you next month!

As always, it’s a pleasure to catch up with you all. Stay safe, healthy, and happy! I’ll see you guys next month and hopefully have some even cooler stuff ready by then. Just keep your eyes and ears open!

Yours always,

♥ NOKORIWARE

Stay updated!

NOKORIWARE YouTube

Robot Farm Twitter

Check these out too:

PuppyGames Twitter

LWJGL Website

Previous
Previous

Java | Using JPackage (Quick-Start Guide for Windows)

Next
Next

July Update: Friendship ended with 2D graphics, now Voxoid is my best friend