Forum rules - please read before posting.

Hotspot Labels - How do I get those up and running?

Hello,

I noticed in the 3D first person tutorial for AC that when the player looks at a hotspot, a label appears:

My project started with this tutorial, but somewhere along the way I've lost this functionality and I'm not sure how to activate it (or perhaps because my interactions are so custom that has affected it?)

I did a bit of digging and noticed there was a hotspot label in the demo. I've also got that in my project so I don't think the issue is that:

My hotspot settings match that of the demo as well:

And of course, my hotspots do have labels set and are on the default layer as well:

Any ideas?

Comments

  • That your interactions are custom is most likely the cause. If you switch back to e.g. Context Sensitive, do the labels reappear?

    If you're selecting Hotspots through code, you may have to force AC's internal record of the active Hotspot manually with:

    KickStarter.playerInteraction.SetActiveHotspot (myHotspot);
    
  • edited April 2019

    Hello @ChrisIceBox.

    You are indeed right sir, switching back to Context Sensitive made the labels reappear.

    At the moment all the custom code I have is about verbs hitting hotspots. I'm not sure how I'd make that label reappear on having the hotspot in the centre of the screen. Was AC performing a raycast in the first place?

  • Yes, but it'll be disabled if you're doing it custom.

    You can grab the same code AC uses, however, in PlayerInteraction's CheckForHotspots method. The Raycasting specific for 3D games, based on the mouse position, can be found at the end.

  • Thanks Chris. I'll have a dig into it at the weekend. Have a good one!

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.