mIRC Home    About    Download    Register    News    Help

Print Thread
mIRC lock password #20123 19/04/03 08:53 PM
Joined: Dec 2002
Posts: 15
C
CrAsh0v3r Offline OP
Pikka bird
OP Offline
Pikka bird
C
Joined: Dec 2002
Posts: 15
can somebody tell me how's the mirc lock password script ?
i want to set a password on something... confused


Mess With The Best & Die Like The Rest !!!
Re: mIRC lock password #20124 19/04/03 11:15 PM
Joined: Mar 2003
Posts: 272
C
c0ldfusi0n Offline
Fjord artisan
Offline
Fjord artisan
C
Joined: Mar 2003
Posts: 272
Hit ALT+O, scroll down to the "General" item, expand it to find "Lock". Select it, then play with those settings. Remember your password, though.


- cF
Dedicated helper for rent.
Re: mIRC lock password #20125 19/04/03 11:27 PM
Joined: Dec 2002
Posts: 15
C
CrAsh0v3r Offline OP
Pikka bird
OP Offline
Pikka bird
C
Joined: Dec 2002
Posts: 15
that's not what i was asking for. well, i will explain again. I need to know who is the mirc lock pass script. because i want to set a pass on a script that i made. the script was designed that when you open mirc to ask for you nickname and then after you type the nick in the box, the script draws something cool and some text in a window and after timer 1 4 -@ and change your nickname as you typed it in the box.
i want to remove that thing with the nickname and make it act like a password. so that means when i type the wrong pass to draw that text and say wrong password bye !! and then exit mirc.


Mess With The Best & Die Like The Rest !!!
Re: mIRC lock password #20126 19/04/03 11:54 PM
Joined: Jan 2003
Posts: 96
J
Jesper Offline
Babel fish
Offline
Babel fish
J
Joined: Jan 2003
Posts: 96
Ok first you have to set a password, either a %var or in an ini file.
this example uses an ini file, in $mircdir named password.ini.

Code:
on *:load: { writeini password.ini passsection password1 $$?="-=ENTER REAL PASS=-" }

on *:start: {
  if (%passfail == on) { unset %passfail }
  writeini password.ini passsection password2 $$?="-=ENTER PASS=-" 
  var %pass1 $readini(password.ini,passsection,password1)
  var %pass2 $readini(password.ini,passsection,password2)
  if (%pass1 === %pass2) { return }
  else { set %passfail on }
}

on *:CONNECT: {
  if (%passfail == on) { echo -a INTRUDER | quit }
}


3x === means its case sensitive
sure you can hide the passwords in any ini file
its rather useless as people will just look in the script to see where your password is stored
Oh and script is untested, so maybe it works, maybe it dont wink

Re: mIRC lock password #20127 20/04/03 03:11 PM
Joined: Dec 2002
Posts: 15
C
CrAsh0v3r Offline OP
Pikka bird
OP Offline
Pikka bird
C
Joined: Dec 2002
Posts: 15
okay that's working, but what's happening when he clicks on OK or CANCEL ? because you didnt write that there... and it's still connecting...


Mess With The Best & Die Like The Rest !!!
Re: mIRC lock password #20128 20/04/03 08:22 PM
Joined: Feb 2003
Posts: 76
G
gerdigos Offline
Babel fish
Offline
Babel fish
G
Joined: Feb 2003
Posts: 76
Store $$?="-=ENTER PASS=-" in a variable and use an if to determine if there is a value in it. If not, exit.

Oh, and i think you should use /exit instead of /quit there.
Hope i helped! smirk

Re: mIRC lock password #20129 21/04/03 09:18 PM
Joined: Jan 2003
Posts: 96
J
Jesper Offline
Babel fish
Offline
Babel fish
J
Joined: Jan 2003
Posts: 96
but it should connect, then it will check if the pass entered is wrong by comparing the var it sets with the one stored in the ini file., if they dont match up, then it "should" disconnect from the server youre trying to connect to... doesnt it do that?

OK/Cancel shouldnt matter unless the var isnt set when you press cancel, but thats quickly fixed:
Code:
on *:CONNECT: {  
   if (%passfail == on) || (%passfail == $null) { echo -a INTRUDER | quit }
}

Maybe that will do it smile