1. Updated Resource Submission Rules: All model & skin resource submissions must now include an in-game screenshot. This is to help speed up the moderation process and to show how the model and/or texture looks like from the in-game camera.
    Dismiss Notice
  2. DID YOU KNOW - That you can unlock new rank icons by posting on the forums or winning contests? Click here to customize your rank or read our User Rank Policy to see a list of ranks that you can unlock. Have you won a contest and still havn't received your rank award? Then please contact the administration.
    Dismiss Notice
  3. The Lich King demands your service! We've reached the 19th edition of the Icon Contest. Come along and make some chilling servants for the one true king.
    Dismiss Notice
  4. The 4th SFX Contest has started. Be sure to participate and have a fun factor in it.
    Dismiss Notice
  5. The poll for the 21st Terraining Contest is LIVE. Be sure to check out the entries and vote for one.
    Dismiss Notice
  6. The results are out! Check them out.
    Dismiss Notice
  7. Don’t forget to sign up for the Hive Cup. There’s a 555 EUR prize pool. Sign up now!
    Dismiss Notice
  8. The Hive Workshop Cup contest results have been announced! See the maps that'll be featured in the Hive Workshop Cup tournament!
    Dismiss Notice
  9. Check out the Staff job openings thread.
    Dismiss Notice
Dismiss Notice
60,000 passwords have been reset on July 8, 2019. If you cannot login, read this.

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

Discussion in 'World Editor Help Zone' started by Dougletron, Jan 4, 2012.

  1. Dougletron

    Dougletron

    Joined:
    Jul 25, 2006
    Messages:
    173
    Resources:
    3
    Maps:
    3
    Resources:
    3
    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.
     
  2. Hashjie

    Hashjie

    Joined:
    Apr 20, 2009
    Messages:
    1,515
    Resources:
    0
    Resources:
    0
    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?
     
  3. Dougletron

    Dougletron

    Joined:
    Jul 25, 2006
    Messages:
    173
    Resources:
    3
    Maps:
    3
    Resources:
    3
    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.
     
  4. Meticulous

    Meticulous

    Joined:
    Nov 15, 2007
    Messages:
    779
    Resources:
    0
    Resources:
    0
    Why not just place a dummy unit to give vision?
     
  5. Hashjie

    Hashjie

    Joined:
    Apr 20, 2009
    Messages:
    1,515
    Resources:
    0
    Resources:
    0
    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.

    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?
     
  6. kkots

    kkots

    Joined:
    Jun 21, 2007
    Messages:
    534
    Resources:
    0
    Resources:
    0
    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: Jun 23, 2012
  7. Dougletron

    Dougletron

    Joined:
    Jul 25, 2006
    Messages:
    173
    Resources:
    3
    Maps:
    3
    Resources:
    3
    Interesting find sir. Thank you, guess i'll just start the map off in mid day cycle.