Forum rules - please read before posting.

Hotspot Limit To Camera Not Working in 2.5D?

When switching cameras in a 2.5 game, the hotspots in the scene in the first camera, are still visible and interactable when switched to another camera. The option 'Limit To Camera' in the hotspot doesn't seem to work, or I am doing something wrong? Version of AC 1.64.5 and Unity 2018.1.61.

Comments

  • The "Limit To Camera" field won't affect a Hotspot's visibility - if the Hotspot is attached to a mesh, it will still be visible with other cameras.

    It should, however, affect interactivity - and I can't recreate any such issue.

    Does the issue occur if the "other" camera is the scene's default?  What layer is the Hotspot on when it's interactive in the other camera?  It should move itself onto "Ignore Raycast" automatically.

    If you wanted to brute-force the Hotspot out of the way completely when switching to another camera, you could hook into the OnCameraSwitch custom event:


  • With visible, I meant interactive (i.e. the hotspot's name comes up when you hover over it with your mouse). What i did:

    1. Started a new game using the AC wizard. Set it up as 2.5 D and used 'context sensitive' for hotspot management. Waited for wizard to set things up.
    2. First step: created 3 different cameras, each with their own background image. I didn't move the camera's.
    3. Created hotspots for camera scene 1. Hotspots are to 'navigate' between cameras and flip switches for a door. Selected 'limit to camera' on all hotspots and chose the camera in question for each one by dragging them from the inspector.
    4. Set Cam 1 as 'active' cam. When I run the game, the hotspots that are supposed to be limited to cams 2 and 3, are visible and clickable whilst in Cam 1 scene.

    What am I missing? do I need to set up a player first? (My came doesn't really need one as it is first person and all I do is switch between cameras / scenes).  





  • I found the problem: I didn't set up a 'Camera at Player Start'. Once I did this, the hotspots work perfectly.
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Welcome to the official forum for Adventure Creator.