SRL Archive - Help and Support

TPA Strike List


Dynamite

2011-12-19 16:55:14

hi guys,
so for my woodutter I am looking to do this sort of thing -

TPA search for willow tree colour.
sortTPA
mouse over, if uptext not willow then take it off the Array and don't let it be added to the next TPA when searching for the colour.

how would I do the last bit to make sure it won't put that point in the tpa again?

-Boom

footballjds

2011-12-19 17:11:09

From: Dynamite
hi guys,
so for my woodutter I am looking to do this sort of thing -

TPA search for willow tree colour.
sortTPA
mouse over, if uptext not willow then take it off the Array and don't let it be added to the next TPA when searching for the colour.

how would I do the last bit to make sure it won't put that point in the tpa again?

-Boom


why do you care if that point is in if you can take it out? ;)
two options.
Make an array of points you want to ignore and ignore them.
Use skip box when searching for your points.

I would simply:
Search for _TreeColor
Shorten and sort tpa
loop through your points with the mouse to check uptext
every point where the uptext isn't "Willow" add to the array IgnorePoints
next time you go to move the mouse check whether or not the position you wanna move the mouse to is in IgnorePoints

YoHoJo

2011-12-19 17:13:43

Why take it off and why two TPAs?
Just one TPA and have a for to do loop to go though each of the points and once the proper uptext is up click the tree.

Check out my mining script. When I was just learning TPAs I made the mining procedure and it will do exactly what you stated up there.

Post back here if you need any explanation of the code! Good luck!

Dynamite

2011-12-19 17:17:20

From: YoHoJo
Why take it off and why two TPAs?
Just one TPA and have a for to do loop to go though each of the points and once the proper uptext is up click the tree.

Check out my mining script. When I was just learning TPAs I made the mining procedure and it will do exactly what you stated up there.

Post back here if you need any explanation of the code! Good luck!


I know how to find a click the tree and loop through :duh: but by making an ignore list, it shortens the loop as it won't mouse over worthless points.

YoHoJo

2011-12-19 17:28:12

Is your character always standing in the exact same spot/angle? If not that won't even work well.
I'd just autocolor it better and add height and width and pixel check so only the proper points are found in the first place :)?

Kyle Undefined

2011-12-19 17:34:23

Well, when you're looping through the points, you will obviously need to break when you find the ones that pertain to the Willow tree. So looping through worthless points will be minimal.

Dynamite

2011-12-19 17:44:49

From: YoHoJo
Is your character always standing in the exact same spot/angle? If not that won't even work well.
I'd just autocolor it better and add height and width and pixel check so only the proper points are found in the first place :)?


Well I was thinking of adding an ignore list per tile. Which will learn as the script goes on.

footballjds

2011-12-20 10:37:13

From: Dynamite
Well I was thinking of adding an ignore list per tile. Which will learn as the script goes on.


sparked my interest.
I'd love to see how you can keep track of tiles accurately with just color while moving.
It takes a shit ton of math, main screen tiles can be calculated with regard to the minimap however this is a shaky reference point at best. There's an algorithm for that but you'll find you need to tweak it. I've done this before but that was 3 years ago. :P
Math + Color > fagex

Claymore

2011-12-20 23:32:29

Your a mad man, this isnt possible. Is it?

euphemism

2011-12-20 23:39:20

From: Deathscytex
Your a mad man, this isnt possible. Is it?


Mmmm, the concept doesn't seem like it is too difficult to implement. As in, in my mind I see it as very possible. No doubt there will be some fun stuff to write to actually get it to work, though.

mormonman

2011-12-21 00:39:06

There are better ways to find objects…Do length checks, use a very unique color, use flight's idea of bordering colors, etc. Don't resort to uptext checking so much ;)

footballjds

2011-12-21 11:18:28

From: mormonman
There are better ways to find objects…Do length checks, use a very unique color, use flight's idea of bordering colors, etc. Don't resort to uptext checking so much ;)


I would still use uptext. It's a perfect way to know whether or not you're on the object you want to click. However, I think uptext is the LAST thing you should check, if you moved your mouse then you'd better be sure that's the object already, uptext should just prevent miss clicks.

Claymore

2011-12-22 14:47:36

From: mormonman
There are better ways to find objects…Do length checks, use a very unique color, use flight's idea of bordering colors, etc. Don't resort to uptext checking so much ;)


True, ill keep this in mind next time i create a TPA object finding function.