Create a function that summons and entity that runs a function when looked at

All I want to do is run a function when an entity WITH A SPECIFIC TAG is looked at. I am aware that the predicate for testing if it is looked at exists, but I have no idea how I use that in an overall function.

Continue to help post