Project

General

Profile

$eventtarget » History » Version 8

Per Amundsen, 08/18/2021 09:37 PM

1 1 Per Amundsen
_Added in 2.3_
2
3 8 Per Amundsen
*$eventtarget(type, [channel], [nick])*
4 1 Per Amundsen
5
Returns the event target settings for a event type/channel.
6
7
0 = In Channel.
8
1 = In Status.
9
2 = Hide.
10
11
_Number is relative to the event dropdowns._
12
13 4 Per Amundsen
*Parameters*
14 1 Per Amundsen
15 7 Per Amundsen
type - Event type to check (Join,Mode,Part,Topic,Quit,Ctcp,Kick,Nick,Names,Away,Invite,Whois,Error,Private,Wallops,Notice,Motd,SNotice,PingPong).
16 1 Per Amundsen
[channel] - The channel to check. (If no channel is specified, the global value is returned)
17 8 Per Amundsen
[nick] - if specified, the nick to check for the "[[Messages_Options#Only-show-join-parts-quits-nick-from-active-users|Only show join parts quits nick from active users]]" option.
18 1 Per Amundsen
19
*Example*
20
21
<pre>
22 2 Per Amundsen
on ^*:JOIN:*:{
23 1 Per Amundsen
  if ($eventtarget(join, #) == 2) {
24
    ; Hide
25
    halt
26
  }
27
28
  if ($eventtarget(join, #) == 1) {
29
    ; Show in status window.
30
    echo -s $nick joins #
31
  }
32
  else {
33
    ; Show in channel window.
34
    echo # $nick joins #
35
  }
36 2 Per Amundsen
37
  halt
38 1 Per Amundsen
}
39
</pre>