Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Harbors push borders #132

Open
Spikeone opened this issue Aug 1, 2015 · 25 comments
Open

Harbors push borders #132

Spikeone opened this issue Aug 1, 2015 · 25 comments
Labels

Comments

@Spikeone
Copy link
Member

Spikeone commented Aug 1, 2015

After capturing an enemy military building, its flag was on the border and not within the border. The military building is adjacent to an enemy harbour.

Spooky (cpp-ema9o-9ei) wrote on 2012-05-05: #1
Save game Edit (225.3 KiB, application/zip)

Spooky (cpp-ema9o-9ei) wrote on 2012-05-05: #2
Screenshot Edit (2.1 MiB, image/png)

Spooky (cpp-ema9o-9ei) wrote on 2012-09-24: #3
I think I know what the problem is now.

In RTTR, Harbours act completely like military buildings. i.e. they have their own border-increasing-radius and they will "enforce" that radius against enemy military buildings. Despite of that, you are able to build a harbour on a harbour place no matter what, i.e. even within 5 nodes of another military building of your own.

These two properties together probably lead to this problem. In the game of the screenshot, the enemy harbour is pushing against the border that the watchtower above is is trying to increase. Since the enemy harbour is only 4 nodes apart from that watchtower, it results into this bug.

The solution is, to make harbours only increase your own border once. After that, the harbour will not counter any changes to the border (by enemy influence for instance). e.g. if the enemy pushes against a border generated by a harbour and then the enemy border goes away again (when the enemy destroys its military building for example) the border will not go back again, etc.

This would be the original Settlers II behavior. In Settlers II you can also build harbours independently from nearby military buildings (i.e. within the 5 node radius of another military building), but the harbours to not act as active border changing buildings, they push the boundary only once and then never again.

Spooky (cpp-ema9o-9ei) wrote on 2014-04-21: #4
Small push - I recently noticed, that harbours still actively push boundaries (instead of only once like in the original game) ;) (which could still lead to the problem mentioned here)

https://bugs.launchpad.net/s25rttr/+bug/995048

@Flow86 Flow86 added the bug label Aug 3, 2015
@Spikeone
Copy link
Member Author

Spikeone commented Aug 3, 2015

Yeah it's quite strange, somethimes if an enemy expedition lands close to your country and he builds up that harbor you get the message "lost land by this building" and then after it's finished you get the same message again.

@Flow86 Flow86 added this to the 0.9.0 milestone Aug 7, 2015
@Flamefire
Copy link
Member

If harbors cannot push borders, it would mean, that they can be destroyed by a military building build close to it. But this would be the only solution to the flag problem

@Spikeone
Copy link
Member Author

Spikeone commented May 31, 2016

But it "double" pushes. This only happens with expedition harbors, not normal ones. Also it was that way in the original game, you got land once your expedition landed or/and if the harbor was finished. But they could never push borders -> only took land that was not taken.

S2 actually had 2 states of "your" country, one for: held by military building and one for not held by military building.

If your country was held by a military building it couldn't be held without anymore at any time.

If we had those two states instead of one it would be also possible to implement "civil buildings give land".

Fun fact: That way it was possible to build a barracks far away from your expedition harbor, destroy both and still keep some land (anything that wasn't 'flagged' to held by military building after finishing the barracks)

@Flow86
Copy link
Member

Flow86 commented May 31, 2016

thats like settlers 3

@Spikeone
Copy link
Member Author

No Idea how it worked in S3, only S4 - but it is okay if the double message bug was fixed, any building should only send a push message once, not once it is placed and after it is finished.

@fritzmg
Copy link

fritzmg commented May 31, 2016

You get two messages, because there are two different boundary pushes. Once when the expedition lands and the harbour is being built. And once when the harbour is finished, which will create a bigger boundary around the harbour.

That's not a bug, is it?

@Flamefire
Copy link
Member

Might be fixed if the finished harbor does not give more land. And actually these 2 states already exist: Land is flagged as owned and this is recalculated in the influence radius of a captured or conquered military building. So we can set land to owned and this ownership is only changed when a military building influences this land.
So fix part 1: Constructing and finished harbor give the same land -> no double push -> no double message

But it needs to push borders. Otherwise an enemy military building could just destroy a harbor by occupying its borders. This would be a huge loss, wouldn't it?

Note: S3 and S4 were the same with boundaries. Only gaining and pushing, no reduction with destroyed buildings.

@Spikeone
Copy link
Member Author

Spikeone commented Jun 1, 2016

But in s4 harbors didn't give any land. You had to first ship a foundation cart and let pioneers take some land - this means you could destroy enemy expeditions.

I think it's okay the way it is at the moment but pushing twice and getting more land with the second push triggering a secod message is just annoying. Also I see no problem with destroying unfinished harbors by military buildings - when an enemy can destroy your expedition harbor with a military building this means that he already has a colony, resulting in either instant destroying your finished harbor or destroy-pushing your harbor - doesn't change anything but it's quite logical that you could destroy a single enemy builder with soldiers

@fritzmg
Copy link

fritzmg commented Jun 1, 2016

I think it's okay the way it is at the moment but pushing twice and getting more land with the second push triggering a secod message is just annoying.

But it's important to keep that. When an expedition first lands, the area it takes is just very small, it might not even touch your own boundary. When the harbour is finished, the boundary will be bigger and maybe touch your boundary now.

@jhkl
Copy link
Contributor

jhkl commented Jun 1, 2016

What about handling the harbor more like a normal military building:

  • During construction only the minimal amount of land is hold by the harbor (same like current implementation)
  • If an enemy territory is expanded over the harbor's land during construction, the harbor is destroyed.
  • After finishing the construction, a soldier has to occupy the harbor to increase the land.
  • During the time the harbor is constructed, but not occupied by at least one soldier, the land does not increase. The harbor is not attackable (like any other unoccupied military building)
  • If an enemy territory is expanded over the harbor's land while it is still unoccupied, the harbor is destroyed (like any other unoccupied military building close to a border when the enemy expand the territory)

@fritzmg
Copy link

fritzmg commented Jun 1, 2016

Suggestions 2 and 3 will make the usage of harbours even more cumbersome than it already is, imho.

@Flamefire
Copy link
Member

What about: harbor occupies regular land region on placement but does not push any borders. Hence you need a minimal unowned territory to place it. It can also be destroyed by capturing the territory with another building
When the harbor is finished it does push borders and can be attacked. This would fix the double push. But I don't see anything to fix the flag issue in the screenshot

@fritzmg
Copy link

fritzmg commented Jun 1, 2016

The double push doesn't need to be fixed imho.

@Flamefire
Copy link
Member

@fritzmg So you wouldn't change anything at all?
How is this done in S2?

@fritzmg
Copy link

fritzmg commented Jun 1, 2016

So you wouldn't change anything at all?

No, the original issue is not about the boundary pushing two times (and hence you get two notificaitons, if you were already adjacent to the harbour boundary) ;)

How is this done in S2?

As mentioned in the original post, in S2 the harbour boundary does not "keep pushing". The harbour's boundary is always only pushing once (each time) - it does not try to keep up the boundary.

So if you only have a harbour there (doesn't matter if it's finished or not) and an enemy military building pushes the boundary, the harbour's boundary does not push back.

So, in S2, the harbour would simply be destroyed in the original issue.

@Flamefire
Copy link
Member

Ok... Do we want that? A destroyed harbor is a huge loss (wares etc) which might make them even less useful. Although warehouses act the same.

@Spikeone
Copy link
Member Author

Spikeone commented Jun 1, 2016

Why should a harbor give more land after it was finished that when it was placed? There is no reason. Currently it's just a reminder "hey, my undue fended harbor is finished, please attack me".

In the original you got land once you landed, after that your harbor did neither push nor take more land. The original game assumed that the distance to the next building is just as short as it needs to be, thus holding the harbor. When finished the harbor and destroyed it, you'd lose all land, if you'd build a military building (which borders included the harbor) and destroyed that, you'd keen any land obtained by the harbor but not held by the military building.

That's a bug for me.

A harbor should push borders:

  1. If it was finished when it's in your land
  2. When it is placed by an expedition (actually creating the building site)

A harbor should hold land:

  1. after it is finished

Edit: saw your posts
It should be possible to destroy a harbor that is under construction not regarding if it was placed by player or by expedition. It should be impossible after the harbor is finished (act like an HQ)
Fritz mentions the issue shouldn't be fixed but I see no use for a bug - I have no idea if you actually get more land after the building is finished but oft it is that way, that'd be annoying as a building site you placed might be destroyed by a push that should occur. That's why I asse a double message is a bug.

@Flamefire
Copy link
Member

Imagine the following: You gain land by placing a harbor. Then an enemy builds a military next to each reducing the gained land. Once the harbor is finished the border might be pushed, as the harbor actually holds some land. Otherwise it would inconsistent (which is also hard to implement) to what happens, when a nearby military building is destroyed.

So I see 2 solutions: 1) harbor does not hold any land. But expeditions create some at landing. 2) land hold by harbor is the same as created on expedition landing. So no double push under "normal" circumstances, but they are possible if you lost land during construction of the harbor

@fritzmg
Copy link

fritzmg commented Jun 2, 2016

Why should a harbor give more land after it was finished that when it was placed? There is no reason. Currently it's just a reminder "hey, my undue fended harbor is finished, please attack me".

I'd argue the initial, small patch of land you gain by the expedition makes it more sneaky. You may only realize that the enemy built a harbour near you once it's finished.

Otherwise you might notice right when the expedition lands.

@Spikeone
Copy link
Member Author

Spikeone commented Jun 2, 2016

The harbor should just have 0 push power when it was placed by an expedition.
It should be possible to destroy such a harbor by "over pushing" it's held land (and either harbor flag or building spot)

It is no military building (no upgrading, stores goods, not hit by catapult, can't attack) so it's not inconsistency if it behaves different.

Also "sneaky" isn't possible - when you get the message twice, the harbor isn't sneaky at all as you already have a border.

The second solution (by Flamefire) sounds quite okay but:
Why take land in the first place? Can't see any reason.
Maybe it'd be better (also more "sneaky") if an expedition harbor does either occupy 0 land until it's finished (maybe also as a preparation for colonies) or at least does only occupy 2 full nodes (flag and building spot) and that way avoiding the first push.
Anyway the harbor pushes after it's finished (just like building it without expedition) and holding land (just like building without expedition)

IMHO that'd be a good way at all.

@fritzmg
Copy link

fritzmg commented Jun 2, 2016

Also "sneaky" isn't possible - when you get the message twice, the harbor isn't sneaky at all as you already have a border.

It is possible. When you first land your expedition, the small boundary pushed by the expedition might not yet touch an enemy boundary. It's a niche case of course.

@Flamefire
Copy link
Member

The expedition harbor must occupy land. I would not change the simple requirement, that you can only build on your own land. However one can make it so, that it does not push borders. This would be as my solution 1) above: Harbor does not hold/push/gain land, only a landing expedition occupies free land, before it places the harbor. This way the harbor is just like a storehouse, but attackable like a HQ
I also like the idea, about using only 2 nodes (harbor and flag) but pushing regularly after it is finished.

@Spikeone
Copy link
Member Author

Spikeone commented Jun 3, 2016

The first idea isn't that good as the harbor should behave like a HQ.

HQs can't be built like harbors but if it was possible, the building should behave for land like any other military building (just like you said) but while it's in building state, it should behave like a normale building site.

It should suffice that a harbor occupies, after beeing placed by an expedition, land with a 2 node radius (the harbor node itself and the flag node). As you need a minimum distance to enemy borders (which is more than 2 nodes I think) you can not push any bordor when landing. A push after the building is finished is okay and it should stay that way.

@fritzmg
Copy link

fritzmg commented Jun 3, 2016

As you need a minimum distance to enemy borders (which is more than 2 nodes I think) you can not push any bordor when landing.

But wouldn't that mean that you cannot land an expedition on places anymore, where the enemy barely touches the landing ground?

@Spikeone
Copy link
Member Author

Spikeone commented Jun 3, 2016

It alread works that way.
Or at least it did. I have no idea if anobody changed it, the minimum distance was decreased but should be still in the game. In my opinion it is good for two reasons:

  1. If you are that close to an enemy, you wont defend your harbor and should just attack close enemy military buildings
  2. When your ship starts, the harbor spot might be occupied by a military building before your ship even reaches it's target

Sadly, also seafaring is something that is quite map and setting dependant.
Some maps might work great in multiplayer with seafaring, some may not.

@Flow86 Flow86 removed this from the 0.9.2 - minor improvements milestone May 19, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

5 participants