alias comchanM {
var %nick = $1, %room = $2, %cid = $3, %cx = $scon(0), %num
if ($0 != 3 || (%cid == 0 && %room != 0)) { echo -s $!comchanM invalid parameters | halt }
if (%cid != 0) { scid %cid | return $iif($prop == net,$network,$($+($,comchan(%nick,%room),$iif($prop,$+(.,$prop))),2)) }
while (%cx) { scid $scon(%cx) | inc %num $comchan(%nick,0) | scid -r | dec %cx }
return %num
}
Usage: $comchanm(nick,channel,cid).property
Same properties as $comchan, with a new one: net
$comchanm(nick,0,0) = total rooms
$comchanm(nick,0,1) = total rooms on first connection
$comchanm(nick,1,1) = name of first room on first connection
$comchanm(nick,x,1).net = name of first connection network
other properties work the same (.op, .help, .voice)
Enjoy.