• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

[General] Sharing Vision with a unit but site radius capped?

Status
Not open for further replies.
Level 8
Joined
Jul 25, 2006
Messages
177
I'm having a neutral unit share vision with a player, the neutral unit has 1400 site radius but only shows a radius of about 400-500. The neutral unit is a building, can't figure out whats wrong.

Edit: It appears to work in the day but at night it does not, both day and night radii are set to 1400.
 
Level 14
Joined
Apr 20, 2009
Messages
1,543
Have you checked the Gameplay Constants?
I'm not sure if there is a cap, but if there is then that would probably be the place to look...

Have you tested this with non-shared player owned units, or any other units with night sight radius set to 1400?
 
Level 8
Joined
Jul 25, 2006
Messages
177
Yes, there are no values in gameplay constants that affect site radius.
I tried making neutral an ally with shared vision even to that player, still the reduced night time site radius problem. It's wierd. Night and day is going to have no effect on my map so I am most likely just going to freeze the clock cycle in it as a hot fix to this problem.

The building was a Goblin Laboratory cnp.
 
Level 14
Joined
Apr 20, 2009
Messages
1,543
Yes, there are no values in gameplay constants that affect site radius.
I tried making neutral an ally with shared vision even to that player, still the reduced night time site radius problem. It's wierd. Night and day is going to have no effect on my map so I am most likely just going to freeze the clock cycle in it as a hot fix to this problem.

The building was a Goblin Laboratory cnp.

But have you tryed using a different unit and/or building to reproduce the same problem?

This problem is strange indeed as I can simply create a unit with the same site radius for day and night cycles.

Why not just place a dummy unit to give vision?
I get why he needs to test with a different unit that has both site radius for day and night set to 1400, it might be that something is bugging the unit he's using at this moment.
But could you explain to me: why does it need to be a dummy unit?
 
Level 11
Joined
Jun 21, 2007
Messages
505
You won't believe it.
I've just did a test with Goblin Laboratory.
Placed it in middle (the only unit on entire map) and put in triggers code:
  • Events
    • Map Initialization
  • Actions
    • Unit - Grant shared vision of Goblin Laboratory to Player 1 (Red) //to me
    • Game - Set time of day to 12
    • Game - Set time of day to you_starting_time
That will make units share sight normally.

PS: I'm getting really annoyed by the amount of bugs and weirdness there are in wc3... Units can't even share sight normally on first night. And also the lack of full documentation regarding native functions... makes me not so want to make a map.

EDIT: You can set the time of day to any value, after it has been set to 12. It is not necessary to start the map at day time.
The bug with sharing night-time sight is present only on the first night of the game. When a new day comes with a new night, units will share sight without bugs. Or you can just set time to 12 and after that to any other value you need.
 
Last edited:
Status
Not open for further replies.
Top