Hi everyone!
I figured I would update the OP this time. So my project is still going strong even though I can barely work on it one day a week. Recently I rewrote the entire AI. I went from a 2000 lines switch statement in update to a simple finite state machine using interfaces. The whole thing is less than 400 lines and works amazingly.
It’s basically modular blocks that I can push in a queue, it’s faster and much easier to add new tasks. I also stumbled on a grass shader [Shader] Moving Trees Grass in Wind Outside of Terrain - Community Showcases - Unity Discussions that I modified to fade based on distance. At first I was using the Terrain grass system, it looked horrible and took about 30 FPS. I wrote my own grass system using the shader above. It generates 100 patches of 60 000 vertex each in about 6 seconds. The whole thing sways in the wind and doesn’t cost any performance (apart from the massive amount of vertex but I’m still running at 100FPS in editor). The shader fades the grass in a linear fashion I’ll need to find something so it fades only when it gets to the edge of the last visible patch.
Now the grass and the crops in the fields all sway in the wind it adds a lot of character to the scene. Below screenshots are taken directly from the editor, in the build there are rocks scattered around the terrain and flowing rivers.
I reworked the hunger and food system so now people require a lot more food. Also now people will no longer die from starvation, they’ll get a massive satisfaction penalty and will start looking for food themselves therefore impacting goods productions in your village.
I also have a working version of a dynamic quests and event system that parses text files to build possible events. It’s super easy to write your own events with triggers and actions. I will feature this system on the next update.
Here are some screenshots of the game in its current state. All UI panels are still WIP and will most likely change.
Here’s the new grass system from ground level (I now realize my pine trees look silly from this angle)
The blacksmith repairing some tools
The Character Sheet - When you click on a villager you’ll see this screen, it contains the attributes (Diplomacy, Constitution, Craftsmanship, Stewardship and Ruse), the traits, and also the current satisfaction. More information will be added to this screen. Here you can see the current statisfaction and factors:
The traits - These are the different physical and personality traits of the character, these are the purple and black squares as I haven’t yet made icons.
The Attributes - Here we’re looking at the Stewardship attribute and what traits modify it
The Budget - This shows you the various income and expanses of your Fief. This screen will change as I find it too basic for now
Overhead view -















