SRL Archive - Help and Support

Am i missing something?


XcanadamanX

2007-12-02 15:09:30

if getting this error: Line 960: [Error] (16124:42): Type mismatch in script
i donno why..can someone figure it out please! here's the part
     if FindDtm(Ring,x,y,MSX1,MSY1,MSX2,MSY2) then //line 960
begin
Mouse(x,y,4,4,true)
NoRing:=False;
end else

Harry

2007-12-02 15:10:51

Did you forget a begin/end near line 960 ? That sometimes triggers that error.

XcanadamanX

2007-12-02 15:12:04

a type mismatch? i dont think so…ill check again
edit:nope begin/ends are fine

Method

2007-12-02 15:15:33

Is Ring declared as an Integer?

XcanadamanX

2007-12-02 15:17:53

yepp

Method

2007-12-02 15:19:27

Can you post the procedure/function it's in? It could be a line above or below it.

XcanadamanX

2007-12-02 15:26:22

   if(UseRing) then
if (NoRing) then
if (Players[CurrentPlayer].strings[0]='Iron') then
begin
if FindDtm(Ring,x,y,MSX1,MSY1,MSX2,MSY2) then
begin
Mouse(x,y,4,4,true)
NoRing:=False;
end else
begin

theres somemore

XcanadamanX

2007-12-03 18:00:37

sorry for the double post but i still dont have an answer
heres the whole proc
Procedure WithdrawOres(option1,option2:string;amount1,amount2,rock1,rock2:integer;Ring:boolean);
Begin
if (not(Loggedin)) then exit;
if rock2=0 then
begin
if FindDTM(rock1,x,y,MSX1,MSY1,MSX2,MSY2) then
begin
Mouse(x,y,3,3,false)
repeat
wait(10)
Until(ChooseOption('All'))
end else
Begin
Writeln('Didnt Find Ores...Logging Out')
closebank;
closebank;
Logout2;
exit;
end;
end else
begin
if FindDTM(rock1,x,y,MSX1,MSY1,MSX2,MSY2) then
Begin
repeat
Mouse(x,y,3,3,false)
wait(10)
Until(ChooseOption(option1))
if option1='X' then
begin
if FindT then
TypeSend(inttostr(amount1))
end;
If FindDTM(Rock2,x,y,MSX1,MSY1,MSX2,MSY2) then
Begin
repeat
Mouse(x,y,3,3,false)
wait(10)
Until(ChooseOption(option2))
if option2='X' then
begin
if FindT then
TypeSend(inttostr(amount2))
end;
end else
Begin
Writeln('Didnt Find Ores...Logging Out')
closebank;
closebank;
Logout2;
exit;
end;
end else
Begin
Writeln('Didnt Find Ores...Logging Out')
closebank;
closebank;
Logout2;
exit;
end;
if (NoMould) then
if ((Players[CurrentPlayer].strings[0]='or-ball') or
(Players[CurrentPlayer].strings[0]='st-ball')) then
if FindDtm(mould,x,y,MSX1,MSY1,MSX2,MSY2) then
begin
Mouse(x,y,4,4,true)
NoMould:=False;
end else
begin
Writeln('Didnt Find Mould...')
closebank;
closebank;
Logout2;
exit;
end;
if(UseRing) then
if (NoRing) then
if lowercase(Players[CurrentPlayer].strings[0]) = 'iron' then
begin
if FindDtm(Ring,x,y,MSX1,MSY1,MSX2,MSY2) then//heres the screw up. on the MSY2
begin
Mouse(x,y,4,4,true)
NoRing:=False;
end else
begin
Writeln('Didnt Find Mould...')
closebank;
closebank;
Logout2;
exit;
end;
end;
end;
end;

Macrosoft

2007-12-03 18:25:51

hmmm, type mismatches are misuses of types. Did you declare x and y as integers?

check all your types

XcanadamanX

2007-12-03 18:33:44

it worked fine until i put this in vv
   if(UseRing) then
if (NoRing) then
if lowercase(Players[CurrentPlayer].strings[0]) = 'iron' then
begin
if FindDtm(Ring,x,y,MSX1,MSY1,MSX2,MSY2) then//heres the screw up. on the MSY2
begin
Mouse(x,y,4,4,true)
NoRing:=False;
end else
begin
Writeln('Didnt Find Mould...')
closebank;
closebank;
Logout2;
exit;
end;
end;

Method

2007-12-03 19:35:05

You have Ring as one of the arguments for the function, and also as a DTM. Change the name of one and that should fix your problems.

XcanadamanX

2007-12-03 19:36:58

man i knew it was something simple. thanks Method!

edit: Yep Fixed!! thanks alot

R0b0t1

2007-12-03 20:27:01

Good luck.


But I'm really posting 'cause I lost the game. I'm serious this time. Its haunting me.

XcanadamanX

2007-12-03 22:02:22

uhh spam much…