[script]
n0=#note on
n1=on *:TEXT:!note help*:*:{
n2=  .timer 1 1 msg $nick !Note List <yourpassword>  This command will list all notes you have
n3=  .timer 1 2 msg $nick !Note Send <yourpassword> <name to send to> <message> This command sends a note to another registered user.
n4=  .timer 1 3 msg $nick !Note delete <yourpassword> <message number to delete> This command deletes a message. find the message number with the !note list command
n5=  .timer 1 4 msg $nick !Note read <yourpassword> <message number to read> This command reads a message. Find the message number with the !note list command
n6=  .timer 1 5 msg $nick The message system allows you to have only 5 messages please delete your message after you have read them.
n7=  .timer 1 6 msg $nick You also may not recieve or send notes unless you have a password set. Use the !pass command to set that.
n8=
n9=}
n10=on 1:JOIN:#: { 
n11=  if ($readini(nts.ini,n,$nick,msgg) != $null ) { /msg $nick you have messages in your note box type !note list <yourpassord> in a query to me to list them }
n12=  elseif ($readini(taglines.ini,n,$nick,nopass) == OFF) { halt }
n13=  elseif ($readini(taglines.ini,n,$nick,nopass) == ON) {
n14=    .msg $nick one or more people tried to send you a message at   $readini nts.ini $nick nopasstime but you do not have your password set so no message has been registered. Please set a password now with the following command (and remember do not use your ISP or other password, pick a unique one): !pass <anygoodpassword> 
n15=    /writeini taglines.ini $nick nopass OFF
n16=  }
n17=  else { halt }
n18=}
n19=
n20=on *:TEXT:!note list*:*:{
n21=  if ( $3 == $null ) { /msg $nick *IN PM* use the format !note list <yourpassword>  | halt }
n22=  if ($readini(mcbpwd.ini,n,$nick,pass) == $null) { /msg $nick please use !pass before you can check your messages | halt }
n23=  if ($readini(mcbpwd.ini,n,$nick,pass) != $hash($3,32))  { /msg $nick the password you supplied is incorrect please try again | halt }
n24=  if ( $readini(nts.ini,n,$nick,msgg) == $null ) { /msg $nick You have no messages | halt }
n25=  if ( $readini(nts.ini,n,$nick,msgg) > 0 ) {  msg $nick You have notes from the following people. | /msg $nick #1 $readini nts.ini $nick sname  } 
n26=  else { /msg $nick You can read your message with !note read # for example !note read 1 | halt }
n27=  if ( $readini(nts.ini,n,$nick,msgg) > 1 ) { /msg $nick #2 $readini nts.ini $nick sname2 }
n28=  else { /msg $nick You can read your message with !note read # for example !note read 1 | halt }
n29=  if ( $readini(nts.ini,n,$nick,msgg) > 2 ) { /msg $nick #3 $readini nts.ini $nick sname3 }
n30=  else { /msg $nick You can read your message with !note read # for example !note read 1 | halt }
n31=  if ( $readini(nts.ini,n,$nick,msgg) > 3) { /msg $nick #4 $readini nts.ini $nick sname4 }
n32=  else { /msg $nick You can read your message with !note read # for example !note read 1 | halt }
n33=  if ( $readini(nts.ini,n,$nick,msgg) == 5 ) { /msg $nick #5 $readini nts.ini $nick sname5 }
n34=  else { /msg $nick You can read your message with !note read # for example !note read 1 | halt }
n35=}
n36=
n37=
n38=on *:TEXT:!note read*:*:{
n39=  if ($readini(mcbpwd.ini,n,$nick,pass) == $null) { /msg $nick please use !pass before you can check your notes | halt }
n40=  if ($readini(mcbpwd.ini,n,$nick,pass) != $hash($3,32)) { /msg $nick the password you supplied is incorrect please try again | halt }
n41=  if  ( $readini(nts.ini,n,$nick,msgg) == $null  )  { /msg $nick You have no such message | halt }
n42=  if  ( $4 > 5  )  { /msg $nick Your message box can only hold 5 messages | halt }
n43=
n44=  if ( $4 == 1 ) && ( $readini(nts.ini,n,$nick,msgg)  >= 1 ) { 
n45=    .msg $nick Your have recieved the following message
n46=    .msg $nick The message was sent at: $readini nts.ini $nick time 
n47=    .msg $nick message from: $readini(nts.ini,n,$nick,sname)
n48=    .msg $nick your messageto: $readini(nts.ini,n,$nick,rname)
n49=    .msg $nick your message is  $readini(nts.ini,n,$nick,message)
n50=    halt
n51=  }
n52=  if ( $4 == 2 ) && ( $readini(nts.ini,n,$nick,msgg)  >= 2 ) { 
n53=    .msg $nick Your have recieved the following message
n54=    .msg $nick The message was sent at: $readini(nts.ini,n,$nick, time2 
n55=    .msg $nick message from: $readini(nts.ini,n,$nick,  sname2 
n56=    .msg $nick your messageto: $readini(nts.ini,n,$nick, rname2 
n57=    .msg $nick your message is $readini(nts.ini,n,$nick, message2
n58=    halt
n59=  }
n60=
n61=  if ( $4 == 3 ) && ( $readini(nts.ini,n,$nick,msgg)  >= 3 ) { 
n62=    .msg $nick Your have recieved the following message
n63=    .msg $nick The message was sent at: $readini(nts.ini,n,$nick, time3 
n64=    .msg $nick message from: $readini(nts.ini,n,$nick,  sname3 
n65=    .msg $nick your messageto: $readini(nts.ini,n,$nick, rname3 
n66=    .msg $nick your message is $readini(nts.ini,n,$nick, message3
n67=    halt
n68=  }
n69=
n70=  if ( $4 == 4 ) && ( $readini(nts.ini,n,$nick,msgg)  >= 4 ) { 
n71=    .msg $nick Your have recieved the following message
n72=    .msg $nick The message was sent at: $readini(nts.ini,n,$nick, time4 
n73=    .msg $nick message from: $readini(nts.ini,n,$nick,  sname4 
n74=    .msg $nick your messageto: $readini(nts.ini,n,$nick, rname4 
n75=    .msg $nick your message is $readini(nts.ini,n,$nick, message4
n76=    halt
n77=  }
n78=
n79=  if ( $4 == 5 ) && ( $readini(nts.ini,n,$nick,msgg)  == 5 ) { 
n80=    .msg $nick Your have recieved the following message
n81=    .msg $nick The message was sent at: $readini(nts.ini,n,$nick, time5 
n82=    .msg $nick message from: $readini(nts.ini,n,$nick,  sname5 
n83=    .msg $nick your messageto: $readini(nts.ini,n,$nick, rname5 
n84=    .msg $nick your message is $readini(nts.ini,n,$nick, message5
n85=    halt
n86=  }
n87=  else  { /msg $nick You have no such message | halt }
n88=}
n89=
n90=on *:TEXT:!note send*:*:{
n91=  if ( $3 == $null ) { /msg $nick *IN PM* use the format !note send <yourpassword> <recipient name> <your message> | halt }
n92=  if ($readini(mcbpwd.ini,n,$nick,pass) == $null)  { /msg $nick please set your password with !pass before you may send a note | halt }
n93=  if ($readini(mcbpwd.ini,n,$nick,pass) != $hash($3,32))  {  /msg $nick the password you supplied is incorrect please try again | halt }
n94=  if ($readini mcbpwd.ini $4 pass == $null) {
n95=    /writeini taglines.ini $4 nopass ON
n96=    /writeini nts.ini $4 nopasstime  $asctime(hh:nntt) on $asctime(dd mmmm yyyy) 
n97=
n98=    .msg $nick $4 does not have a password set and can not retrieve messages.
n99=    halt 
n100=  }
n101=  if ( $readini(nts.ini,n,$4,msgg) == $null ) { /writeini nts.ini $4 msgg 1 | goto cont }
n102=  elseif ( $readini(nts.ini,n,$4,msgg) == 1 ) { /writeini nts.ini $4 msgg 2 | goto cont1  }
n103=  elseif ( $readini(nts.ini,n,$4,msgg) == 2 ) { /writeini nts.ini $4 msgg 3 | goto cont2  }
n104=  elseif ( $readini(nts.ini,n,$4,msgg) == 3 ) { /writeini nts.ini $4 msgg 4 | goto cont3  }
n105=  elseif ( $readini(nts.ini,n,$4,msgg) == 4 ) { /writeini nts.ini $4 msgg 5 | goto cont4 } 
n106=  elseif ( $readini(nts.ini,n,$4,msgg) == 5 ) { /msg $nick $4 has a full note book please try later | halt  } 
n107=  else  { /msg $nick there has been a problem please contact rya{VB} }
n108=
n109=
n110=  :cont
n111=  { 
n112=    /writeini nts.ini $4 rname $4  
n113=    /writeini nts.ini $4 sname $nick 
n114=    /writeini nts.ini $4 message $5- 
n115=    /writeini nts.ini $4 time  $asctime(hh:nntt) on $asctime(dd mmmm yyyy) 
n116=    .msg $nick your message is being sent to $readini nts.ini $4 rname 
n117=    .msg $nick your message is $readini nts.ini $4 message
n118=    .msg $nick message from $readini nts.ini $4 sname
n119=    .msg $nick your message has been recorded $4 will get it when they next check messages
n120=    halt
n121=  }
n122=
n123=  :cont1
n124=  { 
n125=    /writeini nts.ini $4 rname2 $4   
n126=    /writeini nts.ini $4 sname2 $nick 
n127=    /writeini nts.ini $4 message2 $5- 
n128=    /writeini nts.ini $4 time2 $asctime(hh:nntt) on $asctime(dd mmmm yyyy) 
n129=    .msg $nick your message is being sent to $readini nts.ini $4 rname2 
n130=    .msg $nick your message is $readini nts.ini $4 message2
n131=    .msg $nick message from $readini nts.ini $4 sname2
n132=    .msg $nick your message has been recorded $4 will get it when they next check messages
n133=    halt
n134=  }
n135=
n136=  :cont2
n137=  { 
n138=    /writeini nts.ini $4 rname3 $4   
n139=    /writeini nts.ini $4 sname3 $nick 
n140=    /writeini nts.ini $4 message3 $5- 
n141=    /writeini nts.ini $4 time3  $asctime(hh:nntt) on $asctime(dd mmmm yyyy) 
n142=    .msg $nick your message is being sent to $readini nts.ini $4 rname3 
n143=    .msg $nick your message is $readini nts.ini $4 message3
n144=    .msg $nick message from $readini nts.ini $4 sname3
n145=    .msg $nick your message has been recorded $4 will get it when they next check messages
n146=    halt
n147=  }
n148=
n149=  :cont3
n150=  { 
n151=    /writeini nts.ini $4 rname4 $4 
n152=    /writeini nts.ini $4 sname4 $nick 
n153=    /writeini nts.ini $4 message4 $5- 
n154=    /writeini nts.ini $4 time4  $asctime(hh:nntt) on $asctime(dd mmmm yyyy) 
n155=    .msg $nick your message is being sent to $readini nts.ini $4 rname4
n156=    .msg $nick your message is $readini nts.ini $4 message4
n157=    .msg $nick message from $readini nts.ini $4 sname4
n158=    .msg $nick your message has been recorded $4 will get it when they next check messages
n159=    halt
n160=  }
n161=  :cont4
n162=  { 
n163=    /writeini nts.ini $4 rname5 $4 
n164=    /writeini nts.ini $4 sname5 $nick 
n165=    /writeini nts.ini $4 message5 $5- 
n166=    /writeini nts.ini $4 time5  $asctime(hh:nntt) on $asctime(dd mmmm yyyy) 
n167=    .msg $nick your message is being sent to $readini nts.ini $4 rname5 
n168=    .msg $nick your message is $readini nts.ini $4 message5
n169=    .msg $nick message from $readini nts.ini $4 sname5
n170=    .msg $nick your message has been recorded $4 will get it when they next check messages
n171=    halt
n172=  }
n173=}
n174=
n175=
n176=
n177=on *:TEXT:!note delete*:*:{
n178=
n179=  if ($readini(mcbpwd.ini,n,$nick,pass) == $null)  { /msg $nick please set your password with !pass before you may delete a note | halt }
n180=  if ($readini(mcbpwd.ini,n,$nick,pass) != $hash($3,32))  {  /msg $nick the password you supplied is incorrect please try again | halt }
n181=  if ($readini(nts.ini,n,$nick,msgg) == $null ) { /msg $nick you have no messages to delete | halt }
n182=  if  ($readini(nts.ini,n,$nick,msgg) >= $4 ) { goto checkit }
n183=  else  { /msg $nick you have no such message | halt }
n184=
n185=  :checkit
n186=  {
n187=    if ( $4 == 1) { goto move1 }
n188=    if ( $4 == 2) { goto move2 }
n189=    if ( $4 == 3) { goto move3 }
n190=    if ( $4 == 4) { goto move4 } 
n191=    if ( $4 == 5) { goto move5 } 
n192=  }
n193=
n194=
n195=  :end1
n196=  {
n197=    /writeini nts.ini $nick msgg 0 
n198=    /remini  nts.ini $nick
n199=    /msg $nick message deleted
n200=    halt
n201=  }
n202=
n203=  :end2
n204=  {
n205=    if %count != $null { /msg $nick Sorry I am helping someone else right now please try again in a moment | halt }
n206=    set %count  $readini(nts.ini,n,$nick,msgg) 
n207=    If ( %count <= 5 ) && ( %count > 0 ) {
n208=      dec %count
n209=      /writeini nts.ini $nick msgg %count
n210=      unset %count
n211=      /remini  nts.ini $nick time2 
n212=      /remini  nts.ini $nick sname2  
n213=      /remini  nts.ini $nick rname2  
n214=      /remini  nts.ini $nick message2
n215=      /msg $nick message deleted
n216=    halt }
n217=  }
n218=
n219=  :end3
n220=  {
n221=    if %count != $null { /msg $nick Sorry I am helping someone else right now please try again in a moment | halt }
n222=    set %count  $readini(nts.ini,n,$nick,msgg) 
n223=    If ( %count <= 5 ) && ( %count > 0 ) {
n224=      dec %count
n225=      /writeini nts.ini $nick msgg %count
n226=      unset %count
n227=      /remini  nts.ini $nick time3 
n228=      /remini  nts.ini $nick sname3  
n229=      /remini  nts.ini $nick rname3  
n230=      /remini  nts.ini $nick message3
n231=      /msg $nick message deleted
n232=    halt }
n233=  }
n234=  :end4
n235=  {
n236=    if %count != $null { /msg $nick Sorry I am helping someone else right now please try again in a moment | halt }
n237=    set %count  $readini(nts.ini,n,$nick,msgg) 
n238=    If ( %count <= 5 ) && ( %count > 0 ) {
n239=      dec %count
n240=      /writeini nts.ini $nick msgg %count
n241=      unset %count
n242=      /remini  nts.ini $nick time4 
n243=      /remini  nts.ini $nick sname4  
n244=      /remini  nts.ini $nick rname4  
n245=      /remini  nts.ini $nick message4  
n246=      /msg $nick message deleted
n247=    halt }
n248=  }
n249=
n250=  :move1
n251=  {
n252=    if  ( $readini(nts.ini,n,$nick,msgg) > 1 )  {
n253=      /writeini nts.ini $nick time $readini(nts.ini,n,$nick,time2) 
n254=      /writeini nts.ini $nick sname $readini(nts.ini,n,$nick,sname2) 
n255=      /writeini nts.ini $nick rname  $readini(nts.ini,n,$nick,rname2) 
n256=      /writeini nts.ini $nick message $readini(nts.ini,n,$nick,message2)
n257=    goto move2  }
n258=    else { goto end1 }
n259=  }
n260=
n261=
n262=  :move2
n263=  {
n264=    if  ( $readini(nts.ini,n,$nick,msgg) > 2 )   { 
n265=      /writeini nts.ini $nick time2 $readini(nts.ini,n,$nick,time3)
n266=      /writeini nts.ini $nick sname2 $readini(nts.ini,n,$nick,sname3) 
n267=      /writeini nts.ini $nick rname2  $readini(nts.ini,n,$nick,rname3)
n268=      /writeini nts.ini $nick message2 $readini(nts.ini,n,$nick,message3)
n269=    goto move3 }
n270=    else { goto end2 }
n271=  }
n272=  :move3
n273=  {
n274=    if  ( $readini(nts.ini,n,$nick,msgg) > 3 )   { 
n275=      /writeini nts.ini $nick time3 $readini(nts.ini,n,$nick,time4) 
n276=      /writeini nts.ini $nick sname3 $readini(nts.ini,n,$nick,sname4) 
n277=      /writeini nts.ini $nick rname3  $readini(nts.ini,n,$nick,rname4) 
n278=      /writeini nts.ini $nick message3 $readini(nts.ini,n,$nick,message4)
n279=    goto move4 }
n280=    else { goto end3 }
n281=  }
n282=  :move4
n283=  {
n284=    if  ( $readini(nts.ini,n,$nick,msgg) > 4 ) { 
n285=      /writeini nts.ini $nick time4 $readini(nts.ini,n,$nick,time5)
n286=      /writeini nts.ini $nick sname4 $readini(nts.ini,n,$nick,sname5) 
n287=      /writeini nts.ini $nick rname4  $readini(nts.ini,n,$nick,rname5)
n288=      /writeini nts.ini $nick message4 $readini(nts.ini,n,$nick,message5)
n289=    goto move5 }
n290=    else { goto end4 }
n291=  }
n292=  :move5
n293=  {
n294=    /remini  nts.ini $nick time5 
n295=    /remini  nts.ini $nick sname5  
n296=    /remini  nts.ini $nick rname5  
n297=    /remini  nts.ini $nick message5
n298=    /msg $nick message deleted
n299=    set %count  $readini(nts.ini,n,$nick,msgg) 
n300=    If ( %count <= 5) && ( %count > 0) { dec %count | /writeini nts.ini $nick msgg %count }
n301=    unset %count
n302=    else halt
n303=
n304=    halt    
n305=  }
n306=
n307=}
n308=#note end
