Page 1 of 1

AutoBuy

Posted: 01.12.2009 12:52
by duque777
I'm not able to make a script to buy a particular item, but to sell worked perfectly.

Я не в состоянии сделать сценария купить определенный пункт, а продавать работали прекрасно.

Sell:
[code]Program Sell;

{$Include 'all.inc'}

uosay('Tak Sell');
AutoSell($1F03,$0000,10);
wait(2000);[/code]

Buy:
[code]Program Buy;

{$Include 'all.inc'}

begin
if not GetAutoBuyMode then SetAutoBuyMode(true);
SetAutoBuyDelay(400);
AutoBuy($175D,$0000,20);
UOSay('Chiin buy'); [/code]

Where is the problem?

Где ошибка?

thanks.

Posted: 01.12.2009 17:56
by WladL
Why You use AutoBuy function in Sell programm?
procedure AutoSell(ItemType: Word; ItemColor: Word; Quantity: Word);
function GetAutoSellMode: Boolean;
procedure SetAutoSellMode(Value: Boolean);
function GetAutoSellDelay: Word;
procedure SetAutoSellDelay(Value: Word);

Posted: 01.12.2009 18:16
by duque777
error when I put in the forum.
but the problem is on BUY program.

Re: AutoBuy

Posted: 01.12.2009 19:05
by WladL
duque777 wrote: SetAutoBuyDelay(400);
SetAutoBuyDelay(Sekond:Word);
You are set 400 sekond = 6,7 minute? it's correct?

Posted: 01.12.2009 20:35
by duque777
this is not the problem, as already modified it and still not buying.

Posted: 02.12.2009 2:30
by WladL
1)check second param($0000), it's must be strong a color of item.
2)after UOSay('Chiin buy') insert wait-function with BuyDelay argument

Code: Select all

SetAutoBuyDelay(5);
...
UOSay('Chiin buy');
wait(5000);

3)try set SetSilentMode(false) before buy and find in list your item.
4)Your server type?