SRL Archive - FAQ

how do i repeat?


hobofight101

2012-02-29 21:06:38

ok so im doing a basic macro script i created and i want it to "loop" (in C++ terms). but i dont know how to make my script loop i tried doing loop and end loop like a normal computer program. and i found out repeat is an actual function. but i dont know how to use it. (and yes i did try looking in the SIMBA FAQ for 30 minutes)
help plz

Horodirus

2012-02-29 21:14:53

while condition do

begin
(Do stuff here)
end;



I'm relatively certain this is correct.

If it's not, post back and I'll research it.

RyGuy

2012-02-29 21:25:31

repeat
thing 1
thing 2
until(....)

hobofight101

2012-02-29 21:44:53

heres my script but i want to put a never ending script on it. i know its noob but its a start :).

"program chocolatedustmaker;
begin
MoveMouse(759, 452);
Wait(1234)
Clickmouse(759, 452, 0);
Wait(1139)
MoveMouse(762, 490);
Clickmouse(762, 490, 1);
Wait(1345)
MoveMouse(943, 404);
ClickMouse(943, 404, 0);
Wait(1223)
MoveMouse(948, 516);
ClickMouse(948, 516, 1);
Wait(1453)
MoveMouse(390, 300);
ClickMouse(390, 300, 0);
Wait(1274)
MoveMouse(390, 410);
ClickMouse(390, 410, 1);
Wait(1432)
MoveMouse(824, 226);
ClickMouse(824, 266, 1);
Wait(1132)
MoveMouse(900, 400);
ClickMouse(900, 400, 1)
Wait(1167)
MoveMouse(944, 402);
ClickMouse(944, 402, 1);
Wait(1293)
MoveMouse(535, 647);
ClickMouse(535, 647, 1);
Wait(27894)
end. "

Inception

2012-02-29 21:45:01

Be sure to include a fail safe so you don't get stuck in an infinite loop :)

E: Nevermind…


repeat
{Your code}
until not LoggedIn

hobofight101

2012-02-29 21:51:58

inception thanks +rep

hobofight101

2012-02-29 21:55:24

From: Inception
Be sure to include a fail safe so you don't get stuck in an infinite loop :)

E: Nevermind…


repeat
{Your code}
until not LoggedIn


it gives me this error "[Error] (38:13): Unknown identifier 'LoggedIn' at line 37
Compiling failed." so what would i define loggedIn as?

hobofight101

2012-02-29 21:59:40

answered question mod or admin plz close thread. or ill delete it

hobofight101

2012-02-29 22:00:41

question answered mod or admin plz close thread or ill delete it