]> jfr.im git - irc/kvirc/kvirc-scripts.git/commitdiff
Extio's NickTracker (#18)
authorextioStorm <redacted>
Mon, 11 Jul 2016 00:01:52 +0000 (19:01 -0500)
committerun1versal <redacted>
Mon, 11 Jul 2016 00:01:52 +0000 (01:01 +0100)
* Create readme.md

* Add files via upload

* Update readme.md

* Delete ExtioNickTrackerVer5.6.kvs

* Add files via upload

* Delete ExtioNickTrackerVer5-6.kvs

* Corrected Version of script

Found and changed uninstall aliase errors, and removed semicolons from starting brackets like {;  (not sure how those got there but it bugged me.)

* Update readme.md

ExScripts-NickTracker/ExtioNickTrackerVer5.63.kvs [new file with mode: 0644]
ExScripts-NickTracker/readme.md [new file with mode: 0644]

diff --git a/ExScripts-NickTracker/ExtioNickTrackerVer5.63.kvs b/ExScripts-NickTracker/ExtioNickTrackerVer5.63.kvs
new file mode 100644 (file)
index 0000000..3d1d30e
--- /dev/null
@@ -0,0 +1,600 @@
+echo Installing NickTracker By Extio v5.6
+
+#following is legacy, relates to early version of script, no longer applicable to most.
+#echo Removing any old aliases, aliases now namespaced (only if previously installed).
+#alias -q (NTCloneScanProcessAll) {};
+#alias -q (NTCloneScanProcess) {};
+#alias -q (NTCloneScan) {};
+#alias -q (NickTrackerProcess) {};
+
+echo building CloneScan Processes;
+alias(NT::CloneScanProcess)
+{
+       %chanUsersArray[] = $chan.users($channel($chan.name),,m) ;
+       %r = 0; %s = 0;
+       %clonetext="";
+       while (%r < %chanUsersArray[]#)
+       {
+               %chanUsersArrayPieces[] = $str.split([!@],%chanUsersArray[%r],r) ;
+               if ( $1 == %chanUsersArrayPieces[2] && $0 != %chanUsersArrayPieces[0]) 
+               {
+                       if (%s == 0)
+                       {
+                               %clonetext .="\Clones: \[$0\] and \[%chanUsersArrayPieces[0]\]";
+                               %s++;
+                       } else {
+                               %clonetext .= " and \[%chanUsersArrayPieces[0]\]";
+                               %s++;
+                       };
+               };
+               %r++;
+       };
+       if (%s>0) { echo -i=$msgtype(genericwarning) %clonetext" \>\> \[$1\]"; };
+}
+
+
+alias(NT::CloneScan)
+{
+       %chanUsersArray[] = $chan.users($channel($chan.name),,m) ;
+       %j = 0 ;
+       # echo chanUsersArray: %chanUsersArray[] ;
+       while (%j < %chanUsersArray[]#)
+       {
+               %clonetext="";
+               %chanUsersArrayPieces[] = $str.split([!@],%chanUsersArray[%j],r) ;
+               %g = $(%j+1);
+               %s = 0;
+               while (%g < %chanUsersArray[]#)
+               {
+                       if(%chanUsersArray[%j] != ".") # this checks if the nick has been deleted, because it already matched.
+                       {
+                               %chanUsersArrayPieces2[] = $str.split([!@],%chanUsersArray[%g],r) ;
+                               if ( %chanUsersArrayPieces[2] == %chanUsersArrayPieces2[2] ) 
+                               {
+                                       if (%s == 0)
+                                       {
+                                               %clonetext .="\Clones: \[%chanUsersArrayPieces[0]\] and \[%chanUsersArrayPieces2[0]\]";
+                                               %s++;
+                                       } else {
+                                               %clonetext .= " and \[%chanUsersArrayPieces2[0]\]";
+                                               %s++;
+                                       };
+                                       %chanUsersArray[%g] = "."; # this deletes tokens from chanusersarray so that when the second loop comes to them, they wont be checked, because a match has already been found.
+                               };
+                       };
+                       %g++;
+               };
+               %j++;
+               if (%s>0) { echo -i=$msgtype(genericwarning) %clonetext" \>\> \[%chanUsersArrayPieces[2]\]"; };
+       };
+}
+
+
+echo Building Nicktracker Process;
+alias(NT::NickTrackerProcess)
+{
+       %NTSet = $config.open(NickTrackerSettings.kvs) ;
+       %nOfN = $config.read(%NTSet,NickNum,6) ;
+       %ntUserDisplay = $config.read(%NTSet,NTdisplayUser,"on");
+       %ntIpDisplay = $config.read(%NTSet,NTdisplayIp,"on");
+       %powerstate = $config.read(%NTSet,NTpower,"on")
+       config.close %NTSet ; 
+       config.setsection %NT $my.network
+       config.setsection %NT2 $my.network
+       %nicksread = $config.read(%NT,$2,"") ;
+       %nicksreadUserName = $config.read(%NT2,$1,"") ;
+       %nicks = "";
+       %nicksUserName = "";
+       if (%nicksread != "") {
+               %nicksarray[] = $str.split(" ",%nicksread,n) ;
+               # echo full array: %nicksarray[];
+               %i = 0 ;
+               while (%i < %nicksarray[]#)
+               {
+                       if (%nicksarray[%i] != $0 && %i < $(%nOfN+1))
+                       {
+                               %nicks << %nicksarray[%i] ;
+                       };
+                       %i++ ;
+               };
+               if (%nicks != "" && %nicksarray[] != $0 && $3 == 1 || $3 == 4)
+               {
+                       if (%ntIpDisplay != "off")
+                       {
+                               echo $0 \["@"$2\] IP match: %nicks ;
+                       };
+               };
+       };
+       %newNicks = $0 ;
+       if (%nicks != "")
+       {
+               %newNicks << %nicks ;
+       };
+       config.write %NT $2 %newNicks ;
+       if (%ntUserDisplay != "off")
+       {
+               if (%nicksreadUserName != "")
+               {
+                       %nicksarrayUserName[] = $str.split(" ",%nicksreadUserName,n) ;
+                       # echo full array: %nicksarrayUserName[];
+                       %i = 0 ;
+                       while (%i < %nicksarrayUserName[]#)
+                       {
+                               if (%nicksarrayUserName[%i] != $0 && %i < $(%nOfN+1)) {
+                                       %nicksUserName << %nicksarrayUserName[%i] ;
+                               };
+                               %i++ ;
+                       };
+                       if (%nicksUserName != "" && %nicksarrayUserName[] != $0 && $3 == 1 && %nicksUserName != %nicks || $3 == 4) 
+                       {
+                               echo $0 \["!"$1\] User match: %nicksUserName ;
+
+                       };
+               };
+               %newNicksUserName = $0 ;
+               if (%nicksUserName != "") {
+                       %newNicksUserName << %nicksUserName ;
+               };
+               # echo newNicks written to file:  %newNicksUserName
+               config.write %NT2 $1 %newNicksUserName ;
+       };
+};
+
+echo Building OnJoin ;
+event(OnJoin,NickTrack)
+{
+       %NTSet = $config.open(NickTrackerSettings.kvs) ;
+       %ntstate = $config.read(%NTSet,NTpower,"on")
+       %csstate = $config.read(%NTSet,CSpower,"on")
+       config.close %NTSet ; 
+       %NT = $config.open(NickTracker.kvs) ;
+       %NT2 = $config.open(NickTracker2.kvs) ;
+       if (%ntstate==on)
+       {
+               NT::NickTrackerProcess $0 $1 $2 1;
+       };
+       if (%csstate==on)
+       {
+               NT::CloneScanProcess $0 $2;
+       };
+       config.close %NT ;
+       config.close %NT2 ;
+       # echo $mask($0,0) ;
+};
+
+echo Building OnChannelSync ;
+event(OnChannelSync,NickTrackerInitialize)
+{
+       %NTSet = $config.open(NickTrackerSettings.kvs) ;
+       %ntstate = $config.read(%NTSet,NTpower,"on");
+       %csstate = $config.read(%NTSet,CSpower,"on");
+       %csdisplay = $config.read(%NTSet,CSdisplay,"on");
+       config.close %NTSet ;
+       %echotext = "";
+       %NT = $config.open(NickTracker.kvs) ;
+       %NT2 = $config.open(NickTracker2.kvs) ;
+       if (%ntstate==on)
+       {
+               %echotext = "Nicks processed for tracking";
+               %chanUsersArray[] = $chan.users($channel($chan.name),,m) ;
+               %j = 0 ;
+               # echo chanUsersArray: %chanUsersArray[] ;
+               while (%j < %chanUsersArray[]#)
+               {
+                       %chanUsersArrayPieces[] = $str.split([!@],%chanUsersArray[%j],r) ;
+                       NT::NickTrackerProcess %chanUsersArrayPieces[0] %chanUsersArrayPieces[1] %chanUsersArrayPieces[2] 0 ;
+                       %j++ ;
+               };
+       };
+       if (%csstate==on && %ntstate==on && %csdisplay==on) { %echotext .= ", "; };
+       if (%csstate==on && %csdisplay==on) 
+       {
+               %echotext .= "Clone Scan Completed.";
+               NT::CloneScan;
+       };
+       config.close %NT ;
+       config.close %NT2 ;
+       if (%echotext!="") { echo %echotext; };
+};
+
+
+
+echo Building OnNickChange ;
+event (OnNickChange,NickChangeTrack)
+{
+       %NTSet = $config.open(NickTrackerSettings.kvs) ;
+       %ntstate = $config.read(%NTSet,NTpower,"on")
+       config.close %NTSet ;
+       if (%ntstate==on)
+       {
+               %NT = $config.open(NickTracker.kvs) ;
+               %NT2 = $config.open(NickTracker2.kvs) ;
+               NT::NickTrackerProcess $3 $1 $2 0 ;
+#              echo newNicks written to file ;
+               config.close %NT ;
+               config.close %NT2 ;
+       };
+};
+
+echo Building OnChannelNickLinkClick ;
+event (OnChannelNickLinkClick,NickTrackShow)
+{
+       %NTSet = $config.open(NickTrackerSettings.kvs) ;
+       %ntstate = $config.read(%NTSet,NTpower,"on")
+       config.close %NTSet ; 
+       if (%ntstate==on)
+       {
+               %NTSet = $config.open(NickTrackerSettings.kvs) ;
+               %ntstate = $config.read(%NTSet,NTpower,"on") ;
+               config.close %NTSet ;
+               if (%ntstate==on)
+               {
+                       %NT = $config.open(NickTracker.kvs) ;
+                       %NT2 = $config.open(NickTracker2.kvs) ;
+                       %identifyNick[] = $str.split([!@],$mask($0,0),r) ;
+                       NT::NickTrackerProcess %identifyNick[0] %identifyNick[1] %identifyNick[2] 4 ;
+                       config.close %NT ;
+                       config.close %NT2 ;
+               };
+       };
+};
+
+echo Building OnQueryNickLinkClick ;
+event (OnQueryNickLinkClick,NickTrackShow)
+{
+       %NTSet = $config.open(NickTrackerSettings.kvs) ;
+       %ntstate = $config.read(%NTSet,NTpower,"on")
+       config.close %NTSet ; 
+       if (%ntstate==on)
+       {
+               %NTSet = $config.open(NickTrackerSettings.kvs) ;
+               %ntstate = $config.read(%NTSet,NTpower,"on")
+               config.close %NTSet ;
+               if (%ntstate==on)
+               {
+                       %NT = $config.open(NickTracker.kvs) ;
+                       %NT2 = $config.open(NickTracker2.kvs) ;
+                       %identifyNick[] = $str.split([!@],$mask($0,0),r) ;
+                       NT::NickTrackerProcess %identifyNick[0] %identifyNick[1] %identifyNick[2] 4 ;
+                       config.close %NT ;
+                       config.close %NT2 ;
+               };
+       };
+};
+
+echo Building OnQueryTargetAdded ;
+event (OnQueryTargetAdded,NickTrackShow)
+{
+       %NTSet = $config.open(NickTrackerSettings.kvs) ;
+       %ntstate = $config.read(%NTSet,NTpower,"on") ;
+       config.close %NTSet ; 
+       if (%ntstate==on)
+       {
+               %NTSet = $config.open(NickTrackerSettings.kvs) ;
+               %ntstate = $config.read(%NTSet,NTpower,"on")
+               config.close %NTSet ;
+               if (%ntstate==on)
+               {
+                       %NT = $config.open(NickTracker.kvs) ;
+                       %NT2 = $config.open(NickTracker2.kvs) ;
+                       %identifyNick[] = $str.split([!@],$mask($0,0),r) ;
+                       if (%identifyNick[2] != "*") 
+                       {
+                               NT::NickTrackerProcess %identifyNick[0] %identifyNick[1] %identifyNick[2] 4 ;
+                       };
+                       config.close %NT ;
+                       config.close %NT2 ;
+               };
+       };
+};
+
+
+
+echo Building NickTracker alias ;
+alias (NickTracker)
+{
+       if ($0 == "") { popup.show nicktracker; }; 
+       if ($0 == "help") 
+       {
+               echo \-----------------------------------------------------------------------
+               echo NickTracker by extio version 5.6 help file.
+               echo this script logs hostmask and usernames and associates nicks with them
+               echo it then tells you previous names used under hostmask and usernames.
+               echo this alias accepts some commands in addition, as following.
+               echo \-----------------------------------------------------------------------
+               echo Alias Commands:
+               echo \/nicktracker - shows options popup.
+               echo \/nicktracker uninstall - completely removes the script.
+               echo \/nicktracker identify <nick> brings up the nicks for a mask and username
+               echo \/nicktracker help - displays this help file
+               echo \/nicktracker clear - clears the names stored in the config file
+               echo \/nicktracker clear [network] - to clear only network nicks. -
+               echo [ For current network: \/nicktracker clear $my.network ]
+               echo \/nicktracker set nicktracker nicknumber [#] - replace [#] with a number -
+               echo \(6 is default\) to set the number of nicks recorded.
+               echo \-----------------------------------------------------------------------
+               echo You can left click a users name in channel (or query) to have the default effects,
+               echo or you can right click and chose the option from the poppup menu.
+               echo You can right click in the usermenu, and track previous nicks.
+               echo Script will show you previous names in channel space.
+               echo When Query window open, script automatically displays information
+               echo When Users Join the channel, script automatically shows information.
+               echo \-----------------------------------------------------------------------
+       }
+       if ($0 == "set") 
+       {
+               %NTSet = $config.open(NickTrackerSettings.kvs) ;
+               if ($1==clonescanner)
+               {
+                       if ($2==power)
+                       {
+                               if ($3==on)
+                               {
+                                       # echo Previous power state: $config.read(%NTSet,CSpower,"on") ;
+                                       config.write %NTSet CSpower "on" ;
+                               }
+                               if ($3==off)
+                               {
+                                       # echo Previous power state: $config.read(%NTSet,CSpower,"on") ;
+                                       config.write %NTSet CSpower "off" ;
+                               };
+                               echo CloneScanner Power state now: $config.read(%NTSet,CSpower,"on") ;
+                       };
+                       if ($2==display)
+                       {
+                               if ($3==on)
+                               {
+                                       # echo Previous power state: $config.read(%NTSet,CSpower,"on") ;
+                                       config.write %NTSet CSdisplay "on" ;
+                               };
+                               if ($3==off)
+                               {
+                                       # echo Previous power state: $config.read(%NTSet,CSpower,"on") ;
+                                       config.write %NTSet CSdisplay "off" ;
+                               };
+                               echo CloneScanner Channel Sync display state now: $config.read(%NTSet,CSdisplay,"on") ;
+                       };
+               };
+               if ($1==nicktracker)
+               {
+                       if ($2==power)
+                       {
+                               if ($3==on)
+                               {
+                                       # echo Previous power state: $config.read(%NTSet,NTpower,"on") ;
+                                       config.write %NTSet NTpower "on" ;
+                               };
+                               if ($3==off)
+                               {
+                                       # echo Previous power state: $config.read(%NTSet,NTpower,"on") ;
+                                       config.write %NTSet NTpower "off" ;
+                               };
+                               echo NickTracker Power state now: $config.read(%NTSet,NTpower,"on") ;
+                       };
+                       if ($2==track)
+                       {
+                               if ($3==user)
+                               {                               
+                                       if ($4==on)
+                                       {
+                                               # echo Previous power state: $config.read(%NTSet,NTpower,"on") ;
+                                               config.write %NTSet NTdisplayUser "on" ;
+                                       }
+                                       if ($4==off)
+                                       {
+                                               # echo Previous power state: $config.read(%NTSet,NTpower,"on") ;
+                                               config.write %NTSet NTdisplayUser "off" ;
+                                       }
+                                       echo NickTracker user tracking state now: $config.read(%NTSet,NTdisplayUser,"on") ;
+                               };
+                       };
+                       if ($2==display)
+                       {
+                               if ($3==ip)
+                               {                               
+                                       if ($4==on)
+                                       {
+                                               # echo Previous power state: $config.read(%NTSet,NTpower,"on") ;
+                                               config.write %NTSet NTdisplayIp "on" ;
+                                       }
+                                       if ($4==off)
+                                       {
+                                               # echo Previous power state: $config.read(%NTSet,NTpower,"on") ;
+                                               config.write %NTSet NTdisplayIp "off" ;
+                                       }
+                                       echo NickTracker Ip Display state now: $config.read(%NTSet,NTdisplayIp,"on") ;
+                               };
+                       };
+                       if ($2==nicknumber)
+                       {
+                               if ($isNumeric($3) && $3 > 0)
+                               {
+                                       echo Previous Number of nicks: $config.read(%NTSet,NickNum,6) ;
+                                       config.write %NTSet NickNum $3 ;
+                                       echo New Number of nicks to show: $config.read(%NTSet,NickNum,6) ;
+                                       echo warning: If the new number is lower than the old, you will lose the
+                                       echo previous nicks stored above the number of the new number when processed.
+                               } else {
+                                       dialog.textinput -d=6 (NickNumber Setting,"<center>What do you want to set the<br>number of saved nicks to?</center>","Set","Cancel")
+                                       {
+                                               switch($0)
+                                               {
+                                                       case(0):
+                                                       { if($isNumeric($1)) { nicktracker set nicktracker nicknumber $1; } else echo you need to use a number for that setting. canceled.; }
+                                                       break;
+                                                       default:
+                                                       # Cancelled
+                                                       break;
+                                               };
+                                               echo John 3:16 says it simply.  God loves us, and died for us.  We would be fools to pass up what he gives.;
+                                       };
+                               };
+                       };
+               };
+               config.close %NTSet ;
+       }
+       if ($0 == "identify") 
+       {
+               if ($1)
+               {
+                       %NT = $config.open(NickTracker.kvs) ;
+                       %NT2 = $config.open(NickTracker2.kvs) ;
+#                      %identifyNick[] = $str.split([!@],$1,r) ;
+                       %identifyNick[] = $str.split([!@],$mask($1,0),r) ;
+                       NT::NickTrackerProcess %identifyNick[0] %identifyNick[1] %identifyNick[2] 4 ;
+                       config.close %NT ;
+                       config.close %NT2 ;
+               }
+       }
+       if ($0 == "channel") 
+       {
+               %NT = $config.open(NickTracker.kvs) ;
+               %NT2 = $config.open(NickTracker2.kvs) ;
+               if ($1) 
+               {
+                       if ($str.contains($1,"#"))
+                       {
+                               if ($channel($1) != 0) { echo Showing NickTracker for $1; %chanUsersArray[] = $chan.users($channel($1),,m);     } else { echo Channel does not exist.; };
+                       } else { echo channel specified needs a pounds sign.; } ;
+               } else { if ($1 != "") { echo Current channel:; %chanUsersArray[] = $chan.users($channel($chan.name),,m); } else { echo Non-Channel passed, please select a valid channel ;}; };
+               %j = 0 ;
+               # echo chanUsersArray: %chanUsersArray[] ;
+               while (%j < %chanUsersArray[]#)
+               {
+                       %chanUsersArrayPieces[] = $str.split([!@],%chanUsersArray[%j],r) ;
+                       NT::NickTrackerProcess %chanUsersArrayPieces[0] %chanUsersArrayPieces[1] %chanUsersArrayPieces[2] 4 ;
+                       %j++ ;
+               };
+               echo Nicks processed for tracking ;
+               config.close %NT ;
+               config.close %NT2 ;
+       }
+       if ($0 == "clear") 
+       {
+               %NT = $config.open(NickTracker.kvs) ;
+               %NT2 = $config.open(NickTracker2.kvs) ;
+               if ($1 == "") 
+               {
+                       config.clear %NT ;      
+                       config.clear %NT2 ;
+               }
+               if ($config.hassection(%NT,$1)) 
+               {
+                       config.clearsection %NT $1
+               }
+               if ($config.hassection(%NT2,$1)) 
+               {
+                       config.clearsection %NT2 $1
+               }
+               config.close %NT ;
+               config.close %NT2 ;
+       }       
+       if ($0 == "uninstall") 
+       {
+               echo Removing NickTracker script onjoin event. ;
+               event (OnJoin,NickTrack) {} ;
+               echo Removing NickTracker script OnChannelSync event. ;
+               event (OnChannelSync,NickTrackerInitialize) {} ;
+               echo Removing NickTracker script OnNickChange event. ;
+               event (OnNickChange,NickChangeTrack) {} ;
+               echo Removing NickTracker script OnChannelNickLinkClick event. ;
+               event (OnChannelNickLinkClick,NickTrackShow) {} ;
+               echo Removing NickTracker script OnQueryNickLinkClick event. ;
+               event (OnQueryNickLinkClick,NickTrackShow) {} ;
+               event (OnQueryTargetAdded,NickTrackShow) {} ;
+               echo Clearing NickTracker script Config file, searching for file and deleting ;
+               %NT = $config.open(NickTracker.kvs) ;
+               config.clear %NT ;
+               config.close %NT ;
+               %NT2 = $config.open(NickTracker2.kvs) ;
+               config.clear %NT2 ;
+               config.close %NT2 ;
+               %NTSet = $config.open(NickTrackerSettings.kvs);
+               config.clear %NTSet ;
+               config.close %NTSet ;
+               if ($file.exists($file.localdir(config/scripts/NickTrackerSettings.kvs))) 
+               {
+                       echo removing file $file.localdir(config/scripts/NickTrackerSettings.kvs) ;
+                       file.remove $file.localdir(config/scripts/NickTrackerSettings.kvs);                     
+               };
+               if ($file.exists($file.localdir(config/scripts/NickTracker.kvs))) 
+               {
+                       echo removing file $file.localdir(config/scripts/NickTracker.kvs) ;
+                       file.remove $file.localdir(config/scripts/NickTracker.kvs);                     
+               };
+               if ($file.exists($file.localdir(config/scripts/NickTracker2.kvs))) 
+               {
+                       echo removing file $file.localdir(config/scripts/NickTracker2.kvs) ;
+                       file.remove $file.localdir(config/scripts/NickTracker2.kvs);                    
+               };
+               echo Removing NickTracker script NickTracker Function/Alias. ;
+               alias (NT::NickTrackerProcess) {} ;
+               echo Remove NickTracker script completed. ;
+               alias (NT::CloneScan) {} ;
+               echo Remove NT::CloneScan script completed. ;
+               alias (NT::CloneScanProcess) {} ;
+               echo Remove NT::CloneScanProcess script completed. ;
+               alias (NickTracker) {} ;
+               popup.delitem channel channel.nicktrackerpopup ;
+               popup.delitem querytextview querytextview.nicktrackerpopup ;
+               popup.destroy nicktracker ;
+               echo destroyed popup menus, nicktracker uninstalled.;
+       }
+}
+
+defpopup(nicktracker)
+{
+       prologue
+       {
+               %NTSet = $config.open(NickTrackerSettings.kvs) ;
+               %nOfN = $config.read(%NTSet,NickNum,"6") ;
+               %:ntstate = $config.read(%NTSet,NTpower,"on");
+               %:csstate = $config.read(%NTSet,CSpower,"on");
+               %:ntUserDisplay = $config.read(%NTSet,NTdisplayUser,"on");
+               %:ntIpDisplay = $config.read(%NTSet,NTdisplayIp,"on");
+               %:csDisplay = $config.read(%NTSet,CSdisplay,"on");
+               config.close %NTSet;
+       }
+       label(Notice: CloneScanning is OFF!!!)(%:csstate==off);
+       item(Clone Scanning On,113)(%:csstate==off) { nicktracker set clonescanner power on; }
+       item(Clone Scanning Off,113)(%:csstate==on) {   nicktracker set clonescanner power off; }
+       item(CloneScan at ChanSync On,132)(%:csDisplay==off) { nicktracker set clonescanner display on; }
+       item(CloneScan at ChanSync Off,134)(%:csDisplay==on) { nicktracker set clonescanner display off; }
+       separator;
+       label(Notice: All NickTracking is OFF!!!)(%:ntstate==off);
+       item(NickTracking On,143)(%:ntstate==off) { nicktracker set nicktracker power on; }
+       item(NickTracking Off,143)(%:ntstate==on) { nicktracker set nicktracker power off; }
+       separator;
+       label(Notice: NickTracking display IP OFF!!!)(%:ntIpDisplay==off);
+       item(Display Ip Nicks On,35)(%:ntIpDisplay==off) { nicktracker set nicktracker display ip on; }
+       item(Display Ip Nicks Off,277)(%:ntIpDisplay==on) { nicktracker set nicktracker display ip off; }
+       item(NickTrack UserNames On,69)(%:ntUserDisplay==off) { nicktracker set nicktracker track user on; }
+       item(NickTrack UserNames Off,67)(%:ntUserDisplay==on) { nicktracker set nicktracker track user off; }
+       separator;
+       item("Set NickTracking number...",31) { nicktracker set nicktracker nicknumber; }
+       separator;
+       item(NickTracker Help,173) { nicktracker help; }
+#      epilogue {  }
+}
+
+echo Clearing any previous nicktrackerpopup item, Building channel item nicktrackerpopup ;
+popup.delitem -q channel channel.nicktrackerpopup ;
+popup.addItem (channel, Track Previous Nicks of \%:visible, 92, channel.nicktrackerpopup, "")
+{
+       nicktracker identify $0 ;
+}
+echo Clearing any previous nicktrackerpopup item, Building query item nicktrackerpopup ;
+popup.delitem -q querytextview querytextview.nicktrackerpopup ;
+popup.addItem (querytextview, Track Previous Nicks of \%:visible, 92, querytextview.nicktrackerpopup, "")
+{
+       nicktracker identify $0 ;
+}
+
+popup.delitem -q windowpopup windowpopup.nicktrackerpopup ;
+popup.addItem (windowpopup, NickTrack and CloneScan \$chan.name, 92, windowpopup.nicktrackerpopup, \$window.type=="channel")
+{
+       if ($window.type == "channel") { nicktracker channel $chan.name ; NT::CloneScan; Echo "CloneScan Complete"; } ;
+}
+
+echo NickTracker script installed.
+echo Try it out! Access the new menu with just \"/nicktracker\", or \"/nicktracker help\" to learn all the alias commands.  You can also right click names in a channel to check names.  on first load you will want to rejoin any channels you want to use it on, in order to build all the nicks database to track them.  You can do this with using /hop in each channel you want to start using it on, or just restart kvirc.
\ No newline at end of file
diff --git a/ExScripts-NickTracker/readme.md b/ExScripts-NickTracker/readme.md
new file mode 100644 (file)
index 0000000..45a3205
--- /dev/null
@@ -0,0 +1,32 @@
+## Script Purpose
+
+This is a script designed for KVIrc, a client program.  I wrote this script from scratch,  it allows a user to track the previous nicks of other users based on usernames and IP hostmasks.
+
+## How it works
+
+The NickTracker script works by taking note of all names when a channel is synced, and saving nicks associated with visible hostmasks in a configuration file.  when a user joins the channel, they are also added to this list.  If the hostname that is visible matches a name already saved, it will display the name.  It also saves according to usernames.  Lastly, this script will check to see if any person in the room has the same hostmask as another person, and alert you to any clones.  It is designed to operate without much user interface, so it should be installed and left alone after setting up.
+
+## Installation
+
+To install, download the script file.
+Open KVIrc and navigate to Menu > scripting > execute script, or push ctrl+shift+x.   Navigate to and select the script file and run it.  You can now delete the original downloaded script file if you desire.
+
+## Operation
+
+This script is primarly controled through right clicking names, through an added item on the pop-up, and clicking nicks in the main chat room, but ```/nicktracker``` can control it through alias if you read the script to know the commands.
+
+type ```/nicktracker``` or click a name in a channel, or right click a name in the list to operate.
+
+to remove script use ```/nicktracker uninstall```
+
+(Legacy update changelog from before github)
+*update 4-21-2013 - If you have a previous install and are updating, its recommended that you use /nicktracker clear or /nicktracker uninstall before installing this.  It should be noted that due to the changes in this script, updating will cause you to lose your database of names. However it should also respond more quickly int the future if multiple networks are frequented.
+*last updated 4-26-13 - Added feature to to track entire name, and now tracks in pm on opening pm, no long falsly tracks * as a host.
+updated 4-29-13 - added settings file, can set number of nicks to show now.
+updated nov 20 2013 - added clone scanner, still needs controls.
+updated nov 21 2013 - added controls.  "/nicktracker" to see basic controls.
+changed output to be smaller.  || nov. 24 2013 - more small changes
+updated jan 12 2014 - added more controls to "/nicktracker" menu, ability to just disable username tracking, disable
+onchannelsync clone display, and to turn off ip tracking display on userjoins.  may rework some of these options later.
+
+Please test this script and post any problems in the issues, or with this script.