Page 1 of 1

Spirit of the Tempest Heights(event) and target_Object()

Posted: Thu Sep 23, 2010 4:07 pm
by Paton
I like the Spirit of the Tempest Heights(event) and it takes to much time to collect those chests(with clicking, searching, mouse moving), which dont need an ancient treasure key to unlock. The amount of objects(chests) is really really big. I wonder if this could cause any problems with player:target_Object().

I collected allready a few IDs with getid.lua. There are like 7 IDs(chests), which dont need a key to open. I could check for all 7 with else if,..., but it would be alot more elegant if you could pass a list of IDs to target and if it finds one from the list it targets it.

This wont be a AFK bot script. It just does 1 looting/scanning for chests per keypress.

What do you guys think ?

Re: Spirit of the Tempest Heights(event) and target_Object()

Posted: Fri Sep 24, 2010 12:09 am
by rock5
Actually that wouldn't be too difficult to implement. I could even implement it so you could still use single values so you would still have backward compatibility for already existing scripts.

This is how I envision it being able to be used;
player:target_Object("objectname")
player:target_Object(207359)
player:target_Object({"objectname 1", "objectname 2"})

Or even mixing up names and ids
player:target_Object({"object1", 204022, "object3"})

What do you think?

Re: Spirit of the Tempest Heights(event) and target_Object()

Posted: Wed Sep 29, 2010 11:30 am
by radulfizz
It's been a while since i played around with the bot at the TH event, so i might be a little off here.
I never checked the ID's there, so never knew about different ID's for the chests in question,
but they all go by the same name, so something like

player:target_Object("Mysterious Treasure Chest")

worked for me iirc.

But eventually I ended up using a simple macro instead of the bot.
It cycles through every object there with

TargetNearestFriend()

until it finds a Mysterious Chest which it leaves targeted.
I found this easier to handle,
though at the cost of having to face into the direction where chests are searched
and probably a reduced search radius.