--- deliantra/Deliantra-Client/DC/Protocol.pm 2007/08/22 21:27:13 1.164 +++ deliantra/Deliantra-Client/DC/Protocol.pm 2007/08/30 07:08:17 1.168 @@ -403,7 +403,7 @@ my @diffs = map $_->[1]->($self, $_->[2], $prev->{$_->[0]}, $stats->{$_->[0]}), @statchange ) { my $msg = "stat change: " . (join " ", @diffs); - $self->{statusbox}->add ($msg, group => "stat $msg", fg => [0.8, 1, 0.2, 1], timeout => 10); + $self->{statusbox}->add ($msg, group => "stat $msg", fg => [0.8, 1, 0.2, 1], timeout => 20); } $self->update_stats_window ($stats, $prev); @@ -568,7 +568,7 @@ my ($idx, $name) = @$_; my $val = $stats->{$idx}; - next if $prev->{$idx}[1] == $val->[1]; + next if $prev->{$idx}[1] eq $val->[1]; my $sw = $self->{skillwid}{$idx}; $sw->[0]->set_text (::formsep ($val->[1])); @@ -580,14 +580,6 @@ } } -sub macro_send { - my ($self, $macro) = @_; - - for my $cmd (@{ $macro->{action} }) { - $self->send_command ($cmd); - } -} - sub user_send { my ($self, $command) = @_; @@ -596,7 +588,6 @@ $self->logprint ("send: ", $command); $self->send_command ($command); - ::status ($command); } sub record { @@ -889,23 +880,19 @@ my ($meta, $data) = unpack "(w/a*)*", $face->{data}; $face->{data} = $meta; + # rely on strict ordering here and also on later fetch CFPlus::DB::put res_data => $face->{name} => $data, sub { }; CFPlus::DB::put res_meta => $face->{name} => $meta, sub { }; } $face->{data} = $self->{json_coder}->decode ($face->{data}); - ::add_license ($face); + ::message ({ markup => CFPlus::asxml "downloaded resource '$face->{data}{name}', type $face->{type}." }) + if $changed; if ($face->{type} == 3) { # FT_MUSIC - ::message ({ markup => "downloaded song #$facenum" }) - if $changed; - &::audio_music_push ($facenum); } elsif ($face->{type} == 5) { # FT_SOUND - ::message ({ markup => "downloaded sound #$facenum" }) - if $changed; - &::audio_sound_push ($facenum); }