ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/Deliantra-Client/DC/Protocol.pm
(Generate patch)

Comparing deliantra/Deliantra-Client/DC/Protocol.pm (file contents):
Revision 1.187 by root, Sat Dec 29 13:44:30 2007 UTC vs.
Revision 1.192 by root, Thu Mar 27 20:42:23 2008 UTC

27 ); 27 );
28 28
29 $self->{map_widget}->clr_commands; 29 $self->{map_widget}->clr_commands;
30 30
31 my @cmd_help = map { 31 my @cmd_help = map {
32 $_->{kw}[0] =~ /^(\S+) (?:\s+ \( ([^\)]*) \) )?/x 32 $_->[DC::Pod::N_KW][0] =~ /^(\S+) (?:\s+ \( ([^\)]*) \) )?/x
33 or die "unparseable command help: $_->{kw}[0]"; 33 or die "unparseable command help: $_->[DC::Pod::N_KW][0]";
34 34
35 my $cmd = $1; 35 my $cmd = $1;
36 my @args = split /\|/, $2; 36 my @args = split /\|/, $2;
37 @args = (".*") unless @args; 37 @args = (".*") unless @args;
38 38
43 for @args; 43 for @args;
44 44
45 map ["$cmd$_", $text], 45 map ["$cmd$_", $text],
46 sort { (length $a) <=> (length $b) } 46 sort { (length $a) <=> (length $b) }
47 @args 47 @args
48 } sort { $a->{par} <=> $b->{par} } 48 } sort { $a->[DC::Pod::N_PAR] <=> $b->[DC::Pod::N_PAR] }
49 DC::Pod::find command => "*"; 49 DC::Pod::find command => "*";
50 50
51 $self->{json_coder} 51 $self->{json_coder}
52 ->convert_blessed 52 ->convert_blessed
53 ->filter_json_single_key_object ("\fw" => sub { 53 ->filter_json_single_key_object ("\fw" => sub {
275 spell_list => $::SPELL_LIST, 275 spell_list => $::SPELL_LIST,
276 276
277 floorbox => $::FLOORBOX, 277 floorbox => $::FLOORBOX,
278 help_window => $::HELP_WINDOW, 278 help_window => $::HELP_WINDOW,
279 message_window => $::MESSAGE_WINDOW, 279 message_window => $::MESSAGE_WINDOW,
280 message_dist => $::MESSAGE_DIST,
280 statusbox => $::SDTATUSBOX, 281 statusbox => $::SDTATUSBOX,
281 282
282 inv => $::INV, 283 inv => $::INV,
283 invr => $::INVR, 284 invr => $::INVR,
284 invr_hb => $::INVR_HB, 285 invr_hb => $::INVR_HB,
333 334
334# message window 335# message window
335sub ext_channel_info { 336sub ext_channel_info {
336 my ($self, $info) = @_; 337 my ($self, $info) = @_;
337 $self->{channels}->{$info->{id}} = $info; 338 $self->{channels}->{$info->{id}} = $info;
338 $::MESSAGE_WINDOW->add_channel ($info); 339 $::MESSAGE_DIST->add_channel ($info);
339} 340}
340 341
341############################################################################# 342#############################################################################
342 343
343sub logprint { 344sub logprint {
1139 1140
1140 my %skill_help; 1141 my %skill_help;
1141 1142
1142 for my $node (DC::Pod::find skill_description => "*") { 1143 for my $node (DC::Pod::find skill_description => "*") {
1143 my (undef, @par) = DC::Pod::section_of $node; 1144 my (undef, @par) = DC::Pod::section_of $node;
1144 $skill_help{$node->{kw}[0]} = DC::Pod::as_label @par; 1145 $skill_help{$node->[DC::Pod::N_KW][0]} = DC::Pod::as_label @par;
1145 }; 1146 };
1146 1147
1147 for my $skill (values %{$self->{skill_info}}) { 1148 for my $skill (values %{$self->{skill_info}}) {
1148 $self->{map_widget}->add_command ("ready_skill $skill", 1149 $self->{map_widget}->add_command ("ready_skill $skill",
1149 (DC::asxml "Ready the skill '$skill'\n\n") 1150 (DC::asxml "Ready the skill '$skill'\n\n")
1319 . "extended command support $yesno[$self->{setup}{extcmd} > 0]\n" 1320 . "extended command support $yesno[$self->{setup}{extcmd} > 0]\n"
1320 . "examine command support $yesno[$self->{setup}{excmd} > 0]\n" 1321 . "examine command support $yesno[$self->{setup}{excmd} > 0]\n"
1321 . "editing support $yesno[!!$self->{editor_support}]\n" 1322 . "editing support $yesno[!!$self->{editor_support}]\n"
1322 . "map attributes $yesno[$self->{setup}{extmap} > 0]\n" 1323 . "map attributes $yesno[$self->{setup}{extmap} > 0]\n"
1323 . "big image protocol support $yesno[$self->{setup}{fxix} > 0]\n" 1324 . "big image protocol support $yesno[$self->{setup}{fxix} > 0]\n"
1324 . "cfplus support $yesno[$self->{cfplus_ext} > 0]" 1325 . "client support $yesno[$self->{cfplus_ext} > 0]"
1325 . ($self->{cfplus_ext} > 0 ? ", version $self->{cfplus_ext}" : "") ."\n" 1326 . ($self->{cfplus_ext} > 0 ? ", version $self->{cfplus_ext}" : "") ."\n"
1326 . "map size $self->{mapw}×$self->{maph}\n" 1327 . "map size $self->{mapw}×$self->{maph}\n"
1327 ); 1328 );
1328 1329
1329} 1330}

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines