SRL Archive - Development

Simba Account Manager


Rick

2011-08-28 20:31:38

I've been working on making an account manager which is integrated into Simba.

I'm not sure where to start, so here's a picture:


This adds a new option to the Tools menu. Tools -> Account Manager

When clicked it will ask you for a key. This is used to encrypt and decrypt the passwords of the accounts (uses rijndael). Make sure you remember this.

All account info is stored in 'accounts.xml' in the same directory as Simba's executable.

Heres an example of how to load the accounts into SRL's Player Array:

program AccountManagerTest;
{$I SRL\SRL.scar}

const
SALT = 'salt'; // Salt used to encrypt/decrypt passwords

procedure DeclarePlayersAccountManager(Salt: String);
var
p: T2DStringArray;
i: Integer;
begin
p := LoadAccounts(Salt);

HowManyPlayers := Length(p);
NumberOfPlayers(HowManyPlayers);
CurrentPlayer := 0;

for i := 0 to High(p) do
begin
with Players[i] do
begin
Name := p[i][0];
Pass := p[i][1];
Nick := p[i][2];
Pin := p[i][3];
Member := StrToBool(p[i][4]);
Active := StrToBool(p[i][5]);
end;
end;
end;

begin
SetupSRL;
DeclarePlayersAccountManager(SALT);
end.

The replacement executable file can be downloaded here: http://www.sendspace.com/file/2bci4x

For those of you who wish to look at the source code or compile it yourself: https://github.com/bentzilla/Simba/tree/AccountManager

Feedback and suggestions would be appreciated :)

MylesMadness

2011-08-28 20:34:22

I feel like this as an extension would make more sense?

Rick

2011-08-28 20:59:20

From: MylesMadness
I feel like this as an extension would make more sense?


I felt like it was more suited to be integrated into Simba, just like a script manager would be, but I'd like to hear why you think that. Communicating between extension and script isn't directly possible, so I think file manipulation and encryption is easier to handle this way.

Coh3n

2011-08-28 21:06:12

From: Rick
I felt like it was more suited to be integrated into Simba, just like a script manager would be, but I'd like to hear why you think that. Communicating between extension and script isn't directly possible, so I think file manipulation and encryption is easier to handle this way.
Because Simba isn't meant just for RS, so it would make a lot more sense as an extension. Also, the SRL Player Remote uses INI files to communicate with scripts and it works quite well and would be extremely simple for this tool as it would only be used when the script starts.

I love the idea though. :)

Wizzup?

2011-08-29 05:57:15

I'm not particularly against including it in Simba, tbh. But it could perhaps live in a separate branch. We'll have to think about how to include this.

Good work! :)

Jakkle

2011-08-29 10:48:48

I was thinking about, something like this is needed, grate work :)

Nava2

2011-08-29 14:02:26

Love the use of password encryption. Very nicely done. :) Especially using a SALT. :D

Wizzup?

2011-08-29 14:23:37

Granted Simba Developer/Maintainer/Casual contributor rank. :)

Nava2

2011-08-29 16:21:47

This is excellent, I would suggest getting the password TEdits to use the password chars though. I do not remember how to do it off the top of my head, though.

Rick

2011-08-29 17:23:06

From: Nava2
This is excellent, I would suggest getting the password TEdits to use the password chars though. I do not remember how to do it off the top of my head, though.


If you mean '*', then it's already in place. The plain text checkbox turns that on and off.

Thanks for the feedback and the cup :D

Nava2

2011-08-29 18:01:08

From: Rick
If you mean '*', then it's already in place. The plain text checkbox turns that on and off.

Thanks for the feedback and the cup :D


I did! My apologies… Also didn't realise that I posted twice haha.

moparisthebest

2011-08-30 00:07:04

From: Coh3n
Because Simba isn't meant just for RS, so it would make a lot more sense as an extension. Also, the SRL Player Remote uses INI files to communicate with scripts and it works quite well and would be extremely simple for this tool as it would only be used when the script starts.

I love the idea though. :)


I really agree with this, doesn't this make Simba far too RS-specific? Couldn't it be implemented just as well as a plugin? (and then distributed with SRL, or Simba, or whatever?)

Dynamite

2011-08-30 06:52:54

I agree with the above.
Make it an extension.
The abilities will be the same just doesn't make Simba look RS-Specific.

-Boom

i luffs yeww

2011-08-30 07:13:09

I've always been curious as to why we try to make Simba not "RS-specific.."

Sort of on topic, since it's bout whether this should be an extension or not.

Dan Cardin

2011-08-30 12:30:33

You ship a whole bunch of rs specific extensions and such with simba afaik. i guess it makes sense to seperate it but i dont think it makes a huge difference.

footballjds

2011-08-30 17:03:34

lets face it. Simba is RS specific.

sure, its very useful for other things. but its DEFINITELY RS specific.

Coh3n

2011-08-30 19:20:53

From: footballjds
lets face it. Simba is RS specific.

sure, its very useful for other things. but its DEFINITELY RS specific.
Not true. It's primarily used for RS, but it's in no way written for RS. Give me an example of something in Simba that is specifically for RS.

Wizzup?

2011-08-30 19:26:29

Well, Simba has a few RS specific functions, like rs_GetUpText. But really, that's not much of an issue. Not right now anyway. Eventually, (which was something I was thinking about, but in the end I don't think it's good) we could make something like Simba CSE (Community SRL Edition), which would be Simba with some SRL-specific things compiled into it. But Simba's main purpose at this point is to make SRL work and provide a stable macroing base - and it seems like it's pretty good at that. Also, I think some people at Mopar have already used Simba for macroing different games. Someone also rewrote the classic defend your castle macro IIRC.

Any suggestions are welcome. I'm having trouble making my mind up. (Not that's it's just my decision anyway). Perhaps we should just go with what feels alright. I mean, if we later on decide we don't want/need it anymore for whatever reason, it shouldn't be too hard to remove it?

i luffs yeww

2011-08-30 19:38:38

I don't see the harm in trying it out. For one, I would like to be able see some rs-specific code in Pascal and possibly speed some stuff up. I know Lape is in the works as well, but there's some functionality Pascal has that PS doesn't, which could be useful (pointers and what not).

Really doesn't make an awful big difference, I was just curious as I can't think of a reason to keep it rs-independent. It would still have all of the features it already has, so it wouldn't take away from the ability to code for non-rs things (which is definitely something to keep, but we wouldn't take that ability away).

Coh3n

2011-08-30 20:17:01

From: i luffs yeww
I don't see the harm in trying it out. For one, I would like to be able see some rs-specific code in Pascal and possibly speed some stuff up. I know Lape is in the works as well, but there's some functionality Pascal has that PS doesn't, which could be useful (pointers and what not).

Really doesn't make an awful big difference, I was just curious as I can't think of a reason to keep it rs-independent. It would still have all of the features it already has, so it wouldn't take away from the ability to code for non-rs things (which is definitely something to keep, but we wouldn't take that ability away).
In this case I don't think there are any advantages to have this included in Simba? Honestly I think it would be better to be included in the srl.sex updater.

footballjds

2011-08-31 11:07:41

From: Coh3n
Not true. It's primarily used for RS, but it's in no way written for RS. Give me an example of something in Simba that is specifically for RS.


From: Wizzup?
Well, Simba has a few RS specific functions, like rs_GetUpText. But really, that's not much of an issue…


you asked for "an" example.

Wizzup?

2011-08-31 11:10:45

From: footballjds
you asked for "an" example.


Can you please just get out of this thread? You're taking this to a next facepalm level.

footballjds

2011-08-31 11:15:25

From: Wizzup?
Can you please just get out of this thread? You're taking this to a next facepalm level.


Sorry, But he asked me to do something.
I'll try to help less around here… :P[ObviousSarcasmObvious]

BraK

2011-08-31 12:33:45

I actually use Simba for Ragnorok Online right now. Made an Auto feeder for my pet so it can keep fighting. :) I also made so stuff for Aika Global. Really it's kinda fun developing things for different games. I really just get lazy after awhile playing them. I'm reworking the Player form and was planing to having the data for all scripts stored in the same file using the Script ID as a key to finding specific data.

~BraK

i luffs yeww

2011-08-31 14:42:47

From: Coh3n
In this case I don't think there are any advantages to have this included in Simba? Honestly I think it would be better to be included in the srl.sex updater.


The advantages may be slim, and I really don't care either way, but I've just been curious is all.

This thread has strayed too far, my apologies, Rick.

New thread here.

Wizzup?

2011-10-28 10:35:57

So what are we going to do with this?

Dynamite

2011-10-28 13:28:39

I think anything is better than nothing, I don't see why this hasn't been used in the meantime?
Especially now that java bots have been stopped for a while we need to improve ease of use, this will be a step forward no matter how it is integrated.

-Boom

Mark

2011-10-28 13:59:02

From: Dynamite
I think anything is better than nothing, I don't see why this hasn't been used in the meantime?
Especially now that java bots have been stopped for a while we need to improve ease of use, this will be a step forward no matter how it is integrated.

-Boom


I also agree with you. have thought about this afew times
And like you say it can be removed

Coh3n

2011-10-28 15:00:37

Eh it's tough unless we can somehow have EVERY script use it. I think it would just be confusing if some scripts use this and some don't. Also, it would work to store just the player's information, but most scripts have other settings such as how long to run or how many loads to do for each player.

Sex

2011-10-28 15:54:54

From: Coh3n
Eh it's tough unless we can somehow have EVERY script use it. I think it would just be confusing if some scripts use this and some don't. Also, it would work to store just the player's information, but most scripts have other settings such as how long to run or how many loads to do for each player.

Yeah, this should not be added until custom fields/checkboxes are supported (much like the SRL player form).