… | |
… | |
190 | $ob->reply (undef, $ob->contr->braced ? "You are braced." : "Not braced."); |
190 | $ob->reply (undef, $ob->contr->braced ? "You are braced." : "Not braced."); |
191 | |
191 | |
192 | 1 |
192 | 1 |
193 | }; |
193 | }; |
194 | |
194 | |
|
|
195 | cf::register_command 'output-count' => sub { |
|
|
196 | my ($ob, $arg) = @_; |
|
|
197 | |
|
|
198 | return $ob->reply (undef, "Output count is presently " . $ob->contr->outputs_count) |
|
|
199 | unless $arg > 0; |
|
|
200 | |
|
|
201 | $ob->contr->outputs_count ($arg); |
|
|
202 | $ob->reply (undef, "Output count now set to " . $ob->contr->outputs_count); |
|
|
203 | |
|
|
204 | 1 |
|
|
205 | }; |
|
|
206 | |
|
|
207 | cf::register_command 'output-sync' => sub { |
|
|
208 | my ($ob, $arg) = @_; |
|
|
209 | |
|
|
210 | return $ob->reply (undef, "Output sync time is presently " . $ob->contr->outputs_sync) |
|
|
211 | unless $arg > 0; |
|
|
212 | |
|
|
213 | $ob->contr->outputs_sync ($arg); |
|
|
214 | $ob->reply (undef, "Output sync time now set to " . $ob->contr->outputs_sync); |
|
|
215 | |
|
|
216 | 1 |
|
|
217 | }; |
|
|
218 | |
195 | # XXX: This has a bug. After one sets his wimpy level to 0 and resets it to |
219 | # XXX: This has a bug. After one sets his wimpy level to 0 and resets it to |
196 | # some other level (which may also be 0), this does not get echoed, |
220 | # some other level (which may also be 0), this does not get echoed, |
197 | # but it does get set. |
221 | # but it does get set. |
198 | cf::register_command wimpy => sub { |
222 | cf::register_command wimpy => sub { |
199 | my ($ob, $arg) = @_; |
223 | my ($ob, $arg) = @_; |
… | |
… | |
221 | #$ob->contr->peaceful ($ob->contr->peaceful ? 0 : 1); |
245 | #$ob->contr->peaceful ($ob->contr->peaceful ? 0 : 1); |
222 | #$ob->reply (undef, $ob->contr->peaceful ? "You will attack other players." : "You will not attack other players."); |
246 | #$ob->reply (undef, $ob->contr->peaceful ? "You will attack other players." : "You will not attack other players."); |
223 | |
247 | |
224 | 1 |
248 | 1 |
225 | }; |
249 | }; |
226 | |
|
|
227 | |
250 | |
228 | cf::register_command rename => sub { |
251 | cf::register_command rename => sub { |
229 | my ($ob, $arg) = @_; |
252 | my ($ob, $arg) = @_; |
230 | |
253 | |
231 | $ob->speed_left ($ob->speed_left - 0.25); |
254 | $ob->speed_left ($ob->speed_left - 0.25); |