XaiJu
fantasytowngenerator
fantasytowngenerator

patreon


Development Update - December 2023

Hey everyone, hope you're all doing well! So, last time I said I was going to work on optimising the relationships and then taking a look at family trees. However, I got distracted by schedules - honestly I thought it would be a quick change, but it turned into a whole thing. So lets get into it!

Previously, only working people had schedules, and that would only control where and how they would work. At generation time, each person would get a schedule and it would be persisted in the settlement file. As you can imagine, this is a lot of duplicated data, as many people share a similar schedule. Also, the schedules would only be applied on the days that people worked.

Now, every person type (except delegating) can have a schedule, and a schedule can be created for each day of the week:

I've also added some new building matcher / sub-location matcher options, for example an exact building matcher (where you choose a specific building to go to), and a sub-location tag matcher. Sub-location tags are a new thing, and are used to describe basic functionality of a location that can be used by schedules so people will go to the correct places.

For example, the service door of a bar might look like this:

and a labourer can have a schedule that looks like this:

This also allowed me to make better use of the new entertainment artisans that I added in the last update - they'll now perform in taverns, making use of the performance tag on the tavern stage sub locations:

So that's the new feature - however I did also fix a couple of related issues - one being that some buildings were more empty than they should have been (e.g. taverns in the evening should be busy). 

This change also was a step in the right direction to enable larger settlement sizes - I mentioned before that previously copies of schedules were stored on each person, now that information is lazy loaded based on the persons job. This has reduced the storage size of the settlement file by ~5%. I also took this opporunity to optimise the simulation algorithm, which resulted in a 5% speed up of settlement generation, and a 20% speed up of simulation

So that's it for this post! Next up, actually looking into optimising relationships, and creating a family tree view. As always, thank you all so much for your support, you have made all this possible - if you have any questions or feature ideas, let me know!



More Creators