SRL Archive - OSR Help

Duplicate identifier '' Error


Ian

2012-09-12 16:51:41

Hey guys i'm working on my first script and using Yohojo's video tutorials. I got this error and searched around but all the solutions say that it is already included in SRL but I don't think this is the problem here. Anyway here's the Error:

[Error] C:\Simba\Scripts\Chicken Cooker.simba(27:8): Duplicate identifier '' at line 26
Compiling failed.

And here's the rest of the script

program ChickenCooker;

{$Define smart}
{$i srl/srl.simba}


procedure DeclarePlayers;
begin
HowManyPlayers := 1;
NumberOfPlayers(HowManyPlayers);
CurrentPlayer := 0;

with Players[0] do
begin
Name := ''; // Player username
Pass := ''; // Player password
BoxRewards := ['XP', 'ostume', 'mote', 'oins', 'une', 'ssence'];
LampSkill := Skill_Cooking;
Active := True;
end;
end;


Function GetTheChicken:Boolean;
Var
x, y,: Integer; // This line has the error highlights
begin
//FindObjCustom(x, y, ['att', 'ack'], [123456, 345678], 5);
If FindObjCustom(x, y, ['take', 'Raw', 'Chicken'], [9673643, 9343908, 9212579, 8160399], 10) Then
WriteLn('Chicken Located')
End;





begin
SetupSRL;
DeclarePlayers;
Repeat
GetChicken
Until(false);
end.

Any help is appreciated, Thanks

NKN

2012-09-12 16:56:40

Take the comma out after the y

Nebula

2012-09-12 16:56:42

get rid of the comma before the semicolon

Ian

2012-09-12 17:00:53

Thanks NKN and Nebula! Silly mistake :p