--- deliantra/Deliantra-Client/DC.pm 2007/12/26 21:03:21 1.169 +++ deliantra/Deliantra-Client/DC.pm 2008/05/22 20:45:20 1.182 @@ -17,7 +17,7 @@ use Carp (); BEGIN { - $VERSION = '0.9962'; + $VERSION = '0.9972'; use XSLoader; XSLoader::load "Deliantra::Client", $VERSION; @@ -166,13 +166,13 @@ } sub write_cfg { - my ($file) = @_; + my $file = "$Deliantra::VARDIR/client.cf"; $::CFG->{VERSION} = $::VERSION; open my $fh, ">:utf8", $file or return; - print $fh encode_json $::CFG; + print $fh JSON::XS->new->utf8->pretty->encode ($::CFG); } sub http_proxy { @@ -200,7 +200,7 @@ DC::set_proxy; my $ua = LWP::UserAgent->new ( - agent => "cfplus $VERSION", + agent => "deliantra $VERSION", keep_alive => 1, env_proxy => 1, timeout => 30, @@ -225,7 +225,6 @@ } else { fcntl $fh, &Fcntl::F_SETFL, $nb ? &Fcntl::O_NONBLOCK : 0; } - } package DC::Layout;