demos/demotool output error

demos/demotool output error

Discuss your problems with the latest release of the engine here. Problems with games, maps or other utilities belong in their respective forums.

Moderator: Moderators

Post Reply
nop@
Posts: 2
Joined: 22 Aug 2011, 21:07

demos/demotool output error

Post by nop@ »

I'm not sure if there's corruption in the demo recording, the demotool or somewhere else. Either way when I run the demotool, all the stats it reports are way off. If I had to guess it looks like an endian issue, but I'm not 100% sure. I just figured I'd check here before posting a bug report.

If there's another way to get the game statistics that'd be helpful too.

My output looks like this:
-- Team statistics for player 0, game second 128 --
MetalUsed: 7.88861e-030
EnergyUsed: 0
MetalProduced: 0
EnergyProduced: 0
MetalExcess: 1.07003e+038
EnergyExcess: 2.6364e-041
MetalReceived: -1.44504e+024
EnergyReceived: 2.63542e-041
MetalSent: 0
EnergySent: 0
DamageDealt: 0
DamageReceived: 0
UnitsProduced: 0
UnitsDied: 5767168
UnitsReceived: 65536
UnitsSent: 0
UnitsCaptured: 0
UnitsOutCaptured: 0
UnitsKilled: 0
User avatar
knorke
Posts: 7971
Joined: 22 Feb 2006, 01:02

Re: demos/demotool output error

Post by knorke »

corruption in the demo recording
if that happend, the replay would not play correctly at all. you would notice pretty soon that the replay plays different then the real game.

what demotool do you mean?
nop@
Posts: 2
Joined: 22 Aug 2011, 21:07

Re: demos/demotool output error

Post by nop@ »

knorke wrote:
corruption in the demo recording
if that happend, the replay would not play correctly at all. you would notice pretty soon that the replay plays different then the real game.

what demotool do you mean?
I'm using the demotool provided in the source code. I'm mostly looking to get the stats that are presented at the end of a match (damage over time, units lost etc). It seems like that data is saved in the demo files, but I have no way to read it outside of the demotool (as far as I know).
User avatar
knorke
Posts: 7971
Joined: 22 Feb 2006, 01:02

Re: demos/demotool output error

Post by knorke »

hm, at least UnitsReceived: 65536 seems like a bug because 65536 is also 2^16?
so i guess you could make a real bugreport...

If there's another way to get the game statistics that'd be helpful too.
if you do not mind running the whole replay (on fast forward) you can use Lua scripting.
abma
Spring Developer
Posts: 3798
Joined: 01 Jun 2009, 00:08

Re: demos/demotool output error

Post by abma »

i'm unsure if this bug is fixed in current spring master... can you check that?

if the bug still persits, it should be located here:
https://github.com/spring/spring/blob/m ... r.cpp#L107

https://github.com/spring/spring/blob/m ... r.cpp#L235

which version of the demotool did you use?

did you compile the demotool from the 0.82.7.1 source-code? your link on github goes to the development version, this demotool should be incompatible to demos recoreded in 0.82.7.1... correct link would be: https://github.com/spring/spring/tree/0 ... s/DemoTool
Post Reply

Return to “Help & Bugs”