SRL Archive - SRL Suggestions

Login.scar crash define


Harry

2011-11-26 04:37:04

I'm not betting on this being added because "any code that crashes the client is a bug, and we don't intentionally add bugs to SRL".

I disagree with this fact, and it will never execute unless the user WANTS it to execute via a {$DEFINE} in their script.

It's a pain in the butt for us users that use this hack to "bot forever", when the SRL updater overwrites it every time.

http://villavu.com/forum/showthread.php?t=67864

Simple diff of code:
Change (these are not line numbers, but a number in a case):
732: Actions := ['Runescape has been updated.', 0, 0, 'Terminate', 'RS updated'];

To:
732: Actions := ['Runescape has been updated.', 0, 0, 'Updates', 'RS updated'];
and
Change SECTION: case Actions[3] of 

To:
'Terminate': TerminateScript;

'Updates':
begin
{$IFDEF CRASHSMART}
Writeln('You are using CRASHSMART, we are going to reload your client after update!');
SmartgetFieldObject(1488,'crash'); // will crash SMART (and Simba).
// IF THIS DOES NOT CRASH YOUR SIMBA, YOU ARE NOT USING THE PROPER PLUGIN
// AN ACCESS VIOLATION HERE IS NOT THE CRASH - MOVE THE EDITED PLUGIN
Wait(5000);
WriteLn('Something went wrong, you should not be reading this!');
TerminateScript;
Exit;
{$ENDIF}
Writeln('You have no CRASHSMART enabled, so you can not reload RS. Sorry, bye!');
TerminateScript;
end;

I propose this simple change be added as it will not ever execute unless the user explicitly defines it inside their script. If the user does not define it, the update crash is just as normal as before.

Thanks!

Wyn

2011-11-26 22:26:51

Commit. Like now. Seriously…Now.

Harry

2011-11-28 00:56:52

Bump.

Gu3st...

2011-11-28 06:44:42

Instead of doing this, I propose we add srl_OnRSUpdate to the srl_Procs array, then call that procedure instead of terminating when RS updates

Coh3n

2011-11-28 21:23:06

From: Zyt3x
Instead of doing this, I propose we add srl_OnRSUpdate to the srl_Procs array, then call that procedure instead of terminating when RS updates
I like that also. That would mean Harry's fix would have to be applied to scripts, though, which I don't think is a big deal.

Harry

2011-11-29 04:49:34

From: Zyt3x
Instead of doing this, I propose we add srl_OnRSUpdate to the srl_Procs array, then call that procedure instead of terminating when RS updates

That's not that bad of an idea. I personally prefer my method, but your is more "standardized", I guess.

Coh3n

2011-11-29 19:58:47

Committed this. The srl_OnRSUpdate is a good idea, and should probably be added for SRL 5.