• 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.

Remaining Buffs

Status
Not open for further replies.
Level 8
Joined
Dec 29, 2006
Messages
359
I have a reputation system in my map that functions basically the same as the pvp honor system in WoW (w/o the pvp part) if you don't have enough rep points the item will be removed from your inventory

  • Kirin Item Selling
    • Events
      • Unit - Kirin Quartermaster 0042 <gen> Sells an item (from shop)
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Reputation_Kirin Greater than or equal to (Integer((Current life of (Sold Item))))
        • Then - Actions
          • Set Reputation_Kirin = (Reputation_Kirin - (Integer((Current life of (Sold Item)))))
          • Game - Display to (All players) for 3.00 seconds the text: (Item purchased successfully! You now have + ((String(Reputation_Kirin)) + Kirin Reputation points remaining.))
        • Else - Actions
          • Item - Remove (Sold Item)
          • Game - Display to (All players) for 3.00 seconds the text: Insufficient Reputa...
the problem is if the unit buys an item like cloak of flames or an item that gives a damage bonus, the buff is applied to the buying unit and stays there even though they dont have the item. How can I fix this? Thanks to all replies!
 
Last edited:
Level 4
Joined
Sep 20, 2005
Messages
72
well thats strange... abilities that items have normally get removed as the item is removed. Not sure, but could it be a conflict with the event firing before the unit even has the item that it bought? try putting a wait/0 timer that fires before you remove the item. Just a guess though.
Or perhaps force unit to drop item, then remove?
 
Status
Not open for further replies.
Top