Quick Dialog Question

JakeWC123

New Member
Reaction score
2
Ok for my dialog its a atribute system where wen u lvl up u get to add your stats. your lumber represents stat points.this is what i have but my problem is that if you lvl up 2 times with 1 kill you only get 3 Atribute points not 6


Events
Dialog - A dialog button is clicked for Dialog
Conditions
(Clicked dialog button) Equal to DialogButton[1]
Actions
Hero - Modify Agility of (Random unit from (Units in (Entire map) owned by (Triggering player))): Add 1
Player - Add -1 to (Triggering player) Current lumber
Dialog - Clear Dialog
 

Pineapple

Just Smile.
Reaction score
576
edit:: show me the trigger thats adds lumber

Also don't bump after 8 minutes. You are not the only one looking for help.
 
K

Kota

Guest
Ok for my dialog its a atribute system where wen u lvl up u get to add your stats. your lumber represents stat points.this is what i have but my problem is that if you lvl up 2 times with 1 kill you only get 3 Atribute points not 6

PHP:
Events
Dialog - A dialog button is clicked for Dialog
Conditions
(Clicked dialog button) Equal to DialogButton[1]
Actions
Hero - Modify Agility of (Random unit from (Units in (Entire map) owned by (Triggering player))): Add 1
Player - Add -1 to (Triggering player) Current lumber
Dialog - Clear Dialog

I got ur problem, random unit from units in entire map wont work, if its not that might be ur lumber adding
 

AceHart

Your Friendly Neighborhood Admin
Reaction score
1,495
> random unit from units in entire map won't work

Well, if that's your only unit ever, it will.

Then again, if you only have one unit, I'd just put them in an array, indexed by player number, as soon as you get them, and work from there.
It would also prevent that unit group leak.
It's faster too, since you don't need to find the unit first.


Hero - Add <whatever>: Level of <unit> - HeroLevel[Player number of (Owner of <unit>)]
Set HeroLevel[Player number of (Owner of <unit>)] = Level of <unit>

I.e. with an integer array that keeps track of the previous level of the Hero, it's no problem to see if they got more than one level at once.
 
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