View Full Version : I there a way i can write procedures into a
Johura
02-20-2007, 08:16 AM
I there a way i can write procedures into a includes script so that way i dont need to rewrite a procedure into more then one script. Example. To run the procedure opentext; all i have to do is type
program New;
begin
opentext;
end.
An it will get the opentext proceduer from an includes script?
Jason2gs
02-20-2007, 08:37 AM
Lol. Funny you should say that.
I did that just today.
Lemme bring it up...
{************************************************* ******************************
procedure LogMeOut;
By: Jason2gs
Description: Used as an RC to tell the active slave to logout.
************************************************** *****************************}
procedure LogMeOut;
begin
wait(500+random(200));
if(InChat('pullout'))then
begin
Logout;
end;
end;
It's so I can tell my slave (bot) to "Pullout" (log out) either from a different computer, or from the computer I'm autoing on, without having to stop the script alltogether.
All you have to do is place the procedure in a SCAR script in one of the SRL include files. Like mine is... SRL/SRL/core.scar
There's no need to put it in the {...} style though, it's already in the SRL/SRL.scar include.
Jason2gs
02-20-2007, 08:39 AM
Btw. I've had this question up for HOURS, and it's not answered yet. Do you mind taking a look at it?
http://www.villavu.com/forum/showthread.php?t=6164
Thanks,
Mike
Johura
02-20-2007, 08:40 AM
Thanks
Jason2gs
02-20-2007, 08:42 AM
You still have to place:
{.include SRL/SRL.scar}
and
SetupSRL;
In your script, though.
SetupSRL; at the begining of your main loop, and {...} right under "program New;"
Johura
02-20-2007, 08:52 AM
yeh it worked :)
Jason2gs
02-20-2007, 08:53 AM
Gratz ;)
Powered by vBulletin® Version 4.2.1 Copyright © 2024 vBulletin Solutions, Inc. All rights reserved.