Quest Triggers

The Arcot

New Member
Reaction score
7
Hi again everyone. Im making an ORPG and its starting to take shape. I'm now adding quests, but I hit a minor snag with some of the triggers, and I dont know what happened. Ill post them here, and I would be grateful if you help me find out what the problem is.

Basically, the idea of the quest is you go out and kill 15 satyrs, then come back and your whole team gets gold and xp, but the final trigger doesnt work for some reason.

Code:
Blackwood Bothers Start
    Events
        Unit - A unit comes within 400.00 of Captain Leif 0016 <gen>
    Conditions
        ((Entering unit) is A Hero) Equal to True
    Actions
        Special Effect - Destroy QuestEffect[1]
        Quest - Display to (All players) the Quest Discovered message: Captain Leif: Hail ...
        Quest - Create a Required quest titled Blackwood Bothers with the description Hail Adventurers. W..., using icon path ReplaceableTextures\CommandButtons\BTNAmbush.blp
        Set Quests[1] = (Last created quest)
        Trigger - Turn off (This trigger)

Code:
Blackwood Bothers Progress
    Events
        Unit - A unit Dies
    Conditions
        (Unit-type of (Dying unit)) Equal to Blackwood Satyr
    Actions
        Set BlackwoodSatyrKills = (BlackwoodSatyrKills + 1)
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                BlackwoodSatyrKills Equal to 15
            Then - Actions
                Quest - Mark Quests[1] as Completed
                Quest - Display to (All players) the Quest Update message: The satyrs are dead...
            Else - Actions
                Do nothing
Code:
Blackwood Bothers End
    Events
        Unit - A unit comes within 400.00 of Captain Leif 0016 <gen>
    Conditions
        ((Entering unit) is A Hero) Equal to True
        BlackwoodSatyrKills Equal to 15
    Actions
        Quest - Display to (All players) the Quest Completed message: THNX  
        Unit Group - Pick every unit in (Units in (Playable map area) matching (((Picked unit) is A Hero) Equal to True)) and do (If ((Owner of (Picked unit)) Not equal to Player 4 (Purple)) then do (Hero - Add 1000 experience to (Picked unit), Hide level-up graphics) else do (Do nothing))
        Player Group - Pick every player in (All players) and do (Player - Add 100 to (Picked player) Current gold)
        Special Effect - Create a special effect attached to the overhead of Captain Leif 0016 <gen> using Abilities\Spells\Other\TalkToMe\TalkToMe.mdl
        Set QuestEffect[2] = (Last created special effect)
        Trigger - Turn off (This trigger)
        Wait 15.00 seconds
        Trigger - Turn on Mushroom Soup Start <gen>
 

ManyTimes

I'm so lonesome I could cry...
Reaction score
293
>>((Entering unit) is A Hero) Equal to True
Your condition in the last trigger.
Change "entering unit" to "Triggering Unit".
How/Why I know this?
Select the event you got, and read the "blizzard-comment-line", when you are about to click "OK" after you have choosed that event. I'll qoute the line
"Use "Event Response - Triggering Unit' to refer to the unit that is entering within range.".

And in your second trigger, you should add a "Trigger - Turn off (this trigger)"
Why? So it doesnt keep on counting killed Satyrs, for no reason.

Last but not least, if you kill, lets say, 16 satyrs then return home, you wont get the Quest Completed, why is that? Cause of you need exactly 15 satyr kills. It can be fixed in either turning off trigger 2, like i said above, or like this (but you should add both, both turn off triggers and this i will write now)
I also suggest use "greater than or equal to 15" isntead of "equal to 15" in the condition in your third trigger.
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top