HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

IsUnitVisible Craziness

03-27-2007, 10:10 PM#1
UnMi
I am posting this, because this case has bothered me 48 hours in a row.
I think it might even be obvious for some of you, but in case it's not, let me tell you that
Collapse JASS:
IsUnitVisible
returns a false if that unit is deep deep within a forest.
Like, it doesn't even have to be invisible or something, if it's between so many trees so you "cannot see it with your naked eyes", then it's not Visible anymore...
03-27-2007, 10:42 PM#2
Szythe
IsUnitVisible returns false if the unit is not within sight of any of your units. It has nothing to do with whether the unit has invisibility. Granted, if the unit is invisible it will return false, but as I think you discovered (and many of us knew) as long as none of your units have a line of sight on the unit in question, it will not be counted as "visible"
03-27-2007, 11:57 PM#3
UnMi
...IsUnitVisible(Unit,Player)
It doesn't have anything to do with your units.
I can have units that have 0.00 Sight Radius.
They return false if the fog of war is disabled and they return true if it's not.