Why was replay format changed? - Page 2

Why was replay format changed?

Discuss the source code and development of Spring Engine in general from a technical point of view. Patches go here too.

Moderator: Moderators

User avatar
TradeMark
Posts: 4867
Joined: 17 Feb 2006, 15:58

Re: Why was replay format changed?

Post by TradeMark »

imbaczek wrote:trademark: i didn't notice any bug reports from you before release, is it perhaps because you, like, didn't test it?
Or because the only way you can notice this is when you upload replay at replays.adune.nl
Tobi wrote:
Tobi wrote:This is because only the host has to specify the script and Spring sends it over by itself. Reduces chance for sync errors due to lobby errors by a huge amount.
Fucking stupid eh, that we reduced chance for sync errors caused by lobby bugs?
My point is that you make such changes which requires me to use unitsync.dll to read the replay script.txt, when in old versions there was no need for such, and you could easily just cut the script.txt from the replay by using the header data. Now you need to process the stuff with unitsync.dll, when the simpliest thing is to just tell where is the script.txt and how long it is.

You guys love to make / explain stuff too complicated :?
imbaczek
Posts: 3629
Joined: 22 Aug 2006, 16:19

Re: Why was replay format changed?

Post by imbaczek »

it's not that hard to parse a binary stream, really. you could actually try a recent build (post 78.1.1) and see for yourself that some bugs (like the missing startscript) were fixed.
MelTraX
Posts: 470
Joined: 02 Jan 2007, 16:18

Re: Why was replay format changed?

Post by MelTraX »

TradeMark, it's basically a bug. You shouldn't have to change anything to get to the startscript, it's just not there in the current version. It will be in the next. (I know it looks like it's there but it isn't where it's supposed to be.)
Auswaschbar
Spring Developer
Posts: 1254
Joined: 24 Jun 2007, 08:34

Re: Why was replay format changed?

Post by Auswaschbar »

Information is wrong. Its not (yet) fixed.
MelTraX
Posts: 470
Joined: 02 Jan 2007, 16:18

Re: Why was replay format changed?

Post by MelTraX »

I didn't say it's fixed.. I said it will be in the version.. :P
Auswaschbar
Spring Developer
Posts: 1254
Joined: 24 Jun 2007, 08:34

Re: Why was replay format changed?

Post by Auswaschbar »

Should now work. Uploaded a replay to http://replays.adune.nl/?648, no errors. (can be deleted, thought)
MelTraX
Posts: 470
Joined: 02 Jan 2007, 16:18

Re: Why was replay format changed?

Post by MelTraX »

Yeah, that one seems to work fine. :)
User avatar
TradeMark
Posts: 4867
Joined: 17 Feb 2006, 15:58

Re: Why was replay format changed?

Post by TradeMark »

Auswaschbar wrote:Should now work. Uploaded a replay to http://replays.adune.nl/?648, no errors. (can be deleted, thought)
So there is two script.txt's now, first my own, then the host?
MelTraX
Posts: 470
Joined: 02 Jan 2007, 16:18

Re: Why was replay format changed?

Post by MelTraX »

Should be the same. The second one is in the demostream. It's the one actually sent over the network (which is recorded in the demofile).

The first one is just a copy for convinience so you don't have to parse the demostream (or guess the position/do hacky stuff).
Auswaschbar
Spring Developer
Posts: 1254
Joined: 24 Jun 2007, 08:34

Re: Why was replay format changed?

Post by Auswaschbar »

TradeMark wrote:
Auswaschbar wrote:Should now work. Uploaded a replay to http://replays.adune.nl/?648, no errors. (can be deleted, thought)
So there is two script.txt's now, first my own, then the host?
No, they are both from the host (and such, equivalent copies).

Or do you need such a script too:
script.txt wrote:[GAME]
{
HostIP=91.66.184.52;
HostPort=8454;
IsHost=0;
ModHash=989582745;
MapHash=-1843968990;
Mapname=Mearth_v3.smf;
GameType=BA661.sd7;

MyPlayerName=Auswaschbar;
}
???
User avatar
TradeMark
Posts: 4867
Joined: 17 Feb 2006, 15:58

Re: Why was replay format changed?

Post by TradeMark »

I need it as it was before
Tobi
Spring Developer
Posts: 4598
Joined: 01 Jun 2005, 11:36

Re: Why was replay format changed?

Post by Tobi »

That's not going to happen.
MelTraX
Posts: 470
Joined: 02 Jan 2007, 16:18

Re: Why was replay format changed?

Post by MelTraX »

It's as close as it'll get. Just work with that replay Auswaschbar uploaded.
User avatar
TradeMark
Posts: 4867
Joined: 17 Feb 2006, 15:58

Re: Why was replay format changed?

Post by TradeMark »

I want to know who played the replay, so everyone wont get autohost as player when they play, nor get their autohosts buggy scripts without flags or ranks etc.

Cant you send the data important for sync only, and include the player own script.txt. flags etc probably wont desync the game :p
User avatar
Hoi
Posts: 2917
Joined: 13 May 2008, 16:51

Re: Why was replay format changed?

Post by Hoi »

Tobi wrote:That's not going to happen.
Tobi
Spring Developer
Posts: 4598
Joined: 01 Jun 2005, 11:36

Re: Why was replay format changed?

Post by Tobi »

Actually that kind of stuff would be possible (including lobby generated script (ie. the one Auswaschbar quoted) and then TradeMark concvincing all lobby devs to still include this player information. (Since it won't be required for Spring anymore.)
User avatar
lurker
Posts: 3842
Joined: 08 Jan 2007, 06:13

Re: Why was replay format changed?

Post by lurker »

Tobi wrote:Actually that kind of stuff would be possible (including lobby generated script (ie. the one Auswaschbar quoted) and then TradeMark concvincing all lobby devs to still include this player information. (Since it won't be required for Spring anymore.)
Well, lobby devs don't have to include that; if both scripts are include Trademark can parse the first for myplayername and get the rest of the info from the real script.
Tobi
Spring Developer
Posts: 4598
Joined: 01 Jun 2005, 11:36

Re: Why was replay format changed?

Post by Tobi »

Ya but he then still doesn't have flags etc. when the host didn't write those in the script.
MelTraX
Posts: 470
Joined: 02 Jan 2007, 16:18

Re: Why was replay format changed?

Post by MelTraX »

And he would still have to parse the demostream to do it right.
Tobi
Spring Developer
Posts: 4598
Joined: 01 Jun 2005, 11:36

Re: Why was replay format changed?

Post by Tobi »

Nah, a new field could be added to the header, clientScriptSize :-)

Client script could then follow (host) script, no need to parse stream.
Post Reply

Return to “Engine”