Hello firstly, I'm a real big noob. Im no coder, I know very little.
I used PowerFlop by Aaron126 and ripped it to make this.
All I want it to do is use Mithril bolts (unf) with Feathers. As simple as that
When I try to run I get this error:
[Error] C:\Simba\Scripts\Myattempt.simba(381:4): Identifier expected at line 380
Compiling failed.
BY THE WAY - Line 380 is last line in this script. The 'end.'
SCRIPT:
Program MithBoltFletcher;
{$define SMART8}
{$I SRL-OSR/SRL.Simba}
{$I SRL-OSR/SRL/Misc/SmartGraphics.Simba}
var
WarningInfo: string;
BoltsX, BoltsY, FeathersX, FeathersY, RepeatCount:Integer;
DebugOverride:Boolean;
const
BoltsSlot = 1; // Inventory slot that your Bolts are in (1 through 28)
FeathersSlot = 2; // Inventory slot that your axe is in, 0 if wielding your axe (1 through 28)
Procedure DeclarePlayer;
begin
HowManyPlayers := 1;
NumberOfPlayers(HowManyPlayers);
CurrentPlayer := 0;
Players[0].Name := ''; //Username goes here
Players[0].Pass := ''; //Password goes here
Players[0].Nick := ''; //Character name (excluding first letter)
Players[0].Active := True;
end;
(************************************************* *****************************)
(* END OF COFIGURATION *)
(************************************************* *****************************)
Function ContainsText(CheckText: String; Text: TStringArray): Boolean;
Var
TheText: String;
i, n: Integer;
Begin
TheText := CheckText;
n := High(Text);
For i := 0 to n do
If (Pos(Text[i], TheText) > 0) then
Begin
Result := True;
Exit;
End;
End;
Procedure randomMouseClick(mx,my: Integer);
begin
case random(200) of
1..160: Mouse(RandomRange(mx - 7, mx + 7), RandomRange(my - 7, my + 7), 2, 2, true);
161..190: Mouse(RandomRange(mx - 9, mx + 9), RandomRange(my - 9, my + 9), 2, 2, true);
191..200: Mouse(RandomRange(mx - 12, mx + 12), RandomRange(my - 12, my + 12), 2, 2, true);
end;
end;
Procedure GetFeathersCoords;
begin
FeathersX := 0;
FeathersY := 0;
case (FeathersSlot) of
1:
begin
FeathersX := 575;
FeathersY := 230;
end;
2:
begin
FeathersX := 620;
FeathersY := 230;
end;
3:
begin
FeathersX := 665;
FeathersY := 230;
end;
4:
begin
FeathersX := 710;
FeathersY := 230;
end;
5:
begin
FeathersX := 575;
FeathersY := 265;
end;
6:
begin
FeathersX := 620;
FeathersY := 265;
end;
7:
begin
FeathersX := 665;
FeathersY := 265;
end;
8:
begin
FeathersX := 710;
FeathersY := 265;
end;
9:
begin
FeathersX := 575;
FeathersY := 300;
end;
10:
begin
FeathersX := 620;
FeathersY := 300;
end;
11:
begin
FeathersX := 665;
FeathersY := 300;
end;
12:
begin
FeathersX := 710;
FeathersY := 300;
end;
13:
begin
FeathersX := 575;
FeathersY := 335;
end;
14:
begin
FeathersX := 620;
FeathersY := 335;
end;
15:
begin
FeathersX := 665;
FeathersY := 335;
end;
16:
begin
FeathersX := 710;
FeathersY := 335;
end;
17:
begin
FeathersX := 575;
FeathersY := 370;
end;
18:
begin
FeathersX := 620;
FeathersY := 370;
end;
19:
begin
FeathersX := 665;
FeathersY := 370;
end;
20:
begin
FeathersX := 710;
FeathersY := 370;
end;
21:
begin
FeathersX := 575;
FeathersY := 405;
end;
22:
begin
FeathersX := 620;
FeathersY := 405;
end;
23:
begin
FeathersX := 665;
FeathersY := 405;
end;
24:
begin
FeathersX := 710;
FeathersY := 405;
end;
25:
begin
FeathersX := 575;
FeathersY := 440;
end;
26:
begin
FeathersX := 620;
FeathersY := 440;
end;
27:
begin
FeathersX := 665;
FeathersY := 440;
end;
28:
begin
FeathersX := 710;
FeathersY := 440;
end;
end;
if (BoltsSlot > 28) then
begin
writeln(' FATAL! Invalid Feathers slot specified, must be between 0 and 28!');
TerminateScript;
end;
end;
Procedure GetBoltsCoords;
begin
BoltsX := 0;
BoltsY := 0;
case (BoltsSlot) of
1:
begin
BoltsX := 575;
BoltsY := 230;
end;
2:
begin
BoltsX := 620;
BoltsY := 230;
end;
3:
begin
BoltsX := 665;
BoltsY := 230;
end;
4:
begin
BoltsX := 710;
BoltsY := 230;
end;
5:
begin
BoltsX := 575;
BoltsY := 265;
end;
6:
begin
BoltsX := 620;
BoltsY := 265;
end;
7:
begin
BoltsX := 665;
BoltsY := 265;
end;
8:
begin
BoltsX := 710;
BoltsY := 265;
end;
9:
begin
BoltsX := 575;
BoltsY := 300;
end;
10:
begin
BoltsX := 620;
BoltsY := 300;
end;
11:
begin
BoltsX := 665;
BoltsY := 300;
end;
12:
begin
BoltsX := 710;
BoltsY := 300;
end;
13:
begin
BoltsX := 575;
BoltsY := 335;
end;
14:
begin
BoltsX := 620;
BoltsY := 335;
end;
15:
begin
BoltsX := 665;
BoltsY := 335;
end;
16:
begin
BoltsX := 710;
BoltsY := 335;
end;
17:
begin
BoltsX := 575;
BoltsY := 370;
end;
18:
begin
BoltsX := 620;
BoltsY := 370;
end;
19:
begin
BoltsX := 665;
BoltsY := 370;
end;
20:
begin
BoltsX := 710;
BoltsY := 370;
end;
21:
begin
BoltsX := 575;
BoltsY := 405;
end;
22:
begin
BoltsX := 620;
BoltsY := 405;
end;
23:
begin
BoltsX := 665;
BoltsY := 405;
end;
24:
begin
BoltsX := 710;
BoltsY := 405;
end;
25:
begin
BoltsX := 575;
BoltsY := 440;
end;
26:
begin
BoltsX := 620;
BoltsY := 440;
end;
27:
begin
BoltsX := 665;
BoltsY := 440;
end;
28:
begin
BoltsX := 710;
BoltsY := 440;
end;
end;
if (BoltsSlot > 28) then
begin
writeln(' FATAL! Invalid Bolt slot specified, must be between 0 and 28!');
TerminateScript;
end;
end;
Procedure Fletch;
begin
GameTab(Tab_Inv);
mmouse(BoltsX, BoltsY, 5, 5);
Clickmouse2(mouse_left);
repeat
mmouse(FeathersX, FeathersY, 5, 5);
Clickmouse2(mouse_left);
Begin
DeclarePlayer;
SetupSRL;
GetBoltsCoords;
GetFeathersCoords;
SetBrightness(4);
ClearDebug;
end.
Its properly all wrong anyway![]()



Reply With Quote







