Re: Problem to solve

From: The Fungi (
Date: 05/18/03

On Sun, May 18, 2003 at 06:20:25PM -0500, Tseran wrote:
> I have set up an overhead mapping system, and now I want to add a
> little more realism to the system.  To that effect, I want to make it
> so that if certain sectors are designated as 'blocking' (like forests
> and mountains) you can't see the sectors behind them.  I want to make
> it so that it will cast a 'shadow' depending on location.  For example,
> if you get right up beside a blocked sector, it will 'fog' 1/4 of the
> map, and when you get further away, it lets you see more around it.
> However, I am wondering how to do this.  The best way I can think of is
> to do a test to see if there are any 'blocking' sectors between the one
> you are in and the one you are trying to 'see'.  Any ideas?

If you want to do this in a realistic manner, add an elevation value
for every room on the map. Then it's simple trig to calculate line
of sight from the current tile to every tile in the max visibility
radius. Then give terrain type "forest" or whatever a 15m addition
to simulate an average 15m tree height blocking visibility. And of
course, if the current tile is "forest" then a -15m penalty or
something unless you want to give players the ability to fly or
climb trees to get a better view of the surrounding area. Note that
this assumes some regularity in tile size. You could also use
elevation differences to make travel costs in movement points for
adjacent tiles more realistic as well.
{ IRL(Jeremy_Stanley); PGP(9E8DFF2E4F5995F8FEADDC5829ABF7441FB84657);
SMTP(; IRC(; ICQ(114362511);
AIM(dreadazathoth); YAHOO(crawlingchaoslabs); FINGER(;
MUD(; WWW(; }

   | FAQ: |
   | Archives: |
   | Newbie List:   |

This archive was generated by hypermail 2b30 : 06/26/03 PDT