Latest Posts

Topic: Technical Ideas

Nordfriese
Avatar
Joined: 2017-01-17, 18:07
Posts: 1928
OS: Debian Testing
Version: Latest master
Ranking
One Elder of Players
Location: 0x55555d3a34c0
Posted at: 2020-09-17, 07:36

Having each building check for enemy soldiers nearby might become performance-hungry (don't know how exactly it's being handled currently). But the soldiers themselves could, while walking to an attack, check whether they are on enemy territory and this territory is being seen by its owner (which is efficient), in which case they trigger the sending of an attack message to their enemy. No need to keep the internal mechanisms logical as long as the result is correct face-wink.png


Top Quote
the-x
Avatar
Topic Opener
Joined: 2019-01-19, 13:23
Posts: 967
Ranking
One Elder of Players
Posted at: 2020-09-17, 11:05

Nordfriese wrote:

Having each building check for enemy soldiers nearby might become performance-hungry (don't know how exactly it's being handled currently). But the soldiers themselves could, while walking to an attack, check whether they are on enemy territory and this territory is being seen by its owner (which is efficient), in which case they trigger the sending of an attack message to their enemy. No need to keep the internal mechanisms logical as long as the result is correct face-wink.png

Sounds very logical face-smile.png i like that Idea. Time should be maximized with players reacting to the attack.

I dont want to hear the sound thinking 2 second if dismantle and then the building gets destroyed and all the territory just gone to the enemy.

This is crucial. Imagine your building your bakery, checking your coal mine calculating if you go to stone mine or expanding, hearing the sound - even if you hear it and not being lost in your thoughts it is very stressfull then even if you mange to locate where the attack is happening right now two secons later all your buildings burn cause you didnt stress yourself right now. We need this to make widelands more enjoyable, we can create a nice gameplay experience where you can dream and think about your buildings in the same time like tactical discussion.

What I see at the moment is so much waiting for your build order being created, your first coal, your first soldiers come to the game but if someone attacks you it gets immediatly stressful and you have to react in a second and do not have any time to think "tactical Ideas". We need so enlarge this time you can think if you push tzhe other side or if you just retreat and dismantle. And now think of you being attacked at 3 places at the same time. gg - that means the game is over


Top Quote
hessenfarmer
Avatar
Joined: 2014-12-11, 23:16
Posts: 2646
Ranking
One Elder of Players
Location: Bavaria
Posted at: 2020-09-17, 12:51

Nordfriese wrote:

Having each building check for enemy soldiers nearby might become performance-hungry (don't know how exactly it's being handled currently). But the soldiers themselves could, while walking to an attack, check whether they are on enemy territory and this territory is being seen by its owner (which is efficient), in which case they trigger the sending of an attack message to their enemy. No need to keep the internal mechanisms logical as long as the result is correct face-wink.png

I agree on the part of the internal mechanism (i.e. the result matters not the solution does to reflect outside world.
But I believe you misunderstood the request I believe. It was requested to trigger attack messages while the enmy isn't yet over the border he is just marching to it. So the most simple solution would be to trigger the message with the click on the attack button. However this would lead to triggering messages where you can't see the soldiers yet, and would discourage building towers. So the thing to check for is enemy soldiers that are seen by an opponent and are in attack mode. So in terms of performance we really could try to let soldiers in attack mode check if they are seen by an enemy every 1.8 second (this is their marching speed I believe), as I assume this might be less checks as letting all buildings check for soldiers every time. the message should then be not related to the building that spotted the enemy but more general and pointing to the soldiers rather then to the building. This would lead to a massive ammount of attack messages though as every atttacking soldier would trigger it.


Top Quote
Nordfriese
Avatar
Joined: 2017-01-17, 18:07
Posts: 1928
OS: Debian Testing
Version: Latest master
Ranking
One Elder of Players
Location: 0x55555d3a34c0
Posted at: 2020-09-17, 17:18

Yes just letting each attacking soldier check frequently whether he's being seen by his enemy would be enough, and also have good performance. For the message spam, we have a timeout mechanism already that can supress the sending of many similar messages in one area for a while.


Top Quote