Latest Posts

Topic: Choosable File Format

toptopple
Avatar
Topic Opener
Joined: 2013-10-30, 08:11
Posts: 156
Ranking
At home in WL-forums
Posted at: 2016-12-02, 15:07

There is a new challenge for the developers of the Widelands editor! It says map developers should be in the position to save a map at a distinct and specific file format. I wonder if this can be done with reasonable effort, it likely demands the use of object oriented programming. face-wink.png

The purpose is to enable the supply of maps to the gallery which can be digested by the latest release (B19 in this case). Maps saved with later development versions cannot be opened in B19.


Top Quote
SirVer

Joined: 2009-02-19, 15:18
Posts: 1445
Ranking
One Elder of Players
Location: Germany - Munich
Posted at: 2016-12-02, 17:10

Maps saved with later development versions cannot be opened in B19.

This is a bug and should not be the case. Could you report it or outline what the problem is? Maps should be fully compatible, except for the break in b19 (where we switched to one-world). So in detail:

  • b19: should be able to open all maps ever made, including those made with current dev versions of Widelands.
  • b18: and below: Can open all maps till one-world was merged. Newer maps no longer work with these. We added support in the maps downloading on the website to mention that you require something newer than b18 for these maps.

Top Quote
GunChleoc
Avatar
Joined: 2013-10-07, 15:56
Posts: 3324
Ranking
One Elder of Players
Location: RenderedRect
Posted at: 2016-12-03, 12:07

Maps created with versions newer than B19 will not open in b19 if they have more than 8 players. This is not a bug.

We increased the allowed number of players so Tibor can do better testing for his new AI project.

Widelands should detect the number of players automatically and set the packet version accordingly. There is no need to make the user choose anything.

Edited: 2016-12-03, 12:09

Busy indexing nil values

Top Quote
toptopple
Avatar
Topic Opener
Joined: 2013-10-30, 08:11
Posts: 156
Ranking
At home in WL-forums
Posted at: 2016-12-03, 17:15
We increased the allowed number of players so Tibor can do better testing for his new AI project.


That is what in the classical case code branches are good for. What ever the error is, you didn't need to put this untested innovation into the main trunk!
Top Quote
GunChleoc
Avatar
Joined: 2013-10-07, 15:56
Posts: 3324
Ranking
One Elder of Players
Location: RenderedRect
Posted at: 2016-12-03, 19:03

That's what we have code reviews for, but things still get missed. You can't expect us to be perfect all the time. If we had left this in a branch for a long time, probably nobody would have noticed anyway.

Anyway, the problem is a different one, as I have commented in the bug.


Busy indexing nil values

Top Quote
SirVer

Joined: 2009-02-19, 15:18
Posts: 1445
Ranking
One Elder of Players
Location: Germany - Munich
Posted at: 2016-12-03, 21:50

What ever the error is, you didn't need to put this untested innovation into the main trunk!

What makes you think it was untested? We test each change and run all automated tests. Problem is: this change affected old versions of Widelands - how do you test old versions against new changes? Long story short, this slipped through the testing cracks - and there are many testing cracks in Widelands so this happens. Sorry for the inconvenience, we try to do better next time.


Top Quote
Tibor

Joined: 2009-03-23, 23:24
Posts: 1377
Ranking
One Elder of Players
Location: Slovakia
Posted at: 2016-12-03, 23:28

Well, I believe there will be another breaks of savegame compatibility. My toy branch expects to put new data into savegame. And also you (@Toptopple) will probably want to add further information into savegame (via extending AI persistent data).

EDIT: But also B19 is still new, so we could keep savegame compatibility for some time (3 months or so) and then say that B19 is already bit old and development went on

Or somehow notify map creators that they should use B19 to guarantee compatibility. You can create map there and test it in newer version.

Edited: 2016-12-03, 23:32

Top Quote
SirVer

Joined: 2009-02-19, 15:18
Posts: 1445
Ranking
One Elder of Players
Location: Germany - Munich
Posted at: 2016-12-04, 00:36

Savegames are not Maps though. We must be much more stringent with maps.

But we should also strive to keep savegames compatible - in the past we always kept the last 3 versions compatible, i.e. b17 could load games from b14, b15 and b16. We only made an exception for b19 and broke savegame compatibility there because it was a massive housecleaning release.


Top Quote
kaputtnik
Avatar
Joined: 2013-02-18, 20:48
Posts: 2433
OS: Archlinux
Version: current master
Ranking
One Elder of Players
Location: Germany
Posted at: 2016-12-04, 10:07

There is a confusion with the error message when loading a map in EDITOR fails. It says something like:

" This savegame couldn't be loaded. ...."

whereas one try's to load a map in editor.


Fight simulator for Widelands:
https://wide-fighter.netlify.app/

Top Quote
toptopple
Avatar
Topic Opener
Joined: 2013-10-30, 08:11
Posts: 156
Ranking
At home in WL-forums
Posted at: 2016-12-04, 17:27

I think if you create a new package number, someone should be sensible enough to judge the consequences. You can test older game versions simply by trying to open maps saved with the new version by the old.

One of these two solutions is easier, I don't know which:

1. create a branch for Tibor's experiments (where he has to confine himself for experiments), then revert the crucial changes back to the old state in trunk. However, few maps created or modified since the change may turn out unusable!

2. create a editor feature to save a map in the old format. Not sure if this meets the problem, though. Such a feature is perhaps nice to keep for the future, where it may be enhanced.

Edited: 2016-12-04, 17:56

Top Quote