From WikiChip
Difference between revisions of "mirc/identifiers/$click"
< mirc‎ | identifiers

(Example)
m
 
(8 intermediate revisions by 3 users not shown)
Line 1: Line 1:
The '''$click''' identifier allows the tracking of clicks within a custom [[Picture Windows - mIRC|Picture Window]].
+
{{mirc title|$click Identifier}}The '''$click''' identifier allows the tracking of clicks within a custom [[Picture Windows - mIRC|Picture Window]].
 +
 
  
 
== Synopsis ==
 
== Synopsis ==
Line 9: Line 10:
 
| N | The Nth target in the click event list to track.
 
| N | The Nth target in the click event list to track.
 
}}
 
}}
 
'''Note:''' Although mIRC's help file states that one or both of these parameters can be omitted, and even suggests that '''$click()''', or '''$click''' may be used, unfortunately that is not true. These practices will be met with a ''Too few parameters: $click'' error. It's best to define both the custom picture window name and the Nth item.
 
  
 
== Properties ==
 
== Properties ==
Line 31: Line 30:
  
 
   ; Custom picture window, which is centered
 
   ; Custom picture window, which is centered
   window -pC @clicker 0 0 250 125
+
   window -dpC @clicker 0 0 250 125
  
 
   ; Custom 'update' alias keeps code from repeating
 
   ; Custom 'update' alias keeps code from repeating
Line 60: Line 59:
 
; from this example
 
; from this example
 
alias -l update {
 
alias -l update {
   drawtext @clicker 1 7 $1 $2-
+
   drawtext @clicker $color(normal) 7 $1 $2-
 
}</source>
 
}</source>
  
 
== Compatibility ==
 
== Compatibility ==
Added: mIRC v5.3
+
{{mIRC compatibility|5.3}}
 
 
Added On: 13/12/97
 
  
 
== See Also ==
 
== See Also ==
* [[Picture windows - mIRC|Picture Windows]]
+
* [[Picture Windows - mIRC|Picture Windows]]
 
+
{{mIRC identifier list}}
  
[[Category:mIRC identifiers]]
+
[[Category:mIRC identifiers|color]]

Latest revision as of 13:39, 20 September 2017

The $click identifier allows the tracking of clicks within a custom Picture Window.


Synopsis[edit]

$click(@,N)[.property]

Parameters[edit]

@ The custom picture window name to target
N The Nth target in the click event list to track.

Properties[edit]

x Get the current x position of the mouse click
y Get the current y position of the mouse click

Attached Command[edit]

The $click click event history can be cleared from a custom picture window by using the following command:

/clear -c @pictureWindowName

Example[edit]

The example below will create a custom alias, /clickWatch, that, when executed, will popup a custom window and display the live click results from the sclick event.

; Create the custom alias to launch the example
;
; Synopsis: /clickWatch
 
alias clickWatch {
 
  ; Custom picture window, which is centered
  window -dpC @clicker 0 0 250 125
 
  ; Custom 'update' alias keeps code from repeating
  ; During initial launch the values should be empty
  update 15 Total Clicks: empty
  update 35 Current Position: none yet
  update 55 Previous Position: none yet
}
; Monitor the sclicks in our custom '@clicker' window
menu @clicker  {
  sclick: {
 
    ; Clear the window for the new value updates
    clear @clicker
 
    ; Set the %current and %prev variables to the current
    ; x/y click location, and to the previous x/y click
    ; locations, respectively
    var %current = $click(@clicker,0), %prev = $calc(%current - 1)
 
    ; Utilizing the custom 'update' alias, update the data
    update 15 Total Clicks: $click(@clicker,0)
    update 35 Current Position: $click(@clicker,%current)
    update 55 Previous Position: $iif(%prev,$click(@clicker,%prev),none yet)
  }
}
; Custom update alias removes a lot of the /drawtext repetition
; from this example
alias -l update {
  drawtext @clicker $color(normal) 7 $1 $2-
}

Compatibility[edit]

Added: mIRC v5.3
Added on: 13 Dec 1997
Note: Unless otherwise stated, this was the date of original functionality.
Further enhancements may have been made in later versions.


See Also[edit]

v · d · e mIRC identifier list

$ $$, $, $0, $1-, $!, $&, $*, $+, $++, $?

A $abook, $abs, $acos, $active, $activecid, $activewid, $adate, $address, $addtok, $addtokcs, $agent, $agentname, $agentstat, $agentver, $alias, $and, $anick, $ansi2mirc, $aop, $appactive, $appstate, $asc, $asctime, $asin, $atan, $atan2, $auto, $avoice, $away, $awaymsg, $awaytime

B $banlist, $banmask, $base, $beta, $bfind, $bindip, $bitoff, $biton, $bits, $bnick, $bvar, $bytes

C $calc, $caller, $cancel, $cb, $cd, $ceil, $chan, $chanmodes, $channel, $chantypes, $chat, $chr, $cid, $clevel, $click, $cmdbox, $cmdline, $cnick, $color, $colour, $com, $comcall, $comchan, $comchar, $comerr, $compact, $compress, $comval, $cos, $cosh, $count, $countcs, $cr, $crc, $creq, $crlf, $ctime, $ctimer, $ctrlenter

D $date, $day, $daylight, $dbuh, $dbuw, $dccignore, $dccport, $dde, $ddename, $debug, $decode, $decompress, $deltok, $devent, $dialog, $did, $didreg, $didtok, $didwm, $dir, $disk, $dlevel, $dll, $dllcall, $dname, $dns, $donotdisturb, $dqwindow, $duration

E $ebeeps, $editbox, $email, $emailaddr, $encode, $envvar, $error, $eval, $evalnext, $event, $eventid, $eventparms, $exists, $exiting

F $false, $feof, $ferr, $fgetc, $file, $filename, $filtered, $find, $finddir, $finddirn, $findfile, $findfilen, $findtok, $findtokcs, $fline, $flinen, $floor, $font, $fopen, $fread, $fromeditbox, $fserv, $fserve, $fulladdress, $fulldate, $fullname, $fullscreen

G $get, $getdir, $getdot, $gettok, $gmt, $group

H $halted, $hash, $height, $hfile, $hfind, $hget, $highlight, $hmac $hmatch, $hnick, $host, $hotline, $hotlinepos, $hotlink, $hotp, $hregex, $hypot

I $iaddress, $ial, $ialchan, $ibl, $idle, $iel, $ifmatch, $ifmatch2, $ignore, $iif, $iil, $inellipse, $ini, $initopic, $inmidi, $inmode, $inmp3, $inpaste, $inpoly, $input, $inrect, $inroundrect, $insong, $insongpause, $instok, $int, $intersect, $inwave, $inwho, $ip, $iptype, $iql, $isadmin, $isalias, $isbit, $isdde, $isdir, $isfile, $isid, $islower, $istok, $istokcs, $isupper, $isutf

K $keychar, $keyrpt, $keyval, $knick

L $lactive, $lactivecid, $lactivewid, $left, $leftwin, $leftwincid, $leftwinwid, $len, $level, $lf, $line, $lines, $link, $lock, $locked, $lof, $log, $log10, $logdir, $logstamp, $logstampfmt, $longfn, $longip, $lower, $ltimer

M $maddress, $mask, $matchkey, $matchtok, $matchtokcs, $maxlenl, $maxlenm, $maxlens, $md5, $me, $menu, $menubar, $menucontext, $menutype, $mid, $mididir, $mircdir, $mircexe, $mircini, $mkfn, $mklogfn, $mknickfn, $mnick, $mode, $modefirst, $modelast, $modespl, $mouse, $mousecx, $mousecy, $mousedx, $mousedy, $mousekey, $mouselb, $mousex, $mousey, $mousewin, $mp3, $mp3dir, $msfile, $msgstamp, $msgtags

N $N, $naddress, $network, $newnick, $nhnick, $nick, $nickmode, $no, $nofile, $nopath, $nopnick, $noqt, $not, $notags, $notify, $null, $numeric, $numtok, $nvnick

O $ok, $online, $onlineserver, $onlinetotal $onpoly, $opnick, $or, $ord, $os

P $parmN, $parms, $parseline, $parsetype, $parseutf, $passivedcc, $pi, $pic, $play, $pnick, $portable, $portfree, $pos, $poscs, $prefix, $prop, $protect, $puttok

Q $qt, $query

R $r, $raddress, $rand, $rands, $rawbytes, $rawmsg, $read, $readini, $readn, $regbr, $regerrstr, $regex, $regml, $regmlex, $regsub, $regsubex, $remote, $remove, $removecs, $remtok, $remtokcs, $replace, $replacecs, $replacex, $replacexcs, $reptok, $reptokcs, $result, $rgb, $right, $rnick, $round

S $samepath, $scid, $scon, $script, $scriptdir, $scriptline, $sdir, $send, $server, $serverip, $servertarget, $sfile, $sha1, $sha256, $sha384, $sha512, $shortfn, $show, $signal, $sin, $sinh, $site, $sline, $snick, $snicks, $snotify, $sock, $sockbr, $sockerr, $sockname, $sorttok, $sorttokcs, $sound, $speak, $sqrt, $sreq, $ssl, $sslcertsha1, $sslcertsha256, $sslcertvalid, $ssldll, $ssllibdll, $sslready, $sslversion, $starting, $status, $str, $strip, $stripped, $style, $submenu, $switchbar, $sysdir

T $tan, $tanh, $target, $tempfn, $ticks, $time, $timeout, $timer, $timestamp, $timestampfmt, $timezone, $tip, $tips, $titlebar, $token, $toolbar, $topic, $totp, $treebar, $true, $trust

U $ulevel, $ulist, $unsafe, $upper, $uptime, $url, $usermode, $utfdecode, $utfencode

V $v1, $v2, $var, $vc, $vcmd, $vcmdstat, $vcmdver, $version, $vnick, $vol

W $wavedir, $wid, $width, $wildsite, $wildtok, $wildtokcs, $window, $wrap

X $xor

Y $yes

Z $zip

= =$nick