item remove

1

1188

Guest
i need a trigger which removes item, 100 seconds after its being created.
and it must work for multiple items at same time.
thx

i tried a lot but i could make only a trigger which work for one item at same time, if multiple items are created then the last was removed and others stays...
 

Juliano

New Member
Reaction score
8
Try using a variable to it, store the item on the variable, wait 100 seconds, and remove the item...for multiple itens, use an array...explain me better your question:)
 
1

1188

Guest
i just don't understand the system how to make multiple things to work in same time, anyways here is my trigger...

Code:
item drop settings Copy 2
    Events
        Unit - A unit Dies
    Conditions
        (Unit-type of (Dying unit)) Equal to Footman
    Actions
        Item - Create Mask of Death at (Position of (Dying unit))
        Set item_number[item_num] = (Last created item)
        Wait 60.00 seconds
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (item_number[item_num] is owned) Equal to True
            Then - Actions
                Do nothing
            Else - Actions
                Item - Remove item_number[item_num]
        Set item_num = (item_num + 1)
 

darkRae

Ueki Fan (Ueki is watching you)
Reaction score
173
> i tried a lot but i could make only a trigger which work for one item at same time, if multiple items are created then the last was removed and others stays...

Try this :

Code:
Events
Conditions
Actions
    --somehow you created the item, then--
    If IntegerVar == 100
    Then Set IntegerVar = 1
    Else Set IntegerVar = IntegerVar + 1
    Set Item[IntegerVar] = Last Created Item
    Start a Timer for TimerVar[IntegerVar] that ends in 100 seconds
    Add the event 'TimerVar[IntegerVar] expires' to TheNextTrigger

Code:
Events
Conditions
Actions
    For Integer A Loop 1 to 100
        If TimerVar[Integer A] == Expiring Timer
        Then Remove/Destroy Item[Integer A]
        Else

(I'm not sure if there's 'Expiring Timer')
These triggers are for up to 100 items at the same time.
 
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