← Back to team overview

widelands-dev team mailing list archive

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

 

Review: Approve review

Since this is no code change there is no sense in compiling this.
All fine foe me, ther mor docs the better.

If my inline comment abot critter is correct I will iclude it.

Diff comments:

> 
> === modified file 'src/scripting/lua_map.cc'
> --- src/scripting/lua_map.cc	2017-06-24 08:18:48 +0000
> +++ src/scripting/lua_map.cc	2017-07-25 07:00:49 +0000
> @@ -1616,9 +1616,18 @@
>  }
>  
>  /* RST
> -   .. attribute:: type
> -
> -         (RO) the name of the building, e.g. building.
> +   .. attribute:: type_name
> +
> +         (RO) the map object's type as a string. Possible values are:
> +
> +         * Bobs: ``bob``, ``critter``, ``ship``, ``worker``, ``carrier``, ``soldier``
> +         * Wares: ``ware``
> +         * Immovables: ``immovable``
> +
> +            * Buildings: ``building``, ``constructionsite``, ``dismantlesite``, ``warehouse``, ``productionsite``, ``militarysite``, ``trainingsite``
> +            * Other: ``flag``, ``road``, ``portdock``
> +

'critter' are the animals on the map (not including Donkye, Horse, Oxen, as they are carriers).
If this is corerct I would like to add this (did not know what critters are till now).

> +         * Other: ``battle``, ``fleet``
>  */
>  int LuaMapObjectDescription::get_type_name(lua_State* L) {
>  	lua_pushstring(L, to_string(get()->type()));


-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is subscribed to branch lp:~widelands-dev/widelands/doc_type_name.


References