Item to Unit

Levdragon

Member
Reaction score
2
Hey,

I'm making a Necromancer map and I was wondering how to make it so if any unit gets two items, essence and skeleton corpse, a skeleton will appear at the unit which used the two items.

I want it so as soon as he/she has the items in inventory that the skeleton will appear. Remember I want it to be a unit not hero, just in case that even matter. Plus rep. for all that post something useful.
 

Somatic

You can change this now in User CP.
Reaction score
84
Just use an event to pick up if a unit has aquired an item, then check if the item is either A) Skeleton Corpse or B) Essence, then check throught the inventory of the unit manipulating the aquired item and then if there is a check on both items, then create the skeleton.
 

Levdragon

Member
Reaction score
2
Umm, I don't really understand that, could you write it up for me please, I'm not to good with improvising triggers, please write that up for me, oh yes and remember not a hero a unit please.
 

Somatic

You can change this now in User CP.
Reaction score
84
1 - The Event to the whole thing is
Code:
Event - A unit has aquired an item

2- You have to make 2 trigger, so the following will be quite repeative when making the 2nd trigger.
You need to first check if you are Aquiring which item, the Essence or the Corpse and then (for this case we will use the Essence)
Code:
Condition - Item Manipulated is equal to type Essence

3 - Then comes an important part, you need to make sure that either A) You have a Corpse or B) You do not have a Corpse or C) You already have an Essence

To do that, use this following action found on the forum,

Code:
        For Integer A = 1 to 6
            If Conditions
                Item in Slot(Integer A) for (Hero Manipulating Item) Not Equal to Essence
            Then ActionsCODE]
and if the case is A) where you have a Corpse then
[CODE]Set Temp_Point = position of Hero Manipulating Item
Unit - Create 1 Skeleton for Owner of Hero Manipulating Item at Temp_Point facing Building default angle
and if you want to destory the Essense just drop 1 more part
Code:
Item - Destory Item in Slot (Integer A) for (Hero Manipulating Item)

We have finished A so far, maybe you would like to try out the rest as Im typing this free hand. And Hero Manipulating Item Works for units to heros alike, so no problem with those
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top