News Forums RAIN General Discussion and Troubleshooting Waypoint Route is not visible by rain after Unity close

This topic contains 3 replies, has 2 voices, and was last updated by  Sigil 5 months, 4 weeks ago.

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #38527

    gray_wolf
    Participant

    Hi. I have a small problem. When I close unity (save scene) rain doesn’t see my Waypoint Route’s (before closer they worked fine). The routs are steal visible in unity editor and in objects tree.

    Unity 5.1.0 f3
    Rain 2.11.1.0

    #38538

    Sigil
    Keymaster

    Just to clarify what is happening: You create a Waypoint Route in your scene, press play and your AI sees and moves along the route (assuming you set that up at this point). You save the scene, close and reopen Unity, press play, and the AI no longer moves along the route?

    #38613

    gray_wolf
    Participant

    Yes.
    Some more info I receive in console NullrefrrenceException

    NavigationManager.Instance.GetWaypointSet(wpSetName) returns null
    NavigationManager.Instance.WaypointSets is empty

    I use A* script for pathfinfing (found on this board)

    #38619

    Sigil
    Keymaster

    Hmmmm, well the Waypoint Set registers itself with the NavigationManager when Awake is called on the WaypointRig, is it possible that the code you pasted above is in the Awake of another script? If that is the case, moving it to Start should alleviate that particular problem.

    If this is the case, the reason it works the first time is that Awake gets called when the editor creates the component initially.

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.