Clanfolk Progress Update! (My unexpected 2 week water adventure!)

Clanfolk

Clanfolk is a colony sim set in the Scottish Highlands. Harness your environment to survive - fish, gather, hunt, and farm as you prepare for the winter. Build an inn, trade with other clans, have children and marry them off - live life and prosper across the generations.

[img]{STEAM_CLAN_IMAGE}/41036152/f8e9d660317849d7615660c4e4f73c4f75dcfc37.jpg[/img] Hi Everyone, It has been a very busy two weeks, and the [u]Testing Branch[/u] just got a Big Update. [i]Note: Anyone can join the Testing Branch under Clanfolk/Properties/Betas on Steam.[/i] [b]Here are the details.[/b] Before I go into the tale of the last two weeks, for those of you who just want the high level info, here it is: [h3]New Stuff:[/h3] [list] [*]Beavers [*]Swimming [*]New Better Shoreline System [*]Natural River Generation [*]Bridges [*]Piers that can be built on! [/list] For those who want to know how this all came about, please pull up a chair. This is the tale of how one thing lead to another and two weeks of unplanned work was born. So two weeks ago, after working intensely on the Story Generator systems for the previous few months, I decided, "Hey, I should add something cool for players for the weekend!" [img]{STEAM_CLAN_IMAGE}/41036152/012674c98a965811c376eecaeb788b5357abd405.png[/img] It all started with a Beaver. I decided, Beavers are cool, lets add them as that weekend surprise. I got to work modifying the Bunny template, then made some AI tweaks and there were Beavers in the game. Woohoo. I set up the art, then made a Beaver Lodge and things were going quite smoothly and all in time for the weekend. (two weeks ago) Then it struck me when I saw the Beavers... walking on water... Oh no. Beavers must swim! But how can beavers swim on a 2d plane!?! Soo... That lead to me having to create the concept of Water Depth. To have Water Depth, I needed to add a new camera to the game that could write depth data that the other cameras could use to determine what to draw and what not to draw. So after a few more days, tada! Beavers were swimming, and it looked pretty good! So I tried a few more animals and they swam mostly sensibly, but sometimes floated a little high or low, nothing to serious. It was all cool. Then I put a person in the water... Annnnnnnd their clothing went semi transparent and their bits were showing... Originally water was semi transparent, but Humans have a dozen layers of clothing on them, that all went semi transparent and suddenly you could see through the cloak, jacket, shirt, and braises. Oh no. So after banging my head on the keyboard, I reworked the water and converted it to opaque (which in the end does look better) Crisis averted, and now Everyone Swims with their modesty intact! Now we have swimming Beavers and Water Depth. The Water Depth had a very interesting side effect in that the shoreline got a LOT more realistic where the terrain leading up the the shore was now visible and would appear an disappear with the waves. So this was a big win as well. I was feeling pretty great. I decided to show a preview pic of the new changes to one of my go to players/friends on Discord, and to paraphrase the response. "Cool!, but Beavers are kind of lame without Rivers." My triumphant unveiling was properly crushed and a brain worm was now loose in my head. I had worked so hard on this new feature, but if players first response was going to be "Where are the Rivers?" this was going to be a problem. I mean Beavers need highways too I suppose... So, I got to thinking and thinking and grumbling and thinking. I never thought natural looking Rivers would work with square tiles, but I set out to at least make an attempt to see for sure. I owed Beavers that much for giving me Swimming and Water Depth. After the first day of experiments, Rivers were functional. They looked like ruler drawn lines between Lakes, but they did work. There was enough there to keep a grip on, so I continued. The next day, I started applying noise textures to the river flow, and the hard lines started getting natural and wavy, then I started varying their width in places, and finally I created some narrows for animal crossings and unbelievably, Rivers looked great! I was thrilled. [img]{STEAM_CLAN_IMAGE}/41036152/b50404cc189ec0fd5557ca18716daa9128520764.jpg[/img] Ok, so a week had now passed since Beavers, but there was lots of good new stuff so it was all worth it. Time to generate a testing build... (this was about a week ago) Animal crossings... Oh no. What about "People Crossings"... So now that there was swimming, do people really want to take a dip to cross a River 10x a day. I needed Bridges too! That meant building on water and breaking a bunch of very specific "Never On Water" rules everywhere in the game. So back to experimenting. After a couple more days and a few tears, simple bridges started to work. As a side note, for a while people were swimming in the stone of the bridges instead of walking on them, which was a sight to behold. And by early this week, Bridges were functional, but they did not feel "Bridgey." Next I did an experiment with the shaders to generate some railings on the bridges, and much to my surprise, they looked amazing. They even rounded off the ends. I was thrilled. Then I realized that they ALSO rounded off then ends whenever not connected to a path. So that looked terrible, especially with double wide bridges. A bunch of rules later and the bridges were open in the right spots and railed in the right spots and things were finally looking done. By now I had some pretty nice looking bridges and was planning on writing some rules to enforce that bridges be 1 lane. I didn't want people paving lakes for example. On a whim, I tried to make one last Mega Wide Bridge before enforcing the single lane, just to see how it looked. For whatever reason, I decided to roof the path to the bridge, then it happened. I could roof the path, BUT not the bridge... There was still a "Don't Even Think About Building Here" rule for Water that was heavily bent for Floors to become Bridges, but what about Walls and Roofs!?!?! That was getting nuts because then bridges support walls which support roofs or decorations. What about other Objects built on the bridge. What if the Bridge Deck was removed? It was best to avoid this insanity. [img]{STEAM_CLAN_IMAGE}/41036152/b31b6f7bf1a54967d68cf41577768a3ad57a921c.jpg[/img] So I asked my Son's opinion of my big wide unroofed test bridge. Would people "really" want roofs on their bridges thaaaat badly? He just kept chanting "Lake House, Lake House" and then made some jazz hands. The decision was made... Not only would we need to Roof the bridges, but we needed Piers and Decks to allow that lakeside house. I can't resist Jazz Hands accompanying an idea. So another couple days of breaking rules that were never meant to be broken, and it was done. I built a beautiful deck coming off of a bedroom next to a lake. I also added some decorations to the floor and placed a roof over it. I was thrilled. Tomorrow would be the big day where I unveil this secret project! So it was Thursday now (Yesterday,) and I was going through some final tests and just looking at the bridges, feeling pretty happy with them, but something was bothering me. They were STILL flat. they had rails, but no lighting. They weren't "there" like all the other world objects. It was time for one last experiment. So since I had the data that was used to produce the railings, I tried sending that info along to the lighting engine, and sure enough the Bridges popped right off of the ground and suddenly began creating shadows like everything else. Yes! Then the race was on to get the build out yesterday, but the Beavers had one final trick up their sleeve. In my final tests of the build, I thought: "You know, I really should test the beavers one last time since they started all this," and sure enough, they were moonwalking. This turned out to be a new pathfinding issue due to them being aquatic and not having the usual water slowdown with movement. It is never a good idea to push a build in the evening, so that got us to this morning and here we are. I hope you enjoyed a glimpse into the crazy adventure started by just wanting to add a Beaver for fun. Please note: It is highly likely the Testing Branch will have a few issues because of the amount of new material in there over such a short time. I will try to get these fixed as quickly as possible. I will also be going back to fixing bugs and reading emails etc. I have been very much "in the zone" again over the last couple weeks so I am just coming up for air again now. Thanks very much for your support! Andrew Hume (Blorf) MinMax Games Ltd.