Cavalorn on 8/8/2017 at 20:17
Okay, so I began the process of (re)learning how to set up mission objectives and I already hit a dead-end right at my first objective. I went through several tutorials but I can't solve this so I ask for your help once again.
Right at the beginning of the mission, when Garrett reaches a certain point, I want the one and only objective to be canceled and to get new ones instead. I'm sure I have to make use of QVars somehow, but the problem is that I can't set up the objective to get canceled instead of completed. I'd really appreciate some instructions.
Daraan on 8/8/2017 at 20:32
Well objectives are tracked by QVars so at the point you want it to be canceled you want to change it for that you need iirc a TrapSetQVar.
One Step back:
I don't know if you were successful in creating the QVars in the first place, look for RSouls Tool here in the Forum.
Back to Topic:
What you want to change is the goal_state_#, so if it's the first quest the QVar would be named goal_state_0 and you want to give it the value 2.
See also for example: (
http://southquarter.com/dromed/?p=174)
Renault on 8/8/2017 at 20:35
The objective needs to be marked as inactive (0 is incomplete, 1 is complete, 2 is inactive, 3 is fail). So...
quest_create_mis goal_state_0,2
if you're doing it manually. Of course, there needs to be other active objectives I believe or the mission will end. You might have a set up a small delay or timer in making this goal inactive, so your new objectives can be implemented first.
Renault on 8/8/2017 at 20:45
Those programs are good for the initial setup, but not for changing objectives mid mission, right?
@Cavalorn - so do you need to know specifically how the Qvars work for making a goal inactive, or triggering a change when you reach a certain point in the map?
Cavalorn on 8/8/2017 at 20:48
Thank you all.
Unfortunately, TOW won't work for me so I was trying to use GM instead which is reportedly much better anyways, but I still couldn't get what I wanted (I know I suck at this, but hopefully I will learn it this time). I might have to resort to the old manual method, but I'm fine with that as long as I can get it to work. I'll go and see if I can get it to work this time. Thank you very much, everyone.
Cavalorn on 8/8/2017 at 20:53
Quote Posted by Brethren
Those programs are good for the initial setup, but not for changing objectives mid mission, right?
@Cavalorn - so do you need to know specifically how the Qvars work for making a goal inactive, or triggering a change when you reach a certain point in the map?
I believe so. I could only set up simple objectives like get x loot and steal x. But I couldn't do anything out of ordinary like changing objectives and receiving new ones.
Yes, that's correct. Even GM mentioned that I would need to use Qvar for these stuff.
Renault on 8/8/2017 at 21:51
So you basically need to create a QVAR trap (Object Heirarchy, fnord->marker->trap trigger->quest var trap). It's just a marker object. Under it's properties, Add->Trap->Qvar. Then enter the command for what you want to change when the QVAR trap is activated. For making objective 0 inactive, it would be:
=2:goal_state_0
Hope that makes sense. Then all you have to do is find a way to activate the QVAR trap, either by CD linking from a Bounds Trigger or a Concrete Room brush (same kind used for "Go to location X" objectives). There should be plenty of tutorials here on that stuff.
Then you would just create additional QVAR traps for all of your new objectives. Their Add->Trap->Qvar might look something like this:
=1:goal_visible_1
=1:goal_visible_2
=1:goal_visible_3
That should hopefully get you started. Let me know if you need more clarification.
Edit:
There's a great tutorial by The Pixie on Qvars here:
(
http://thiefmissions.com/tutorials/qvars10.zip)
Cavalorn on 8/8/2017 at 22:08
Thank you very much, Brethren! I really do appreciate this lengthy and detailed description. It definitely makes sense, and now I have a pretty good idea of how to proceed. Thanks again.
R Soul on 8/8/2017 at 22:57
You should set things up so that the new goals are made visible
before the original one gets cancelled, otherwise there will be a brief period (only a few milliseconds, which is enough) where the game will be satisfied that there's nothing left for you to do, and the mission will end.
If you're using multiple QuestVarTraps, have them all triggered via a RelayTrap and set the order of the links so the 'cancel' qvar is last.
Or have a go at using my custom (
http://www.ttlg.com/forums/showthread.php?t=147751) SetMultQVars script, which allows you to set things up using just one object.