[Widelands-dev] [Merge] lp:~widelands-dev/widelands/use_sdl_image_in_one_place into lp:widelands

2014-11-27 Thread SirVer
SirVer has proposed merging lp:~widelands-dev/widelands/use_sdl_image_in_one_place into lp:widelands with lp:~widelands-dev/widelands/texture_atlas as a prerequisite. Requested reviews: Widelands Developers (widelands-dev) For more details, see: https://code.launchpad.net/~widelands-dev/widel

[Widelands-dev] [Merge] lp:~widelands-dev/widelands/texture_atlas into lp:widelands

2014-11-27 Thread SirVer
SirVer has proposed merging lp:~widelands-dev/widelands/texture_atlas into lp:widelands. Requested reviews: Widelands Developers (widelands-dev) For more details, see: https://code.launchpad.net/~widelands-dev/widelands/texture_atlas/+merge/243119 Suggested commit message: - Adds a TextureAt

Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/bug-1380286 into lp:widelands

2014-11-27 Thread wl-zocker
I think counting the roads is not necessary. Furthermore, it could be implemented in lua itsself quite easily: local result = 0 for k,v in pairs(flag.roads) do result = result + 1 end return result or something along these lines. The only thing that remains is to use this function in the first

Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/bug-1380286 into lp:widelands

2014-11-27 Thread TiborB
Counting of roads can be used to say whether it is an end or "middle" of road. The bug/request was reported by wl-zocker, if he is fine not having such explicit count, I dont mind I made some changes to the code, as you wanted -- https://code.launchpad.net/~widelands-dev/widelands/bug-1380286/+

Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/fonts into lp:widelands

2014-11-27 Thread wl-zocker
I had changed the new_objectives function to work as (probably) intended. Now you have changed it back. As far as I can see, s is overwritten everytime and only the last objective is returned as formatted string. -- https://code.launchpad.net/~widelands-dev/widelands/fonts/+merge/238608 Your tea

Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/fonts into lp:widelands

2014-11-27 Thread GunChleoc
Review: Resubmit Time for the next round. FontSet now has its own class and parses itself. The singleton is gone - FontHandler1 now does the job. I pulled TextStyle out of the basic font class to avoid circular dependencies, and moved: src/wui/text_constants.h => src/graphic/text_constants.h s

Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/bug-1380286 into lp:widelands

2014-11-27 Thread GunChleoc
My best guess is that #field.roads doesn't work because you have an associative array rather than an indexed one in your table. Is there a particular reason you need to count roads in your test? You could test for the 6 directions individually if they're there or not. -- https://code.launchpad.

Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/bug-1380286 into lp:widelands

2014-11-27 Thread TiborB
LUA test done (not pushed up yet) - one issue, though. It is not trivial to count roads returned as '#field.roads' returns 0, though when accessing a particular road via field.roads.tl works and shows the road is there. So perhaps if convenient, I can add also function field.roads_count return

[Widelands-dev] [Merge] lp:~widelands-dev/widelands/bug-768826 into lp:widelands

2014-11-27 Thread noreply
The proposal to merge lp:~widelands-dev/widelands/bug-768826 into lp:widelands has been updated. Status: Needs review => Merged For more details, see: https://code.launchpad.net/~widelands-dev/widelands/bug-768826/+merge/242544 -- Your team Widelands Developers is subscribed to branch lp:~

Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/bug-768826 into lp:widelands

2014-11-27 Thread GunChleoc
No problem. Let me know if you need help with the Lua tests, I have written a few simple ones for the building descriptions. -- https://code.launchpad.net/~widelands-dev/widelands/bug-768826/+merge/242544 Your team Widelands Developers is subscribed to branch lp:~widelands-dev/widelands/bug-7688

Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/bug-768826 into lp:widelands

2014-11-27 Thread TiborB
OK, and thanks for saving me from this work, I am struggling with that LUA testing now... -- https://code.launchpad.net/~widelands-dev/widelands/bug-768826/+merge/242544 Your team Widelands Developers is subscribed to branch lp:~widelands-dev/widelands/bug-768826. __

Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/bug-768826 into lp:widelands

2014-11-27 Thread GunChleoc
Review: Approve They are, except for the first variable. That looks weird, so I have removed it. Going to merge now. -- https://code.launchpad.net/~widelands-dev/widelands/bug-768826/+merge/242544 Your team Widelands Developers is subscribed to branch lp:~widelands-dev/widelands/bug-768826. __

Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/bug-768826 into lp:widelands

2014-11-27 Thread TiborB
re: "- In the editor, remove the blank space between ( and the first coordinate" Talking about this line? static boost::format node_format("(%3i, %3i, %2i)"); Because there is no space. But I can say that numbers between % and i are flatly ignored, if you know how to make them work... -- https

Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/bug-1380286 into lp:widelands

2014-11-27 Thread GunChleoc
Can you please add some regression tests as well? They should go in test/maps/lua_testsuite.wmf/scripting/flag.lua You can run these tests directly without having to run the whole test suite: ./widelands --scenario=test/maps/lua_testsuite.wmf I have also spotted a NOCOM comment in the diff - pl

Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/bug-768826 into lp:widelands

2014-11-27 Thread GunChleoc
LGTM, except for a couple more nits. One functionality change: - In the editor, remove the blank space between ( and the first coordinate And two code style nits: - add operator padding to (is_game)?25:5 (codecheck doesn't catch this case, but it should look like this: (is_game) ? 25 : 5) - P