I'm guessing
void SetEntityActive(string& asName, bool abActive);
In combination with an area which is triggered when you have looked at it, and then look away again.
I haven't done this before, but you can probably use this then:
void SetEntityPlayerLookAtCallback(string& asName, string& asCallback, bool abRemoveWhenLookedAt);
I haven't used this Callback before; what I would do is make a new variable that adds one when you look at the object. When you look away, it adds another one.
Make a check if the variable is 2. If so, SetEntityActive();
But there's probably a simpler method with that callback. Feel free to experiment.