flakes / mirc_fish_10

"FiSH 10" - a blowfish encryption script for mIRC 7, compatible to previous FiSH scripts and other clients! Come visit us in #fish10 on EFNet!
https://syndicode.org/fish_10/
86 stars 17 forks source link

Request: save all FiSh related settings (variables) within mIRC? #13

Closed Anti-You closed 14 years ago

Anti-You commented 14 years ago

Hi flakes,

regarding FiSh.mrc: I am trying to optimize & update the FiSh.mrc + making a little Gui for FiSh.

After some time I realized, that some variables are saved within mIRC (i.e. " set %mark_outgoing [On] " ), others instead are saved within the blow.ini-file (i.e. " writeini -n %blow_ini FiSH plain_prefix $1- ". Does this have a particular reason?

Ok, not bad at all, but what I am trying to do is following:

I elaborated following workaround, if the "mark_encrypted"-variable has to stay in the blow.ini-file: If you want to edit the variable within mIRC, use following command: writeini -n %blow.ini FiSH mark_encrypted $chr(34) $+ $!chr(2) $!+ $!chr(3) $!+ 12 · $!+ $!chr(3) $!+ $!chr(2) $+ $chr(34)

output in blow.ini would be: mark_encrypted="$chr(2) $+ $chr(3) $+ 12 · $+ $chr(3) $+ $chr(2)"

If you want then to evaluate this variable, just use Evaluation brackets (http://script.quakenet.org/wiki/Evaluation_brackets), i.e. var %mark = [ [ $readini(%blow.ini,n,FiSH,mark_encrypted) ] ]

This method works fine with Crypt-Mark (Outgoing), but does not work so far with Crypt-Mark (Incoming). The last one would need a modified .dll I guess.

Solution #2

But I think the better solution would be as following: Just save this variable (and all others except the keys) within mIRC, using i.e. " /set %mark_encrypted ". Because writing Color codes with set-command is absolutely possible.

What do you think? Is there really an important reason to leave those settings in the blow.ini-file?

After all, many thanks for your work. Your work is highly appreciated :-).

Kind regards,

flakes commented 14 years ago

The DLL can not read "set" things, but it needs to read mark_encrypted. I never realized that was a permanent storage, too.

Anyway, I could add some code to the DLL that interprets $chr(2) etc. in mark_encrypted. Do you want me to do that?

Anti-You commented 14 years ago

"The DLL can not read "set" things" <--- are you sure? Because those variables get also stored in an .ini file: mIRC: /scripts/vars.ini (should be located in AppData) or nnScript: /scripts/vars.nns (it's just a renamed .ini)

If not possible: are there any other variables, which need to stay in the blow.ini-file then (mark_encrypted, plain_prefix)? Just for further coding purpose on my side.

"I could add some code to the DLL that interprets $chr(2) etc" <--- if possible, yes please :). That would be nice.

Anti-You commented 14 years ago

Additionally: "I could add some code to the DLL that interprets $chr(2) etc" <--- I guess, most important $chr's should be following:

$chr(3) color, $chr(2) bold, $chr(31) underline, $chr(9) italics, $chr(15) turns off all previous attributes, including color, bold, underline, and italics.

See also: http://www.mirc.com/help/colors.html

flakes commented 14 years ago

Added $chr(N) and $+ parser in 1e9e5baf02034d6b26e15304b871c1bbaaac70fe ... not sure when I'm going to upload a new DLL with it. If you need it soon, just let me know.

Anti-You commented 14 years ago

Cool, thank you for your work :).