I finally have a new build. Most of these are performance fixes that I covered in my last post, but I also added a lot of extra stuff to the City Inbound level.
Using Coroutine for line-of-sight detection
While trying to improve the performance of the line-of-sight detection, I started using a Coroutine instead of OnTriggerStay. OnTriggerStay is called on the physics timestep, which by default is 0.02 milliseconds. I set my Coroutine to run every 0.25 seconds, which spreads out the relatively expensive conversion of a position to a Node. It’s not perfect, but it will do for now.
Spicrab Storage and Spicrab Square
This is a former storage warehouse. At the moment, it’s mostly empty, but there are a few notes to find inside the office. Two of the other buildings around the square are accessible, but the rest are not. One of the buildings contains a lift…which I haven’t tested yet.
A shop that sells washing machines…in a medieval city. This is a reference to a particularly obnoxious spammer that used to clog up the Unity forums with threads about fixing washing machines, fridges or air conditioning. I originally planned to add this arsehole in as a particularly persistent boss, but I ditched that early on.
You now start in the sewers, and must find your way to the sewer entrance next to the Museum. That will lead into the next part of the City, which I am hoping to finish within a month or so.
Have some screenshots! These are all from the Editor, rather than the build.