For Eternity (Post Mortem)

If you didn't tried out my entry here is a link to For Eternity.

Let's start with the ugly things so we can end with some positve. :wink:
The UglyThis time i had some ugly things to deal with. In the past i never had to deal with crashes or other problem beyond just bad performance. But this time was different! I used a seperate thread for pathfinding in my game and this was my first time using custom multithreading inside a ld entry. And yes i did the most obvious mistake you can do when you write multithreaded code. I wrote code that wasn't thread safe at all! :sob: But before i was able to fix that i had to reimport all my models because all my models were missing inside my unity cloud build. So what went wrong there? A short (actually longer) google search informed me that clod build doesn't have support for automatic light baking with that info i came to the conclusion that cloud build doesn't have support for my Cinema4d files. So i reimported all my models as fbx files and baked the lightmap and now cloud build was working. With that working build pipline i recognized my stupid mistake of having a not thread safe pathfinding code. So i fixed that mistake and thought now every thing is fine. :laughing: Oh boy was i wrong! The real pain in my as* just started. I played my game a couple of times and had no problem at all. Even a buddy of mine tested it and had no problem too. But the first comments that i got were telling me that the game freezes occasionally. So i did some more testing and couldn't find the problem. I looked into my code because i thought i missed something while i was making my pathfinding code thread safe. But i couldn't figgure it out (there was no bug in pathfinding anymore). So i asked those who experienced this problem to help me. And thanks to @automatonvx (Thank you!) i was able to replicate this freezing behaviour. But it took me hours to narrow it down to a while loop, that under some special conditions, i send into a infinity loop and that was causing the freeze. So that was the ugly part my story how i made my game playable.
The badSo after the ugly what's left for the bad, you might asking yourself? Here comes the stroy of the jam. After the announcement of the theme i went into bed. I had no idea what kind of game i should make. The theme hit me by surprise. So i woke up and thought a city builder like "Paraoh" would be a nice idea maybe a little challenging but i was fine with that. I totally underestimated the scope of such a game. This resulted that i ran out of time at the end of the jam. I had no time to create a proper ingame tutorial, the price calculation for goods is just a random value betwin a min and max price, there isn't a event system with some random events, there is no music and only a few sound effects, the caravan isn't animated and the whole game isn't balanced at all in particular the quality of life system.
The goodI'm very pleased with the look of the graphics espacially the look of the ui. But the thing i'm most proud of is the underlying structure. That's the reason i ended up with something that is actually playable and fun. The world generator is pretty good for something that's created in just a few hours. The building system, goods and the ai are all modular and flexible. So it was pretty easy to create more and more buildings and goods. I used a very modular and reusable approach towards the ai and it payed off very well. Only because of this decision i was able to create a city building game in the given time. Even though i had more plans of features, i allways knew that i wouldn't be able to implement them all, i'm pleased and happy with the game For Eternity became.
