Jump to content

DOWNLOAD MODS

Are you looking for something shiny for your load order? We have many exclusive mods and resources you won't find anywhere else. Start your search now...

LEARN MODDING

Ready to try your hand at making your own mod creations? Visit the Enclave, the original ES/FO modding school, and learn the tricks of the trade from veteran modders...

JOIN THE ALLIANCE

Membership is free and registering unlocks image galleries, project hosting, live chat, unlimited downloads, & more...

Quest Design Lesson 1: Basic Quest


Lingwei
 Share

Recommended Posts

Questbuilding Lesson 1

Setting up a basic quest.

This lesson contains the basics of setting up a new quest in a step-by-step manner.

1. After loading up the Oblivion esm, click on the character menu bar at the top of

the screen. Then click quests (about 2/3rds way down).

2. Create a new quest by right clicking in the area on the far left hand side and

clicking the 'new' option. Type out your new questID, for this example I will name it

LingTutorialQuest.

It's a good idea to adopt some naming conventions to make remembering what you have

created easier. Firstly you should always add a prefix onto anything new that you add.

This will allow you to easily recognise what new things have been added by you and

what are pre-existing things that have been modified. I use Ling since it is the start

of my internet handle and not many other things start off with Li, you can use what

you want. The second part of the questID should give you some idea about what the

quest is about. Since this is a tutorial quest I name the second part 'tutorial' makes

sense right? The third part tells you what kind of ID it is. Since it is a quest you

call it a quest. You can also apply this to all of the other IDs that you create. Call

a script a script, call a spell a spell etc etc.

3. Scroll down to select the new quest. An easy way is to just type the first letter

of the quest, that way it will scroll down closer to your new ques (hint: don't make

your prefix start with M). You will find yourself in the opening tab of the quest

window, the 'Quest Data' tab. This is used to set up several basic parts of the quest.

4. Set up the basics of the quest in the quest tab. I'll explain most of the stuff

that is contained in the Quest Data tab here since you will need to know how most of

it works

Quest Name: This is the name that will show up in the player's journal entries. I'll

call this quest Lingwei's Amazing Quest

Priority: This determines what dialogue will be played for NPCs. 100 takes highest

priority and 0 takes lowest. If you have two seperate quests running at the same time

that both give a different greeting dialogue to the same NPC the quests will compare

which has the higher priority to decide which dialogue to play first. If they both

have the same priority then...well who knows, flip a coin and that's which one you'll

get. For now we'll give this quest a priority of 50 which is fine because it's a

sidequest. If you are in doubt then just look at how Bethesda has assigned their quest

priority to decide how high you think you should be.

Script: I'll come back to this later.

Add Icon Image: This will display the quest icon in the journal. If you want your

quests to look like decent quality then you will need to add a quest icon. You'll need

to unpack all your textures if you haven't done so yet and put them into your Oblivion

data folder. Once that is done, click on 'add icon image' which will bring up a

windows explorer window. Double click the folder that says 'quest' which will bring up

a bunch of files. You can then choose which one you want to use. For most sidequests

you can just use the standard sidequest icon that Bethesda used: icon_miscellaneous.

Click on it and select open, when you get back to the quest screen you will see the

new icon next to the add icon button and the add icon button will now give the path

name of your icon.

Start Game Enabled: This will determine whether your quest starts enabled, meaning

that the script associated to it will run from the beginning of the game, or not,

meaning...I think you know what it means. If you are planning on making a questline

where one quest follows another, or having a single quest start a bunch of other

quests, then you can uncheck it so that it doesn't start enabled, but if you are just

making a standalone quest (like this one) then you will want to leave it enabled.

Quest Conditions: This sets conditions for the dialogue for the whole quest. If you

for instance assign a condition GetisID Martin == 1, then for all of the dialogue you

right it will only be played whenever you are talking to Martin. If you assign

GetItemCount Gold >= 50 and set to run on target (i.e 'the player who will be the

target of the dialogue') it will only be played whenever the player has 50 or more

gold. You'll rarely use this, trust me. All the Bethesda quests have the condition

GetIsPlayableRace == 1, which says that the NPC needs to be one of the playable races

for the dialogue to display (so you don't have dremora talking about mudcrabs presumeably). You may as well add it to yours as well.

--------

Now we have the basics of our quest set out. From here we get into the actual business of creating a quest. First thing I usually do it write out my quest stages, it can

help you to conceptualise what and how you will need to do, and as you work through

the quest you can use it as a sort of check list to mark what has been done. For this

simple introductory quest I'm just going to do a simple kill quest with no other trappings.

------

Click on the 'Quest Stages' tab to the right of the Quest Data tab. You'll see several

boxes, mostly grayed out at the moment. In this tab you will create however many quest

stages of the quest there will be. There are several extra parts to this tab, but

since we aren't using them for this simple quest I'll explain them in a later lesson.

1. Start by right clicking on the white part of the screen under the words index, then

click new. This will create a little box with the number 0 selected and the Log Entry

box will suddenly become whie.

2. Change the 0 to another number. A good starting number is 10 (this is the

convention that Bethesda uses). Occasionally you might need to set some things up

before you give out the actual quest, and those can be done by adding stages before

10. But you won't need to do that for a while.

3. Once you've changed the number to 10, reselect the number and then right click on

the white part underneath Log Entry and click new. Now both the Log Entry and Result

Script part of the pages will become white, and the letter EMPTY will show up under

the Log Entry part.

4. Type in the quest stage entry. The quest stage entry is just another name for the

journal entry, so you can think of it that way if you want. Any of the stuff you right

here will show up in the players journal ingame. We can write �short summary of what

happened, and what the player's next goal is. For this tutorial quest I'll just write:

I need to kill some dude standing on the bridge near Bravil.

This lets me know that I need to set up 2 NPCs, and dialogue asking me to kill one of

them. You'll also notice that the part that used to say EMPTY now says the beginning

part of the journal entry that you have just written.

5. Create a second stage entry with the stage number of 20, and do the same as before. Now if you were following the Oblivion Bethesda school of quest design you would now be required to write out dialogue explaining that the player just killed the NPC and needs to go back to collect their money. I however believe that players are smart

enough to figure out if the guy lying on the floor infront of them is the one they

were meant to kill and that they should go back to get their gold on their own. This

was how it was done in Morrowind, but for some reason Bethesda decided that everyone must have took a collective c*** on our brains during the time the two games were released. So it's up to you whether you want to hold the player's hand and treat them like a 6 year old, or like the grown ups that they truly are.

We set up a seperate stage even if we aren't going to add a journal entry because it

is a good way to keep track of what the player has done on their quest.

6. Set up a final stage (100) and write out a concluding journal entry:

I got 250 gold for killing someone. I'll rot in hell hopefully someday. (note you don't really need to write the last part, I just think it's funny how we so easily kill npcs in computer games for such a small amount).

------

Quest Targets: Don't need to worry about this for this lesson.

------

Now we get to the Topics tab. You'll be spending a lot of time in this tab, assuming that you are creating a dialogue heavy mod.When you first go into the topics tab you are confronted with a mass of options (grayed out at the moment). Since explaining everything now will cause you an information overload I'll only deal with the basics you need to know.

1. Right click on the white area underneath the part that says 'Topic' and click the option to Add New Topic. A box will come up saying Select Topic, you need to right click again and click new, then you can create a new topic. For this example I will give it the name LingTutorialMurderTopic.

Topics are what appear in the dialogue screen ingame. Each topic has two important parts. The 'Topic Text' which is what the topic is called ingame (e.g Rumors) and the 'Info' which is what dialogue you actually see when you click on the topic (e.g I hear the Fighters Guild are recruiting again, not bad work if you've got the stomach for it).

The new topic we created will be used for all the things related to the murder. It will allow us to give the starting dialogue, and the ending dialogue. I've named it LingTutorialMurderTopic to follow the naming convention we established with our questID. Ling is my prefix, Tutorial is the name of the quest, Murder is the keyword that tells us what the topic is related to, and Topic tells us that it is a topic.

You'll see that in the spot underneath the letters EditorID where there used to be nothing, there is now the words LingTutorialMurderTopi..., whenever you add a new topic it will appear in this place.

2. There is a second topic that we will need to use. The GREETING topic. This is a special topic that will always play when the NPC is first greeted. It isn't absolutely necessary as all NPCs have some basic 'Hi' and 'Hello' greetings to fall back to if they don't have anything else, but it's nice to have your own personalised greeting, espcially if they are a quest related npc.

Right Click underneath EditorID again, click new, and scroll down to the GREETING topic (you can do this quickly just by typing GREETING). Once it is selected click okay.

3. Now it's time to change the 'Topic Text' of the LingTutorialMurderTopic. When you first create the topic it will add the name of the editorID to the topic text, this will look really weird ingame. So it's a better idea to change the name of the topic text to a one or two word response that can be used to cover all of the possible situations that you might need to ask the NPC about. For this case we can just call it 'Murder' so highlight the topic text box and type Murder to overwrite the current text.

Don't do this for GREETING though. GREETING is a special case and overwriting the topic text of it can mess up the game. So don't do it.

4. Now it is time to add the first of our info.Select the GREETING topic, right click the white part underneatht the letter Info and select new. A big box covering the right third of the screen will pop up.In the top box marked Response Text is the part where you write the dialogue you want your NPC to say. For this quest we can write something corny like:Hey, want to murder someone for a bit of money?

5. Now you can edit some of the other parts of the dialogue. The part labelled script notes are directions for the voice actors, so you don't even need to use that. The part that says Emotion Type affects how the actors face appears when they say the line. You can click on the bar and change it to one of the other emotions that exist, but for now we can leave it at neutral.

The part that says Emotion Value affects how strongly the face changes, with 100 being the highest and 0 being the lowest (although why you would want to choose 0...the lowest I usually use is 30).

The part that says Voice Filename...well close the window first.

6. You'll now see that a line has appeared in the info box, and below it in the box labelled Response Text the same line has appeared. Each time an info is played in the game it will play all of the responses in the response box in a row until the end. This lets us add more dialogue to a single Info, for example if we have run out of space due to the ridiculously low character limit.

Right click on the white part below the text in the Response Text box and click new. �The same new response box pops up again. We can write out something extra to convince the player now. E.g:

Don't worry, it won't count as murder.

Click okay and we get back to the dialogue screen. You'll see now that a new line has appeared in the Response Text box, but there is still only one line in the Info box, so the one Info will now play two responses.

7. Click under the Info box again and create a new response box. This time type:

Hey, you killed that guy yet?

Do it again and type:

So I hope you didn't have any trouble killing that person.

We now have three different greetings for one NPC, that will play when you first meet him, when you talk to him after meeting him but before you kill the other dude, and for when after you kill the other dude."But wait" you say, "how will the game know to play these things at the different times. They all look the same to me at the moment".

And right you are. The game will run through the greetings from top to bottom until it finds a greeting that matches the conditions of the game at that point in time. Which means if you have a greeting with no conditions then the game will always play that condition, and not move on to any of the others. So you need to set conditions to prevent that.

The conditions box is down the bottom, under the part marked (obviously) Conditions.

Right click and select new to add a new condition. Dialogue conditions are similar to the conditions you use in scripting.The most important condition to set is the GetIsID condition. This will only allow NPCs with the editorIDs that match to speak the topic. We haven't actually got an NPC to give you the quest yet, so it's time to do that now.

-----------------

Go back to the main window by pressing ok and then click the NPC tab under Actors. I find the easiest way to create a new NPC is to just edit a preexisting one. Find and actor who is the same race as the one you want, who has the relatively same inventory that you want, and then duplicate them. We'll make the NPC who hires you an Imperial, so we can use the easily accessible AdrianDecanius as our base.

1. Right click on his name and select edit. Then change his ID from AdrianDecanius to LingTutorialClient. If you are creating a unique NPC then you'll want to give them a unique name, but for fodder or pretty unimportant NPCs you can just give them generic IDs.Change his name to whatever sounding Imperial name you want, like Becian Flavius.

Imperials all have Roman sounding names, so you can't go wrong with ending their name with -ius and -ium etc.

Next click on his AI button (down the bottom). You'll see he has six AI packages there at the moment. Use right click and select delete on all of them. Now we want to add just a basic wander package, so that he wanders around a few feet and stares at the wall a lot.

Click on the tab Character at the top and select the option called Packages, just above quests. This will bring up a list of pre-existing AI packages (created by Bethesda). You can add one of the basic aaaDefaultWander packages by dragging and dropping it onto the white part where you deleted the other AI packages. Then click save to close the window (close the packages window as well).

Go into his inventory and remove the items AdrainDecaniusHouseKey, ChainmailCuirass,

and the WeapIronDagger and WeapIronMace by right clicking them and selecting delete.

He already has some pants and gold (which is all they really need) and since he doesn't have any eat packages he doesn't need any food).

Go to the faction tab and delete his factions.Once that is done the last thing is to change the face. Click on the button that says face tab, once there change his hair to another hair style by clicking on the tab next to the label Hair (down the bottom), change the colour of it by altering the three numbers in the middle of the screen, and once that is done click the button generate to create a new face until you have found one sufficiently unugly enough.Then click okay, when prompted to create a new form, click yes.

2. Now to chuck him into the game world. We'll drop him into the Lonely Suitor Lodge in Bravil, since it is suitably low-life enough to hold someone who would want another person killed for no reason other than to give the player money.Scroll down to the Lonely suitor lodge (the cell name starts with BravilL so just type that to scroll down to it once the cell view window is selected).Drag and drop the NPC from the object window into the render window. Hey presto our NPC is set up. Back to the quest window.

------------

Now that we have an NPC editorID we can assign a getisid condition to make sure that only that npc says those conditions.

1. Go back to the LingTutorialQuest and select the topics tab. Then select the top info of the greeting topic. In the part down the bottom where it says Conditions right click and select new, then click on the drop down bar that currently says GetDisposition. Type out getisid to scroll to that condition and select it.Now it should look like:

<pre class='prettyprint'>Target Function Name Function Info Comp Valueno � � � GetIsId � � � INVALID � � � == � 1.00</pre>

Target it used to decide whether the condition runs on the NPC or the player. If the target is no, it is the NPC, if the target is yes, it is the player. Function Name is the name of the condition. In this case it will check what the ID of the NPC is and compare it against the value to see if it passes the check or not. Function Info decides what ID the condition will check for. Comp is...well I don't actually know why the call it comp, but basically it decides if something is equal to, not equal to, less than, more than, etc. Value is what...value it needs to be to pass (or not pass).For true or false statements (such as "this NPC has the editorID of Martin) it checks to see if something is 0 (false) or 1 (true). Writing GetIsID Martin == 2 won't do anything, because 2 doesn't mean anything in a true or false statement. However for conditions that need to check how much you have of something (e.g GetItemCount Gold001 == 2) then it will work, in this case it will check if the NPC has 2 gold, or the player if the target is set to yes.

Since we need to check if the NPC is the one we just created, click on the button currently called INVALID and scroll down to the npc we just created (LingTutorialClient, remember you can scroll directly to it by just typing the name of the thing you want). Once you select it and click okay it will take you back to the topic screen with INVALID replaced by NPC: LingTutorialClient.

2. We now need to set up the condition to check what quest stage we are at, so that it doesn't continually play the first greeting dialogue.

Create a new condition but this time change it to GetStage. In the part currently called INVALID, click it and scroll down to LingTutorialQuest. We'll leave it as it is now. Since the quest stage will start at 0, it will pass the check of Getstage == 0, which is what we want.So now we have two conditions, one that will check if the NPC is the LingTutorialClient NPC, and the other that will check if we are at quest stage 0 for the quest LingTutorialQuest.

3. Now we can just copy and paste them to the other infos. This way saves a lot of time. Right click on one of the conditions and select copy all conditions. Then click on the next down info, the one asking "Hey, you killed that guy yet?"

Right click in the conditions box and select paste conditions. Now in the GetStage condition change the value from 0 to 10. This will check if the quest stage is 10 (i.e you have recieved the quest, but not killed the guy yet).Repeat it for the next one, but change it to check stage 20.

Now we've set up all our greetings for our new NPC. They will play 3 sepearete greetings depending upon what stage of the quest you are at.

4. We need to head back up to the first Greeting info and do one last thing.In the box called "Result Script" you need to write addtopic LingTutorialMurderTopic.This is because without adding the topic it will not display. However you CAN NOT USE

THE ADDTOPIC BOX. IT IS BUGGED. DO NOT USE IT. That is all. If you want to know more just google addtopic on the CS wiki.

5. Now we need to set up the last bit of dialogue, the stuff that will actually give us the quest.

Click on LingTutorialMurderTopic and create a new info. Something like:

There is a guy standing out just near the bridge leading to Leyawiin. Go and ill him,

and I'll give you 250 gold.

We can copy and paste the same conditions over from the greeting topic. Pick the first

info and copy and paste the conditions over.

6. Add a second info with the text:

Good job killing that random stranger. Here's your 250 gold.

Copy and paste the condition for the last greeting topic over to this topic.

7. The last part to do is set up the scripting done through dialogue.

Select the first info of the the murder topic and type in the results script box

setstage LingTutorialQuest 10.

Then in the second info type setstage LingTutorialQuest 100, then create a second line

and type player.additem Gold001 250

This has set it up so that we will be advanced to the first stage when we first talk

about the murder, and will be advanced to the second stage when we talk about the

murder the second time, as well as being given 250 gold.

--------

One last thing to do before we quit out of the quest window. We need to go back to the

quest stages window and deal with the cleanup.

1. Click on stage 100, and type in the results script StopQuestLingTutorialQuest. Also

tick the box called Complete Quest. This will cause the quest to be moved to the

completed part of the journal. We don't have a quest script running this time, but if

we did then the stopquest command would stop the quest script from running, it also

stops any related dialogue from being played. It's a good idea to get in the habit of

stopping all your quests once they are done whether they have a quest script or not.

--------

Now go back to the render window and navigate your way down to the bridge near Bravil.

Once you are there we will need to set up our final NPC and our first script.

--------

1. You can just edit the Client NPC that we created already. Change his editorID from

Client to Target, change his name to Dilian Fleg, his race to Breton, and change his

face around a bit by changing the hair style and colour and then clicking the button

called generate. Finally place a check on the little box down the bottom left next to

the word Essential. This is so that he isn't killed by random raiders and goblins

(thanks a lot MMM and OOO) Then click okay to create a new form.

2. An important thing to do now is to add him to an evil faction (such as the

bandits). This will make him evil, and so you won't get a bounty from killing him. If

he isn't evil then you do get a bounty, simple right? Just open up the faction window

which is in the character tab at the top and drag and drop the bandit faction into his

faction window.

Once you have created a new form, drag him into the game world near the Bravil bridge.

2. Then go back to edit his editorID. Click on the little button with three dots (...)

next to the drop down menu that says script.

Click on the tab called 'Script' and select the option new. You will want to keep the

script type as object type (found in the top right corner) for now, because he is an

object-he's accessed from the object window after all.

3.Next type out the script like so:

Scriptname LingTutorialTargetScript

begin ondeath

if getstage LingTutorialQuest == 10

setstage LingTutorialQuest 20

endif

end

begin onhit player

setessential LingTutorialTarget 0

end

4. Most of this stuff is likely to be covered in the scripting tutorials, but since you might be skipping straight to the quest tutorial I'll give a bried explanation of each thing, separated by a ;

The explanation:

Scriptname LingTutorialTargetScript ;For each script you will need to write out the name of the script first. Start with the word Scriptname and then type the name of the script. Um...I think that's fairly simple.

begin ondeath ;this means that the script will only run once, when the NPC is killed.

if getstage LingTutorialQuest 10 ;this checks if the quest stage of the quest is stage

10 (you've got the quest but haven't killed him yet), you'll need to start this with

an if so that the script knows to check the function

� setstage LingTutorialQuest 20 ;This sets the quest to the stage that marks that the

NPC has been killed

endif ;if you have an if function you need an endif function

end ;if you have a begin command you need an end command

begin onhit player ;this creates a block that will run whenever the npc is hit, by adding the word player afterwards it means it will only run whenever the npc is hit by the player, this is a little trick that will allow you to create an essential npc, yet make them killable by the player

setessential LingTutorialTarget 0 ;this is the command that will make the npc killable

so that the player can kill him

end

5. Now click the button that looks like a floppy disk (second from left) to save the script. If you get a box coming up saying you have an error, click yes to continue running and look back over more closely to see if you have any spelling errors. Close the editorID of the NPC, then open it back up again. Click on the drop down menu for script and scroll down to the script caled LingTutorialTargetScript and select it. It will now appear in the part previously called NONE.

--------

That's it. You're done. You've now set up everything needed to create a simple kill quest.

Now try and do it again, but this time writing your own dialogue and journal entries so that it doesn't sound so unprofessional. If you do it again you will be able to cement your knowledge of how to set up a basic quest.

Link to comment
Share on other sites

  • 1 year later...

I haven't found that information, so I'll ask, if it's not a problem: am I forced to keep Bethesda's manner in numbers of stages, i.e. don't go over 200 number? Because my quest is going to have a huge amount of stages (as I think, at least) and I don't know that going over 500 number, and maybe even 1000 is possible or not.

Link to comment
Share on other sites

Not 100% certain where the cutoff is, but 200 seems to be the magic number for BGS. :)

If you have a quest that requires more than that, let's say 1000, you would be better off dividing your story into 10 chapters with 100 stages each the way BGS set up their mainquest. That way as chapters are completed, you can stop that section of the quest and avoid having some massive quest running in the background all the time; especially if the quest will have a script running on it.

Any time you have that sort of thinking in the background of the game you can see lags and fps hits in game so break it down. The break down won't be noticeable to the players or to your story, but it's a cleaner way to quest build. :)

Good Luck!

Link to comment
Share on other sites

  • 1 month later...

I believe that it stops at 255. Seeing how 255 is the hard coded limit for a lot of things, as it is the end of hexidecimal code. Any more will just eat up memory and destroy performance in the long run. Which is probably why the MQ is broke up in multiple parts. (small bit of programming knowledge) Also it seems that 100 is completion and stage 200 is failure at the conclusion of the quest.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
 Share

×
×
  • Create New...