Currently Online

Latest Posts

Topic: automatic upgrading of a building

GunChleoc
Avatar
Joined: 2013-10-07, 14:56
Posts: 3324
Ranking
One Elder of Players
Location: RenderedRect
Posted at: 2015-09-04, 06:33

We could add a new "Mute/Unmute this building's messages" button to each building's window. If others support this idea, I'd be willing to implement it; it shouldn't be that difficult.

Let's tweak the values first though, thanks for offering to work on them.

Edited: 2015-09-04, 06:33

Busy indexing nil values

Top Quote
einstein13
Avatar
Joined: 2013-07-28, 23:01
Posts: 1118
Ranking
One Elder of Players
Location: Poland
Posted at: 2015-09-04, 08:54

GunChleoc wrote:

We could add a new "Mute/Unmute this building's messages" button to each building's window.

I have a question: for all possible buildings (all coal mines/ all woodcutters)? Or each building, one by one (50 times for woodcutters, 100 times for each mine)?


einstein13
calculations & maps packages: http://wuatek.no-ip.org/~rak/widelands/
backup website files: http://kartezjusz.ddns.net/upload/widelands/

Top Quote
king_of_nowhere
Avatar
Topic Opener
Joined: 2014-09-15, 17:35
Posts: 1668
Ranking
One Elder of Players
Posted at: 2015-09-04, 10:46

for each building. if i have no gold but plenty of iron, i will want to receive an exhausted message by the iron mines, while i'll be running the gold mines exhausted and would not want to hear ffrom those. Or, if i build a wooodcutter to chop a few trees i would want to dismantle it when it's done, but if for some reason i placed one in a semidesertic area i'd just want it to work at 30% and would rather silence it.


Top Quote
GunChleoc
Avatar
Joined: 2013-10-07, 14:56
Posts: 3324
Ranking
One Elder of Players
Location: RenderedRect
Posted at: 2015-09-04, 10:49

Adding a button for each individual building is easy. Adding a button for whole building types (e.g. Mute/Unmute all Deep Gold Mines at once) would be more complicated.


Busy indexing nil values

Top Quote
king_of_nowhere
Avatar
Topic Opener
Joined: 2014-09-15, 17:35
Posts: 1668
Ranking
One Elder of Players
Posted at: 2015-09-05, 20:14

GunChleoc wrote:

king_of_nowhere wrote:

in that map, hearing the sound of messages was complicated by the fact that my economy was reliying on charcoal for coal, I had some 50 woodcutters and they kept sending the "no more trees" message as soon as their productivity dropped a little bit. which is also something that i suggested fixing, some time ago.

I did a rework of these a few weeks ago; looks like the frequency of messages still isn't optimal. Could you please play around with the values a bit to see what would be the best productivity % to trigger the message? e.g. for the Barbarian Lumberjack (tribes/barbarians/lumberjacks_hut/conf), we have productivity_threshold=66 at the moment. The trigger for the mines is separate from these.

We could also adjust how often these messages get sent - at the moment, Widelands will only send them again after 30 minutes in-game have expired. We could adjust the frequency of the messages for the mines separately from the other production buildings.

ok, i can't do it myself because if i open the file with notepad, it saves it as txt and it doesn't work anymore, and if i open it with wordpad, it says i lack the autorization even if i am admin. however, i'd try either 49% or 29% as threshold


Top Quote
Ergo
Avatar
Joined: 2015-08-29, 14:04
Posts: 61
Ranking
Likes to be here
Posted at: 2015-09-05, 20:31

You can try rename it after it was saved to .txt Try to rename the filename to conf (without extension) and I also see it has a hidden attribute too. I can do that on win7 64-bit, idk what OS you have.


Hic regum sceptrum dominus tenet
orbisque habenas temperat
et volucrem currum stabilis regit
rerum coruscus arbiter.
-- Anicius Manlius Severinus Boethius

Top Quote
GunChleoc
Avatar
Joined: 2013-10-07, 14:56
Posts: 3324
Ranking
One Elder of Players
Location: RenderedRect
Posted at: 2015-09-06, 06:12

If you installed Widelands in Program Files, try installing it in C:\Widelands instead.

king_of_nowhere wrote:

i'd try either 49% or 29% as threshold

For which building?


Busy indexing nil values

Top Quote
einstein13
Avatar
Joined: 2013-07-28, 23:01
Posts: 1118
Ranking
One Elder of Players
Location: Poland
Posted at: 2015-09-06, 20:50

GunChleoc wrote:

Adding a button for each individual building is easy. Adding a button for whole building types (e.g. Mute/Unmute all Deep Gold Mines at once) would be more complicated.

For all building it should be easy too. Only new GUI is needed. I think that the easiest way to introduce the global behaviour is: when you press "mute all", in all buildings chosen type "mute" button is enabled. When you press "unmute all", all buildings change state to "mute disabled".

@ king_of_nowhere: I see the point to both ways: "all buildings" and "each building". For "all buildings" you wrote: all gold mines, because you have lack of gold in the mountains you have. "For each building" it can be used in (for example) woodcutters which are chopping trees far from foresters to prevent spawning them next to farms (I do that very often).


einstein13
calculations & maps packages: http://wuatek.no-ip.org/~rak/widelands/
backup website files: http://kartezjusz.ddns.net/upload/widelands/

Top Quote
GunChleoc
Avatar
Joined: 2013-10-07, 14:56
Posts: 3324
Ranking
One Elder of Players
Location: RenderedRect
Posted at: 2015-09-07, 05:45

How about a button click for the current building, and Shift + Click for all buildings?


Busy indexing nil values

Top Quote
einstein13
Avatar
Joined: 2013-07-28, 23:01
Posts: 1118
Ranking
One Elder of Players
Location: Poland
Posted at: 2015-09-07, 13:18

GunChleoc wrote:

How about a button click for the current building, and Shift + Click for all buildings?

That sounds good face-smile.png But it has to be written somewhere. New players HAVE TO KNOW that (have the possibility to know).


einstein13
calculations & maps packages: http://wuatek.no-ip.org/~rak/widelands/
backup website files: http://kartezjusz.ddns.net/upload/widelands/

Top Quote