Seriously..? Uptext isn't working
I was working on my script and it can't recognize uptext. Is there any way to make my own function? I really need this!
Seriously..? Uptext isn't working
I was working on my script and it can't recognize uptext. Is there any way to make my own function? I really need this!
Are you running SCAR 3.23 BETA (better known as scarprerelease)?
yup, used SVN. Have latest SRL Dev too. I don't know what's wrong:
SCAR Code:program new;
{.Include SRL\SRL\Misc\SMART.SCAR}
{.include srl/srl.scar}
Var
x, y: Integer;
Lobster: Integer;
procedure DeclarePlayers;
begin
HowManyPlayers := 1;
NumberOfPlayers(HowManyPlayers);
CurrentPlayer := 0;
with Players[0] do
begin
Players[0].BoxRewards := ['Xp', 'mote', 'ostume', 'oins', 'aphire', 'ssence'];
Name := ' ';
Pass := ' ';
Nick := ' ';
Active := True;
Pin := '';
Integers[0] := 1000;{Inventories without logging out?}
Strings[1] := 'lobster';{What do you want to fish? Look to the top of the script}
Booleans[1] := False; {Drop?}
end;
end;
procedure AntiBan;
var
Z: Integer;
begin
Z:= 1+random(20);
case Random(140) of
0: MMouse(x, y, 50+random(6), 50+random(3));
1: PickUpMouse;
2: if (Z = 10) then HoverSkill('fishing', false) else RandomMovement;
end;
end;
procedure AntiRandoms;
var
Z: Integer;
R: String;
begin
Z:= 1+random(20);
case Random(50) of
0: R:= 'Fishing';
1: R:= 'Mining';
2: R:= 'Woodcutting';
3: R:= 'Crafting';
4: if (Z = 10) then R:= 'Fishing' else R:= 'Cooking';
end;
FindNormalRandoms;
LampSkill := R;
end;
procedure LoadItemBitmaps;
begin
Lobster:= BitmapFromString(5, 7, 'beNozlo43l023VuDj5S1wUCp' +
'3VU20kANygWygSKWbGpwLlAKKJFvKw7n1nuoQrpuGKARBuEBlENTs' +
'rcHAwOStLR6kLxkBANHVFdw=');
end;
function FindFish: Boolean;
begin
GameTab(tab_Inv);
if FindBitmapToleranceIn(Lobster, x, y, MIX1, MIY1, MIX2, MIY2, 7) then
begin
Writeln('Found Lobster!');
MMouse(x, y, 5, 5);
if IsUpText('Lobster') then
begin
wait(100+random(450));
Mouse(x, y, 0, 0, False);
wait(100+random(250));
ChooseOption('rop');
Result := True;
end else
Writeln('Wrong object? Could not find uptext of object.');
end else
Writeln('Couldn''t find lobster.');
FreeBitmap(Lobster);
end;
begin
Smart_Server := 91;// |Edit to which world you want.
Smart_Members := True;// |do not touch
Smart_Signed := True;// |do not touch
Smart_SuperDetail := False;// |do not touch
ClearDebug;
SetUpSRL;
DeclarePlayers;
LoginPlayer;
LoadItemBitmaps;
if FindFish then Writeln('Yippie!');//testing lobster finding
end.
I also tried 'obste', 'aw lobst' , 'Raw Lob'
Hmm.. Edit "Writeln('Wrong object? Could not find uptext of object.');" to "Writeln('Wrong object? Could not find uptext of object. UPTEXT: ' + GetUpText);" and tell me what the debug box says
SCAR Code:Found Lobster!//hovers over raw lobster
Wrong object? Could not find uptext of object. UPTEXT:
Delete scar.exe and then update your scarprerelease folder.. Tell me how that goes! ^^
SCAR Code:Found Lobster!
Wrong object? Could not find uptext of object. UPTEXT:
I re-installed the whole SCAR folder and it still gives me the same results![]()
Are you using Dev or Public SVN? If public use dev,
Code:http://www.villavu.com/repositories/srl-opendev
MMouse(x, y, 5, 5);
Wait(250 + Random(100)); //Important.
if (IsUpTextMultiCustom(['aw L', 'Lob', 'obster', 'bste'])) then
Last edited by Wanted; 01-30-2010 at 04:31 PM.
IceFire- THANK YOU
Last edited by DeSnob; 01-30-2010 at 04:36 PM.
Just remember the wait between MMouse and uptext, the game doesn't respond instantly.
What I think also is possible, is you were searching for 'lobster' when the uptext, which would return false, because it would read 'Lobster' which is why you see many scripts use 'obster' instead of 'lobster' or 'Lobster'
There are currently 1 users browsing this thread. (0 members and 1 guests)