Screen Blocker

By _Dean_ on Jan 28, 2011

Everytime you're AFK, someone can check your mIRC or can mess with it...

Screen Block can Block your screen from any person

right click on screen, then choose Screen Blocker, set a pass and click Block now

dialog sb {
  title "Screen Blocker"
  size -1 -1 125 81
  option dbu
  text "Clicking on Block now, will Block this screen and only you password can unblock this", 1, 6 37 112 27, disable
  edit "", 2, 6 15 62 10
  text "Set a password:", 3, 6 6 41 8
  button "ok", 4, 70 14 22 12
  button "Block now", 5, 45 66 37 12
  text "A password has been set", 6, 6 26 73 8, hide
  text "You need to set a password first", 7, 6 26 82 8, hide
}

menu channel,status,menubar { 
  Screen Blocker: dialog $iif($dialog(SB), -v, -m sb) sb
}
on *:dialog:sb:sclick:*:{
  if (($did == 4) && ($did(2) != $null)) {
    set %Sblocker $encode($did(2).text,mu)  
    did -h sb 7 | did -v sb 6
  }
  if (($did == 5) && (!%Sblocker)) {
    did -v sb 7
  } 
  if (($did == 5) && (%Sblocker)) {
    set %Sb on
    dialog -x sb
    timer -m 1 1 asb
  }
}

on *:start:{
  if (%Sb == on) {
    var %Squest = $?*="Type the password to unblock"
    if (%Squest != $decode(%Sblocker,mu)) { echo -a 4Invalid password, type again | timerblock -m 1 1 asb }
    else {
      echo -a 12Password accepted 
      set %Sb off
    }
  }
}

alias asb {
  var %Squest = $?*="Type the password to unblock"
  if (%Squest != $decode(%Sblocker,mu)) { echo -a 4Invalid password, type again | timerblock -m 1 1 asb }
  else {
    echo -a 12Password accepted  
    set %Sb off
  }
}

Comments

Sign in to comment.
Stewie1k94   -  Oct 29, 2011

SReject wrote:

Code:
on :START:if (%block:pass) block $?="Please enter the password:"
on
:INPUT::if (%block:pass) block $?="Please enter the password:"
on
:ACTIVE:*:{
if ($active != @Block && %block:pass) {
block $?="Please enter the password:"
}
}

alias Block {
if (%block:pass && $md5($encode($1-,mu)) == %block:pass) {
.treebar %block:treebar
.switchbar %block:switchbar
.menubar %block:menubar
.toolbar %block:toolbar
unset %block:*
close -@ @Block
return
}
if (!%block:Pass) {
set %block:pass $md5($encode($$iif($1-,$1-,$$?="Enter a password:"),mu))
set %block:treebar $iif($treebar,on,off)
set %block:switchbar $iif($switchbar,on,off)
set %block:menubar $iif($menubar,on,off)
set %block:toolbar $iif($toolbar,on,off)
}
if (%block:Pass) {
.treebar off
.switchbar off
.menubar off
.toolbar off
window -ax @Block
halt
}
}
menu @Block {
Unblock: block $?="Please enter the password:"
}Nice work on that

 Respond  
SReject   -  Oct 28, 2011

Yes I did :) I don't use the toolbar so I didn't realize the typo. Thank you

 Respond  
_Dean_   -  Oct 28, 2011
$iif($toobar,on,off)

did you mean: $toolbar

 Respond  
SReject   -  Oct 28, 2011

It's fixed, I bug tested it myself :D

 Respond  
Stewie1k94   -  Oct 28, 2011

It's ok :)

 Respond  
SReject   -  Oct 28, 2011

And I apologize toclafane1, I should of bug tested before posting it.

 Respond  
Stewie1k94   -  Oct 28, 2011

Ty,

 Respond  
SReject   -  Oct 28, 2011

Dean, I posted mine as a comment due to it being of the same idealogy. Hiding wut your mIRC is showing, and keeping others from being able to see it without knowning the password. :)

 Respond  
SReject   -  Oct 28, 2011

Once that's done, restart mIRC. and /menubar on
from there u can enable/disable your other bars (view -> switch|tree|toolbar)

 Respond  
SReject   -  Oct 28, 2011

exit mirc. open vars.ini erase %block, %block:treebar, %block:switchbar, %block:menubar, %block:toolbar

 Respond  
Stewie1k94   -  Oct 28, 2011

How do i get back on now?

 Respond  
Stewie1k94   -  Oct 28, 2011

SReject that f'cked my mIRC up :@

 Respond  
_Dean_   -  Oct 28, 2011

SReject why didnt you post this as script ._.?
since it wasnt a comment to improve the code or alternative methods... its far away from the original code
by the way, someone may say that, using $encode its easy enough to break the pass
i think that $md5 comparation its safer, i didnt think in that when i did the code long time ago

 Respond  
SReject   -  Oct 28, 2011

Window based blocking system:

To use: /block

on *:START:if (%block:pass) block $?="Please enter the password:"
on *:INPUT:*:if (%block:pass) block $?="Please enter the password:"
on *:ACTIVE:*:{
  if ($active != @Block && %block:pass) {
    block $?="Please enter the password:"
  }
}

alias Block {
  if (%block:pass && $md5($encode($1-,mu)) == %block:pass)  {
    .treebar   %block:treebar
    .switchbar %block:switchbar
    .menubar   %block:menubar
    .toolbar   %block:toolbar
    unset %block:*
    close -@ @Block
    return
  }
  if (!%block:Pass) { 
    set %block:pass      $md5($encode($$iif($1-,$1-,$$?="Enter a password:"),mu))
    set %block:treebar   $iif($treebar,on,off)
    set %block:switchbar $iif($switchbar,on,off)
    set %block:menubar   $iif($menubar,on,off)
    set %block:toolbar   $iif($toolbar,on,off)
  }
  if (%block:Pass) {
    .treebar off
    .switchbar off
    .menubar off
    .toolbar off
    window -ax @Block  
    halt
  }
}
menu @Block {
  Unblock: block $?="Please enter the password:"
}

Edited: I fixed the code

 Respond  
Stewie1k94   -  Oct 28, 2011

Oh well, good script anyway :P

 Respond  
_Dean_   -  Oct 28, 2011

you're not, i had an old account here, and i re-posted all my scripts

 Respond  
Stewie1k94   -  Oct 28, 2011

Hmmm, i like it, 6/10 from me, and it looks like i am first one to say something xD

 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.