OnTriggerEnter
Posted: Tue Sep 28, 2021 2:41 pm
Would it be possible to use a Dialogue System Trigger component with ontriggerenter so that it runs every frame?
I'm aware this would be bad for conversations but also very useful for running Sequence commands!
You can also use SendMessage to run a function every frame but only while inside a trigger. How cool is that!
Alternatively, if I can run this code on update. Is it bad for performance?
I'm aware this would be bad for conversations but also very useful for running Sequence commands!
You can also use SendMessage to run a function every frame but only while inside a trigger. How cool is that!
Alternatively, if I can run this code on update. Is it bad for performance?
Code: Select all
//trigger = GetComponent<DialogueSystemTrigger>();
void Update()
{
trigger.OnUse();
}