SRL Archive - SRL Archives

Concerning two randoms and FindNormalRandoms..


EvilChicken!

2008-04-22 10:07:11

FindPlant and Leo. (Gravedigger random.)

// * function FindPlant: Boolean;                  // * by ?

PriSoner has a fairly good FindPlant function in his woodcutter. It needs some minor work, but after that it will work perfectly. My idea was that it could be added to FindNormalRandoms along with another boolean being added to SetupSRL; SolvePlant. By default, SolvePlant should be false, but in the 'setup' part of a script, the user could type in SolvePlant := True and then plant random handling should be included in FindNormalRandoms.

Another thing, I was wondering, how the progress is with the Leo/Gravedigger solver? Sky Scripter made one not too long ago, but it is still not included in SRL and I haven't heard anything abput the staus yet.

And, the third and last thing. FindNormalRandoms; should be renamed to FNR; Why? Shorter, better sounding, less frustrating to write, short, easy and simple. The question is rather "why not?"

Post your opinions about all of the three things please.

mixster

2008-04-22 10:47:35

SRL is supposed to be backwards compatible, so changing FindNormalRandoms would stuff up literally every RS SRL script ;)
SkyScripter's Leo solver was still in the beta stage I believe and he was asking for people to test it, so as it isn't definately 100% working , it hasn't been added, but probably will be when he gets it thoroughly tested (based on what I know).
However, there seems to be no reason why FindPlant shouldn't be added as long as it works well, so maybe it will be added with credits :)

ZephyrsFury

2008-04-22 10:57:42

FindNormalRandoms should be left as it is. The reason being the current name is a good description of what it does. By changing it to FNR you might confuse anyone thats trying to learn.

As for shortening the name you can do it yourself:

function FNR: Boolean;
begin
Result := FindNormalRandoms;
end;

or


var
FNR: function : Boolean;
begin
FNR := @FindNormalRandoms;
end.

EvilChicken!

2008-04-22 11:54:56

Zeph, no offence - but how little do you think I know?

{*******************************************************************************
procedure FNR;
By: EvilChicken!
Description: Shortened FindNormalRandoms and made more effective!
Removed FindMod, FindTalk, Respond and more.
*******************************************************************************}
procedure FNR;
begin
if not LoggedIn then Exit;
SolveNonTalkingRandoms;
FindDead;
FindLamp('Agility');
if FindBox then SolveBox;
end;

This is my procedure for my G.A.R. script which I'm gonna release. Yes, it does not have FindTalk ect. But, focus on the name. Look how short and simple the name is.

SKy Scripter

2008-04-22 15:28:00

As for Leo..
It's not completely working 100% so wizzup is working on it… (I hope).

EvilChicken!

2008-04-23 00:45:28

Thanks for your reply, Sky.
Anyone got any comments on the other points?

EvilChicken!

2008-04-23 08:43:56

Sorry for double post, but I have to.

What about FindNormalRandoms(Members: Boolean);? FindNormalRanoms(True); would include members randoms checkers like Findplant.

And, the second thing: What's wrong with SRL's pinball solver? Why hasn't it been fixed?

ZephyrsFury

2008-04-23 08:54:46

From: EvilChicken!
Zeph, no offence - but how little do you think I know?


Hmm I'm sorry. I didn't mean to put you down. :redface:

And with that members boolean. It would mean that the user would need to change it based on whether or not they're in a members world. That could get annoying if you have to change it everytime you swap worlds.

EvilChicken!

2008-04-23 08:59:44

And how many scripts are used for BOTH members and non-members world?

And, a single const at the start of the script can fix that IF you're constantly switching between using the script in a members world/F2P world..

ZephyrsFury

2008-04-23 09:22:40

From: EvilChicken!
And how many scripts are used for BOTH members and non-members world?

And, a single const at the start of the script can fix that IF you're constantly switching between using the script in a members world/F2P world..


A lot of scripts can be used for both types of worlds. Basically any script that works in a free world could be used in a member world if the user thinks they'll have less people bothering them or if they can use members only items.

EvilChicken!

2008-04-23 09:39:01

Still, one const can fix it all.


const
MembersWorld = True;

begin
FindNormalRandoms(MembersWorld);
end.

Sir R. M8gic1an

2008-04-23 09:42:29

i don't think there are as many member randoms solvers and we haven't even solved all non member ones. best would probably be to add a Const like


SolveMemb = True;

//then in FindNormalRandoms;

if SolveMemb then
begin
....blablabla
end;

and leave the name as it is, if it's too much of a hassle to write it out just do it like you did. change the name and all of a sudden you'll have to update ALL scripts. and it's not that long to write. takes you about 2 secs.

but i do agree abou the plant. and Pinball has some sort of error in it, Wizzy posted about it not too long ago.

~RM

Santa_Clause

2008-04-26 11:24:42

From: EvilChicken!
Still, one const can fix it all.


const
MembersWorld = True;

begin
FindNormalRandoms(MembersWorld);
end.


I'm quite sure MembersWorld would have to be a variable not a constant, or else the FindNormalRandoms parameters would have to be:

function FindNormalRandoms(const Members : Boolean) : Boolean;

ZephyrsFury

2008-04-26 11:28:39

The best way to do this would be to just add a variable and set it in SetupSRL.

Timer

2008-05-03 09:12:15

Add SolvePlant: Boolean and the FindPlant: Function In SRL.
Add World Getter Before or After Login.
If SolvePlant Then
If MemberWorld(World_From_Login) Then
SolvePlantEx := True
Else
SolvePlantEx := False;

And In FindNormalRandoms
If SolvePlantEx Then
FindPlant;//Or Whateva..

May That Work?