Hello, I am using Unity 2018.3.5 to develop for the HoloLens and I am using Image Targets so show some Objects to the user.
Since I need to add custom behaviour to the detection-progress, I created my own TrackableEventHandler-Script as a copy of the DefaultTrackableEventHandler-Script (as suggested in this post: https://developer.vuforia.com/forum/hololens/modify-ontrackingfound-ontrackinglost-behaviours?sort=2)
The only thing I added to the Handler is a check at the beginning of the OnTrackableStateChanged-Method if the current user position is close enough to a certain, static position. This calculation works, I logged it and the results are correct. The OnTrackableStateChanged-Method should return if the user is not close enough. But when I deploy to the HoloLens, it does not work.
All Objects, which are children of my Image Targets, are shown before I found a target and when I find a target they are placed, regardless if the position check returns true.
I removed the default component in the inspector of the target-object and added my custom handler, but it still does not work!
Please help me find my mistake!