Warcraft III World Editor Tutorial – 02: Quests

This tutorial will show you how to create quests, update them, and show messages to say the quest is updated. Also, Custom Hero units will be covered here.

The mission that has to be accomplished in this map will be as follows:

Main Quest:

  • Kill Daddy Bear
  • Get to his house

Daddy Bear annoyed Goldilocks when he would not give her free porridge, kill him and go to his house.

Optional Quest:

  • Find the Cheese

Little Red Riding Hood cannot find her cheese! Help her find it.

First, create a new map. Easily enough done, then go to the ‘Unit Editor’. We will start off by creating our Heroes.

This is what you should be looking at:

02 - 01

Click on the ‘New Custom Unit’ button (CTRL + N) in the top left of the screen. First, we will make Little Red Riding Hood, obviously a sorceress. Change the name to Little Red Riding Hood, and select the sorceress in the main panel. Then press OK. We now have Goldilocks! We need to make ‘Daddy Bear’ though.

Repeat the above process, but change the name to ‘Daddy Bear’, and select the ‘Furbolg – Level 4’ unit. To do this, change the ‘Base Unit’ to ‘Neutral’, and select Ashenvale. You should see a screen like this:

02 - 02

After selecting the correct unit, press OK. Lastly, we need to make ‘Goldilocks’. We will use a hero to do this:

Start by creating a new unit as before, type in the name: ‘Little Red Riding Hood’, and select the Night Elf unit: ‘Priestess Of The Moon’. Then click OK. For this to be effective, we need to change the possible names of the Hero. To do this, select her at the bottom of the list, under Custom Units – Night Elf – Heroes – Goldilocks.

There will now be a huge array of options for ‘Goldilocks’. We want to change the ‘Proper Names’ to just one: ‘Goldilocks’, obviously. Double click on the ‘Proper Names’, and delete every string. When there are no strings, add a new one: ‘Goldilocks’. Done!

Now we have created our units, we will create the landscape. All we need to actually test the map are a few things (it doesn’t have to look good!), so place our three custom units (quite far apart so they don’t start killing each other, but not too far).

The player controls should be as follow:

  • Goldilocks – Player 1 (Red)
  • Daddy Bear – Player 2 (Blue)
  • Little Red Riding Hood – Player 3 (Teal)

Also, place the item ‘Cheese’ nearby. Then place a neutral building, a farmhouse or inn or something. You should finally have a map that looks a little like this:

02 - 03

We also need a couple of regions, so create a region surrounding ‘Little Red Riding Hood’, and also in front of ‘Daddy Bear’’s House. Like so:

02 - 04

Call this region (the one around ‘Little Red Riding Hood’) ‘Cheese’

Call the next region (in front of the house) ‘House’:

02 - 05

All you have to do now is create starting positions for the three players. It doesn’t matter where you put these, they have no relevance in this map (other than that is where the game screen is at the beginning for the player).

That’s it for the set up, now we can get down to some serious work with the Trigger Editor.

First, delete all of the triggers that the map started off with – yes that’s right, delete them all. We will start off with a clean slate!

We will now create all of the variables, so we don’t have to keep creating them throughout.

Variable Name – Variable Type – Initial Value
CheeseDone – Boolean – False
CheeseGot – Quest Requirement – – None –
CheeseQuest – Quest – – None –
CheeseStart – Boolean – False

The above variables are all for the optional tutorial and are not needed if you are just doing the main quest. The following variables are for the Main Quest:

Variable Name – Variable Type – Initial Value
DaddyHouse – Quest Requirement – – None –
DaddyKill – Quest Requirement – – None –
DaddyQuest – Quest – – None –

Start off with the first trigger. Create a new one with the following layout:

Name – ‘Start’

Events:
Map Initialisation
– Activates the trigger when the map starts

Conditions:

Actions:
Visibility – Disable black mask
– Disables the shroud so we can see the entire map.
Visibility – Disable fog of war
– Disables fog of war, again so we can see what is going on.
Wait 1.00 seconds
– I find it best to wait before the real triggers start. It is safer, and I find if you start off in the deep end with this event, sometimes nothing works at all. I try to avoid using this event.
Trigger – Run Quest 1 [gen] (ignoring conditions)
– Runs the next trigger. You have to wait till you have created the next trigger first.

The next trigger:

Name – ‘Quest 1’

Events:

Conditions:

Actions:
Quest – Create a Required, undiscovered quest titled Get Your Porridge! With the description Daddy Bear annoyed …, using icon path ReplaceableTextures\CommandButtons\BTNFurbolgTracker.blp
– Creates our quest. It is a required quest, with the title ‘Get Your Porridge!’, and the description ‘Daddy Bear annoyed Goldilocks when he would not give her free porridge, kill him and go to his house.’. It has the furbolg icon.

Set DaddyQuest = (Last created quest)
– Sets the variable ‘DaddyQuest’ to be the last created quest.

Quest – Create a quest requirement for DaddyQuest with the description Kill Daddy Bear
– Creates a requirement for the main quest

Set DaddyKill = (Last created quest requirement)
– Sets the variable ‘DaddyKill’ to be the last created quest requirement.

Quest – Create a quest requirement for DaddyQuest with the description Get to Daddy Bear’s…
– Creates a requirement ‘Get to Daddy Bear’s House’ for the main quest

Set DaddyHouse = (Last created quest requirement)
– Sets the variable ‘DaddyHouse’ to be the last created quest requirement.

Quest – Enable DaddyQuest
– Enables the main quest

Wait 1.00 seconds
– Splits up the triggers

Quest – Mark DaddyQuest as Discovered
– The Player discovers the main quest

Quest – Flash the quest dialog button
– Flashes the ‘Quest’ button at the top of the screen

Quest – Display to (All players) the Quest Discovered message: |cffffcc00MAIN QUES…
– Displays a quest update message that reads:

MAIN QUEST (–YELLOW–)
Get Your Porridge
– Kill Daddy Bear
– Get to Daddy Bear’s House

To get the colour of text to change, there is a simple method. Start off with a pipe (|). This just contains the information.

Then type ‘cff’, put the colour in – using hex code.

Then go straight into the text, type what you want to be in colour.

Then finish off with: ‘|r’

Like so:

|cffffcc00MAIN QUEST|r

Split up:
|cff – ffcc00 – MAIN QUEST – |r

So the actual value is as follows:

|cffffcc00MAIN QUEST|r
Get Your Porridge
– Kill Daddy Bear
– Get to Daddy Bear’s House

The next trigger:

Name – ‘Kill Daddy’

Events:
Unit – Daddy Bear 0002 [gen] Dies
– when ‘Daddy Bear’ (selected) dies

Conditions:

Actions:
Quest – Mark DaddyKill as Completed
– Marks the quest requirement ‘DaddyKill’ complete.

Quest – Display to (All Players) the Quest Update message |cffffcc00MAIN QUES…
– Displays the following message:

MAIN QUEST (–YELLOW–)
Get Your Porridge
– Kill Daddy Bear (COMPLETED) (–GREY–)
– Get to Daddy Bear’s House

Done by using the following value:

|cffffcc00MAIN QUEST|r
Get Your Porridge
|cff888888 – Kill Daddy Bear (COMPLETED)|r
– Get to Daddy Bear’s House

|cffffcc00 **** |r – gives YELLOW text
|cff888888 **** |r – gives GREY text

The next trigger:

Name – ‘Got There’

Events:
Unit – A unit enters House [gen]
– When a unit enters the region ‘House’

Conditions:
((Triggering unit) equal to Goldilocks 0000 [gen] ) and ((Daddy Bear 0002 [gen] is dead) equal to True)
– As long as the unit is Goldilocks, and Daddy Bear is dead

Actions:
Quest – Mark DaddyHouse as Completed
– Marks the quest requirement ‘DaddyHouse’ complete.

Quest – Display to (All Players) the Quest Update message |cffffcc00MAIN QUES…
– Displays the following message:

MAIN QUEST (–YELLOW–)
Get Your Porridge
– Kill Daddy Bear (COMPLETED) (–GREY–)
– Get to Daddy Bear’s House (COMPLETED) (–GREY–)

Done by using the following value:

|cffffcc00MAIN QUEST|r
Get Your Porridge
|cff888888 – Kill Daddy Bear (COMPLETED)|r
|cff888888 – Get to Daddy Bear’s House (COMPLETED)|r

(–BACK TO THE TRIGGERS–)

Wait 2.00 seconds
– Gives the player a chance to see the message

Game – Victory Player 1 (Red) (Show dialogs, Show scores)

(–THE FOLLOWING TRIGGERS ARE FOR THE OPTIONAL QUEST ONLY–)

The first trigger of the Optional Quest:

Name – ‘Quest 2 – Optional’

Events:
Unit – A unit enters Cheese [gen]
– When a unit enters the region ‘Cheese’

Conditions:
((Triggering unit) equal to Goldilocks 0000 [gen] ) and ((CheeseDone Equal to False) and (CheeseStart Equal to False))
– As long as the unit is Goldilocks, and The quest has not been done, and she has not been here before.

Actions:
Quest – Create a Optional, undiscovered quest titled Give Little Red Rid… With the description Little Red Riding H…, using icon path ReplaceableTextures\CommandButtons\BTNCheese.blp
– Creates our second quest. It is an optional quest, with the title ‘Give Little Red Riding Hood Cheese’, and the description ‘Little Red Riding hood has lost her cheese, can you find it for her?’. It has the cheese icon.

Set CheeseQuest = (Last created quest)
– Sets the variable ‘CheeseQuest’ to be the last created quest.

Quest – Create a quest requirement for CheeseQuest with the description Get Little Red Riding Hood some cheese
– Creates a requirement for the optional quest

Set CheeseGot = (Last created quest requirement)
– Sets the variable ‘CheeseGot’ to be the last created quest requirement.

Quest – Enable CheeseQuest
– Enables the new optional quest

Wait 1.00 seconds
– Splits up the trigger

Quest – Mark CheeseQuest as Discovered
– The Player discovers the ‘Cheese’ quest

Quest – Flash the quest dialog button
– Flashes the ‘Quest’ button at the top of the screen

Quest – Display to (All players) the Quest Discovered message: |cffffcc00OPTIONAL …
– Displays a quest update message that reads:

OPTIONAL QUEST (–YELLOW–)
Find Little Red Riding Hood some Cheese
– Get the Cheese to Little Red Riding Hood

Seen by doing this:

|cffffcc00OPTIONAL QUEST|r
Find Little Red Riding Hood some Cheese
– Get the Cheese to Little Red Riding Hood

(–BACK TO THE TRIGGER–)

Wait 1.00 seconds
– splits up the actions

Set CheeseStart = True
– Changes the Variable ‘CheeseStart’ to true

If ((Goldilocks 0000 [gen] has Cheese 0002 [gen]) Equal to True) Then do (Trigger – Run Got Cheese [gen] (ignoring conditions)) Else do (Trigger – Run Not Got Cheese [gen] (ignoring conditions))
– Says that if Goldilocks has the cheese, then run the trigger ‘Got Cheese’. If she has not got the cheese, run the trigger ‘Not Got Cheese’

The next trigger:

Name – ‘Not Got Cheese’

Events:
Unit – A unit enters Cheese [gen]
– When a unit enters the region ‘Cheese’

Conditions:
((Triggering unit) Equal to Goldilocks 0000 [gen] ) and ((CheeseDone Equal to False) and (((Triggering unit) has Cheese 003 [gen] ) Equal to False))

Actions:
Wait 2.00 seconds

Quest – Display to (All Players) the Hint message |cff888888Find Li…
– Displays the following message:

Find Little Red Riding Hood some Cheese (–GREY–)

Done by using the following value:

|cff888888Find Little Red Riding Hood some Cheese|r

|cff888888 **** |r – gives GREY text

The next (and last) trigger:

Name – ‘Got Cheese’

Events:
Unit – A unit enters Cheese [gen]
– When a unit enters the region ‘Cheese’

Conditions:
((Triggering unit) Equal to Goldilocks 0000 [gen] ) and ((CheeseDone Equal to False) and (((Triggering unit) has Cheese 003 [gen] ) Equal to True))

Set CheeseDone = True
– Sets the variable ‘CheeseDone’ to True

Actions:
Wait 2.00 seconds

Quest – Mark CheeseGot as Completed
– Marks the Quest Requirement ‘CheeseGot’ as complete

Quest – Mark CheeseQuest as Completed
– Marks the Quest ‘CheeseQuest’ as complete

Quest – Display to (All players) the Quest Completed message: |cffffcc00OPTIONAL …
– Displays a quest update message that reads:

OPTIONAL QUEST (–YELLOW–)
Find Little Red Riding Hood some Cheese
– Get the Cheese to Little Red Riding Hood (COMPLETED) (–GREY–)

Seen by doing this:

|cffffcc00OPTIONAL QUEST|r
Find Little Red Riding Hood some Cheese
|cff888888 – Get the Cheese to Little Red Riding Hood (COMPLETED)|r

(–BACK TO THE TRIGGER–)

Hero – Add 500 experience to Goldilocks 0000 [gen], Show level-up graphics
– Rewards our hero with 500 experience points for safely finding a piece of cheese.

And that’s it!

Now that really WAS a long tutorial, I have tested the triggers, and they work perfectly. Please tell me if when you go to run your map, it doesn’t work. It will probably be because of a typing error.

Leave a Reply

Your email address will not be published. Required fields are marked *