Version 1.0.7 is now live on Steam and Humble, and should soon be available on GOG.com shortly.

Steam should auto-update the game, otherwise you’ll have to download the new version from your purchase location. If you bought the game from the Humble Store or from Shining Rock Software, you can download the latest version using the link you originally received to download the game. If you no longer have the email, you can get it resent using this tool: https://www.humblebundle.com/store/keyresender

As always, Email support (at) shiningrocksoftware (dot) com if you have any issues.

This will likely be the last update of Banished, except for any major bug fixes. The OSX and Linux versions development has stopped, and won’t be released. Going forward I’ll be focusing on new games and projects.

ModKit & Downloads

For the Mod Kit, here’s the new download. This Mod Kit should build mods created with the beta version with no changes.BanishedKit_1.0.7.170910.zip

Note that you need to apply the patch to version 1.0.6. Previous versions of the game won’t work with this patch. Once downloaded, just unzip the archive into the folder where you have Banished installed. This is usually C:\Program Files\Shining Rock Software\Banished\. Please be sure to run the .exe’s that are in the archive – some distributions have the .exe named differently.

Here’s the last version of the 1.0.7 beta for the modding community. Should all go well with this build, I’ll release it as non-beta, allowing the mods to be uploaded to Steam Workshop. If you use this modkit and build, please let me know how they work out. If it’s working perfectly I’d like to hear about it too. Thoughts, bugs, crashes, etc. Email support (at) shiningrocksoftware (dot) com

Changes

First, the debug menu has changed so that new custom resource types can be added to storage. As always, you’ll need to mod the game to enable the debug menu.

Also, a few crash bugs have been fixed so that buildings can require more than 3 resources to build. There’s also a new example in the mod kit and documentation that gives an overview how to do so.

Downloads

Note that you need to apply the patch to version 1.0.6. Previous versions of the game won’t work with this patch. Once downloaded, just unzip the archive into the folder where you have Banished installed. This is usually C:\Program Files\Shining Rock Software\Banished\. Please be sure to run the .exe’s that are in the archive – some distributions have the .exe named differently.

As always the Beta is up on Steam. If you are using Steam, go into your game library and right click on Banished. Select properties, and then in the windows that opens, select the BETAs tab. Select the drop down and pick Beta Test for 1.0.7.

Here’s a new version of the 1.0.7 beta for the modding community. There weren’t too many bugs reported so far, so hopefully this will be the last test before an official version.
If you use these, please let me know how they work out. If it’s working perfectly I’d like to hear about it too. Thoughts, bugs, crashes, etc. Email support (at) shiningrocksoftware (dot) com

Changes

-This build adds an example to the mod kit so that modders can add custom resources to the auto purchase section of the Trading Post. I overlooked this in the first beta. See the Readme.html for details.

-This build fixes a potential crash when the user interface scale is not 100% and clicking on a dialog that is over a selectable building.

Downloads

Note that you need to apply the patch to version 1.0.6. Previous versions of the game won’t work with this patch. Once downloaded, just unzip the archive into the folder where you have Banished installed. This is usually C:\Program Files\Shining Rock Software\Banished\. Please be sure to run the .exe’s that are in the archive – some distributions have the .exe named differently.

As always the Beta is up on Steam. If you are using Steam, go into your game library and right click on Banished. Select properties, and then in the windows that opens, select the BETAs tab. Select the drop down and pick Beta Test for 1.0.7.

When I started coding my own engine and game, one of my constraints was that I wasn’t going to write an editor for whatever game I made. This was mostly a time saving constraint. Good tools take time, as I certainly learned while making console games. Often the editor tools to go with a new system took as much time to write and debug as the system itself.

However, as I work on a new game, I find that I need an editor for some things. I need to be able to place objects, make paths, and edit properties. Which is potentially a huge project unto itself. So I’ve been looking for ways to write such a tool with minimal code. More immediately, I’ve been working on some procedural generation code for terrain, but I want to be able to edit the generation properties and see results immediately, instead of changing parameters, running the code to see a result, quitting the program, and repeating over and over.

Also important, is the need to not waste time on user interface for code that is under-going development. If I add a parameter to the terrain generation code, then decide I don’t need it, I shouldn’t be spending time adding a new button or number edit field on some UI. This means some sort of automatic user interface.

So what I need is an automatic property page style dialog that uses type reflection to determine field names, types, and values.

Type Reflection

The idea of reflection is that the code that’s running knows about the properties of itself as it’s running. Given some code that defines some data and the functions that operate on that data, the code can find out and use names, types, and all sorts of other useful information about itself. Strangely, the engine sort of has this functionality, but it wasn’t built for this purpose. It just needed some extra glue to make it work.

Serialization

What the engine does have is a very flexible serialization system. A single function is created to read and write data to and from disc. It can operate in binary mode or text mode. Text mode is a bit fancy. I wrote it to be able to edit data (since I had no editor) in a human readable way. It looks somewhat like JSON, but I built it to look more like the C++ class that is used in code. For example, here’s an ImageBuffer (that’s called a texture in most engines…)

There’s some magic here. The stream of data could be text or binary, (or something else) and when the serializer is instantiated for that stream, an appropriate reader or writer is created. The _Field and _InternalField macros define what’s available to the text reader, and what isn’t. For example width and height come from the image, and aren’t user editable.

Nothing says that the serializer has to come from or go to disc. It could be to memory, or some other crazy system, like following object pointers for garbage collection. So by writing a new back end for the serializer, I get exactly what I need for reflection. The field names, types, values, and addresses are available. I even know which fields I can present visibly and which ones not to.

So with a tiny bit of extra code, I get object reflection without modifying any of my engine code. Amazing! Did I luck out or what? While the ImageBuffer example doesn’t show it, this system also works for user defined types, enums, flags, pointers, arrays, colors, type ids, etc.

The User Interface

Again, I’m lucky. In making Banished I wrote a UI system that has a lot of control types. So again I don’t have to write a ton of code or bring in a separate UI library.

The UI in the engine has edit boxes, number edits and spinners, combo boxes, list boxes, check boxes, scroll bars, windows, layout tools, sprites, text, etc. Another game may not have needed so many different controls. I’m not sure what I’d be doing for making this user interface otherwise.

Putting it Together

So all I really needed to do was write some code that would create a control for each specific type. Number edits for integers, a set of check boxes for flags, combo boxes for enums, etc. When the user changes the values in the controls, I’d just need to push the new value into the back end of my serializer and send the data back to the object using the Serialize function.

And since the serialization system is already built to do things like compile a PNG into a block compressed format ready for GPU use, when the values are changed in the propery editor, the same compilation occurs as if it were being loaded from disc.

Easy!

I say that it was easy, but it’s more that the new functionality wasn’t invasive to the existing engine. It was still a fairly sizeable bit of code and took a while to write properly.

The Property Editor

So without too much fuss, and zero engine modifications (just additional code), I have a property editor for any object in my engine. I can edit textures, sounds, or any new game object I add to the engine.

I have a few more editors to write. For example I don’t have a color picker. Right now I just type in a hex value like 0xFFCO80AB. But that shouldn’t be too bad to create in a day or so. And I probably need some resource editor that allows me to browse everything on disc.

I could also modify the serialization functions to provide some meta-data for the editor. For example minimum/maximum values for numbers, increments for spinners, read only fields, field groupings, etc. But this will require modifying every existing serialization function. All in good time.

This is a long way from a full featured editor, but it’s a start and it has a lot of possibilities. First is that I can edit all objects that I serialize without any additional code. It can also be used to do strange things, like editing the user interface properties of the property editor. And because it uses my own UI, in the future I could use it in game to select objects, see their properties, and change them for debugging purposes.

Here’s a new Banished beta for the modding community to test out. It adds 10 mod-usable resource flags and resource limits. It also adds the ability to add these limits to the game windows that use them, such as the status bar, limits, and town hall production/graph. It also has a new memory allocator that doesn’t have a hard limit on system memory used.

If you use these, please let me know how they work out. Thoughts, bugs, crashes, etc. Email support @ shiningrocksoftware . com

Note that you need to apply the patch to version 1.0.6. Previous versions of the game won’t work with this patch. Once downloaded, just unzip the archive into the folder where you have Banished installed. This is usually C:\Program Files\Shining Rock Software\Banished\.

As always the Beta is up on Steam. If you are using Steam, go into your game library and right click on Banished. Select properties, and then in the windows that opens, select the BETAs tab. Select the drop down and pick Beta Test for 1.0.7.

With either the patched version or steam beta, the base game won’t change (except for a few minor bug fixes), but they’ll let you run mods generated with the new mod kit.