GTAStunting

GTA Series => GTA Modding => Topic started by: Reynard The Fox on July 17, 2014, 06:33:45 AM

Title: ReplayReader [SA]
Post by: Reynard The Fox on July 17, 2014, 06:33:45 AM
Info

This all started out as a little project for me all the way back in 2008. I was determined to find a solution to the modding problem that plagues San Andreas. I tried all sorts of things like trying to make a replay speedometer, memory hacking and figuring out the replay format. A while back I found the replay template for 010editor made by Seemann. This really gave me a head start for reading out the replays. I'm not sure about the effectiveness of the program. For me it was just something I really wanted to make for a very long time follow your dreams.

Development

The program is written in Java. There is a great open-source chart library, called JFreeChart, that I used for the drawing of the plots. Initially I wanted to make this program in C++, but due to time constraints, and no prior experience with the language except for regular C, I abolished this idea. The GUI is just regular Java-swing.
If there is enough interest I will make the source public (after I commented the code though).

Analyzing Replays

Before I actually jump into the analyzing I just wanted to mention that this program does not give ANY guarantee that you can spot possible modifications.
So the different things you can view plots of are the coordinates, velocity*, speeds and acceleration. This can be done for every vehicle that occurs in the replay. Note that the speeds and acceleration plots are calculated by the program itself based on the XYZ-coordinates and were not in the replay.

(* The velocity values are read directly from the replay, however I have no idea what they mean just that they fluctuate in a nonsensical way.)

Download

Mediafire:
http://www.mediafire.com/download/m4jkjrgweuffh3r/ReplayReader_v1.0.rar (http://www.mediafire.com/download/m4jkjrgweuffh3r/ReplayReader_v1.0.rar)

Just extract where ever you like and run the executable file.


Instructions

Open a replay and then select the vehicle for which you want to see the plots.


Bugs

Report any bugs you encounter in this thread.

Shout-outs
Rusch69, Artifex for sending me replays and helping out.

Have fun  :cc_detective:
Title: Re: ReplayReader [SA]
Post by: hachi on July 17, 2014, 06:53:43 AM
best project
Title: Re: ReplayReader [SA]
Post by: imbaA on July 17, 2014, 07:10:24 AM
God damn it you must do this for VC too.
Title: Re: ReplayReader [SA]
Post by: Rusch69 on July 17, 2014, 07:12:41 AM
Pinned right away.

Unfortunately I don't have the time to check it out today, but I know this is gonna come in handy. Sadly this is way too late and modders will now still try to find some workaround. Anyway, still big props for having this made dude. I'm sure it'll be all way easier and has more ground to it now.
Title: Re: ReplayReader [SA]
Post by: MxZz. on July 17, 2014, 07:22:55 AM
Daaaaaaamn, did you finish that only now? Great release, such work  :wub:
Title: Re: ReplayReader [SA]
Post by: Blaze on July 17, 2014, 07:35:05 AM
I don't play SA but this is definitely gonna help those who do. Any chance it could be ported to the VC engine? I'm not 100% on coding but arent III/VC/SA ran on the same engine/file system? Obviously it would require some changes but a VC version of this would be spectacular.

Good work man.
Title: Re: ReplayReader [SA]
Post by: Nagash on July 17, 2014, 07:45:15 AM
This will be useful on seeing if somebody used speedhack on his run-up, it's not useful on bump speeding from what I've checked
Title: Re: ReplayReader [SA]
Post by: Artifex on July 17, 2014, 08:27:39 AM
Lekker gerben
Title: Re: ReplayReader [SA]
Post by: VaNilla on July 17, 2014, 10:04:21 AM
Nice job :D. Don't know how accurate this can be, given the calculation of the data, but it will be interesting to see how it is used.
Title: Re: ReplayReader [SA]
Post by: Minq on July 17, 2014, 10:57:08 AM
Aren't replays are faster and slower with low and high fps ? Also isn't the speed than also different ? Cool work,it even leads u to the java site ^^.  btw correct me if i'm wrong
Title: Re: ReplayReader [SA]
Post by: VaNilla on July 17, 2014, 10:58:32 AM
Aren't replays are faster and slower with low and high fps ? Also isn't the speed than also different ? Cool work,it even leads u to the java site ^^.

Yes, but the interpolation of the data within the replay file in game doesn't affect the output. Just tested this program out, awesome job :cheernutz:. Finally can prove some things, a little at least :ninja:.

EDIT: Tool crashes using some replays without running admin rights. Crashing quite consistently opening some WH replays, even with admin rights (which seems to work sometimes, but not always). However, some replays work upon opening them at first, and then crash at other times.

EDIT 2: Some replays report NUL values across all categories - http://gyazo.com/244af560447fbaa4fd70d74d01d2cb2c (http://gyazo.com/244af560447fbaa4fd70d74d01d2cb2c)

EDIT 3: Velocity and Acceleration seem completely broken (as you mentioned). Here's what a constant speed grind looks like, replay beginning and ending on the grind (acelleration X values).

(http://i.gyazo.com/8a6119129084512ce0625d4c691b0c85.png)

Really awesome co-ords tracking though. Works 100% for me (when it's not reporting NUL, regardless of the vehicle selected :P). Seems like there's a lot of bugs to sort out, perhaps inherent to the replay data itself, but good start :ajaja:.
Title: Re: ReplayReader [SA]
Post by: Reynard The Fox on July 17, 2014, 03:21:52 PM
I guess those spikes are when the player is teleported? They really mess up the view of the data but I forgot to mention that it is possible to zoom in on a part of the graph. Th is way you can actually see that the value is not zero but a little more depending on the value ofcourse. I might be wrong though and thats why I encourage you to send me the replays so I can troubleshoot them. Send them via skypeso that I can easily ask you questions about the stunt also (I don't have  access to SA atm). Also why do you capitalise the word nul because you are confusing me with NULL which in this case will give an completely other output,  namely of no graph at all. The program crashing is likely due to weird replay blocks inside the replay that have never occured in my test replays and thus I wasnt able to debug them. I am very interested in those. Thanks for the help though.
Title: Re: ReplayReader [SA]
Post by: Diaz on July 17, 2014, 03:38:25 PM
Amazing job, great effort, I just hope that the bugs can be sort out and it will work properly. It would be good to use it everytime with reliability when someone gets accused.
Title: Re: ReplayReader [SA]
Post by: VaNilla on July 17, 2014, 07:56:42 PM
I guess those spikes are when the player is teleported? They really mess up the view of the data but I forgot to mention that it is possible to zoom in on a part of the graph. Th is way you can actually see that the value is not zero but a little more depending on the value ofcourse. I might be wrong though and thats why I encourage you to send me the replays so I can troubleshoot them. Send them via skypeso that I can easily ask you questions about the stunt also (I don't have  access to SA atm). Also why do you capitalise the word nul because you are confusing me with NULL which in this case will give an completely other output,  namely of no graph at all. The program crashing is likely due to weird replay blocks inside the replay that have never occured in my test replays and thus I wasnt able to debug them. I am very interested in those. Thanks for the help though.

NULL is what I meant. The spikes were simply random, no teleporting occurred. Straight grind, beginning and ending on the rail. I no longer have the specific replay, this was just a quick test of accuracy as to the velocity. The crashing happened with a bunch of different replays I've tested from people, maybe I'll send some soon :P.
Title: Re: ReplayReader [SA]
Post by: NumeRo on July 17, 2014, 11:10:27 PM
this will be helpful :jajaja:
Title: Re: ReplayReader [SA]
Post by: Lex on July 18, 2014, 04:26:49 AM
This mod works perfectly  :a-cheer:
SimplePortal 2.3.7 © 2008-2024, SimplePortal