Forum rules - please read before posting.

Can you access the 'object to highlight' property of Hotspot via a C# script?

edited June 2018 in Technical Q&A
Hey folks,

I'm trying to create a more global solution to highlight / object flashing in my game. Basically I want everything to do it and I'd rather not have to setup ActionLists...etc on every object manually just to make them trigger highlights. It feels like it could be a more globaly assumed behaviour.

Anyway, my first question is when you setup a hotspot, you can pass it a gameObject in the 'object to highlight' field. Is this property / field accessible in a C# script? What I mean is when I do a dot access on a Hotspot object I'm not seeing anything in the list which seems to refer to that field.





Thanks,
Tem




Comments

  • edited June 2018
     I've managed to achieve the effect I was after using Hotspot.Select() & Hotspot.Deselect().

    I wasn't aware about the API guide!





  • Custom events are also a good way of triggering custom code when AC performs common tasks.  In this case, the OnHotspotSelect / OnHotspotDeselect events may be what you're after.

    For more, see the "Interaction scripting" and "Custom events" chapters of the Manual.
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.