quest reward help

Mcbeazy

New Member
Reaction score
2
So my entire little chain of triggers for this quest works fine and the quest completes as it is supposed to, but instead of the amount of gold I am supposed to get, I get like over 2k and from lvl2 to lvl 15 instantly....any ideas?


Trigger:
  • QuestComplete
    • Events
      • Unit - A unit comes within 200.00 of DewShine 0086 <gen>
    • Conditions
      • ((Entering unit) is A Hero) Equal to True
      • ((Entering unit) has an item of type Antidote) Equal to True
    • Actions
      • Set DewshineComplete[(Player number of (Owner of (Entering unit)))] = (DewshineComplete[(Player number of (Owner of (Entering unit)))] + 1)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • DewshineComplete[(Player number of (Owner of (Entering unit)))] Equal to 1
        • Then - Actions
          • Quest - Mark AntiVenom[1] as Completed
          • Quest - Display to (All players) the Quest Update message: Good job you have s...
          • Unit Group - Pick every unit in (Units in (Playable map area) matching (((Picked unit) is A Hero) Equal to True)) and do (Actions)
            • Loop - Actions
              • Hero - Add 200 experience to (Picked unit), Show level-up graphics
              • Player - Add 100 to (Picked player) Current gold
              • Trigger - Turn off (This trigger)
          • Trigger - Turn off (This trigger)
        • Else - Actions
 

jig7c

Stop reading me...-statement
Reaction score
123
glad to see most of your quest is working!

you are probably getting so much more XP and so much more gold because there might be another trigger related to when the same event...

also you are leaking a group
and you don't need 2x Turn off (This trigger); take the first one out, the second one outside the loop stays...

is your map multiplayer or single player?
 

Mcbeazy

New Member
Reaction score
2
woops didn't realize I had put two turn off triggers lol. Also, I have 3 triggers that say

Trigger:
  • remove antidote
    • Events
      • Unit - A unit comes within x(all different ranges) of DewShine 0086 <gen>


but none of them deal with XP, so why would they make it so much more?

EDIT: My map is eventually (hopefully) going to be a multi player map, and also I have no idea how to fix leaks, I am Jass illiterate =(
 

jig7c

Stop reading me...-statement
Reaction score
123
possibly in the Gameplay Constants... where you define how much XP is needed to go to the next level... check there...
set the number to a higher number!
 

Mishtiff

New Member
Reaction score
0
i think it has to do with the loop. try "endloop" after the loop and it should work fine? (where you have the turn off trigger)
 

Mcbeazy

New Member
Reaction score
2
Where is endloop? Is it a custom script, or am I just blind? I don't know Jass, I have tried, but still have no idea how to do it, so if it is in Jass, the trigger will stay broken haha
 

Seprest

New Member
Reaction score
15
Just to clarify for myself.

Wouldn't the loop end if he took out the trigger end action and it ran its natural course?
 

Mcbeazy

New Member
Reaction score
2
thanks, how do I implement it into my map? do I make each line a custom script? =( feel so stupid when it comes to jass
 

Chaos_Knight

New Member
Reaction score
39
Just to clarify for myself.

Wouldn't the loop end if he took out the trigger end action and it ran its natural course?

No it would be an infinty loop.

Mcbeazy: Just use Custom Script. The write: endloop set this custom script Before turn off this trigger(the first one). Maybe it will work
:D
 

Mcbeazy

New Member
Reaction score
2
Trigger:
  • QuestComplete
    • Events
      • Unit - A unit comes within 200.00 of DewShine 0086 <gen>
    • Conditions
      • ((Entering unit) is A Hero) Equal to True
      • ((Entering unit) has an item of type Antidote) Equal to True
    • Actions
      • Set DewshineComplete[(Player number of (Owner of (Entering unit)))] = (DewshineComplete[(Player number of (Owner of (Entering unit)))] + 1)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • DewshineComplete[(Player number of (Owner of (Entering unit)))] Equal to 1
        • Then - Actions
          • Quest - Mark AntiVenom[1] as Completed
          • Quest - Display to (All players) the Quest Update message: Good job you have s...
          • Unit Group - Pick every unit in (Units in (Playable map area) matching (((Picked unit) is A Hero) Equal to True)) and do (Actions)
            • Loop - Actions
              • Hero - Add 200 experience to (Picked unit), Show level-up graphics
              • Player - Add 100 to (Picked player) Current gold
              • Custom script: endloop
          • Trigger - Turn off (This trigger)
        • Else - Actions


error, turned off trigger =(
 

Mishtiff

New Member
Reaction score
0
okay man, take the endloop you have made and put it in place of the "turn off trigger" that you have. get rid of the turn off this trigger and you should be golden. i hope =]
 

jig7c

Stop reading me...-statement
Reaction score
123
you don't need endloop in GUI...
it ends the loop automatically when it cycle's through all the possible match

you only need endloop in jass!

please remove the endloop, it'll cause more bugs!
 

Guest3z

New Member
Reaction score
22
Trigger:
  • Unit Group - Pick every unit in (Units in (Playable map area) matching (((Picked unit) is A Hero) Equal to True)) and do (Actions)
    • Loop - Actions
    • Hero - Add 200 experience to (Picked unit), Show level-up graphics
    • Player - Add 100 to (Picked player) Current gold
You have Picked Player in a unit group, its not a player group. Try Owner of Picked unit instead
 
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