Recordings File Format

Talk about anything here.
Post Reply
methnen
Posts: 1
Joined: Fri Jul 10, 2009 1:48 pm

Recordings File Format

Post by methnen »

Hello,

I'm working on a little project built around the recordings ability in Myth and wondered if you guys could point me to some information (or maybe provide some information) in regards to the actual format of the data.

I'd basically like to be able to reliably pull out the list of people in the battle (as well as teams if appropriate), the text chat/discussion as well as possibly the outcome (who won?).

This would be ideally done server side via a PHP script or something along those lines.

The file appears to be in a Binary format which obviously isn't ideal in this case so any insights would help.

Thanks a lot.

Methnen
User avatar
Doobie
Site Admin
Posts: 1121
Joined: Wed Jan 28, 2004 5:34 pm
Location: Calgary Alberta
Contact:

Re: Recordings File Format

Post by Doobie »

you need to talk to baak, he's put together some cool tools for working with films.
Want to play Myth? New and old Myth players can playmyth online at Mariusnet.com.
KyleMaclean.net
Graydon
Posts: 1605
Joined: Sun Mar 21, 2004 5:10 pm

Re: Recordings File Format

Post by Graydon »

As far as I'm aware (and that might not be very much) recordings in myth are basically 'saved games' that instead of loading all the actions and events that have occured and starting where you left off, it instead loads it up from the beginning and plays all the actions out real-time, allowing you to watch what occured. It's all bits of code that tell Myth 2 what to do with the units loaded on that mesh though.

Extracting the data that occurs in string list format (text basically) could be quite the trick.
Image
User avatar
Pyro
Bug Finder Extraordinaire
Posts: 4751
Joined: Sun Mar 21, 2004 2:14 pm
Location: Texas

Re: Recordings File Format

Post by Pyro »

Baak has done stuff like that if I recall correctly, he has extracted chat from films.

You could find him at the OoH forums.
User avatar
Baak
Posts: 1109
Joined: Sat Mar 20, 2004 6:26 pm
Location: Mything

Re: Recordings File Format

Post by Baak »

Graydon is correct: the films are like a series of vectors that play out only if run through the Myth Engine itself. There is no final information in there (unfortunately) -- although there has been talk of putting something in there at some point.

I remember dissecting a film long ago (when I first got into it) and staring at the screen in wonder as the game kept playing even though I had hacked off the end of the film. I kept hacking bits off and then it started ending differently. It's because the engine thought everything was at a certain point and just kept going from there, but I could not find the "exact point" when something happened because everything depends on everything else.

You can glean a certain amount of information from the film header (though some of it gets a little cryptic). One thing you cannot glean without access to the source code (don't even ask) is "random teams". Unless the teams are preset from the start, the teaming happens based on the random number seed in the film header and follows a non-obvious method (you have to have the source code to get it to work). So I just marked teams as random for these films, although you can still see the players.


Pyro is correct I dissected the chat code many moons ago as well and made it create a basic HTML extraction from the films. Here's a sample (team games show the team captain primary color for all players on the team -- ffa examples are further down -- note the special chars all print correctly and the time on the left shows pre-game Planning Time (-PT-) and post-game (+PG+) time as well as the timestamp including 1/30ths of a second ticks. Dang I got thorough on that:

http://www.orderofhpak.com/FilmPaks/HPa ... _Chat.html

I made a film renamer program and a separate Perl script (before I got into PHP -- again this was long ago) that dissected all the stats I could glean from the films and dumped them as a text file. Here's the last one for all the OoH official games (kinda stopped last April at the 6,418 game mark):

http://www.orderofhpak.com/Archives/HPa ... ummary.txt
Archer
Posts: 254
Joined: Sun May 02, 2004 11:01 pm

Re: Recordings File Format

Post by Archer »

It'd be a bit of a trick to filter out the garbage, and information about who said a given thing in in-game chat (as well as win/loss info) is lost, but you get a decent chunk of what you're looking for by just running strings on the film.

~J
Failure: when your best just isn't good enough.
GodzFire
Posts: 1774
Joined: Wed Nov 02, 2005 8:37 pm

Re: Recordings File Format

Post by GodzFire »

Baak I'm currently going through our Tools list to see what Myth Tools are still workable. Check out the thread there: http://tain.totalcodex.net/forum/viewto ... f=3&t=4476

Could you post your Film Programs you did, and if they are currently workable on Intel Macs.
User avatar
Baak
Posts: 1109
Joined: Sat Mar 20, 2004 6:26 pm
Location: Mything

Re: Recordings File Format

Post by Baak »

Godzfire: Alas, the program for film renaming is PC-only and the version I currently have is not suitable for public consumption. It's been on my list for awhile to make an on-line version (where you could submit films singly or in packs) as part of my toolbox of myth goodies. Also on the list is adding some aspects of the library of function to The Tain as a built-in feature. So they should make their way to public use eventually.
killerking
Posts: 297
Joined: Tue Jul 01, 2008 3:57 am
Location: The Netherlands
Contact:

Re: Recordings File Format

Post by killerking »

Wasn't there somekind of program for windows (could've been mac classic to, forgot that) that allowed you to play replay's outside Myth in a seperate program?
Post Reply