Removing a unit's range of vision

Zealot

Member
Reaction score
11
Is there a way without hiding or changing a unit's ownership to make that unit's owner not see what the unit sees or change it's sight range to 0?
Upgrades are not an option because they can't be removed and I want to make it possible to regain vision of that unit.
Any suggestions are appreciated.
 

thorhunter

You can change this now in User CP.
Reaction score
32
You can set the unit's sight range to 0 and make a system of a following dummy unit with proper sight range that you can delete and recreate on whim. Moreover, you can have few kinds of different dummy units with different sight ranges to change your unit's sight range. This solution isn't recommended for large scale usage though.
 

KaerfNomekop

Swim, fishies. Swim through the veil of steel.
Reaction score
613
The problem with 0 sight range is that you can't select the unit unless it's visible to other units you control. You could give it a very small sight range, but that still reveals units that come too close.
 

Zealot

Member
Reaction score
11
You can set the unit's sight range to 0 and make a system of a following dummy unit with proper sight range that you can delete and recreate on whim. Moreover, you can have few kinds of different dummy units with different sight ranges to change your unit's sight range. This solution isn't recommended for large scale usage though.

I need it for large scale usage though.

The problem with 0 sight range is that you can't select the unit unless it's visible to other units you control. You could give it a very small sight range, but that still reveals units that come too close.

Making the unit unselectable by having 0 sight range is no problem because the unit would have it only under certain conditions that will eventually give the unit it's vision back.
 

KaerfNomekop

Swim, fishies. Swim through the veil of steel.
Reaction score
613
You could try creating Line of Sight blockers that follow the target unit, thus restricting its vision. But then, this might be less effective than the dummy units.
 

Accname

2D-Graphics enthusiast
Reaction score
1,462
Instead of using dummy units you can use visibility modifiers. I dont know if these can be moved with jass (maybe they can) but even if not they would probably still be cheaper then having dummy units. Units in general are pretty heavy-weight data containers in the wc3 engine.
 

Zealot

Member
Reaction score
11
Trigger:
  • Visibility - Create an initially Enabled visibility modifier for (Owner of (Picked unit)) emitting Fog of war from (Position of (Picked unit)) to a radius of 1000.00

It blocks visibility for one second then it dissapears. The unit performs no action or moves at all.
 

Zealot

Member
Reaction score
11
Bump.

Visibility modifiers work only for 1 second, do I have to refresh them constantly or am I doing something wrong?
 

Accname

2D-Graphics enthusiast
Reaction score
1,462
The visibility modifiers work permanent, but you do it wrong. Instead of trying to mask the area (which is getting unmasked by your unit again) you should remove the sight range of the unit and place a visibility modifier unmasking the area around the unit when you want it to be able to see anything.
 

Zealot

Member
Reaction score
11
The visibility modifiers work permanent, but you do it wrong. Instead of trying to mask the area (which is getting unmasked by your unit again) you should remove the sight range of the unit and place a visibility modifier unmasking the area around the unit when you want it to be able to see anything.

The map is riddled with line of sight blockers, constant visibility modifiers instead of the unit's basic vision is not an option as it allows seeing over these blockers.

Is there a way to make a certain player's screen black or not allow him to see the map at all for some time?
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top