Difference between revisions of "Bethesda Tutorial Quest Objectives"
imported>David Brasher (Procedure as written isn't going to work because the window is too big to be displayed on a computer screen and you can't click "OK.") |
imported>Mrmikeymoo |
||
Line 84: | Line 84: | ||
=Setting Objectives= | =Setting Objectives= | ||
Remember all of those <code>SetObjectiveDisplayed()</code>'s I told you ignore? This is where they come into play. Should the following NOT work for some odd reason, those are a safety net. They will do what this is supposed to do. I suggest doing both to have all the bases covered. | Remember all of those <code>SetObjectiveDisplayed()</code>'s I told you to ignore? This is where they come into play. Should the following NOT work for some odd reason, those are a safety net. They will do what this is supposed to do. I suggest doing both to have all the bases covered. | ||
Go back to the Quest Stages tab. We're going to add some logic in here as the quest advances. | Go back to the Quest Stages tab. We're going to add some logic in here as the quest advances. |
Revision as of 00:51, 12 June 2012
Bethesda Tutorial Quest Objectives | |
---|---|
Quest Design Fundamentals Series, Chapter 6 | |
Return to Tutorial Hub | |
Previous Tutorial | Next Tutorial |
Overview
This tutorial will show the reader how to create objectives and quest targets so the player can keep track of their current goals more easily. We'll also tie up some loose ends that could confuse or frustrate the player.
The reader will learn:
- How to create aliases and objectives
- How to turn objectives on and off
- How to handle completing and shutting down a quest
- How to insert additional quest stages
Objectives
When a player goes through a quest in Skyrim, they're able to see the quest in their menu, see their current objective, and get an idea of where they need to go for the next part of the story.
Our first step in making objectives is setting up their targets, which means our first dive into the world of Aliases.
Aliases
You can think of Aliases as the quest defining roles that various people and places will play in the course of its story. Each alias points to a specific reference or place in the game world. For our example quest, these roles include Bendu, the thief, and the amulet. Each of these has to get defined in a slightly different way.
Open up your quest again and this time go over to the Quest Aliases tab. It's pretty much a big empty table at this point. Right-click in the table and select "New Reference Alias" to open up a large intimidating window. Thankfully we'll be ignoring almost all of it for now (most of this functionality will be explained later in the tutorial devoted to aliases).
Fill in "Bendu" for the Alias Name field at the top, then check the "Unique Actor" radio button and select "GSQBenduOlo" from the pulldown menu it enables. When you're done, the window should look like this:
Hit OK to close this window. Right-click and select "New Reference Alias" again to open up a fresh new alias window. Put "Thief" for the Alias Name. Because the thief is not a unique actor (since it's created from a template), we have to use the Specific Reference fill type this time. Click the "Specific Reference" radio button, and click the large "Select Forced Reference" button to its right. We now have two ways of choosing the reference:
- Select "ReachwindEyrie01" from the Cell dropdown, and then "GSQThief" from the Ref dropdown.
- If you have Reachwind Eyrie loaded and visible in your render window, you can click the "Select Reference in Render Window" to turn your mouse pointer into a target. Double-click on the big green M to select it.
Either way, click OK in that window and then the alias window to finish making our second alias.
Now it comes time to make our third alias (for the amulet), but this one is tricky. Only actors can be unique, so the Unique Actor type won't work. And we can't point to it as a specific reference because it only exists in the inventory of our thief. So what we'll do is have the alias itself create its own reference.
Create a new reference alias one more time. Give it the name "Amulet" and click the radio button for "Create Reference to Object" under Fill Type. Moving from left to right, then we want to:
- Select "GSQAmulet" from the first pulldown menu.
- Ignore the Level/Difficulty menu (since we aren't making an actor, there's no notion of the object's difficulty).
- Click the radio button for "Create In"
- Select Thief from the final pulldown.
As you might imagine, this will create a new reference to the amulet in the thief's inventory when the quest begins (at the start of the game). Right now this would give the thief two copies of the amulet, so open up GSQThief and remove the amulet from its inventory.
Creating Objectives
Now move over to the Quest Objectives tab in your quest window. This is where we'll actually set up the objectives as the player sees them.
Each objective has an index (a number we'll use to refer to it), text that will be displayed to the player, and a list of targets that will get arrows placed on them in the player's map and in-game interface.
To make a new objective, right-click in the table at the top of the window and select "New" from the menu. In the "Objective Data" area below there, change the Index value to "10" and make the Display Text say "Kill the thief."
Finally, in the table below the Index and Display Text fields, right-click and select "New" to create a new quest target. This creates a big scary "NO TARGET" until you select something from the "Target Alias" pulldown below. In this list, you'll see all the aliases we defined earlier. Choose "Thief," and we can move on. (The "NO TARGET" will remain until we click away on something else.)
Now make another objective:
- Index: 20
- Display Text: Retrieve Bendu Olo's amulet.
- Target Alias: Amulet
And one more:
- Index: 30
- Display Text: Return Bendu Olo's amulet.
- Target Alias: Bendu
Your window should look something like this when we're done.
Now we have our objectives made, we just have to tell the game when to show them.
Setting Objectives
Remember all of those SetObjectiveDisplayed()
's I told you to ignore? This is where they come into play. Should the following NOT work for some odd reason, those are a safety net. They will do what this is supposed to do. I suggest doing both to have all the bases covered.
Go back to the Quest Stages tab. We're going to add some logic in here as the quest advances.
Click on stage 10 in the list on the left. In order to add script logic or a log entry to a quest stage, it needs to have at least one "quest stage item", so right-click in the table that says "Log Entry" at the top and select "New."
Log entries are the bits of text that will appear in the player's journal. Only the most recent log entry will be visible, so you can use this to update the story of the quest as it changes. Down in the "Log Entry" area, put the following:
I've met Bendu Olo, who had a precious amulet stolen. He offered twice its value as a reward, since he has a sentimental attachment to it.
Click over to the text field on the right (in the Papyrus fragment tab). Doing so will pop up the spell-check window, complaining that "Bendu" and "Olo" are not proper words. Ignore both "mistakes" and we'll add the script logic.
In the Papyrus area, put: SetObjectiveDisplayed(10)
. Press the "Compile" button to make sure you did it right. As you might guess, this set the quest's current objective to 10, and give the player the appropriate quest targets. Because it's the first objective shown for this quest, it will also cause the "STARTED" banner to be shown to the player.
Now select stage 20 from the list on the left, and create a new stage item for it. Remember, stage 20 is after we've killed the thief but before we've gotten the amulet. We have two things to do here -- tell the player that the previous objective (to kill the thief) has been accomplished, and set their next goal. We do that with two lines of script:
SetObjectiveCompleted(10)
SetObjectiveDisplayed(20)
We can leave the journal entry here blank, because the overall story of the quest hasn't changed.
Do the same thing for stage 30, except this time your logic should be completing objective 20 and displaying objective 30.
Finally, in stage 40, we just need to complete objective 30. You should also check the "Complete Quest" checkbox below the Log Entry text field, so that the "COMPLETED" banner will be shown when stage 40 is set. (This will also move the quest to the inactive portion of the player's journal, keeping it somewhat tidy.)
The final journal entry should sum up what happened in the quest, since it's now in the past. For example:
I met Bendu Olo and was rewarded handsomely for retrieving his stolen amulet.
Trying it out
Now when you progress through the quest, your progress will be visible in your journal and you will have quest targets to the various plot points.
Previous Tutorial | Return to Tutorial Hub | Next Tutorial |
Language: | English • français • русский |
---|