Quest Logging

CWolf

First time out of the vault
I'm trying to get a custom made quest to show up in the pipboy.

I've been looking through a few of the .ssl files for information on how to do this. So far I've found an example of a logged quest once it has been finished:

(from the KCTORR.ssl)

set_global_var(GVAR_QUEST_RUSTLE_CATTLE, RUSTLE_SUCCESS);
set_global_var(GVAR_RUSTLE_SUCCESS,1);

However where does this link to for a small one line sentence to show up in the pipboy? Do I need to define the global_var and if so where do I define it?

Any help would be useful, Thanx.

EDIT: ok I research a little and discovered the global_vars all in the vault13.gam and global.h file. How does it get integrated into pipboy and how does pipboy display a custom quest message?
 
the quests are in quests.txt, and set the global variable to check, the value needed to be in that variable for the quest to be listed in the pip-boy, and the value in that variable for that quest to be listed as done in that variable...

Code:
# Kill the Evil Plants
# Arroyo, GVAR_KILL_EVIL_PLANTS, Quest_Accepted, Quest_Completed
1500, 100, 9, 2, 6

1500 is the line number from map.msg that describes the town.
100 is the line number in quest.msg for the description of the quest
9 is the global variable to look for which can be found in the global.h file.. ( in this case GVAR_KILL_EVIL_PLANTS ).
2 is the value the global variable needs to be for the quest to show up in the pip-boy.
6 is the value the global variable needs to be for the quest to show up as DONE in the pip-boy.


it ignores anything after the # so the rest is just explanation info...

the display and done numbers are actually thresholds... the value must be at least that.. so you could set a quest to kill 10 mutants in an area, then increase the global variable by 1 every time you kill one and after you kill 10 the quest would register as done..
 
thank you, I think that answers everything I'll need. I'll go about testing that now.
 
Yep, ColJack get it perfectly all together :)

BTW: Quest editor is next in my "to do" list on FSE project.
 
excellent since i'm using FSE anyway :) would be useful.
Is there a way to open .msg with FSE?

Thanx

EDIT: Nvm, i realise they can be opened by FSE anyway lol
 
CWolf said:
excellent since i'm using FSE anyway :) would be useful.
Is there a way to open .msg with FSE?

Thanx

EDIT: Nvm, i realise they can be opened by FSE anyway lol

You can edit .msg files with notepad but a function that links scripts with message files would be really cool. This would make viewing dialogs a lot easier since you wouldn't have to continuously toggle between the .ssl and .msg files.
 
you can already open the corresponding .msg file when you have a script file open in the FSE.. most usefull when you're trying to remember what the next branch of the dialogue should be...
 
Yes, there is msg editor(F8) for dialog file editing.
It will always open msg file for actual script(but this msg file must exist in "Conversation files folder" or data/text/english/dialog folder.

BTW another nice thing in msg editor is that if you double click on a line with text, its number and file number will be inserted to the
current script like this:

message_str(file_num, txt_num).

message_str(590, 107)

so you don't need to remember script number etc.
 
Corpse said:
CWolf said:
excellent since i'm using FSE anyway :) would be useful.
Is there a way to open .msg with FSE?

Thanx

EDIT: Nvm, i realise they can be opened by FSE anyway lol

You can edit .msg files with notepad but a function that links scripts with message files would be really cool. This would make viewing dialogs a lot easier since you wouldn't have to continuously toggle between the .ssl and .msg files.

Yep I was using notepad anyway but to make things nice and tidy one program is nice to use :P
 
In ACSPORPL.SSL this part of code...

Code:
procedure destroy_p_proc begin
   inc_map_var(MVAR_Kill_Evil_Plants);
   if (KILLED_ALL_EVIL_PLANTS) then begin
      display_msg(mstr(150));
      set_global_var(GVAR_KILL_EVIL_PLANTS,QUEST_COMPLETED);
      inc_general_rep(REP_BONUS_KILL_EVIL_PLANTS);
      give_xp(EXP_KILL_EVIL_PLANTS);
//      terminate_combat;
   end
end

How does the

Code:
 set_global_var(GVAR_KILL_EVIL_PLANTS,QUEST_COMPLETED);

change the global_var from 2 to 6? If I changed the words 'QUEST_COMPLETED' with the number '6' would that work exactly the same? Or does the 'QUEST_COMPLETED' just automatically complete the quest no matter what ?
 
Code:
set_global_var(GVAR_KILL_EVIL_PLANTS,QUEST_COMPLETED);

as a general rule, anything in capitals has been defined in one of the included header files listed at the top of the script.

basically the pre-processor ( watcom etc.. ) reads through the script, and replaces any instances it finds of a defined lable with the number or value it represents.. so wherever it finds QUEST_COMPLETED it puts 6 instead..

a define is just a way of using a text lable instead of a hard value.. and is easier if that number is subject to change..
for example, if you had lots of scripts that used the same value over and over again, then you put a define in instead and then if that value needed to be altered in all the scripts, you only need to change it in the define line in the header and re-compile all of the scripts again without having to edit every script and change the values one by one...

does any of this make any sense?? cos it's hard to explain it in simple terms without using some of the "buzz words" used in programming...
 
it makes perfect sense since I am in first year Computer Science Degree course in the UK ;). Learning Java so it's a little different to this which seems like a mix of Perl and Java or maybe C++.

Thanx for the help mate. I just need pointers in the right directions. I'm determined to learn this
 
well, the Fallout script syntax is like Pascal+C :D
Watcom precompiler is a standart C tool.
 
Back
Top