X-Git-Url: http://dxcluster.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=perl%2FDXCommandmode.pm;h=65d5eb0392d4699fa63672f1de400a46900f0f11;hb=defc60f3e7fab9bb99d1c9f7b8bccc4ec37628d5;hp=1750fee157acd6e87d497ec539642a6b08530893;hpb=a7d7ca1d8383bea004544d002748db81d867ea11;p=spider.git diff --git a/perl/DXCommandmode.pm b/perl/DXCommandmode.pm index 1750fee1..65d5eb03 100644 --- a/perl/DXCommandmode.pm +++ b/perl/DXCommandmode.pm @@ -802,6 +802,26 @@ sub announce $self->local_send($target eq 'WX' ? 'W' : 'N', $buf); } +# send a chat +sub chat +{ + my $self = shift; + my $line = shift; + my $isolate = shift; + my $to = shift; + my $target = shift; + my $text = shift; + my ($filter, $hops); + + return unless grep uc $_ eq $target, @{$self->{user}->{group}}; + + $text =~ s/^\#\d+ //; + my $buf = "$target de $_[0]: $text"; + $buf =~ s/\%5E/^/g; + $buf .= "\a\a" if $self->{beep}; + $self->local_send('C', $buf); +} + # send a dx spot sub dx_spot {