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.102 by root, Wed Apr 18 18:16:16 2007 UTC vs.
Revision 1.104 by root, Mon Apr 23 19:22:24 2007 UTC

20 my ($class, %arg) = @_; 20 my ($class, %arg) = @_;
21 21
22 my $self = $class->SUPER::new (%arg, 22 my $self = $class->SUPER::new (%arg,
23 setup_req => { 23 setup_req => {
24 extmap => 1, 24 extmap => 1,
25 excmd => 1,
25 %{$arg{setup_req} || {}}, 26 %{$arg{setup_req} || {}},
26 }, 27 },
27 ); 28 );
28 29
29 $self->{map_widget}->clr_commands; 30 $self->{map_widget}->clr_commands;
633 $LAST_QUERY = $prompt; 634 $LAST_QUERY = $prompt;
634 635
635 $self->{query}-> ($self, $flags, $prompt); 636 $self->{query}-> ($self, $flags, $prompt);
636} 637}
637 638
639our @CF_COLOR = (
640 [1.00, 1.00, 1.00], #[0.00, 0.00, 0.00],
641 [1.00, 1.00, 1.00],
642 [0.50, 0.50, 1.00], #[0.00, 0.00, 0.55]
643 [1.00, 0.00, 0.00],
644 [1.00, 0.54, 0.00],
645 [0.11, 0.56, 1.00],
646 [0.93, 0.46, 0.00],
647 [0.18, 0.54, 0.34],
648 [0.56, 0.73, 0.56],
649 [0.80, 0.80, 0.80],
650 [0.75, 0.61, 0.20],
651 [0.99, 0.77, 0.26],
652 [0.74, 0.65, 0.41],
653);
654
638sub drawinfo { 655sub drawinfo {
639 my ($self, $color, $text) = @_; 656 my ($self, $color, $text) = @_;
640 657
641 my @color = ( 658 my $fg = $CF_COLOR[$color % @CF_COLOR];
642 [1.00, 1.00, 1.00], #[0.00, 0.00, 0.00],
643 [1.00, 1.00, 1.00],
644 [0.50, 0.50, 1.00], #[0.00, 0.00, 0.55]
645 [1.00, 0.00, 0.00],
646 [1.00, 0.54, 0.00],
647 [0.11, 0.56, 1.00],
648 [0.93, 0.46, 0.00],
649 [0.18, 0.54, 0.34],
650 [0.56, 0.73, 0.56],
651 [0.80, 0.80, 0.80],
652 [0.75, 0.61, 0.20],
653 [0.99, 0.77, 0.26],
654 [0.74, 0.65, 0.41],
655 );
656
657 my $fg = $color[$color % @color];
658 659
659 $self->logprint ("info: ", $text); 660 $self->logprint ("info: ", $text);
660 661
661 ## try to create single paragraphs of multiple lines sent by the server 662 ## try to create single paragraphs of multiple lines sent by the server
662 # no longer neecssary with TRT servers 663 # no longer neecssary with TRT servers
921 $::SERVER_INFO->set_markup ( 922 $::SERVER_INFO->set_markup (
922 "server <tt>$self->{host}:$self->{port}</tt>\n" 923 "server <tt>$self->{host}:$self->{port}</tt>\n"
923 . "protocol version <tt>$self->{version}</tt>\n" 924 . "protocol version <tt>$self->{version}</tt>\n"
924 . "minimap support $yesno[$self->{setup}{mapinfocmd} > 0]\n" 925 . "minimap support $yesno[$self->{setup}{mapinfocmd} > 0]\n"
925 . "extended command support $yesno[$self->{setup}{extcmd} > 0]\n" 926 . "extended command support $yesno[$self->{setup}{extcmd} > 0]\n"
927 . "examine command support $yesno[$self->{setup}{excmd} > 0]\n"
926 . "editing support $yesno[!!$self->{editor_support}]\n" 928 . "editing support $yesno[!!$self->{editor_support}]\n"
927 . "map attributes $yesno[$self->{setup}{extmap} > 0]\n" 929 . "map attributes $yesno[$self->{setup}{extmap} > 0]\n"
930 . "big image protocol support $yesno[$self->{setup}{fxix} > 0]\n"
928 . "cfplus support $yesno[$self->{cfplus_ext} > 0]" 931 . "cfplus support $yesno[$self->{cfplus_ext} > 0]"
929 . ($self->{cfplus_ext} > 0 ? ", version $self->{cfplus_ext}" : "") ."\n" 932 . ($self->{cfplus_ext} > 0 ? ", version $self->{cfplus_ext}" : "") ."\n"
930 . "map size $self->{mapw}×$self->{maph}\n" 933 . "map size $self->{mapw}×$self->{maph}\n"
931 ); 934 );
932 935

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines