File format finalized?

New releases and general discussions.

Post » Mon Oct 29, 2007 1:40 am

Just want to make sure that the file format won't be undergoing any more modifications that will make our games unopenable again before I work more with construct. :)
Moderator
B
88
S
32
G
33
Posts: 3,005
Reputation: 27,432

Post » Sat Nov 03, 2007 2:57 pm

I think now we will say the file format will no longer change.

Besides, if we do, I have to redo all the templates and demos and I don't want to :)
Scirra Founder
B
359
S
214
G
72
Posts: 22,952
Reputation: 178,600

Post » Sat Nov 03, 2007 3:35 pm

Whoo-hoo! That's great news! :D
Moderator
B
88
S
32
G
33
Posts: 3,005
Reputation: 27,432

Post » Mon Nov 05, 2007 5:02 pm

You could, perhaps more simply, add a feature a bit like extensions, where Construct can look for a plugin which explains how to convert an old file format to a new one. So in a simple example, if the file header now includes a bunch more stuff, the plugin would read the old file format and reorganise it into the new one.

I'd have thought you could use your file-reading code from the old version, and file-saving code from the new version, to lift everything into memory, then shove it into a file using the new routines?
B
4
S
1
G
5
Posts: 48
Reputation: 1,546

Post » Mon Nov 05, 2007 5:28 pm

Our plugins have a versioning system. If a plugin needs to save more data in to the .cap, all you have to do is increment the Version number and add two load routines: one for version 1 with defaults for new features, and one for version 2. So even as we add stuff to plugins they can still be loaded from old .caps, and this system is built in to the IDE too. So even as we add new features the .cap format shouldn't have to change :)

Last time we discovered some bugs in this system though so we had to break compatibility. This time around, it seems to be working fine!
Scirra Founder
B
359
S
214
G
72
Posts: 22,952
Reputation: 178,600


Return to Construct Classic Discussion

Who is online

Users browsing this forum: No registered users and 3 guests