Saturday, November 8, 2014

Thermal features

This week, I worked on adding a few "thermal" features to the game.  Sometimes, rarely, you will find a pool or other feature that has some kind of thermal activity around it, causing it to be extremely hot.  Be careful - you can get boiled to death now if you go swimming in a boiling underwater lake!  Thankfully, you'll get some visual clues as to where the dangerous parts of the thermal zones are.  For example, if the water is boiling, perhaps you shouldn't go in:


You won't die immediately from entering a hot area.  But the heat meter will ramp up pretty quickly, so if you see your heat zooming up, you'd better clamber out of that boiling water quickly.

Sadly, this feature ended up being a lot more problematic than I originally thought.  My original visual effect for conveying heat - a kind of faint shimmering - did not play well with the Javascript framework I was using, because it was trying to cache all the different colors it uses, which was growing very large and without bound.  On various browsers, it was either slowing things down or outright making things unplayable.  The above effect is far more efficient, and works better, but it took me several nights of investigation to track down the problem and get it fixed...

1 comment: