Disable message to interact when object destroyed
Posted: Tue Nov 18, 2014 10:19 am
Hello,
I'm not sure this is completly connected to the Dialogue system, but anyway
I've made an game object which has added component usable and it react's with interact message when player is in it's collider.
When I press interact button I want to destroy the item from the scene and disable / hide this interact message.
So I made OnUse function in my script and in it I was trying to disable the object. But after this message to interact still stays.
I've also tried to move/translate the object off scene but message is still visible and object is still interactable until I move with player.
I guess there is no OnTriggerExit sending when I destroy it, so I understand the message stays...
How can I solve this the best?
Thank you !
I'm not sure this is completly connected to the Dialogue system, but anyway
I've made an game object which has added component usable and it react's with interact message when player is in it's collider.
When I press interact button I want to destroy the item from the scene and disable / hide this interact message.
So I made OnUse function in my script and in it I was trying to disable the object. But after this message to interact still stays.
I've also tried to move/translate the object off scene but message is still visible and object is still interactable until I move with player.
I guess there is no OnTriggerExit sending when I destroy it, so I understand the message stays...
How can I solve this the best?
Thank you !