A more radical solution has just occurred to me, which I think I rather
like. What is the gameplay advantage of water? Certainly it makes
life
more interesting when it takes a long time to get to your opponent, but
I think the complexity of building a swimming pool, upgrading it,
repairing it, running globs through it and so on is not worth the
hassle in practice.
How about we fix the speed globs swim at half the speed they walk?
Then
we could make the gradient for moving across land squares 2 and water
squares 1. Since we'd have half as many grids of elevations to deal
with, we could make each elevation a 16 bit value instead of an 8 bit
one without using any more memory. That would mean globs could find
peaks up to about 65,536 squares away across the water or 32,768
squares
across land. In principle, this means it could take longer to
calculate
each grid, but maps 256x256 and smaller would only notice in rare
cases,
and it wouldn't be that hard to split the workload over two or more
ticks (which would cause the occasional hiccup, but nothing hugely
serious). This is a big change, but would be easier to implement, and
goes right along with what I'm working on in the map rewrite at the
minute, so now's the time to decide.