• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[Trigger] GUI to MUI

Status
Not open for further replies.
Level 6
Joined
Mar 22, 2009
Messages
276
Im currently making a mini game map. And i made a trigger that will increase the damage of a unit overtime when he entered his base then will have his damage decreased over time when he left the base. Its not the thing, I made it run smoothly. One thing bothers me, its not MUI. And im not that good in MUI making thats why i came here for help. :confused::cry:
  • entr base
    • Events
      • Unit - A unit enters Team1 Base <gen>
    • Conditions
      • ((Entering unit) belongs to an enemy of Player 6 (Orange)) Equal to True
    • Actions
      • Set plnumE = ((Player number of (Owner of (Entering unit))) + ((Custom value of (Entering unit)) x 4))
      • Unit - Set the custom value of (Entering unit) to ((Custom value of (Entering unit)) + 1)
      • Set EntUnit[plnumE] = (Entering unit)
      • Set OwnrE = (Owner of EntUnit[plnumE])
      • Set skilvl[plnumE] = (Level of dmg[1] for EntUnit[plnumE])
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • skilvl[plnumE] Equal to 0
        • Then - Actions
          • Unit - Add dmg[1] to EntUnit[plnumE]
        • Else - Actions
      • Trigger - Turn on inc dmg <gen>
      • Trigger - Turn off dec dmg <gen>
      • Game - Display to (All players) the text: Entered the base.
  • inc dmg
    • Events
      • Time - Every 2.00 seconds of game time
    • Conditions
      • skilvl[plnumE] Less than or equal to 10
    • Actions
      • Unit - Set level of dmg[1] for EntUnit[plnumE] to (skilvl[plnumE] + 1)
      • Set skilvl[plnumE] = (Level of dmg[1] for EntUnit[plnumE])
  • left base
    • Events
      • Unit - A unit leaves Team1 Base <gen>
    • Conditions
      • (((Leaving unit) is A Hero) Equal to True) and (((Leaving unit) belongs to an enemy of Player 6 (Orange)) Equal to True)
    • Actions
      • Set plnum = ((Player number of (Owner of (Leaving unit))) + ((Custom value of (Leaving unit)) x 4))
      • Unit - Set the custom value of (Entering unit) to ((Custom value of (Entering unit)) - 1)
      • Set unitv[plnum] = (Leaving unit)
      • Set skilvl[plnum] = (Level of dmg[1] for unitv[plnum])
      • Trigger - Turn on dec dmg <gen>
      • Trigger - Turn off inc dmg <gen>
      • Game - Display to (All players) the text: Left the Base.
  • dec dmg
    • Events
      • Time - Every 5.00 seconds of game time
    • Conditions
      • skilvl[plnum] Greater than or equal to 1
    • Actions
      • Unit - Set level of dmg[1] for unitv[plnum] to (skilvl[plnum] - 1)
      • Set skilvl[plnum] = (Level of dmg[1] for unitv[plnum])
i already spent a week working on it but still nothing.
i tried to read tutorials on mui but i cant clearly understand them all.
with a bunch of confusion im reaching out for a hand.
thanks in advance im sure to give rep.
 
Last edited:
Status
Not open for further replies.
Top