Log in

View Full Version : Smart.Scar- line 7 error



oakley123
11-03-2008, 01:18 AM
Ok so I followed the new smart fixes to try to add smart to my own script but when I try to run it I get this error-

Line 7: [Error] (18388:11): Duplicate identifier 'MOVEMOUSE' in script C:\Program Files\SCAR 3.15\includes\srl/srl/misc/Smart.scar


I have read about the duplicate identifier error on other posts but none have solved/helped with the problem. This is with the brand new smart.scar and strangely it just started to say that and about a week ago it was actually working perfectly.


Im also a bit confused on how to setit up...maybe thats the problem. To attempt to set it up I put-

ClearDebug;
ClearReport;
LoadSMART(38, True, True);

within the main loop.

(The guides/tutorials of how to add it are either confusing or arent updated)

Thanks for your help.:D

TViYH
11-03-2008, 01:46 AM
Post the script that gives the errors.

oakley123
11-03-2008, 01:50 AM
Post the script that gives the errors.

program TheSaw;
{.Include SRL\SRL.Scar}
{.Include SRL/SRL/Skill/Woodcutting.scar}
{.Include SRL\SRL\Misc\Users.Scar}
{.include srl/srl/misc/Smart.scar}
{

|----------------------------|
| "The Saw" By: Oakley123 |
| |
| Latest Version: 1.1 |
| |
| |
| *STILL TESTING* |
| |
| |
|Special Thanks to Sand Storm|
| for helping me |
| standardize/fix script. |
|----------------------------|

} //@@@@@@@@@@@@@@@@@@@@@@@@@@@\\
// FILL OUT BELOW \\
//@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@\\
procedure DeclarePlayers;
begin
HowManyPlayers := 1; //Number of players
NumberOfPlayers(HowManyPlayers);
CurrentPlayer:= 0;

Players[0].Name :=''; // Add player name - runescape username
Players[0].Pass :=''; // Add player password - runescape pass
Players[0].Nick :=''; // Add username nick - 3-4 consevutive numbers from username
Players[0].Active:=True;
end;
Procedure AntiBan; Forward;



{DONT TOUCH ANYTHING BELOW}

const
TreeColour1= 1648941;
TreeColour2= 2508859;
TreeColour3= 5264459;
TreeColour4= 1980978;
TreeColour5= 2573880;
TreeColour6= 2902589;
TreeColour7= 1847597;

Var
x, y, cut : integer;

Procedure stats;
begin
ReportVars[0] := cut;
ReportVars[1] := cut * 36;
ReportVars[2] := cut / 28;
SrlRandomsReport;
end;



Procedure RandomDisguise;
begin
case Random(12) Of
0: Disguise('Windows Live Messenger v.8.0');
1: Disguise('Bigfix - Computer Protection Wizard');
2: Disguise('RuneScape - the massive online adventure game by Jagex Ltd - Mozilla Firefox');
3: Disguise('Tip.it Free RS quest help');
4: Disguise('PhotoShop professional v12.9');
5: Disguise('Google Toolbar');
6: Disguise('Norton Internet Security');
7: Disguise('Tip.it Runescape Help!');
8: Disguise('Trust software and hardware development');
9: Disguise('C:/Program/wireless/internet/browser');
10: Disguise('Microsoft Office Professional');
11: Disguise('Desktop files');
12: Disguise('SwiftSwitch i.explorer client');
end;
end;


procedure randoms;
begin
findnormalrandoms;
if findfight=true then
begin
runaway('E',true,1,5000+random(1000));
end;
end;


procedure drop;
begin
if not LoggedIn then Exit;
if (InvFull) then
cut := cut + 28;
DropAll;
end;



procedure MouseOverTree;
begin
if (not (InvFull)) then
begin
if (IsUpText('illow')) then
begin
repeat
antiban;
until (not (IsUpText('illow')));
end;
end else
Drop;
end;


procedure antiban;
begin
if (IsUpText('illow')) or (not (InvFull)) then
begin
end;
Wait(500 + Random(5000));
case Random(8) of
1: Wait(500 + Random(5000));
2: Wait(500 + Random(5000));
3: Wait(500 + Random(5000));
4: MakeCompass('90');
5: MakeCompass('30');
6: MakeCompass('60');
7: MakeCompass('0');
end;
end;


Procedure RandomCut;
begin
if (not (IsUpText('illow'))) then
begin
Case (Random(4)) Of
1: FindObjCustom(X, Y, ['cho', 'hop', 'chop'], [TreeColour1, TreeColour2, TreeColour3], 3);

2: FindObjCustom(X, Y, ['cho', 'hop', 'chop'], [TreeColour2, TreeColour5, TreeColour3], 3);

3: FindObjCustom(X, Y, ['ch', 'hop', 'chop'], [TreeColour6, TreeColour4, TreeColour3], 3);

4: FindObjCustom(X, Y, ['cho', 'hop', 'chop'], [TreeColour7, TreeColour6, TreeColour3], 3);
end;
end;
end;

Procedure RandomC;
begin
case (Random(6)) of
1: Mouse (x, y, 1, 1, true);
2: Mouse (x, y, 2, 2, true);
3: Mouse (x, y, 11, 3, true);
4: Mouse (x, y, 4, 4, true);
5: Mouse (x, y, 13, 3, true);
6: Mouse (x, y, 22, 1, true);
end;
end;


begin
ClearDebug;
ClearReport;
LoadSMART(38, True, True);
SetupSRL;
ScriptID := '1073';
DeclarePlayers;
LoginPlayer;
RandomDisguise;
repeat
FindBirdsNest;
randoms;
RandomCut;
RandomC;
MouseOverTree;
stats;
until(false)
end.

noidea
11-03-2008, 01:53 AM
Put SetupSRL; before LoadSMART() ;)
And {.include srl/srl/misc/Smart.scar} has to be above {.include srl/srl.scar}

ANd LOadSMART() params are (World, signed?, free2play?)

Edit: I just looked at your RandomC procedure, it should be this :)
Procedure RandomC;
var
x, y : Integer;
begin
getmousepos(x, y)
case (Random(6)) of
0: Mouse (x, y, 1, 1, true);
1: Mouse (x, y, 2, 2, true);
2: Mouse (x, y, 11, 3, true);
3:Mouse (x, y, 4, 4, true);
4: Mouse (x, y, 13, 3, true);
5: Mouse (x, y, 22, 1, true);
end;
end;

A case like that one always starts at 0 :) (and you needed a getmousepos())

oakley123
11-03-2008, 02:39 AM
Put SetupSRL; before LoadSMART() ;)
And {.include srl/srl/misc/Smart.scar} has to be above {.include srl/srl.scar}

ANd LOadSMART() params are (World, signed?, free2play?)

Edit: I just looked at your RandomC procedure, it should be this :)
Procedure RandomC;
var
x, y : Integer;
begin
getmousepos(x, y)
case (Random(6)) of
0: Mouse (x, y, 1, 1, true);
1: Mouse (x, y, 2, 2, true);
2: Mouse (x, y, 11, 3, true);
3:Mouse (x, y, 4, 4, true);
4: Mouse (x, y, 13, 3, true);
5: Mouse (x, y, 22, 1, true);
end;
end;

A case like that one always starts at 0 :) (and you needed a getmousepos())


TY! Trying that now! :D If it works plus rep++ :eek:

Brain
11-03-2008, 02:52 AM
Try not to double post, that's what the edit button is for.

As for your problem, I don't know how to fix it, I am just waiting till we get a new smart, if ever.

TViYH
11-03-2008, 04:12 AM
No, you double posted.

It should be SmartSetupEx(); not LoadSMART();, I believe.

Try it.

i st33zy i
11-03-2008, 04:39 AM
ty

oakley123
11-03-2008, 02:20 PM
Ill try that later, thanks alot in advance

noidea
11-03-2008, 09:55 PM
No, you double posted.

It should be SmartSetupEx(); not LoadSMART();, I believe.

Try it.

o rly?
In Nava2's thread, he put function LoadSMART() into the new SMART.scar...
I guess SMARTSetupEX() would sill work though.