|
Post by fadetoblack on Oct 4, 2015 14:37:01 GMT
Hi,
I am sorry , this may seem a pretty basic and clueless thread , but I have been trying and trying to get my head Ankulua and still fully cant lol. Basically, I want to wait for an image to appear in a region of the screen, then execute a series of clicks/moves/ and a long press to paste text. Then once the cycle is complete , to return to wait for the image once more. Is this possible ? Or do I have to have images of everything involved in the clicking process? It's further complicated by the fact that I cant "record" my series of events, I am used to standard macro recorders you see.
Thanks in advance Daniel
|
|
|
Post by AnkuLua on Oct 4, 2015 15:03:11 GMT
Hi, I am sorry , this may seem a pretty basic and clueless thread , but I have been trying and trying to get my head Ankulua and still fully cant lol. Basically, I want to wait for an image to appear in a region of the screen, then execute a series of clicks/moves/ and a long press to paste text. Then once the cycle is complete , to return to wait for the image once more. Is this possible ? Or do I have to have images of everything involved in the clicking process? It's further complicated by the fact that I cant "record" my series of events, I am used to standard macro recorders you see. Thanks in advance Daniel Daniel, you are welcome. Yes. All your descriptions are what AnkuLua designed for. AnkuLua is more powerful than macro recorders. Did you have your first waitClick works. The code look like waitClick("target.png") It should click on the target.png. Anyway, you need to prepare target.png in advance. You should crop the "target.png" from the screen. The most straight forward way is to take the screenshot of your device. Send the screenshot to PC. Zoom to 100%. Use any tools to crop the part that you want. Please provide more information and we can provide more help.
|
|
|
Post by fadetoblack on Oct 4, 2015 18:14:44 GMT
Ok, so I have the image in a folder like as in the calculator example, and it is named target.png.. Created a short script of
-- ========== Settings ================ Settings:setCompareDimension(true, 960) Settings:setScriptDimension(true, 960)
-- ========== main program =========== waitClick("target.png")
But I am getting a runtime error: com.appautomatic.ankulua.c :Cant find target.png stack traceback: C:in function waitclick ankulualib.lua:130:in function "waitclick" /sdcard/ankulua/test/test.lua:6: in main chunk
Any ideas on that ?
|
|
|
Post by zpt on Oct 5, 2015 1:09:53 GMT
-- ========== main program =========== waitClick("target.png") But I am getting a runtime error: com.appautomatic.ankulua.c :Cant find target.png stack traceback: C:in function waitclick ankulualib.lua:130:in function "waitclick" /sdcard/ankulua/test/test.lua:6: in main chunk Any ideas on that ? As far as i know, waitClick generates exception if it can't find target.png within the time limit. Use waitClick("target.png",30) or any other suitable amount, in this example it will search for 30 seconds before generate exception. Without second parameter it will search target.png for 3 seconds.
|
|
|
Post by AnkuLua on Oct 5, 2015 1:28:31 GMT
Ok, so I have the image in a folder like as in the calculator example, and it is named target.png.. Created a short script of -- ========== Settings ================ Settings:setCompareDimension(true, 960) Settings:setScriptDimension(true, 960) -- ========== main program =========== waitClick("target.png") But I am getting a runtime error: com.appautomatic.ankulua.c :Cant find target.png stack traceback: C:in function waitclick ankulualib.lua:130:in function "waitclick" /sdcard/ankulua/test/test.lua:6: in main chunk Any ideas on that ? First, you should change the second parameter of following methods according to your device and app. They should not be 960 for most cases. What's your device? Settings:setCompareDimension(true, 960)
Settings:setScriptDimension(true, 960) If it still does not work, send us a zip file including all files. Please also send us a screenshot with target.png on it. Post it here or email ankulua@gmail.com
|
|
|
Post by AnkuLua on Oct 7, 2015 8:13:10 GMT
|
|