Closed yosun closed 6 years ago
if(HighlightRequests.ContainsKey(highlightRequestId)){
var request = HighlightRequests[highlightRequestId];
HighlightIdsToAdd.Add(highlightMeshId);
var gameObject = HighlightStreamer.GetObjects(highlightMeshId)[0];
gameObject.GetComponent<MeshRenderer>().sharedMaterial = request.material;
}
BuildingsAPI.cs line 267ff
That's my fix for now - not sure if that might break other Wrld features...
Accepting this as a known bug - will fix for next release
Fixed on v0.6, but involves api change - migration notes to follow
Snapshot package available here: https://eegeo-static.s3.amazonaws.com/unity/wrld.unity.sdk-SNAPSHOT.zip
temporarily fixed by setting private to public static Dictionary<int, HighlightRequest> HighlightRequests; and checking for BuildingsApi.HighlightRequests.ContainsKey(lastHighlighted.HighlightId)
since the callback seems stochastical when buildings are highlighted too fast, you may want to check for existence before calling it