stock chart counts wares in every building
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
widelands |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
The stock chart counts all wares inside of any building. The attached branch change the ware counting, so that only ware inside a warehouse are considered.
Can someone help me to clear up the meaning of the economy class? Until recently I thought every building, which can store wares have its own economy instance. But this seems wrong.
When I use the economy attached to each warehouse for ware counting, than I get the number of wares stored in every building and not only inside of the warehouses.
I also know that every player owns multiple economy instances, so the economy is also no description for the whole economy of one player.
But what is the the function of the economy class than?
I did not open a merge request, as I want to improve the class description of the economy class, before that. So other developers will profit from a better documentation.
Related branches
- Widelands Developers: Pending requested
-
Diff: 46 lines (+12/-5)2 files modifiedsrc/economy/economy.h (+10/-3)
src/logic/player.cc (+2/-2)
Changed in widelands: | |
milestone: | none → build18-rc1 |
Hi Borim,
I am not sure to which stock chart you are refering. There are different stock charts. Those who (should) list the number of stored (which means in warehouses) wares and workers and those who show the total number in all economies.
By the way: the economy object can be seen as "buildings and flags connected with streets or harbors" - so in most games you will have only one major economy and maybe some small economies. Those small economies are in most cases unconnected constructionsit es/buildings or flags that are not connected.
so two warehouses and several buildings connected via roads share the same economy, but a building that is not connected to that street web has another economy.