HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Tracking down item.

03-05-2008, 11:59 PM#1
cohadar
At some point I save a handle of some item.
After 60 sec I want to know where is that item.

If it is being carried by a unit I want to know which unit.
If it is on the ground I want to know x and y.

Anyone knows how to do this without ForGrouping all units on the map with UnitHasItem check?
03-06-2008, 12:57 AM#2
Ammorth
Keep track of it in a variable.

Unit picks up an item, check if its the item and then keep track that the unit has it.
Unit drops the item, check where he drops it and keep track of its position
Unit gives the item, keep track of the new unit.

This may be longer to code than your method, but it should be more efficient.
03-06-2008, 01:09 AM#3
cohadar
I was hoping for a simpler solution.
03-07-2008, 12:44 PM#4
SkriK
How can that not be simple?
03-07-2008, 12:49 PM#5
Rising_Dusk
It is relatively simple, but it's not an elegant solution, which I think is what Cohadar was hoping for.
03-07-2008, 01:28 PM#6
Toadcop
Gabriel & Dresden - Tracking Treasure Down +1 :pray: - the bes solution xD

to store needed data an item ? (using ItemUserData ?)

A State of Trance 332 :pray:
03-07-2008, 02:57 PM#7
cohadar
Ye I had to do it the hard way.
Well it was worth it...
03-07-2008, 03:46 PM#8
MaD[Lion]
there are only some events with items, just make a system to handle these events, where data is updated to these events...