Help required: Unit picks item & gets a Special effect...

mnoman

New Member
Reaction score
0
OK, so i got this problem here, and im a total newbie on the forum (no idea how to get a screenshot of my triggers into a post) but i'l just write the stuff

Here's my deal:

When a hero buys an item (in this case the items are named Mask of Death and Hammer of Might) the hero gets a special effect on his/her hand/head...

Hammer of Might
Events
Unit Acquires an item
Conditions
((Hero manipulating item) has (item carried by (hero manipulating item) of type Hammer of Might)) equal to true
actions
Special effect - creat a special effect attached to the hand right of (hero manipulating item) using Abilities\spells\human\stormbolt\stormboltmissile.mdl
Set Hammeromight (special effect variable, no array) = (Last created special effect)

But now, my problem is, since i got two items, that when he gets both items (same trigger only names are Mask of Death and variable Maskodeath), he grabs for instance, the mask and directly after the hammer, he gets 2 efects of hammers, so when i drop the hammer, this trigger becomes active:

Hammer of Might Drops
events
Unit - a unit loses an item
unit - a unit pawns an item (to shop)
conditions
item type of sold item equal to hammer of might or item type of item being manipulated equal to hammer of might
actions
Special effect - destroy Hammeromight

but then he still got 1 hammer of might on his hand, and when he first grabs the hammer and then the mask he gets 2 masks :S

how to solve it? if you dont understand my problem im willing to say it another time but this time less complicate XD
 

ultimate11

Active Member
Reaction score
25
Hammer of Might
Events
Unit Acquires an item
Conditions
((Hero manipulating item) has (item carried by (hero manipulating item) of type Hammer of Might)) equal to true
actions
Special effect - creat a special effect attached to the hand right of (hero manipulating item) using Abilities\spells\human\stormbolt\stormboltmissile.mdl
Set Hammeromight (special effect variable, no array) = (Last created special effect)

everytime when you aquire an items of that type your trigger will create a special effect.that is why your special effect still remain.so you can use count to check how many items of that type, hero have.
If i dont understood well please explain more and i will try to help you.

BTW if you want to post your trigger just right click on your trigger =>copy as text then post hero using WC3 GUI tags.
 

mnoman

New Member
Reaction score
0
but it destroys it in the second trigger... i think im not understanding what you mean xD and thanks for the fast reply :)
 

Ayanami

칼리
Reaction score
288
Or else, you could use Item - Damage Bonus with 0 bonus damage. You can attach special effects under the field "Art - Target" and "Art - Target Attachment Point".
 

mnoman

New Member
Reaction score
0
ok, well here are all my triggers, and indeed now i dont have to write it all thanks for that :thup:

Hammer of Might
Events
Unit - A unit Acquires an item
Conditions
((Hero manipulating item) has (Item carried by (Hero manipulating item) of type Hammer of Might)) Equal to True
Actions
Special Effect - Create a special effect attached to the hand right of (Hero manipulating item) using Abilities\Spells\Human\StormBolt\StormBoltMissile.mdl
Set HammeroMight = (Last created special effect)

Hammer of Might Drops
EventsUnit - A unit Acquires an item


Unit - A unit Loses an item
Unit - A unit Pawns an item (to shop)
Conditions
((Item-type of (Sold Item)) Equal to Hammer of Might) or ((Item-type of (Item being manipulated)) Equal to Hammer of Might)
Special Effect - Destroy HammeroMight

second item the trigger of it

Mask of Death
Events
Unit - A unit Acquires an item
Conditions
((Hero manipulating item) has (Item carried by (Hero manipulating item) of type Mask of Death)) Equal to True
Actions
Special Effect - Create a special effect attached to the head of (Hero manipulating item) using Abilities\Spells\Undead\DeathCoil\DeathCoilMissile.mdl
Set MaskoDeath = (Last created special effect)

Mask of Death Drops
Events
Unit - A unit Loses an item
Unit - A unit Pawns an item (to shop)
Conditions
((Item-type of (Sold Item)) Equal to Mask of Death) or ((Item-type of (Item being manipulated)) Equal to Mask of Death)
Actions
Special Effect - Destroy MaskoDeath
 

mnoman

New Member
Reaction score
0
Or else, you could use Item - Damage Bonus with 0 bonus damage. You can attach special effects under the field "Art - Target" and "Art - Target Attachment Point".

Hmm, i think thats the best option xD oversaw that one, will test it now, and thanks for all the fast reactions :thup:

(if it works i see if i can give you +rep)

Jaja :) thanks so much Glenphir, and you also Ultimate11 for helping. No bugging with my items for now :D
 
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