Keyboard Interaction of Objects in View

You will love this.

this.camera = null;

^ That line right there is exactly the issue with the current method testing intersection. It is line 19 of the First Person View tutorial. Even though a camera attribute is available in the script. That line completely overrides it and creates a new active camera on initialization. Deleting that line and reassigning the correct camera in the editor attributes allowed my 2nd attempt script to work as expected.

I only discovered this because of a thread from 2018: Camera Direction Vector

Thanks to @yaustar for seeing the problem in the tutorial script back then. It really seems like something that should be looked at or changed, as it is a bit confusing.

As for the original script, visibleThisFrame still continues to return true always even with the correct camera, so no luck there, but at least I’ve made a little bit of progress. Now I will return to the original interaction problem of the thread, and see what I find.

Thank you @Leonidas for your help!

Here is the working project: https://playcanvas.com/project/674259/overview/1st-person-test-continued

I will fork it again and continue my project.