SRL Archive - SRL Archives

RunEnergy Fixed.


BobboHobbo

2009-05-16 17:19:14

The procedure used to use a cord click to turn on the run if the Min percentage was greater then the MM percentage. Thus if run was already on, it would take it off. Also had some TPA thing aswell which i guess did nothing?


function RunEnergy(Min: Integer): Boolean;
var
tmp: string;
begin
if GetMMLevels('run', tmp) >= Min then
begin
SetRun(true);
Result := True;
end;
end;

Naum

2009-05-17 13:46:37

function RunEnergy(Min: Integer): Boolean;
var
tmp: string;
begin
if GetMMLevels('run', tmp) >= Min then
begin
SetRun(true);
Result := True;
end;
end;


=

function RunEnergy(Min: Integer): Boolean;
var
tmp: string;
begin
Result := GetMMLevels('run', tmp) >= Min
SetRun(Result);
end;

^Shorter :) ^

Nava2

2009-05-18 01:24:22

I agree.. and I think the TPA is to check if its there? Idk. Its in SetRun though.

Tbh:
{*******************************************************************************
function SetRun(Run: Boolean): Boolean;
By: Wizzup? & EvilChicken!
Description: Sets Run on or off.
*******************************************************************************}

function SetRun(Run: Boolean): Boolean;
Var
TPA: TPointArray;
Begin
FindColorsTolerance(TPA, 5753055, 715, 105, 731, 110, 30);
If (Length(TPA) > 10) Xor Run Then
begin
Mouse(715, 95, 10, 10, True);
Result := True;
end;
End;

{*******************************************************************************
function RunEnergy(Min: Integer): Boolean;
By: lordsaturn
Description: Toggles run if energy is greater or equal to MinEnergy. Results
true if run was toggled.
*******************************************************************************}
function RunEnergy(Min: Integer): Boolean;
var
t: String;
begin
Result := SetRun(GetMMLevels('run', t) >= Min);
end;

Committed the latter.

ZephyrsFury

2009-05-18 14:01:39

The TPA Length check is to see if Run is already enabled (Length() > 10 implies RunEnabled).

N2: I understand now. :)

Sir R. M8gic1an

2009-05-21 23:45:04

anyway… thought i might post saying it was changed again :p


{*******************************************************************************
function RunEnergy(Min: Integer): Boolean;
By: lordsaturn
Description: Toggles run if energy is greater or equal to MinEnergy. Results
true if run energy >= Min
*******************************************************************************}
function RunEnergy(Min: Integer): Boolean;
var
t: String;
begin
Result := GetMMLevels('run', t) >= Min;
SetRun(Result)
end;

~RM