Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Zone Controller Pro

Discussion in 'Assets and Asset Store' started by JohnRossitter, Jan 18, 2016.

  1. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    I gotcha.
    Well presently, there is absolutely no problem having multiple Master Controllers.

    And because each individual Zone Controller allows you to pick the Master Zone you wish to use, you can do this as you like.

    The only problem that could arise is, Master Controllers trying to compete with each other should you design your Zones in such a way that they overlap.
     
    hopeful likes this.
  2. Teila

    Teila

    Joined:
    Jan 13, 2013
    Posts:
    6,932
    This could be a problem. If they overlap, any chance we could use one Master controller? I know ours will overlap.

    Problem is that sectors need to be square but the terrain does not. In our city, the sections will not always be square so we will have to overlap the sectors. I was thinking of using Zone Controller to control ambient sounds and possibly other things that will make sections of the city different.
     
    JohnRossitter likes this.
  3. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    Well, overlapping in general is a bad idea in the present version, as I have not yet implemented Nested Zones.
    I intend to work on that in 1.0.2, which I will be starting this week.
     
  4. Teila

    Teila

    Joined:
    Jan 13, 2013
    Posts:
    6,932
    Hmm, but maybe it won't be a problem. Zones are not the same as sectors, so even if the sector overlaps, the zone could be drawn not to overlap. Am I seeing this correctly?
     
    JohnRossitter likes this.
  5. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    Yes, you are 100% correct.
    A Zone is just a 3D region, has nothing to do with a SECTR
     
    Teila likes this.
  6. BackwoodsGaming

    BackwoodsGaming

    Joined:
    Jan 2, 2014
    Posts:
    2,229
    My suggestion would be to slice using Sect. When I get back to my Gaia and Sectr tutorial, I'll add Zone Controller after I'm finished stamping. My thought is you should be able to add the master controller into the scene and leave it as a global object, not a child of any sector. Then it pretty much has a persistent state when any of the individual sectors are loaded. I talked with John a little about Sectr and Zone last night and when I saw your post it reminded me I wanted to look at the Stream docs. Tell Ryan to dig into page 7 of the Stream manual.

    The way I did things back in August during the Gaia beta was stamp my terrain, install suimono and (at the time) Environment Gator, and then I sliced with Sectr. Leaving Suimono and Environment Gator out of the individual sectors at at root of my hierarchy left it in all of the sectors. I didn't have to put it in every one. Obviously if you want a tighter control of your weather, you might have but now with Zone, you probably don't even need to do that. Just use zone to change the weather when you hit into a different climate.

    At any rate, here is the Global stuff from Sectr Stream manual. But still Ryan may want to take a look because it goes on to talk about lightmaps and other stuff you might want to do globally.

    "Gl oba l Ga meObj e ct s
    As described above, dynamic (i.e. non-static) Sectors and any GameObjects not
    parented to a Sector will not be exported into a Chunk. This is necessary because
    an object can only be exported into a single Chunk, but Members may be in multiple
    Sectors at once. Non-static sectors are assumed to change at runtime, and are
    also unsafe to export. Once the game is running, however, both dynamic Sectors
    and global GameObjects they will still behave with the exported data just as they
    did before export.

    This behavior can actually be used as a design tool. Often, there are some objects
    in the level that should always be instantiated (i.e. the player, puzzle objects, etc.).
    As long as these objects do not try to hold direct references to exported objects,
    then they will function just as they did before the export."

    As far as doing anything other than setting up your globals and forming your terrain, I would wait and do all that stuff as you are loading/unloading the sliced sectors. Especially for something like Zone. That way you would know where you need neighboring zones going across scene borders. I'm not sure having a zone cross a border would be a good idea. But if it is already sliced, you can see where you would need two duplicate zones on each side of the crossing.

    I'll let you guys know once I get to that point how it all works out. But I'm thinking maybe master as global object and being careful of your zone placement based on grid lines before you slice, or placing zones after you slice might be workable.
     
  7. BackwoodsGaming

    BackwoodsGaming

    Joined:
    Jan 2, 2014
    Posts:
    2,229
    If you are streaming, I don't think you want your sectors overlapping... Not sure how that will work.
     
  8. Teila

    Teila

    Joined:
    Jan 13, 2013
    Posts:
    6,932
    The city is not in a grid so that won't work. But thanks.
     
  9. Teila

    Teila

    Joined:
    Jan 13, 2013
    Posts:
    6,932
    And he said that was okay, the Sectr Dude. :) We asked. BTW, this belongs in Sectr or via Skype. John is going to yell at us. lol
     
  10. BackwoodsGaming

    BackwoodsGaming

    Joined:
    Jan 2, 2014
    Posts:
    2,229
    Everyone is asking about Zone and Sectr and how they will work together.. don't know how it belongs in Sectr any more than here.. And there were others who asked about it. Wasn't just responding to you and John... ;)
     
  11. hopeful

    hopeful

    Joined:
    Nov 20, 2013
    Posts:
    5,676
    But wait ... I want to say something about SECTR. lol

    It's mainly a tool for loading / unloading additive scenes. So you can even use it to load / unload your music or GUI.

    Obviously, with Zone you'd be using it for geometry, but it could be to add the insides of a building only when the player gets close, adding/removing chambers in a dungeon layout, and so on, not just terrain slices.

    And sectors can overlap.

    So while the question is about SECTR, it's also about how to handle Zone in additive scenes.
     
    Last edited: Mar 2, 2016
  12. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    Well there are certainly complex questions.
    The nature of the way Zone Controller works is: If the Runtime can see it, Zone Controller will work.

    If you do an additive Scene Load at runtime, Zone Controller will see the Game Objects you wish to control and allow you to control them. If the Scene is not currently loaded, Zone Controller will not see the Objects.

    If you want to use Additive Loading, I would use separate Master Zone Controllers in each slice, and bind the things you want to control in each layer to that Master.
     
    hopeful and BackwoodsGaming like this.
  13. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
  14. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    Zone Controller 1.0.1 is now live
     
    TonyLi and BackwoodsGaming like this.
  15. Deckard_89

    Deckard_89

    Joined:
    Feb 4, 2016
    Posts:
    315
    Hi,

    I'd just like to clear something up: there's Zone Controller Pro, and Zone Scion Edition. In the Asset Store page of Zone Controller Pro, it explains that it is compatible with Scion. Does this mean the normal Pro Edition has all the features of the Scion Edition, with the Scion Edition being simply for people who only want to use it with Scion? I hope this makes sense.
     
  16. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    Yes, your question makes sense and sorry for the confusion.
    I made Zone Scion Edition first, and had plans on making individual versions of Zone for other plugins.
    But I decided to make the generic tool Zone Controller instead.

    That being said, Zone Controller Pro will work with 90% of the things in Scion.
    There are some special settings in Zone Scion edition which are very specific to Scion, such are blending textures for the lens dirt.
     
    BackwoodsGaming likes this.
  17. wood333

    wood333

    Joined:
    May 9, 2015
    Posts:
    851
    After reading your User Guide, I must say that the most useful feature for me would be the Conditional Zone Triggering listed under Planned Enhancements. Would you please move this feature upward in your to-do list. Thanks
     
    JohnRossitter likes this.
  18. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    What
    Sure thing.
    I put it on the roadmap in the next release.
    Thanks,
    John
     
    BackwoodsGaming and wood333 like this.
  19. wood333

    wood333

    Joined:
    May 9, 2015
    Posts:
    851
    I was doing an unrelated search on the Unity Asset Store, and a link popped up titled "works with Zone Controller." Forty four assets are listed with their links. Is this authentic? Are there 44 tested and approved 3rd party assets for Zone Controller? I already own Zone Controller, so, am I to trust this assertion by the asset store?
     
    JohnRossitter likes this.
  20. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    Hi there,

    I actually made this list.
    I have personally tested most of these assets myself and the others were tested by existing Zone Controller customers who reported as much to me.

    The list here is so large because Zone Controller can work with any Unity component.

    I hope that helps clear that up for you.
    Thanks,
    John
     
    wood333 likes this.
  21. wood333

    wood333

    Joined:
    May 9, 2015
    Posts:
    851
    Still looking forward to your next release with conditional triggering.

    I'm working on a RPG game where the player carries a level number. I want to use that level number in conjunction with Zone Controller to switch assets on and off. In that manner, ZC can make different features visible or available to the player as the game progress. An area can evolve with the character, and the same area can be relevant again in a later part of the game without building an additional scene. Can't wait to give it a go!

    Got an ETA for the next update?
     
  22. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    I will have an update out soon after Unity releases 5.4 to address some issues people are reporting with the Beta.
    There are a few other goodies stashed away in the release as well.
     
    wood333 likes this.
  23. zhuchun

    zhuchun

    Joined:
    Aug 11, 2012
    Posts:
    433
    Hi, it looks cool! Have it been tested on iOS devices? I remember reflection is limited on AOT platforms so it may affect this asset.
     
    JohnRossitter likes this.
  24. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    As you stated, the support is limited on AOT systems like IOS.
    I tested with some success on them, but on the whole I would not be able to guarantee it will work in every scenario.
     
    zhuchun likes this.
  25. duencil

    duencil

    Joined:
    Dec 17, 2012
    Posts:
    91
    Maybe its beyond what you plan on doing with this asset, but I would like to see an option where the lerp factor is not based on time, but based on distance to an inner zone, inside which the factor is 1, and while you are in the outer zone but outside the inner, it ranges from 0 to 1 according to the distance ratio. That way you can have it smoothly interpolate as you approach a wall, or a glowing sphere, etc. I like this asset but I can think of more uses for it like that.
     
    JohnRossitter likes this.
  26. Smokas

    Smokas

    Joined:
    Mar 7, 2016
    Posts:
    114
    Bought on sale, started Cinematic demo - got error:

    IndexOutOfRangeException: Array index is out of range.
    ZoneMasterController.EnterZone (.ZoneConfig& NewZoneData) (at Assets/UtopiaWorx/Zone Controller Pro/Required/Scripts/ZoneMasterController.cs:798)
    ZoneController.OnTriggerEnter (UnityEngine.Collider Coll) (at Assets/UtopiaWorx/Zone Controller Pro/Required/Scripts/ZoneController.cs:529)

    Unity 5.3.4p5

    Tested more - got more:

    NullReferenceException: Object reference not set to an instance of an object
    ZoneMasterController.EnterZone (.ZoneConfig& NewZoneData) (at Assets/UtopiaWorx/Zone Controller Pro/Required/Scripts/ZoneMasterController.cs:833)
    ZoneController.OnTriggerEnter (UnityEngine.Collider Coll) (at Assets/UtopiaWorx/Zone Controller Pro/Required/Scripts/ZoneController.cs:529)

    Failed to call function ZoneContoller_Zone_Exited of class NotificationTarget
    Calling function ZoneContoller_Zone_Exited with no parameters but the function requires 1.
    UnityEngine.GameObject:BroadcastMessage(String, Object, SendMessageOptions)
    ZoneMasterController:ExitZone() (at Assets/UtopiaWorx/Zone Controller Pro/Required/Scripts/ZoneMasterController.cs:958)
     
    Last edited: May 6, 2016
    JohnRossitter likes this.
  27. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    Hi there,

    Yeah I went back and forth with this one in development.
    The reason it was not implemented was because of the plans I have for Nested Zones in the future. And smoothly interpolating the degree in which to apply effects for multiple zones at the same time.

    However, once Unity 5.4 is released, I'm going to revisit those plans.

    Thank You for your purchase!
     
  28. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    Hi there,
    I'm sorry to hear that you are having this problem.
    Can I ask what platform you have your current Unity Project configured for?
     
  29. Smokas

    Smokas

    Joined:
    Mar 7, 2016
    Posts:
    114
    Mac OSX Standalone.

    I fixed all problems - but it would be nice to have fixes in original version too :)

    1. Added check for array length : if (Parts.Length > 1 && MyType.ToLower() == Parts[1].ToLower())
    2. Added try...catch and null check afterwards.
    3. Added null check for ZoneConfig.ZoneName

    Also removed logo from scripts :) - takes too much space.
     
    JohnRossitter likes this.
  30. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    Wow, I'm really sorry to hear you had these problems.
    Which file did you have to edit to patch that? I want to double check that code.

    Thanks,
    John
     
  31. Smokas

    Smokas

    Joined:
    Mar 7, 2016
    Posts:
    114
    All info in previous post (ZoneMasterController.cs)
     
    JohnRossitter likes this.
  32. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    Just looking into that now.

    TLDR: I think your install may have been corrupted on the demo scene.


    The reported error lines seem to indicate that the ZoneConfig object was missing from your ZoneController.
    While the stack will bubble up and report all the way up, it seems that the root cause was a missing ZoneConfig Object.

    The Hierarchy is setup where a scene will contain a Master Zone Controller which is responsible for mitigating all of the transactions of the individual Zone Controllers contained within the scene.

    Each Individual Zone Controller also contains a Zone Config object, which contains the actual settings for how the transition should happen.

    For you to have gotten a null reference error on the Zone Controller at line 529, indicates that the Zone Config object of the Zone Controller in Question is missing.

    For this to have happened in the Demo scene I shipped out, it makes me think that something went wrong in the import of the asset into your environment.

    If you would like to dig deeper and work through it, send me a PM and I will share my Skype information and we can look at it together. This is the first instance that I have hard of this happening, so I think it's something to do with your import of the asset.

    Thanks, and again, Im sorry you had this trouble
     
  33. BigLouis1971

    BigLouis1971

    Joined:
    Mar 26, 2014
    Posts:
    107
    I was wondering if this asset can be used along with Easy Roads and substances from Substance Designer to change the textures appearance every few feets of roads?
     
    JohnRossitter likes this.
  34. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    Hi there, sorry I just now got to reply, the power was out at my house the last 2 days.
    I have not directly tested the combination of those 2 assets, however I can tell you that if it is a component derived from MonoBehaviour, Zone Controller can modify it at runtime. As far as changing Substances at runtime, this was working in previous versions of Unity, but I have not tested it in 5.4.

    I hope this helps.

    Thanks,
    J
     
  35. wood333

    wood333

    Joined:
    May 9, 2015
    Posts:
    851
    Conditional Triggering: shall we see this soon, now that 5.4 is out?
     
    JohnRossitter likes this.
  36. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    Its still on the Roadmap, but there are some internal changes that have to happen to make this work.
    So, its a big rewrite for a lot of it.
     
    wood333 likes this.
  37. amoeba_VR

    amoeba_VR

    Joined:
    Nov 28, 2015
    Posts:
    8
    Hi wondering how this works with teleporting for the vive having difficulties getting it to work with teleport.
    had it working previously in VR but without teleport (moving camera pov) vive eye with box collider to trigger as Main Camera option didn't work.
    thanks
    pro version ZCP
    unity 5.4 win 10 vive
     
    JohnRossitter likes this.
  38. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    It will have to cross the bounds of the zone collider to work.
    Just being in the zone will not cause it to start, it has to use a trigger collision.
    Sorry
     
    amoeba_VR likes this.
  39. amoeba_VR

    amoeba_VR

    Joined:
    Nov 28, 2015
    Posts:
    8
    thanks for the prompt reply
    dam...trying to figure out a solution,
     
    JohnRossitter likes this.
  40. hopeful

    hopeful

    Joined:
    Nov 20, 2013
    Posts:
    5,676
    If you come up with a clever solution for this use case, post it. :)
     
    amoeba_VR likes this.
  41. amoeba_VR

    amoeba_VR

    Joined:
    Nov 28, 2015
    Posts:
    8
    hahaha I'm sending this to my DEV hed luv the thought of me fixing that.... don't hold ur breath,
     
    JohnRossitter likes this.
  42. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    So as fate would have it, I actually ended up in the same situation myself.
    I found a bit of a clever Zone Controller hack you can do:
    1) you will need some sort of control script to keep track of when to do this.
    2) when you kick off your teleport, you can actually call a method in the MasterZoneController instance in the scene
    3) In your code that will control when you teleport, add a reference like this:
    private ZoneMasterController MyMZC;
    4) In the start event of that script do this:
    MyMZC = FindObjectOfType<ZoneMasterController>();
    5) When you are ready to force the exit of the zone in your script do this:
    MyMZC.ExitZone();

    This is what I did and it worked well for me.
    Again this is a hack and I can't guarantee it 100%

    Best of luck
     
  43. Elzean

    Elzean

    Joined:
    Nov 25, 2011
    Posts:
    584
    My inspector has a tiny area to "managed components", do you know how to change that so it can be more like in your video ?

    upload_2016-9-18_17-28-56.png


    Its really hard to read and navigate the inspector as it is :/
     
    JohnRossitter likes this.
  44. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    Hi there,

    I understand.
    Zone Controller went through a lot of design changes and a lot of functionality was added, so it is difficult to show all of it in a single inspector.

    I'm looking yo refactor the UI soon and will address this issue then.

    Sorry for the UI.

    Thanks,
    john
     
  45. Cyber_2016

    Cyber_2016

    Joined:
    Aug 27, 2016
    Posts:
    46
    Hello John, I posted a review recently on the Asset site about the following issues after I tested quite a bit...
    Again hopefully there is a Fix of some sort or a beta release if possible, I'll edit my review upon experiencing the glory of this Kewl Asset.

    Trigger by "Main Camera" is Not Working... Not sure if I'm having crappy luck today... I must be missing something perhaps. The Unity version I'm using is v5.4.1
    The "Main Camera" is controlled by: Third Person Camera(s) that uses Raycasting for Collision detection. Anyhow I tested with & without the Camera Controller Asset.

    Problems so Far with Version 1.0.2:
    1. I am convinced after testing that the Trigger [Main Camera] doesn't work in Unity 5.4.1 :(

    2. Also the [Pick Collider] trigger is FracD... Console Error:

    NullReferenceException: Object reference not set to an instance of an object
    ZoneMasterController.EnterZone (.ZoneConfig& NewZoneData) (at Assets/UtopiaWorx/Zone Controller Pro/Required/Scripts/ZoneMasterController.cs:120)
    ZoneController.OnTriggerEnter (UnityEngine.Collider Coll) (at Assets/UtopiaWorx/Zone Controller Pro/Required/Scripts/ZoneController.cs:542)

    I suppose I'll wait for a Fix, update :(

    /other minor thing, the Text inside the Buttons "Refresh Source" / "Copy all values from..." the text looks cut off.

    /Also, just an idea for the "Trigger Mode" drop down selection; how about if we can drag in our Camera object or along those lines.

    On a positive Note:
    I'm sure this must be Unity 5.4.1 has changed some inner workings, I'll test with a bit older Unity & see if that's the case or hopefully you might have a temp fix (work-around)?
    /I'll update my review to 5 ***** stars after I get the silly Camera thing figured out, and the other stuff I mentioned already...
    /I really like how this exposes the public properties for us to dream of New ideas. I can't imagine what I'll use this in my New Maze game but used plenty I'm sure :D
     
    JohnRossitter likes this.
  46. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    Hey there, sorry about the issue you are having.
    Do you skype?
    I have a realtim support group you can join, and I can remote look at your project to see whats happening.
    Here is the link to the group: https://join.skype.com/Cb69olXJbDTo
     
  47. Cyber_2016

    Cyber_2016

    Joined:
    Aug 27, 2016
    Posts:
    46
    Thanks John... I haven't really used Skype before but I'll check that link out. :D
     
  48. Cyber_2016

    Cyber_2016

    Joined:
    Aug 27, 2016
    Posts:
    46
    Hello All;
    Thanks!! to John and his quick reply helping me resolve this...
    So, it seems like I didn't have a "Trigger Box Collider" & "Kinematic Rigidbody" on my Main Camera... Silly Me, ya anyhow Unity 5.4.1 is working Awesome with this Clever Jewel of a package :D
     
  49. Cyber_2016

    Cyber_2016

    Joined:
    Aug 27, 2016
    Posts:
    46
    K, this is very strange... When I click on [Pick Collider] ; the button just presses down showing it's pressed but, I get 75+ Console Errors that repeat every second:

    NullReferenceException: Object reference not set to an instance of an object
    ZoneControllerEditor.OnInspectorGUI () (at Assets/UtopiaWorx/Zone Controller Pro/Required/Scripts/Editor/ZoneControllerEditor.cs:110)
    UnityEditor.InspectorWindow.DrawEditor (UnityEditor.Editor editor, Int32 editorIndex, Boolean rebuildOptimizedGUIBlock, System.Boolean& showImportedObjectBarNext, UnityEngine.Rect& importedObjectBarRect) (at C:/buildslave/unity/build/Editor/Mono/Inspector/InspectorWindow.cs:1235)
    UnityEditor.DockArea:OnGUI()

    Truly this is weird...
     
  50. Arganth

    Arganth

    Joined:
    Jul 31, 2015
    Posts:
    277
    as your other asset "Occlutia Culliato" has no forum thread
    what happended with the asset? it was relatively new?
    Is it really dead now?

    Occlutia Culliato
    Scripting/Camera
    UtopiaWorx
    Unfortunately, Occlutia Culliato is no longer available.

    This package has been deprecated from the Asset Store. This means that new purchases of the package are not allowed and that only users who already purchased or downloaded the package before it was deprecated, are allowed to download it.

    In most cases, package deprecation happens because the publisher is unable or unwilling to support the package anymore. We suggest looking for alternative packages or contacting the publisher directly.

    If you’ve already purchased it and need to download a copy, you can do so here.
     
    JohnRossitter likes this.