Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Away System
#1
  • This addon is to help you to save your away message as for some users who use mIRC got this problem while he cant save his away message also it has a bit functions that u will like it .. i just found it by luck on a forum and i saw it really nice so i thought its a good idea to share to you all Big Grin

How to load the addon on your mIRC script
  • 1- Go on Tools on the MenuBar - Script Editor - Remote - File - New then copy the code down and paste it there then press Ok.

    2- Download the Away System.mrc down, Put it on the mirc folder and go on Tools on the MenuBar - Script Editor --- > Remote - File  - Load and then choose the place of the Away System.mrc and then press Open then Ok

Code

Code:
dialog asy {
  title "Away System"
  size -1 -1 172 159
  option dbu
  box "Set Away Nick", 1, 1 1 57 34
  edit "", 2, 4 12 50 9, autohs
  button "Set", 3, 5 23 20 9, flat
  button "Unset", 4, 34 23 20 9, flat
  box "Set Back Nick", 5, 62 1 57 34
  edit "", 6, 65 12 50 9, autohs
  button "Set", 7, 65 23 20 9, flat
  button "Unset", 8, 95 23 20 9, flat
  box "Add/Del Away Reason", 9, 1 36 118 35
  edit "", 10, 4 45 111 9, autohs
  button "Add", 11, 4 56 54 10, flat
  button "Del", 12, 61 56 54 10, flat
  box "Auto Away", 13, 121 1 50 70
  radio "None", 14, 124 12 25 10, flat
  radio "30 Minutes", 15, 124 23 37 10, flat
  radio "60 Minutes", 16, 124 34 37 10, flat
  radio "90 Minutes", 17, 124 45 37 10, flat
  radio "120 Minutes", 18, 124 56 40 10, flat
  box "Reason List", 19, 1 72 170 60
  list 20, 4 81 163 46, size vsbar
  box " Away/Back", 21, 1 133 61 25
  button "Away", 22, 4 143 25 10, flat
  button "Back", 23, 34 143 25 10, flat
  box "Highlite Notice", 24, 64 133 43 25
  check "On", 25, 69 143 17 10, flat
  check "Off", 26, 88 143 17 10, flat
  box "Date/Time", 27, 108 133 63 25
  text "", 28, 112 143 55 8
}
menu menubar,channel {
  .Away System { dialog $iif($dialog(asy),-v,-md) asy asy } 
}
alias -l asytime { did -ra asy 28 $time(mm.dd.yy h:nn:ss tt) }
alias -l auto.away.check {
  if ($ceil($calc($nick($active,$me).idle / 60)) == $iif(%t.30,30,$iif(%t.60,60,$iif(%t.90,90,$iif(%t.120,120,))))) && (!$away) {
    amsg 14,1[12,1»0,1:: Idle Away After ::12,1«14,1]14,1[12,1»0,1:: $iif(%t.30,30,$iif(%t.60,60,$iif(%t.90,90,$iif(%t.120,120,)))) Minutes ::12,1«14,1]
    .away Idle Away After $iif(%t.30,30,$iif(%t.60,60,$iif(%t.90,90,$iif(%t.120,120,)))) Minutes
    nick %asyanick
  }
}
alias asaway {
  if (!$away && %asyanick && %asybnick) {
    nick %asyanick
    amsg 14,1[12,1»0,1:: I am Now Away ::12,1«14,1]14,1[12,1»0,1::Reason: $1- ::12,1«14,1]14,1[12,1»0,1:: Left At ::12,1«14,1]14,1[12,1»0,1:: $time(h:nn tt) ::12,1«14,1]
    .away $1-
  }
}
alias asaback {
  if ($away && %asyanick && %asybnick) {
    amsg 14,1[12,1»0,1:: I am Now back from ::12,1«14,1]14,1[12,1»0,1::Reason: $awaymsg ::12,1«14,1]14,1[12,1»0,1:: Gone for ::12,1«14,1]14,1[12,1»0,1:: $duration($awaytime) ::12,1«14,1]
    nick %asyanick
    .away
  }
}
on *:load: {
}
on *:DIALOG:asy:close:0:{ .timerasytime off }
on *:DIALOG:asy:init:0:{
  did -a $dname 28 $time(mm.dd.yy h:nn:ss tt)
  .timerasytime 0 1 asytime
  if ($away) { did -b $dname 22 | did -e $dname 23,25,26 }
  if (!$away) { did -e $dname 22 | did -b $dname 23,25,26 }
  if (%asyanick) { did -a $dname 2 %asyanick }
  if (%asybnick) { did -a $dname 6 %asybnick }
  did -c $dname $iif(%t.none,14,$iif(%t.30,15,$iif(%t.60,16,$iif(%t.90,17,$iif(%t.120,18,)))))
  $iif(%highlite,did -c $dname 25,did -c $dname 26)
  if $read(awayreason.txt) {
    var %x = 1
    while ( %x <= $lines(awayreason.txt)) {
      did -a $dname 20 $read(awayreason.txt,%x)
      inc %x
    }
  }
}
on *:DIALOG:asy:sclick:*:{
  if ($did == 14) { unset %t.* | set %t.none on | .timert* off }
  if ($did == 15) { unset %t.* | set %t.30 on | .timerta 0 1 auto.away.check }
  if ($did == 16) { unset %t.* | set %t.60 on | .timertb 0 1 auto.away.check }
  if ($did == 17) { unset %t.* | set %t.90 on | .timertc 0 1 auto.away.check }
  if ($did == 18) { unset %t.* | set %t.120 on | .timertd 0 1 auto.away.check }
  if ($did == 25) { set %highlite on | did -u $dname 26 }
  if ($did == 26) { unset %highlite | did -u $dname 25 }
  if ($did == 3) { $iif(!$did(2).text,noop $input(Please Enter An Away Nick,uwo,Error!),set %asyanick $did(2).text) }
  if ($did == 4) { $iif(!$did(2).text,noop $input(Please Enter An Away Nick,uwo,Error!),unset %asyanick $did(2).text) | did -r $dname 2 }
  if ($did == 7) { $iif(!$did(6).text,noop $input(Please Enter A Back Nick,uwo,Error!),set %asybnick $did(6).text) }
  if ($did == 8) { $iif(!$did(6).text,noop $input(Please Enter A Back Nick,uwo,Error!),unset %asybnick $did(6).text) | did -r $dname 6 }
  if ($did == 11) {
    if (!$did(10).text) { noop $input(Please Enter A Reason,uwo,Error!) }
    else {
      .write awayreason.txt $did(10).text
      did -r $dname 10,20
      var %x = 1
      while ( %x <= $lines(awayreason.txt)) {
        did -a $dname 20 $read(awayreason.txt,%x)
        inc %x
      }
    }
  }
  if ($did == 12) {
    if (!$did(20).seltext) { noop $input(Please Select A Reason,uwo,Error!) }
    else {
      var %dawayreason $read(awayreason.txt,w,$did(20).seltext)
      if (%dawayreason == $did(20).seltext) {
        write -dl [ $+ [ $readn ] ] awayreason.txt
        did -r $dname 20
        var %x = 1
        while ( %x <= $lines(awayreason.txt)) {
          did -a $dname 20 $read(awayreason.txt,%x)
          inc %x
        }
      }
    }
  }
  if ($did == 22) {
    if (!%asyanick || !%asybnick) {
      noop $iif(!%asyanick,$input(Please Enter An Away Nick,uwo,Error!),$iif(!%asybnick,$input(Please Enter A Back Nick,uwo,Error!)))
    }
    elseif (%asyanick && %asybnick && !$did(20).seltext) {
      nick %asyanick
      did -b $dname 22
      did -e $dname 23,25,26
      .away none
      amsg 14,1[12,1»0,1:: I am Now Away ::12,1«14,1]14,1[12,1»0,1::Reason: None ::12,1«14,1]14,1[12,1»0,1:: Left at ::12,1«14,1]14,1[12,1»0,1:: $time(h:nn tt) ::12,1«14,1]
    }
    elseif (%asyanick && %asybnick && $did(20).seltext) {
      nick %asyanick
      did -b $dname 22
      did -e $dname 23,25,26
      .away $did(20).seltext
      amsg 14,1[12,1»0,1:: I am Now Away ::12,1«14,1]14,1[12,1»0,1::Reason: $did(20).seltext ::12,1«14,1]14,1[12,1»0,1:: Left at ::12,1«14,1]14,1[12,1»0,1:: $time(h:nn tt) ::12,1«14,1]
    }
  }
  if ($did == 23) {
    nick %asybnick
    amsg 14,1[12,1»0,1:: I am Now back from ::12,1«14,1]14,1[12,1»0,1::Reason: $awaymsg ::12,1«14,1]14,1[12,1»0,1:: Gone For ::12,1«14,1]14,1[12,1»0,1:: $duration($awaytime) ::12,1«14,1]
    did -e $dname 22
    did -b $dname 23,25,26
    unset %highlitecheck.*
    .away
  }
}
on *:TEXT:*:#:{
  if (%highlite && $away) {
    if (%asyanick isin $1- || %asybnick isin $1-) {
      inc $+(%,highlitecheck,.,$nick)
      if ($($+(%,highlitecheck,.,$nick),2) = 1) { .notice $nick  14,1[12,1» 0,1::This Is A One Time Response:: I am Away ATM :Reason:12,1 $awaymsg 0,1:Gone for:12,1 $duration($awaytime) 12,1«14,1] | window @away | aline @away $nick Called Your Name At $time(h:nn:tt) In $chan And Said: $1- }
      if ($($+(%,highlitecheck,.,$nick),2) >= 2) { window @away | aline @away $nick Called Your Name At $time(h:nn:tt) In $chan And Said: $1- }
    }
  }
}
on *:input:*:{
  if (%t.30 || %t.60 || %t.90 || %t.120) {
    if ($away) {
      amsg 14,1[12,1»0,1:: I am Now back from ::12,1«14,1]14,1[12,1»0,1::Reason: $awaymsg ::12,1«14,1]14,1[12,1»0,1:: Gone For ::12,1«14,1]14,1[12,1»0,1:: $duration($awaytime) ::12,1«14,1]
      nick %asybnick
      unset %highlitecheck.*
      .away
    }
  }
}

How to use
  • Right click on any of the mIRC window for the popup prompt called Away System Click on it so that u can see all the functions there also for a fast way you can use /asaway <reason>for away and also /asaback when you back



Attached Files
.mrc   Away System.mrc (Size: 7.02 KB / Downloads: 580)
You don't have to win every argument. Agree to disagree.
Reply
#2
eh Mindfreak!...
could u pls edit ur post, cause " 2- Download the Auto kick on ban.mrc..." and maybe also the "being banned" thing in the last line doesnt refer to this away script, does it?
I wasn't born to become happy, I was born to help others to become happy!
Kev :]
Reply
#3
sry Nex my bad ... thanks for notice me .. its done now...
You don't have to win every argument. Agree to disagree.
Reply
#4
yw, anyway nice script again Smile SmileSmile
I wasn't born to become happy, I was born to help others to become happy!
Kev :]
Reply
#5
thanks you always welcome.. i will try to share more soon
You don't have to win every argument. Agree to disagree.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)