Log in

View Full Version : How do you lower the frequency/speed of movements?



zmarchbank
05-29-2012, 07:47 PM
I'm using R4nd0m's stay logged in script. it moves constantly and I'd like to slow it down. I'm trying to learn coding but i'm not good yet. Just looking for some help.


program R4StayLoggedIn;
{$i srl/srl/misc/smart.simba}
{$i srl/srl.simba}
//{$i SRL/SRL/misc/paintsmart.simba}

var
//CStatus: String;
x, y :Integer;

procedure DeclarePlayers;
begin
HowManyPlayers := 1;
NumberOfPlayers(HowManyPlayers);
CurrentPlayer := 0; // This is the player to start with
Players[0].Name := ''; // Username
Players[0].Pass := ''; // Password
Players[0].Nick := ''; // 3-4 lowercase letters from username;
Players[0].Active := True; // Set to true if you want to use Player 0
Players[0].BoxRewards := ['Xp', 'mote', 'ostume', 'oins', 'aphire', 'ssence'];
end;

{Procedure PrintOnSmart(TP: TStringArray; Placement: TPoint; Colour: integer);
var
mx, my, Pic, I, B, H, TPH, Numb: Integer;
TTP: TPointArray;
Canvas: TCanvas;
begin
SmartSetDebug(True);
GetClientDimensions(mx, my);
Pic := BitmapFromString(mx, my, '');
TPH := High(TP);
for I := 0 to TPH do
begin
TTP := LoadTextTPA(TP[i], SmallChars, H);
for B := 0 to High(TTP) do
begin
Numb := ((I + 1) * 13);
FastSetPixel(Pic, TTP[b].x + 1, TTP[b].y + Numb + 1,8388736);
FastSetPixel(Pic, TTP[b].x, TTP[b].y + Numb, Colour);
end;
end;
Canvas := TCANVAS.Create;
Canvas.Handle := SmartGetDebugDC;
DrawBitmap(Pic, Canvas, Placement.x, Placement.y);
FreeBitmap(Pic);
end; }

{function GetRandomFact: string;
//This function returns a random fact from
// the website 'http://randomfactgenerator.net/'
// Author: kanah
// Special thanks to Euphemism for the idea
var
SearchString0, SearchString1, Text: string;
begin
//Search strings are used to mark the begining and end of useful info
SearchString0 := '<div id="facts">';
SearchString1 := '<br/><br/>';

//Text is loaded with the raw html text from the website
Text := GetPage('http://randomfactgenerator.net/');

//Text is now broken down from the entire html page into the random fact
Text := Between(SearchString0,SearchString1,Text);

//Now trim to remove spaces and get rid of the "<div>" text
Trim(Text);
delete(Text,1,pos('>',Text));
Result := Text;
Wait(randomrange(5000, 10000));
end;


Procedure Painting;
begin
PrintOnSmart(['R4_StayLoggedIn','-----------', 'Status:', CStatus,
'-----------', 'Fact:', GetRandomFact], Point(40, 50),16777215);
end; }


procedure Antiban;
begin
case Random(60) of
10: RandomRClick;
20: HoverSkill('Cooking', False);
30: PickUpMouse;
40: RandomMovement;
50: BoredHuman;
59: ExamineInv;
end;
end;

{procedure RandomComments;
begin
case Random(60) of
10: CStatus := 'Randomly Moving';
20: CStatus := 'So so bored';
30: CStatus := 'Lifting the mouse';
40: CStatus := 'Randomly moving...';
50: CStatus := 'I bored.';
59: CStatus := 'Staying logged in...';
end;
Painting;
end; }
Procedure Loop();
begin
repeat
Antiban;
{RandomComments;}
FindNormalRandoms;
until false;
end;


begin
{
case Random(60) of
10: CStatus := 'Randomly Moving';
20: CStatus := 'So so bored';
30: CStatus := 'Lifting the mouse';
40: CStatus := 'Randomly moving...';
50: CStatus := 'I bored.';
59: CStatus := 'Staying logged in...';
end; }
Smart_Server := 77;
Smart_Members := True;
Smart_Signed := True;
Smart_SuperDetail := False;
SetupSRL;
DeclarePlayers;
LoginPlayer;
{Painting; }
Loop;
end.



Not sure what to edit to make it move less often. Thanks in advance

Nebula
05-29-2012, 10:13 PM
procedure Antiban;
begin
case Random(60) of // <-------------Change the 60 to a higher number
10: RandomRClick;
20: HoverSkill('Cooking', False);
30: PickUpMouse;
40: RandomMovement;
50: BoredHuman;
59: ExamineInv;
end;
end;

putonajonny
05-29-2012, 10:16 PM
Procedure Loop();
begin
repeat
Antiban;
{RandomComments;}
FindNormalRandoms;
Wait(1000+Random(1000));//Add this line in here
until false;
end;

change this:20: HoverSkill('Cooking', False);to:20: HoverSkill(SKILL_ATTACK + Random(SKILL_DUNGEONEERING + 1), False);

zmarchbank
05-29-2012, 11:28 PM
Thank you both so much. That worked perfectly!