X-Git-Url: https://ruin.nu/git/?a=blobdiff_plain;f=NDWeb%2FPages%2FRaids.pm;h=ac1f6b9f936cb2127ef0b30eef885724fdf48b9d;hb=34876053e79ee0153b38c8cad7c9404322472f29;hp=3fb41458751caa7371a37127e46fc87a9567b4f4;hpb=a6f56779ad3ca2c9a2568bc501917c46454853cb;p=ndwebbie.git diff --git a/NDWeb/Pages/Raids.pm b/NDWeb/Pages/Raids.pm index 3fb4145..ac1f6b9 100644 --- a/NDWeb/Pages/Raids.pm +++ b/NDWeb/Pages/Raids.pm @@ -222,9 +222,9 @@ sub render_body { $target{Id} = $target->{id}; $target{Race} = $target->{race}; my $num = pow(10,length($target->{score})-2); - $target{Score} = ceil($target->{score}/$num)*$num; + $target{Score} = "Hidden"; #ceil($target->{score}/$num)*$num; $num = pow(10,length($target->{value})-2); - $target{Value} = ceil($target->{value}/$num)*$num; + $target{Value} = "Hidden"; #ceil($target->{value}/$num)*$num; $num = pow(10,length($target->{size})-2); $target{Size} = floor($target->{size}/$num)*$num; $num = pow(10,length($target->{fleetvalue})-2); @@ -245,14 +245,14 @@ sub render_body { ORDER BY name,i.tick DESC }); $unitscans->execute($target->{planet}) or warn $DBH->errstr; - my $ships = $DBH->prepare(q{SELECT ship,amount FROM fleet_ships WHERE id = ?}); + my $ships = $DBH->prepare(q{SELECT ship,amount FROM fleet_ships + WHERE id = ? ORDER BY num + }); my @missions; while (my $mission = $unitscans->fetchrow_hashref){ my @ships; $ships->execute($mission->{id}); - my $j = 0; while (my $ship = $ships->fetchrow_hashref){ - $ship->{ODD} = $j++ % 2; push @ships,$ship; } push @ships, {ship => 'No', amount => 'ships'} if @ships == 0; @@ -282,7 +282,7 @@ sub render_body { $size -= $roids; my $xp = 0; if ($planet){ - $xp = pa_xp($roids,$planet->{score},$planet->{value},$target{Score},$target{Value}); + $xp = pa_xp($roids,$planet->{score},$planet->{value},$target->{score},$target->{value}); } push @roids,{Wave => $i, Roids => $roids, XP => $xp}; if ($self->{AJAX}){