Extract car location from replay

Moderators: Xymph, NADEO

User avatar
Phenom
Posts: 63
Joined: 28 Feb 2014, 23:54

Extract car location from replay

Post by Phenom »

Hi all

I'm working on a new features for my application and I'm looking at retrieving car location from a replay. I think I've already found the section where the data are, but I can't get how there are arrange (data / offset position / length).

The section is 0303F006 but it is not in the reference table of the GBX on the wiki. I think it works almost the same way as the 0303F005 but I can't found out how to get usable data.

If someone from Nadeo or a member may give me a hint, that would be nice !
Creator of Lerya
Race graphic viewer for TrackMania²
More information on http://www.lerya.org
User avatar
Electron
Posts: 797
Joined: 15 Jun 2010, 18:02
Contact:

Re: Extract car location from replay

Post by Electron »

The layout of chunk 0303F006 is:

Code: Select all

uint32 IsReplaying
... (fall-through chunk 0303F005)
The described part of the layout of chunk 0303F005 in the Wiki seems to be correct.
Image
TM²: TrackMania Telemetry Monitor version 1.2.4
User avatar
Phenom
Posts: 63
Joined: 28 Feb 2014, 23:54

Re: Extract car location from replay

Post by Phenom »

Damm, I may not be on the right page. Thanks for the reply !

I'm taking all information from here : http://en.tm-wiki.org/wiki/GBX

Is there another wiki for maniaplanet 2 ? Where did you find your source ?
Creator of Lerya
Race graphic viewer for TrackMania²
More information on http://www.lerya.org
User avatar
Electron
Posts: 797
Joined: 15 Jun 2010, 18:02
Contact:

Re: Extract car location from replay

Post by Electron »

I'm taking all information from here : http://en.tm-wiki.org/wiki/GBX
This documentation describes the Gbx file format of TMNF. Only the headers and some chunks (blocks, lightmaps) of the compressed body are updated for Maniaplanet.
Where did you find your source ?
Directly from the executable. It looks like the description of chunk 0303F005 is not complete. Depending of "IsReplaying" more data fields follows.
Last edited by Electron on 11 Jun 2017, 14:10, edited 1 time in total.
User avatar
Phenom
Posts: 63
Joined: 28 Feb 2014, 23:54

Re: Extract car location from replay

Post by Phenom »

Thanks for your reply. That explain why I wasn't able to get what I want.

You wrote"from the executable". What do you mean exactly ? Are your using ManiaplanetLauncher with an argument to get this information ? How I may get those infos ? Sorry for asking some question that might seems to be stupid :|
Creator of Lerya
Race graphic viewer for TrackMania²
More information on http://www.lerya.org
User avatar
phil13hebert
Posts: 564
Joined: 29 Oct 2011, 14:11
Location: Québec

Re: Extract car location from replay

Post by phil13hebert »

I think that it's harder than only adding an argument to the game.
OS: Windows 7 64 bit
CPU: Intel Core i7 3770 @ 3.40Ghz
RAM: 8GB DDR3 798MHz
GPU: Nvidia GeForce GTX 660 1536MB
Motherboard: Intel 0KM92T
Sound: 7.1
Peripherals: Logitech G510, SteelSeries sensei raw, Corsair vengeance 1500
User avatar
Phenom
Posts: 63
Joined: 28 Feb 2014, 23:54

Re: Extract car location from replay

Post by Phenom »

phil13hebert wrote:I think that it's harder than only adding an argument to the game.
Yes, I think it must not be the correct way, but we can dream :D
Creator of Lerya
Race graphic viewer for TrackMania²
More information on http://www.lerya.org
User avatar
Phenom
Posts: 63
Joined: 28 Feb 2014, 23:54

Re: Extract car location from replay

Post by Phenom »

Electron, may you help me ? :D
Creator of Lerya
Race graphic viewer for TrackMania²
More information on http://www.lerya.org
User avatar
Electron
Posts: 797
Joined: 15 Jun 2010, 18:02
Contact:

Re: Extract car location from replay

Post by Electron »

Phenom wrote:Electron, may you help me ? :D
Some things should remain internal/closed. I don't know if this subject is one of them. I have no interest to write a tool to read this data section and to interpret them.
If you're so advanced and need information that goes beyond the Wiki documentation, then I will research and try to answer your specific questions.
User avatar
Phenom
Posts: 63
Joined: 28 Feb 2014, 23:54

Re: Extract car location from replay

Post by Phenom »

Ok thanks.

In fact, I was expected this kind of answer, since Nadeo should protect its informations. What I just need is to locate and extract CGameGhostInfo, especially Player location, speed, angle etc. I don't want to trick the replay, I just want to extract trajectory.
Since this part is documented in WIKI, I think it wouldn't be an issues. However, I can't put an hand on the 03 03F 005 (CGameGhostInfo) on a Replay.Gbx file and I'm sure it contain position. May the chunk have a different ID ?

EDIT : Maybe I should contact Nadeo team directly to see if it's possible to retrieve those data ...
Creator of Lerya
Race graphic viewer for TrackMania²
More information on http://www.lerya.org
Post Reply

Return to “General Tools”

Who is online

Users browsing this forum: No registered users and 1 guest