SRL Archive - OSR Help

DTM to search for an image?


cynicz

2013-07-15 09:41:32

How can I make a DTM that searches the screen simba is attached too for an image? Like I want it to search for this small "X" and if present anywhere click it.

http://tinypic.com/r/10pylbl/5

riwu

2013-07-15 09:48:19

Use the DTM editor to make the DTM (refer to a DTM tutorial if you don't know how to use it)

DTM:= DTMFromString();
if FindDTM(DTM, x, y, ...) then
Mouse(x, y, ...);

cynicz

2013-07-15 09:49:57

what if the X will never be in the same spot will it search whole screen?

Rich

2013-07-15 10:09:27

It depends on what area you set it to search, so in reply to your question, yes it will search the whole screen. I suggest, like riwu, to read a tut on DTMs. There's plenty to help you out :)

cynicz

2013-07-15 10:33:16

I tried making a DTM and it still never finds the object.