SRL Archive - Help

WithdrawEx Withdraw-X Problem


RuneDragon

2012-05-28 20:17:41

Hi.

In my code, i have


WithdrawEx(4,1,9,[]);

I want to take 9 items. But at times, it could not find the Withdraw-9 in the Options and click the Withdraw-X and type in number 9.

This happens at times. I think this is caused by RS changing text font at times, not sure if they do this to find bots.

I tried to wait for the option


repeat
Wait(10);
Writeln('Waiting for Option');
until WaitOptionMultiEx(['Withdraw-' + IntToStr(Amount), 'w-' + IntToStr(Amount)], 'All', Nothing, 300);

Even waiting is not helping.

Is there anyway i can blind click the "Withdraw-9" option assuming it is previously entered and working ?

Something like


if (WaitOptionMultiEx(['Withdraw-' + IntToStr(Amount), 'w-' + IntToStr(Amount)], 'All', Nothing, 300)) then
begin
Result := ChooseOptionMulti(['Withdraw-' + IntToStr(Amount), 'w-' + IntToStr(Amount)]);
end else begin

// code to blind click Withdraw-9, it is 4th item in option menu. Above Withdraw-X

end;

Thanks,

Santhosh

Google

2012-05-28 20:38:18

removed.

Brandon

2012-05-28 20:38:28

GetChooseOptions.. It will give you the co-ordinates of the option you want to forcibly click.

RuneDragon

2012-05-28 21:00:28

@GOOGLE In actual code, i have the texts as third option. I just used empty [] because actual Withdraw function calls Result := WithdrawEx(Col, Row, Amount,[]);

@Brandon Thanks, i will check GetChooseOptions.

RuneDragon

2012-05-29 14:03:15

I see RS changing the text/font so OCR get different text at times.

Here is 2 different texts i get, there can be more, i only checked these 2.


Withd@m-27&rimy spirit weed
WithRf0m-2V@rim spirit weed

This is while withdrawing 27 Grimy spirit weed.

The entry is like


('WithRf0m-2V@rim spirit weed', (4, 180, 214, 194), (0, 0, 0, 0))

Is there anyway i can use the value 4, 180, 214, 194 to click or click on 4th entry returned by GetChooseOptions ?