Game Development Community

Fog of war

by Robert Stewart · in RTS Starter Kit · 02/21/2005 (2:26 pm) · 9 replies

When i change bool gFogOfWarIsOn = true; to bool gFogOfWarIsOn = false; Inside visManager.cs. I now have no fog on the server end, but on the client end i cant see any units"except for his own". What did i do wrong? also can i change this and/or the distance of the fog from script?

#1
02/21/2005 (3:52 pm)
A re-write to the visManager has been given to GG, and is in the process of evaluation for the next major release. IIRC, it fixes all of the issues with fog of war on/off except for one related to logging in "late" to a mission (for those that don't use a persistent server across missions, this shouldn't be too much of an issue).

Keeping in mind that "fog" is a bit of a misnomer when it comes to the RTS-SK (there really isn't anything that keeps a specific unit from seeing very far, except for the datablock values set for vision (visionRange maybe? it's been a while since I looked at it). All you need to do is to edit the datablocks for your units to increase their vision distance.
#2
02/21/2005 (5:14 pm)
I see, Nice thanks for that little bit of info.
#3
02/22/2005 (2:55 am)
Just as a little update on this, we have Stephen's team's vis manager integrated and working in a branch of the RTS SK, and are trying to make time to test it fully. :)
#4
04/04/2005 (3:23 am)
Has there been any progress on this one, could do with a fix to disable fog of war
#5
04/04/2005 (6:23 am)
We found a minor problem with the implementation as it stands with using VC7 compilers: that compiler is very strict in how it allows you to define and manipulate dynamic multi-dimensional arrays, and while we have a fix that works across all of the compilers we have access to, we're not incredibly happy with the performance.

Once we've finished internal work on this, we'll release it to GG again and have them review and see if they have any performance suggestions.
#6
04/04/2005 (8:46 am)
Could i have a look at it, might be able to fix it for you!
#7
04/04/2005 (9:05 am)
It's fixed, it's just that the performance hit for lots of units is pretty bad! As I mentioned, we're working on a couple of refactoring moves that will helpfully trim it down, as well as another complete re-write down the road.

Turning off Fog of War completely though isn't very difficult, just need to have every unit always visible to every client--just change the code that determines visibility to always see everything.
#8
04/04/2005 (2:04 pm)
Sorry been stupid, should have read the post closer, thanks for all your help will get the latest release
#9
01/21/2010 (2:23 am)
ok, you got my hopes up and then dashed them ... its not a "fog" of war ... correct?

It sounds like / appears to be - when its "on" only your units show up on the map ?

I was hoping it was a full screen fog of war like many games implement ... anyhow.