Only one quest tracked and active at the same time

Announcements, support questions, and discussion for Quest Machine.
GorkaGames
Posts: 178
Joined: Fri Sep 21, 2018 8:38 pm

Only one quest tracked and active at the same time

Post by GorkaGames »

would be great to have an option in which the player can only have one quest tracked and active at one time.
This is how most actual games are doing now (Origin, Odyssey, FarCry 5, Spiderman,...). If you go to the game's journal it allows to only one quest being tracked (I'm not sure if even only one active) at the same time, so the player focus only on that quest.

We talked about this some months ago also, what do you think? Would be difficult to update? (As an option to the developer). I think only the option to only one tracked wouldn't be difficult. Not sure about only one active at the same time, it would requiere create a new state (like waiting or something) and more logic for us to deactivate / activate all the gameobjects / spawners... that don't have to be active.

EDIT:
Thinking about it... In Origin, Odyssey,.... when you accept one quest it doesn't become active / trackable at that moment, you have to go to Journal and decide which of all of them you want to activate / track. Maybe we could add that option also, so therefore no so many quests are active at the same time..... because if you run into lets say 4 quest givers with 5 quests each one, are 20 quest that are in your Journal, and it doesn't make sense to have all of the activated. It's better to select which ones do you want.

MORE FEEDBACK:
Would be great also to have the chance in the Journal to order the quests by:
- Most Recent. (I think this would be easy)
- Distance. (We may add a location transform position field on every quest on the editor, so its easier for you to code)
- Main / Side/ (diferent categories). This last point is done now with the toggles.
- Completed / No completed (accepted) / actual trackable.

¿What do you think?
User avatar
Tony Li
Posts: 22056
Joined: Thu Jul 18, 2013 1:27 pm

Re: Only one quest tracked and active at the same time

Post by Tony Li »

Hi,

These requests are already on the roadmap. I'll add some notes:

> would be great to have an option in which the player can only have one quest tracked and active at one time.

I plan to add an option to handle the Track checkbox as a radio button. If you tick one, it unticks the others.


> - Most Recent. (I think this would be easy)

Planned.


> - Distance. (We may add a location transform position field on every quest on the editor, so its easier for you to code)

You will need to write this custom. I'll try to add utility functions to make it easy to implement.


> - Main / Side/ (diferent categories). This last point is done now with the toggles.

This is already in Quest Machine. Every quest can belong to a group. Does this work the way you need?


> - Completed / No completed (accepted) / actual trackable.

Can you please explain?
GorkaGames
Posts: 178
Joined: Fri Sep 21, 2018 8:38 pm

Re: Only one quest tracked and active at the same time

Post by GorkaGames »

Thanks for your quick answer. Adding some comments:

1.
> would be great to have an option in which the player can only have one quest tracked and active at one time.

I plan to add an option to handle the Track checkbox as a radio button. If you tick one, it unticks the others.


Yes that should be fine. But.... how is in Quest Machine the state of a ¿Active.NoTrackeable quest? Don't you think it would be great to add a new state call something like "waiting to be tracked again" where you launch messages and our GameObjets in the scene can listen (with the listener) them so we can Dissconect them? And also a new message when the quest becomes again trackable so the listener can activate them again. Or maybe its not necessary as those messages are already launched? (quest trackable, no trackable....)


2.
> - Completed / No completed (accepted) / actual trackable.

Can you please explain?

Yes also same than Most Recent, another filter / order for the sates: Completed / No completed


3.
Any chance on this?
when you accept one quest it doesn't become active / trackable at that moment, you have to go to the journal and activate only the one you want.


Maybe it's easier on this screenshot:
https://www.dropbox.com/s/mkgv4nw7wz9a7 ... j.png?dl=0

On the left are the filters: (So you don't show up all of them) Categories, completed, etc...
Bellow are the "sorter by" in our case would be: Distance, Most recent

And this is the complete UI, where you can see the quest's detail once you select one, and the Track / untrack button:
https://www.dropbox.com/s/ngajgdod9heye ... s.png?dl=0
User avatar
Tony Li
Posts: 22056
Joined: Thu Jul 18, 2013 1:27 pm

Re: Only one quest tracked and active at the same time

Post by Tony Li »

GorkaGames wrote: Mon Feb 25, 2019 9:04 amhow is in Quest Machine the state of a ¿Active.NoTrackeable quest? Don't you think it would be great to add a new state call something like "waiting to be tracked again" where you launch messages and our GameObjets in the scene can listen (with the listener) them so we can Dissconect them? And also a new message when the quest becomes again trackable so the listener can activate them again. Or maybe its not necessary as those messages are already launched? (quest trackable, no trackable....)
I'm not sure I understand you. But it sounds like you can already use the existing messages.
GorkaGames wrote: Mon Feb 25, 2019 9:04 am>> - Completed / No completed (accepted) / actual trackable.
>Can you please explain?
Yes also same than Most Recent, another filter / order for the sates: Completed / No completed
I'll try to make a general purpose filter feature that you can customize in code.
GorkaGames wrote: Mon Feb 25, 2019 9:04 amwhen you accept one quest it doesn't become active / trackable at that moment, you have to go to the journal and activate only the one you want.
In the Quest Editor, tick the quest's Is Trackable checkbox, but leave Show In Track HUD unticked. This means the player has the ability to toggle tracking, but when the quest starts it's not being tracked.

Remember that I have not implemented the radio button feature yet, so turning on tracking for one quest doesn't yet turn off tracking for the others.
GorkaGames
Posts: 178
Joined: Fri Sep 21, 2018 8:38 pm

Re: Only one quest tracked and active at the same time

Post by GorkaGames »

ok, thanks for the general purpose filter and all the rest of upcoming features....

Regarding to this:
I'm not sure I understand you. But it sounds like you can already use the existing messages.

I'll try to explain better, its quite difficult here on the chat :)

Well, right now, once you accept one quest, even if you are not tracking it, you may not have the info on the hud as expected and thats ok, but.....once the action quest gets executed on the active node, all the spawners or game objects that corresponde to that active node are going to be activated. For instance enemies spawned or some chest / navigation hud in scene activated. And this I think should not happend (I may be wrong, but at least in other games I show you its like that) till the quest is really trackable. So thats the reason I was asking you either to a new state on the quest (active and trackable), or asking you if there is a message broadcasted when one quest is tracked / untracked, so I can manage the game objects with the listener and deactivate them when the quest is untracked.

Let's put one example. Player accepts 20 quests but it's not playing / tracking anyone. Quest Machine Hud may be empty and clean, thats ok, but I'll have maybe 100 game objects (some with their own navigation Hud) actives, so it's a mess in the screen and very costed on performance.

Waiting for your thoughts...
User avatar
Tony Li
Posts: 22056
Joined: Thu Jul 18, 2013 1:27 pm

Re: Only one quest tracked and active at the same time

Post by Tony Li »

The message is "Quest Track Toggle Changed" (QuestMachineMessages.QuestTrackToggleChangedMessage).

Add a node after START that waits for the player to track the quest. Example:

Instead of:

[START] --> [Spawn & Kill Enemies]

use:

[START] --> [Wait For Track] --> [Spawn & Kill Enemies]

Set a condition on [Wait For Track] to listen for "Quest Track Toggle Changed".

Set the actions on [Spawn & Kill Enemies] to spawn the enemies.

This way the enemies won't spawn until the player has toggled tracking on.
GorkaGames
Posts: 178
Joined: Fri Sep 21, 2018 8:38 pm

Re: Only one quest tracked and active at the same time

Post by GorkaGames »

okkk, thats a godd idea......

The only problem I have try to figure out, if the player go to the journal once the actual quest is tracked and activated, and decides to toggle other quest to track..... what should I do? :) And if he does it track again? :)

This is getting complicated as more that one quest can be in active status at the same time by design. The ideal behavior should be that only one quest can be active at one time.

Any suggestion are welcome

By the way. all this is saved (tracked / untracked quests) also and gets loaded ?
User avatar
Tony Li
Posts: 22056
Joined: Thu Jul 18, 2013 1:27 pm

Re: Only one quest tracked and active at the same time

Post by Tony Li »

GorkaGames wrote: Mon Feb 25, 2019 2:05 pmThe only problem I have try to figure out, if the player go to the journal once the actual quest is tracked and activated, and decides to toggle other quest to track..... what should I do? :) And if he does it track again? :)
If you want to untrack all other quests, add a script to your player that listens for "Quest Track Toggle Changed". If the message's "(bool)firstValue" is true, then loop through the QuestJournal's questList. If the quest doesn't match the message's parameter, turn off tracking (set Quest.showInTrackHUD = false).

If you want to despawn enemies when changing the active quest, Quest Machine provides the messages so you'll know when quest tracking is toggled, but you'll need to handle the despawning, etc., yourself.
GorkaGames wrote: Mon Feb 25, 2019 2:05 pmBy the way. all this is saved (tracked / untracked quests) also and gets loaded ?
Yes for procedurally-generated quests. The next update will also save the track toggle for hand-written quests.
GorkaGames
Posts: 178
Joined: Fri Sep 21, 2018 8:38 pm

Re: Only one quest tracked and active at the same time

Post by GorkaGames »

Thanks for the feedback.... this is getting interesting :) But a lot of testing for the different states !!! real time + save/loading, ufff...

ok, if I let the player to track other quest (and untrack the other ones, included the one is active) what do you think should I do with the actual active quest? I guess change his state to Disabled or abandoned (and therefore dissconect the gameobjects throw the untrack message as you said on the previos post)
if I change to Abandoned It loses all the progress, doesn't it?
If I change to Disabled it restores from the same node once its active again, doesn't it?

And I have to manage all the states on the gameobjects from my own code because Quest Machine doesn't run the action nodes again....

I mean, I see it's achievable but a lot of control on my end on the different states. Specially when you have to do also for the load game, not only for runtime..... what do you think?


PS:
How do I loop through the QuestJournal's questList ? some help about the code I need to use, thanks.
User avatar
Tony Li
Posts: 22056
Joined: Thu Jul 18, 2013 1:27 pm

Re: Only one quest tracked and active at the same time

Post by Tony Li »

GorkaGames wrote: Mon Feb 25, 2019 6:02 pmok, if I let the player to track other quest (and untrack the other ones, included the one is active) what do you think should I do with the actual active quest? I guess change his state to Disabled or abandoned (and therefore dissconect the gameobjects throw the untrack message as you said on the previos post)
if I change to Abandoned It loses all the progress, doesn't it?
If I change to Disabled it restores from the same node once its active again, doesn't it?
You probably don't want the player to lose his progress. And if you despawn enemies when the player switches quests, it might look strange.

I suggest that you leave the quest state active, but reset the node states.
GorkaGames wrote: Mon Feb 25, 2019 6:02 pmHow do I loop through the QuestJournal's questList ? some help about the code I need to use, thanks.
Here's an example:

Code: Select all

var journal = GetComponent<QuestJournal>();
foreach (var quest in journal.questList) {
    Debug.Log(quest.title);
}
Post Reply