1. Updated Resource Submission Rules: All model & skin resource submissions must now include an in-game screenshot. This is to help speed up the moderation process and to show how the model and/or texture looks like from the in-game camera.
    Dismiss Notice
  2. DID YOU KNOW - That you can unlock new rank icons by posting on the forums or winning contests? Click here to customize your rank or read our User Rank Policy to see a list of ranks that you can unlock. Have you won a contest and still haven't received your rank award? Then please contact the administration.
    Dismiss Notice
  3. Rubbed the right way, the genie is out of its lamp! The 12th Concept Art Contest Results have been announced.
    Dismiss Notice
  4. Race against the odds and Reforge, Don't Refund. The 14th Techtree Contest has begun!
    Dismiss Notice
  5. Check out the Staff job openings thread.
    Dismiss Notice
Dismiss Notice
60,000 passwords have been reset on July 8, 2019. If you cannot login, read this.

Creating Easy Multi-User Quests

Discussion in 'Trigger (GUI) Editor Tutorials' started by The_Big_S, Aug 15, 2007.

  1. The_Big_S

    The_Big_S

    Joined:
    Aug 15, 2007
    Messages:
    42
    Resources:
    1
    Tutorials:
    1
    Resources:
    1
    Tutorial Objectives: Upon completing this tutorial, users should be able to create dynamic quests for up to 12 players using a small amount of variables and triggers. These quests will be able to store just about any objective from killing X amount of creatures to delivering an item to someone.

    (This tutorial was made originally for Clan ORPG, but I thought I would repost it here and see if anyone could benefit from it. Also, it is important to note that the trigger tags will not show correctly because they were made into trigger tags when they were originally quoted, and I did not create the triggers in World Editor. Still, the triggers are not complicated and should be straight-forward to read.)

    Tutorial Index:

    To jump to a specific part of the tutorial, simply highlight the section name, copy it, and enter it into find (CTRL+F).

    I. Introduction
    II. Variables Needed
    III. Our First Quest
    IV. Tips for other quest types
    V. Examples from Athelor ORPG
    VI. Credits


    I. Introduction

    Have you ever wanted to create quests in a multiplayer game, whether it be an ORPG or a simple map? Most people use an approach which uses a huge amount of triggers and variables, which can take up un-needed space in your map and can be glitchy. Today you will learn how to create quests using 1-2 triggers, 3 maximum, and only 1-2 variables per quest.

    To follow this tutorial without any problems, you will firstly need to be using the Warcraft III The Frozen Throne World Editor program. You also need to have a moderate knowledge of triggering and variable types/arrays.

    II. Variables Needed

    Firstly, all of our quests made using this system will be using a string array to store the status of the quest. Go ahead and set up the following variable:

    Name: OurQuest
    Type: String
    Array: Yes; set the number of the array to the number of maximum user controlled players your map has.
    Default Setting: "notstarted"

    Now we have our basic quest variable. You'll see soon why using strings is so nice and simple.

    III. Our First Quest

    Today, I will walk you through how to create a simple delivery quest, as well as a tad more advanced kill X units quest. Let us start out with the delivery quest.

    The quest objective in this delivery quest will be to deliver a letter from Jim to Bob. The letter is an item which will be called simply "Letter."

    First, we will start out with acquiring/completing the quest. Create a unit and call him Jim, and then place him on the map wherever you want. Then create a new trigger. Let's call this trigger "QuestGiverTalk".

    Now add the following events/conditions/actions to the trigger:

    • [b]Events[/b]
    • - A unit comes within 100 feet of Jim 0001 <gen>
    • [b]Conditions[/b]
    • - ((Entering Unit) is a hero) equal to True
    • [b]Actions[/b]
    • If/Then/Else
    • If (All Conditions are true)
    • - OurQuest [(Player number of (Owner of (Triggering Unit)))] equal to "notstarted"
    • Then (Do Actions)
    • - Display to (Player Group (Owner of (Triggering Unit))) for 10 seconds the text "Quest Received: Deliver this letter to Bob!"
    • - Add Letter to (Triggering Unit)
    • - Set OurQuest [(Player number of (Owner of (Triggering Unit)))] equal to "started"
    • - Skip Remaining Actions
    • Else (Do Actions)
    • - Do Nothing
    • If/Then/Else
    • If (All conditions are true)
    • - OurQuest [(Player number of (Owner of (Triggering Unit)))] equal to "started"
    • Then (Do Actions)
    • - Display to (Player Group (Owner of (Triggering Unit)))] for 10 seconds the text "You already have this quest!"
    • - Skip Remaining Actions
    • Else (Do Actions)
    • - Do Nothing


    Alright, now before you start panicking, lets look at this closely.

    What this trigger does is, when a unit comes near the quest giver (Jim), and is a hero, the trigger executes.

    First, it checks to see if you have the quest started or not. This is why we set the default for the string array to "notstarted", because when you start the game you have not completed any quests, nor started any.

    If you have not started the quest, it gives you a little message saying you received the quest, adds the letter item to your inventory, and sets the status for your quest to "started". Why did we use "Player number of owner of triggering unit"? Because each number of the array corresponds to a player.

    For example, OurQuest [1] is the quest status for player 1. OurQuest [2] for player 2, etc. So it updates the quest status only for the player who owned the unit that came in range of the quest giver.

    Now we are going to make our second trigger, this time for finishing the quest by talking to Bob with the letter. Create a new trigger called "Finishquest".

    • [b]Events[/b]
    • - A unit comes within 100 of Bob 0001 <gen>
    • [b]Conditions[/b]
    • - ((Triggering Unit) is a hero) equal to True
    • [b]Actions[/b]
    • If/Then/Else
    • If (All conditions are true)
    • - OurQuest [(Player number of (Owner of (Triggering Unit)))] equal to "started"
    • - ((Triggering Unit) has item of type Letter) equal to True
    • Then (Do Actions)
    • - Display to (Player group (Owner of (Triggering Unit)))] for 10 seconds the text "Quest Complete! Good job!"
    • - Remove item of type Letter from (Triggering Unit)
    • - Set OurQuest [(Player number of (Owner of (Triggering Unit)))] equal to "complete"
    • Else (Do Actions)
    • - Do Nothing


    This trigger worked much the same way as the last. It just checked if the owner of the unit had indeed started the quest, and if they had the letter on them. If they did, it completed the quest for them. In addition, they now will not be able to retake the quest. (Although this can be changed if you wanted them to, just set OurQuest to "notstarted" instead of "complete")

    IV. Tips For Other Quest Types

    As I mentioned earlier, there really is no limit to what you can do with quests this way. Some quests, such as a kill X units quest will need two variables. One variable such as OurQuest (Array just like in the last example), as well as an integer array (With the array being the max amount of players). Then, just add a condition to the quest completion trigger:

    - KillCount [(Player number of (Owner of (Triggering Unit)))] greater than or equal to 10

    You would also need to have it update when you killed the correct unit type. Lets say we needed to kill 10 Trolls:

    • [b]Events[/b]
    • - A unit dies
    • [b]Conditions[/b]
    • - Unit type of (Dying Unit) equal to Troll
    • - ((Killing Unit) is a hero) equal to True
    • [b]Actions[/b]
    • - Set KillCount [(Player number of (Owner of (Killing Unit)))] equal to KillCount [(Player number of (Owner of (Killing Unit)))] + 1
    • - Display to (Player group (Owner of (Killing Unit)))] for 10 seconds the text "Quest Update: You've killed a troll!"


    This just adds one to the killcount every time you kill a troll. If you wanted to make it a set number like 10, just add the condition:

    - KillCount [(Player number of (Owner of (Killing Unit)))] less than 10

    So there you have it, an easy way to make killing quests and delivery quests!

    V. Examples From Athelor ORPG

    This section is coming soon!

    VI. Credits

    Tutorial created by The Big S

    Please give a bit of credit if you are using this Quest System in your map, as it took time to write this tutorial. I hope it helped!
     
    Last edited: Aug 16, 2007
  2. PurplePoot

    PurplePoot

    Joined:
    Dec 14, 2005
    Messages:
    11,161
    Resources:
    3
    Maps:
    1
    Spells:
    1
    Tutorials:
    1
    Resources:
    3
    If you'e going to use
    • tags, you should probably make the GUI actually [b]look[/b] like GUI
     
  3. The_Big_S

    The_Big_S

    Joined:
    Aug 15, 2007
    Messages:
    42
    Resources:
    1
    Tutorials:
    1
    Resources:
    1
     
  4. Wolverabid

    Wolverabid

    Joined:
    Oct 23, 2006
    Messages:
    8,302
    Resources:
    5
    Tutorials:
    5
    Resources:
    5
    It looks pretty good so far The_Big_S!

    Since you are still developing the document:
    1. Please detach your signature file from the tutorial.

    2. Would it be possible to create a simple map; (obvoiusly not the bulk of Athelor ORPG) just a basic demo map that includes all the triggers so that users can download it from this thread and then cnp the elements into their own projects.
     
  5. Flame_Phoenix

    Flame_Phoenix

    Joined:
    May 4, 2007
    Messages:
    2,283
    Resources:
    11
    Tools:
    1
    Maps:
    1
    Spells:
    6
    Tutorials:
    3
    Resources:
    11
    Nice tutorial.... However it only works for very simple quests. My map has a very complicated quest and i cannot not make it MUI. This means that i have to create the same quest for all 8 players of my map. Another thing is that i really think you should fix those GUI tags, i know you coppied them but it is easy to fix. Just re-create the quest on a map make the triggers than use copy as text and post it here. I can do that for you if you need me to, it is very simple. Another thing, the method you mention creates a single new quest for all players ???? Or the main quest gets completed when 1 players finishes it ??? I didn't understand quite well.
    Now i really need help for my map... perhaps you could give me some ... in exchange i can enter your clan or help you with your map - i am an expert at GUI and i am learning JASS and MUI. Also i am an expert at icons (can do anything thing with them) and i have some basic knowledge about modeling (like creating ghosts per example).

    It's up to... your call now...
     
  6. The_Big_S

    The_Big_S

    Joined:
    Aug 15, 2007
    Messages:
    42
    Resources:
    1
    Tutorials:
    1
    Resources:
    1
    @ Wolverabid - Hey, thanks for the comments! I will probably have a demo map coming out soon, just as soon as I am able to release my ORPG's first public version tomorrow. Then I will also edit the trigger tags to accurately display things. Also, signature is now removed on the main post. Sorry about that!

    @ Flame_Phoenix - This quest system can actually be used for about any type of quests. At most you will need two triggers to pull pretty much anything off. I have kill X unit quests, delivery quests, quests where you have to find things, and others, and this system I developed works great for all of them. Also, yes, this system creates the quest for each player and each player has to complete their own quests. However, for killing quests, I create a trigger that allows every player with-in range that has the quest get credit for the quest kill. If you need any help editing this or anything, just let me know and I'll help you after Friday. Also, keep an eye out for the demo map of this that I mentioned. It will include a few different types of quests, so.. :)

    Thanks all, hope it helps! :spell_breaker:
     
  7. Flame_Phoenix

    Flame_Phoenix

    Joined:
    May 4, 2007
    Messages:
    2,283
    Resources:
    11
    Tools:
    1
    Maps:
    1
    Spells:
    6
    Tutorials:
    3
    Resources:
    11
    Well, so be it... i will trust you my very complicated quest... i bet you never seen such a thing in your entire life ... If you do help me, i will ofc credit you in my map ... If you need ANYTHING in your map just tell me and i will be glad to help you.

    Anyway, to scare you away, here is the print screen of my quest, and that is only 1 of the 3 options i have for players ...Don't run away :grin: :

    Image1.jpg

    As you can see the quest's name is Hunts and dryads. If you decide to help me, i will give you further detail ... but i think it is pretty obvious the objective those triggers have.
     
  8. The_Big_S

    The_Big_S

    Joined:
    Aug 15, 2007
    Messages:
    42
    Resources:
    1
    Tutorials:
    1
    Resources:
    1
    Wow, that sure is alot of triggers :p

    Is the Hunts and Dryads quest broken up into parts? It looks like it, so it's almost like the World of Warcraft equivalent of a chain quest? You won't scare me away lol, at least, when I have the time I would be glad to help. If you would trust me with the map, or paste all triggers and variables into another map, I can attempt to reverse engineer that into about a third of what it is now. :)
     
  9. Flame_Phoenix

    Flame_Phoenix

    Joined:
    May 4, 2007
    Messages:
    2,283
    Resources:
    11
    Tools:
    1
    Maps:
    1
    Spells:
    6
    Tutorials:
    3
    Resources:
    11
    mmmmm The_Big_S, i confess myself surprised with your courage. The quest you are seeing is not a simple quest. It is a very advanced quest with multiple tasks. This advanced quest uses simple trigger tags to make my work easy to understand. I took lot's of time to create this.
    mmm i confess i am afraid of lending you my map.... It is a project that took me 4-5 years of very hard work .. all by myself .. all alone (you don't imagine how difficult it is to find help nowadays).
    I will put all these triggers into a simple new map.
    Once you start playing the custom map i am going to post here choose the night elfs race. You will understand the quest once you start playing.
    Btw, it is not a World of Warcraft chain quest (at least i don't compare it to one). What you are seeing can only be played by player 1. The challenge here is to make it MUI. It would eventually save more than 200 kb from my map.

    Another suggestion for your tutorial - i think that some GoTo tags would be very nice, you already have a bookmark, you should take advantage of it.

    Perhaps you may be interested in seeing my icon tutorial at the Submition section... i still have lots of work to do before i finish it, but it would nice to have an opinion (yes it is taking me a lot of time as well, i think you understand me).

     
  10. ragingspeedhorn

    ragingspeedhorn

    Joined:
    Apr 30, 2005
    Messages:
    6,521
    Resources:
    14
    Icons:
    5
    Maps:
    7
    Tutorials:
    2
    Resources:
    14
    Good and simple tutorial learning people some good basic knowledge.
     
  11. Flame_Phoenix

    Flame_Phoenix

    Joined:
    May 4, 2007
    Messages:
    2,283
    Resources:
    11
    Tools:
    1
    Maps:
    1
    Spells:
    6
    Tutorials:
    3
    Resources:
    11
    To send you my map i will need you e-mail. please give it to me as fast as you can.
    Well .. i don't know if i can trust you but i just hope i can ... To play it correctly, you must run warcraft 3 and choose the night elfs race ... keep in mind that my map as not made for tests, but for multiplay.
     
  12. The_Big_S

    The_Big_S

    Joined:
    Aug 15, 2007
    Messages:
    42
    Resources:
    1
    Tutorials:
    1
    Resources:
    1
    Alright, I understand not wanting to give your map away. I have been working on mine all alone as well, and I would hate it if someone stole it and took credit for it.

    Anyway, e-mail is jasen_theck@hotmail.com, I'll see if I can take a look at your map by the end of the week.
     
  13. Flame_Phoenix

    Flame_Phoenix

    Joined:
    May 4, 2007
    Messages:
    2,283
    Resources:
    11
    Tools:
    1
    Maps:
    1
    Spells:
    6
    Tutorials:
    3
    Resources:
    11
    Big_S i am a man of my word. Right now i am sending the triggers as i promised. If you need any kind of help for extra versions of your map, just mail me back.
     
  14. The_Big_S

    The_Big_S

    Joined:
    Aug 15, 2007
    Messages:
    42
    Resources:
    1
    Tutorials:
    1
    Resources:
    1
    Ugh, would you mind re-sending the map? I didn't seem to get it, probably because my e-mail had de-activated from me being inactive. It is now online again :p
     
  15. Flame_Phoenix

    Flame_Phoenix

    Joined:
    May 4, 2007
    Messages:
    2,283
    Resources:
    11
    Tools:
    1
    Maps:
    1
    Spells:
    6
    Tutorials:
    3
    Resources:
    11
    Ok than, i re-sent the file again. remember to follow the instructions i give on it plz. Still i don't understand how is it possible to release a map without using an e-mail to ask for help and other stuff =S
     
  16. The_Big_S

    The_Big_S

    Joined:
    Aug 15, 2007
    Messages:
    42
    Resources:
    1
    Tutorials:
    1
    Resources:
    1
    I have actually just gotten into JASS, and seem to have a natural aptitude for it. Using JASS + My system, you can create pretty much any quest in one trigger now.

    I optimized my old quest system into JASS and created the equivalent of two triggers into one. Again, after release, I will add a section on this with some demo maps.
     
  17. Flame_Phoenix

    Flame_Phoenix

    Joined:
    May 4, 2007
    Messages:
    2,283
    Resources:
    11
    Tools:
    1
    Maps:
    1
    Spells:
    6
    Tutorials:
    3
    Resources:
    11
    Well in my case i am learning JASS from the Hive tutorials and i seem to be a real noob with it ... i just can't catch the meaning of it and my triggers always seem to have errors ... anyway, did you already seen my map ??? do you really think you can help me ?
    Anyway you may not need help with jass .... but if you need some icons or models, just talk to me =)
     
  18. The_Big_S

    The_Big_S

    Joined:
    Aug 15, 2007
    Messages:
    42
    Resources:
    1
    Tutorials:
    1
    Resources:
    1
    All I have done so far is downloaded your map. Like I mentioned earlier, I will be unable to devote any time or resources on it until I can get a stable version of my own map out, which is scheduled tomorrow. Then, I will be happy to take a look at your map. ;)
     
  19. Flame_Phoenix

    Flame_Phoenix

    Joined:
    May 4, 2007
    Messages:
    2,283
    Resources:
    11
    Tools:
    1
    Maps:
    1
    Spells:
    6
    Tutorials:
    3
    Resources:
    11
    mmm i c, well, i understand nearly anything about triggers, as long as your map is not 100% full JASS i will be very happy to help you fix anything you may have.
    If you have problems with items or auras, including any kind of spells, i am sure i will be able to help you out. I am trying to be fair, you help me, i help you, we all win. Just send the map to my e-mail if you want.

    Anyway i would like to help you in the releasing of your map ... i know that is difficult to trust in a stranger (at least it is for me) but i am sure i can do anything to help you in your map ... you can give a simple task if you want ... it is up to you
     
  20. The_Big_S

    The_Big_S

    Joined:
    Aug 15, 2007
    Messages:
    42
    Resources:
    1
    Tutorials:
    1
    Resources:
    1
    It's alright Phoenix, I don't need repayment if I am able to help you. :)

    I am actually doing very well on my map, not even any bugs or anything. I am trying to keep this a solo project, at least in the development, because I have noticed that most group projects tend to break up or just be rather complicated because of having to run the map around, and people losing interest, so I am keeping the making of Unnamed RPG to myself.

    I should be able to take a look at your map later today if all goes well. :)