… | |
… | |
17 | use base 'Crossfire::Protocol::Base'; |
17 | use base 'Crossfire::Protocol::Base'; |
18 | |
18 | |
19 | sub new { |
19 | sub new { |
20 | my $class = shift; |
20 | my $class = shift; |
21 | |
21 | |
22 | my $self = $class->SUPER::new (@_, setup_req => { extmap => 1 }); |
22 | my $self = $class->SUPER::new (@_, |
|
|
23 | setup_req => { |
|
|
24 | extmap => 1, |
|
|
25 | smoothing => 1, |
|
|
26 | }, |
|
|
27 | ); |
23 | |
28 | |
24 | $self->{map_widget}->clr_commands; |
29 | $self->{map_widget}->clr_commands; |
25 | |
30 | |
26 | my @cmd_help = map { |
31 | my @cmd_help = map { |
27 | $_->{kw}[0] =~ /^(\S+) (?:\s+ \( ([^\)]*) \) )?/x |
32 | $_->{kw}[0] =~ /^(\S+) (?:\s+ \( ([^\)]*) \) )?/x |
… | |
… | |
585 | if $changed; |
590 | if $changed; |
586 | |
591 | |
587 | $self->set_texture ($face->{id} => delete $face->{image}); |
592 | $self->set_texture ($face->{id} => delete $face->{image}); |
588 | } |
593 | } |
589 | |
594 | |
|
|
595 | sub smooth_update { |
|
|
596 | my ($self, $facenum, $face) = @_; |
|
|
597 | |
|
|
598 | $self->{map}->set_smooth ($facenum, $face->{smoothface}, $face->{smoothlevel}); |
|
|
599 | } |
|
|
600 | |
590 | sub set_texture { |
601 | sub set_texture { |
591 | my ($self, $id, $data) = @_; |
602 | my ($self, $id, $data) = @_; |
592 | |
603 | |
593 | $self->{texture}[$id] = my $tex = |
604 | $self->{texture}[$id] = my $tex = |
594 | new_from_image CFPlus::Texture |
605 | new_from_image CFPlus::Texture |