Request: Add on to current trigger to make it so if the item is picked back up before the expiration timer runs out the timer stops and the trigger starts over once the meat is dropped again.
I've had problems before with this trigger and now I'm seeing if you drop the item "Meat" and pick it up again, the item will still disappear after the generic timer runs out.
The idea behind this trigger is 'meat becoming moldy'... if you set it down for over, in this case, 30 seconds it disappears as in becomes moldy and inedible. So if you pick the meat back up before 30 seconds it does not get removed.
I've had problems before with this trigger and now I'm seeing if you drop the item "Meat" and pick it up again, the item will still disappear after the generic timer runs out.
The idea behind this trigger is 'meat becoming moldy'... if you set it down for over, in this case, 30 seconds it disappears as in becomes moldy and inedible. So if you pick the meat back up before 30 seconds it does not get removed.
-
ID Init
-
Events
- Map initialization
- Conditions
-
Actions
- Hashtable - Create a hashtable
- Set IDhashtable = (Last created hashtable)
-
Events
-
ID A
-
Events
- Unit - A unit Loses an item
-
Conditions
- (Item-type of (Item being manipulated)) Equal to Meat
-
Actions
- Set IDpoint1 = (Position of (Item being manipulated))
- Unit - Create 1 Dummy for Neutral Passive at IDpoint1 facing Default building facing degrees
- Unit - Add a 5.00 second Generic expiration timer to (Last created unit)
- Hashtable - Save Handle Of(Item being manipulated) as (Key item) of (Key (Last created unit)) in IDhashtable
- Hashtable - Save Handle Of(Last created unit) as (Key unit) of (Key (Item being manipulated)) in IDhashtable
- Custom script: call RemoveLocation (udg_IDpoint1)
-
Events
-
ID B
-
Events
- Unit - A unit Dies
-
Conditions
- (Unit-type of (Triggering unit)) Equal to Dummy
- ((Key item) is stored as a Handle of (Key (Triggering unit)) in IDhashtable) Equal to True
-
Actions
- Hashtable - Clear all child hashtables of child (Key (Load (Key item) of (Key (Triggering unit)) in IDhashtable)) in IDhashtable
- Item - Remove (Load (Key item) of (Key (Triggering unit)) in IDhashtable)
- Hashtable - Clear all child hashtables of child (Key (Triggering unit)) in IDhashtable
-
Events