Problem with QuestDomain
Posted: Fri Mar 19, 2021 10:19 am
Hi!
I continue exploring the QuestMachine and today I have faced a small problem with QuestDomain.
My problem was the following:
Also, in the manual you say:
The only way to represent the domain in the scene is by having a QuestDomain component on one of the game objects, right?
What if I want to have a character game object, that has a collider component and a QuestDomain component. But I don't want every entity that the character collides with to be added to this QuestDomain. How would I achieve this?
One way would be to ensure that the game object that has the QuestDomain component, does not have a Collider component. But this does not seem like a reliable solution.
Perhaps I am missing something. Looking forward to your response.
Artem
I continue exploring the QuestMachine and today I have faced a small problem with QuestDomain.
My problem was the following:
- There is an NPC game object in the scene
- The game object has a Collider and the QuestDomain component
- I then use this QuestDomain as a reference in some other script, and I add entities when needed
- But today I noticed that if any other entity collides with the NPC, it would be added to the QuestDomain
- This is because QuestDomain script uses OnTriggerEnter
Also, in the manual you say:
- "Domains don't always have to represent physical
areas; they can represent anything that can contain quest entities, such as a character's inventory"
The only way to represent the domain in the scene is by having a QuestDomain component on one of the game objects, right?
What if I want to have a character game object, that has a collider component and a QuestDomain component. But I don't want every entity that the character collides with to be added to this QuestDomain. How would I achieve this?
One way would be to ensure that the game object that has the QuestDomain component, does not have a Collider component. But this does not seem like a reliable solution.
Perhaps I am missing something. Looking forward to your response.
Artem