Hazelnut: Linux 116: "startquest" quest action incapable of using quest packs [RESOLVED]

User avatar
Jay_H
Posts: 4061
Joined: Tue Aug 25, 2015 1:54 am
Contact:

Hazelnut: Linux 116: "startquest" quest action incapable of using quest packs [RESOLVED]

Post by Jay_H »

At Hazelnut's request, I'm making a bug report for this matter.

Quest action:

Code: Select all

start quest __________
Expected behavior:

The start quest action would read from files within the same directory as the current quest file. This would allow mods such as "Warm Ashes" and "Perpetual Quests" to use the Quest Packs folders.

Actual behavior:

start quest only reads from the \Quests folder. All targeted quests must be in that folder and not in the Quest Packs folder.

User avatar
Hazelnut
Posts: 3015
Joined: Sat Aug 26, 2017 2:46 pm
Contact:

Re: Hazelnut: Linux 116: "startquest" quest action incapable of using quest packs

Post by Hazelnut »

Thanks Jay,

I've changed the start quest action to pick up quests in the following order

1) Any classic quests in /Quests folder.
2) Any init quests registered by quest list.
3) Any quests in same folder as an init quest.
4) Any guild quests registered by quest list.
5) Any social quests registered by quest list.

However having done this, I'm not sure if this is the best way. Would it be better to require quests to be registered on a quest list to be startable by the action, using another keyword if they're not in a social or guild group? That would be more explicit, but need a bit more work by authors.

Would like to have opinions of both you and Kamer, as well as Interkarma before proceeding further.
See my mod code for examples of how to change various aspects of DFU: https://github.com/ajrb/dfunity-mods

User avatar
Interkarma
Posts: 7236
Joined: Sun Mar 22, 2015 1:51 am

Re: Hazelnut: Linux 116: "startquest" quest action incapable of using quest packs

Post by Interkarma »

That seems like a reasonable discovery order.

I'm happy as long as the questsToInvoke list behaviour isn't broken and the actual logic to find the file is inside ParseQuest(string questName) - or somewhere close to it in execution order.

User avatar
Jay_H
Posts: 4061
Joined: Tue Aug 25, 2015 1:54 am
Contact:

Re: Hazelnut: Linux 116: "startquest" quest action incapable of using quest packs

Post by Jay_H »

Well, more work just becomes a matter of following steps. I'm not so worried about that.

I'm glad there'll be a method to still tie into the Quests folder. As for order and everything, I'm not too worried, as I hope nobody starts using duplicate quest names to begin with ;)

User avatar
Hazelnut
Posts: 3015
Joined: Sat Aug 26, 2017 2:46 pm
Contact:

Re: Hazelnut: Linux 116: "startquest" quest action incapable of using quest packs

Post by Hazelnut »

Okay will submit a PR with this change to start quest action.

This is the only instance where the quest management system is suceptable to duplicate quest names, any duplicate names will result in the first in order of precedence being returned and started. If this is a problem I'll need to create a new action I think.

I also wondered if there would ever be any need to specific a factionId for rep changes on quest success/failure, but I guess that's not relevant to quests that are not dispensed by the guild system so have left it.
See my mod code for examples of how to change various aspects of DFU: https://github.com/ajrb/dfunity-mods

User avatar
Jay_H
Posts: 4061
Joined: Tue Aug 25, 2015 1:54 am
Contact:

Re: Hazelnut: Linux 116: "startquest" quest action incapable of using quest packs

Post by Jay_H »

We'll have to inculcate well the need to use unique quest names. Mine all start with JH so that shouldn't ever conflict with anyone.
I also wondered if there would ever be any need to specific a factionId for rep changes on quest success/failure, but I guess that's not relevant to quests that are not dispensed by the guild system so have left it.
Theoretically yes, if/when people start making huge multi-part guild quests that may be useful. But for now no one's attempting that, so it's no priority.

User avatar
Hazelnut
Posts: 3015
Joined: Sat Aug 26, 2017 2:46 pm
Contact:

Re: Hazelnut: Linux 116: "startquest" quest action incapable of using quest packs

Post by Hazelnut »

Jay_H wrote: Wed Jun 06, 2018 6:48 pm We'll have to inculcate well the need to use unique quest names. Mine all start with JH so that shouldn't ever conflict with anyone.
For quests you start by just specifying the name, yes you will. Everything else I have been very careful that names don't need to be unique across folders. :)
See my mod code for examples of how to change various aspects of DFU: https://github.com/ajrb/dfunity-mods

User avatar
Interkarma
Posts: 7236
Joined: Sun Mar 22, 2015 1:51 am

Re: Hazelnut: Linux 116: "startquest" quest action incapable of using quest packs [RESOLVED]

Post by Interkarma »

Hazelnut's fix for this will be in next round of builds.

User avatar
Jay_H
Posts: 4061
Joined: Tue Aug 25, 2015 1:54 am
Contact:

Re: Hazelnut: Linux 116: "startquest" quest action incapable of using quest packs [RESOLVED]

Post by Jay_H »

Hazelnut, if you ever get a chance, I'd request a modification for this fix. Right now I'm using a quest mechanism where I'm linking one guild quest to another with the "start quest" action. Under the current system, there are two ways to do it:

1. Put the second quest files into the \StreamingAssets\Quests folder (which is what I'm doing now)
2. Put the second quest files into the corresponding \StreamingAssets\QuestPacks\ folder. Add them to the QuestList. (this enables the "start quest" action but it also opens the possibility that the second quests will be offered directly by the questgiver, which is something I don't want to happen)

What I'd request is the ability for the "start quest" action to scan the QuestPacks folder for the second quest file without it being on the QuestList, so as to prevent it being given out as an ordinary initial quest.

The sum effect of this is to make it easier to install, since for now I need to instruct the user to extract an additional folder of quests into the \StreamingAssets\Quests folder. Thus, this isn't a make-or-break situation, but something that would make installation for these quests cleaner. If the desired benefit doesn't match the expected time investment, don't worry about it.

User avatar
Hazelnut
Posts: 3015
Joined: Sat Aug 26, 2017 2:46 pm
Contact:

Re: Hazelnut: Linux 116: "startquest" quest action incapable of using quest packs [RESOLVED]

Post by Hazelnut »

If the second quest is not in same directory as an registered init quest, the you need to add it to the quest list. It's fairly easy to ensure that it cannot be given out by quest giver I think, although I've not actually tested this for you. Simply use the value 'P' for membership. e.g.

JHAMAZINGQ, FightersGuild, P, 0, Only started by JHOTHERQ.

Let me know if that doesn't work.
See my mod code for examples of how to change various aspects of DFU: https://github.com/ajrb/dfunity-mods

Locked