SRL Archive - OSR Help

Invalid number of parameters for smart, does anyone have a smart file I can have?


rj

2013-04-12 19:15:30

Hey, I wanted to change my SMART from 07 to EOC so i just updated SRL so it would overide the smart params for 07. Now when I try to run, I get invalid number of parameters at line 281 :s

The params look right for EOC?

function GetSmartParams: TStringArray;
var
Params: TStringArray;
Page: String;
begin
Page := Between('<iframe id="game" src="', '"', GetPage('http://www.runescape.com/game.ws?j=1'));
Params := Explode(',', Page);
Result := Params;
end;


Can someone else upload their smart include file, I think when i used the 07 auto installer it messed with some other smart params CBA to figure out

Haxz

2013-04-12 19:23:06

Remove the -1 at line 294?

Result := SmartSpawnClient(ReplaceWrap(PluginPath, '\', '/', [rfReplaceAll]), Params[0], ',' + Params[1], 765, 553, 's', '', '', -1);

Sjoe

2013-04-12 19:23:23

Just re-install?

rj

2013-04-12 19:26:36

From: Haxz
Remove the -1 at line 294?

Result := SmartSpawnClient(ReplaceWrap(PluginPath, '\', '/', [rfReplaceAll]), Params[0], ',' + Params[1], 765, 553, 's', '', '', -1);


that worked, you sir get += 7 rep

Haxz

2013-04-12 19:28:44

Not sure why but devs should update the SmartParams, like they did to OSR-SRL include. Since nobody using Smart 7.2 anymore :p

Itankbots

2013-04-12 23:11:49

From: Haxz
Not sure why but devs should update the SmartParams, like they did to OSR-SRL include. Since nobody using Smart 7.2 anymore :p


Im 99% sure it is updated for Smart8 Already, only need to remove the -1 if you running an older version. Unless they downgraded for OSRS? Idk , but last i checked that problem was only for 7.2 and older

Haxz

2013-04-13 01:59:09

From: Itankbots
Im 99% sure it is updated for Smart8 Already, only need to remove the -1 if you running an older version. Unless they downgraded for OSRS? Idk , but last i checked that problem was only for 7.2 and older


You need to remove the -1 if you're using Smart 8 as well. Try force update your SRL, I believe you will encounter the error again.

In OSR-SRL smartparams, its already excluded, looks like this
  //Removal of Smart 7.2?
//{$IFDEF SMART8}
Result := SmartSpawnClient(ReplaceWrap(PluginPath, '\', '/', [rfReplaceAll]), 'http://oldschool' + World + '.runescape.com/', 'j1', 765, 503, '', '', '');
//{$ELSE}
//Result := SmartSpawnClient(ReplaceWrap(PluginPath, '\', '/', [rfReplaceAll]), Params[0], ',' + Params[1], 765, 553, 's', '', '');
//{$ENDIF}

In SRL5…

{$IFDEF SMART8}
Result := SmartSpawnClient(ReplaceWrap(PluginPath, '\', '/', [rfReplaceAll]), Params[0], ',' + Params[1], 765, 553, 's', '', '');
{$ELSE}
Result := SmartSpawnClient(ReplaceWrap(PluginPath, '\', '/', [rfReplaceAll]), Params[0], ',' + Params[1], 765, 553, 's', '', '', -1);
{$ENDIF}

Itankbots

2013-04-13 02:05:44

Smart8 Needs the -1 . Ive forced updated everything to check before i even posted, And it auto updates, last time i got that error was when i ran Smart7.2

The -1 has to do with the the NavBar at the top of runescape i believe. Which OSRS does NOT have, which is why its commented out.

Either way doesn't matter, you guys got it working for you and thats all that matters.

Haxz

2013-04-13 02:26:48

Please note that I'm not trying to start an argument or fight, just trying to get my doubts cleared.


{$IFDEF SMART8}
Result := SmartSpawnClient(ReplaceWrap(PluginPath, '\', '/', [rfReplaceAll]), Params[0], ',' + Params[1], 765, 553, 's', '', '');
{$ELSE}
Result := SmartSpawnClient(ReplaceWrap(PluginPath, '\', '/', [rfReplaceAll]), Params[0], ',' + Params[1], 765, 553, 's', '', '', -1);
{$ENDIF}
If define Smart8, then no -1. If not define Smart8, then -1. But you say Smart8 needs -1. You commented out the -1 on OSRS because of no NavBar, but you commented it out on EOC too to make it able to compile.

rj

2013-04-13 10:45:51

From: Haxz
Please note that I'm not trying to start an argument or fight, just trying to get my doubts cleared.


{$IFDEF SMART8}
Result := SmartSpawnClient(ReplaceWrap(PluginPath, '\', '/', [rfReplaceAll]), Params[0], ',' + Params[1], 765, 553, 's', '', '');
{$ELSE}
Result := SmartSpawnClient(ReplaceWrap(PluginPath, '\', '/', [rfReplaceAll]), Params[0], ',' + Params[1], 765, 553, 's', '', '', -1);
{$ENDIF}
If define Smart8, then no -1. If not define Smart8, then -1. But you say Smart8 needs -1. You commented out the -1 on OSRS because of no NavBar, but you commented it out on EOC too to make it able to compile.


hmm IDK I can always make my scripts with a 50 y offset