… | |
… | |
65 | |
65 | |
66 | if ($msg) { |
66 | if ($msg) { |
67 | my $name = $who->name; |
67 | my $name = $who->name; |
68 | my $NOW = time; |
68 | my $NOW = time; |
69 | |
69 | |
|
|
70 | cf::LOG cf::llevDebug, sprintf "QBERT [%s] %s\n", $name, $msg; |
|
|
71 | |
70 | $_->ob->message ("$name chats: $msg", cf::NDI_BLUE) |
72 | $_->ob->message ("$name chats: $msg", cf::NDI_BLUE) |
71 | for grep { $_->ob->{ext_ignore_shout}{$name} < $NOW && $_->listening >= 10 } cf::player::list; |
73 | for grep { $_->ob->{ext_ignore_shout}{$name} < $NOW && $_->listening >= 10 } cf::player::list; |
72 | |
74 | |
73 | } else { |
75 | } else { |
74 | $who->message ("Chat what?", cf::NDI_UNIQUE); |
76 | $who->message ("Chat what?", cf::NDI_UNIQUE); |
… | |
… | |
79 | my ($who, $msg) = @_; |
81 | my ($who, $msg) = @_; |
80 | |
82 | |
81 | if ($msg) { |
83 | if ($msg) { |
82 | my $NOW = time; |
84 | my $NOW = time; |
83 | my $name = $who->name; |
85 | my $name = $who->name; |
|
|
86 | |
|
|
87 | cf::LOG cf::llevDebug, sprintf "QBERT {%s} %s\n", $name, $msg; |
84 | |
88 | |
85 | $_->ob->message ("$name shouts: $msg", cf::NDI_RED) |
89 | $_->ob->message ("$name shouts: $msg", cf::NDI_RED) |
86 | for grep { $_->ob->{ext_ignore_shout}{$name} < $NOW && $_->listening >= 2 } cf::player::list; |
90 | for grep { $_->ob->{ext_ignore_shout}{$name} < $NOW && $_->listening >= 2 } cf::player::list; |
87 | |
91 | |
88 | } else { |
92 | } else { |
… | |
… | |
103 | if ($target eq $name) { |
107 | if ($target eq $name) { |
104 | $who->message ("You are talking to yourself, you freak!", cf::NDI_UNIQUE); |
108 | $who->message ("You are talking to yourself, you freak!", cf::NDI_UNIQUE); |
105 | } elsif ($other->ob->{ext_ignore_tell}{$name} >= time) { |
109 | } elsif ($other->ob->{ext_ignore_tell}{$name} >= time) { |
106 | $who->message ("$target ignores what you say. Give up on it.", cf::NDI_UNIQUE); |
110 | $who->message ("$target ignores what you say. Give up on it.", cf::NDI_UNIQUE); |
107 | } else { |
111 | } else { |
|
|
112 | cf::LOG cf::llevDebug, sprintf "TELL [%s>%s] %s\n", $name, $target, $msg; |
|
|
113 | |
108 | $who->message ("You tell $target: $msg"); |
114 | $who->message ("You tell $target: $msg"); |
109 | $other->ob->message ("$name tells you: $msg"); |
115 | $other->ob->message ("$name tells you: $msg"); |
110 | $other->ob->{ext_last_tell} = $name; |
116 | $other->ob->{ext_last_tell} = $name; |
111 | } |
117 | } |
112 | } else { |
118 | } else { |
… | |
… | |
127 | |
133 | |
128 | $other->ob->{ext_ignore_tell}{$name} >= time |
134 | $other->ob->{ext_ignore_tell}{$name} >= time |
129 | or delete $other->ob->{ext_ignore_tell}{$name}; |
135 | or delete $other->ob->{ext_ignore_tell}{$name}; |
130 | |
136 | |
131 | if ($other->ob->{ext_ignore_tell}{$name} < time) { |
137 | if ($other->ob->{ext_ignore_tell}{$name} < time) { |
|
|
138 | cf::LOG cf::llevDebug, sprintf "TELL [%s>%s] %s\n", $name, $other->ob->name, $args; |
|
|
139 | |
132 | $who->message ("You tell " . $other->ob->name . ": $args"); |
140 | $who->message ("You tell " . $other->ob->name . ": $args"); |
133 | $other->ob->message ("$name tells you: $args"); |
141 | $other->ob->message ("$name tells you: $args"); |
134 | $who->{ext_last_tell} = $other->ob->name; |
142 | $who->{ext_last_tell} = $other->ob->name; |
135 | } else { |
143 | } else { |
136 | $who->message ($other->ob->name . " ignores what you say. Give up on it.", cf::NDI_UNIQUE); |
144 | $who->message ($other->ob->name . " ignores what you say. Give up on it.", cf::NDI_UNIQUE); |