Page MenuHomeWildfire Games

Murder Holes should apply to all defensive buildings
Changes PlannedPublic

Authored by elexis on Jan 30 2017, 10:21 AM.

Details

Reviewers
None
Trac Tickets
#4421
Summary

Currently the murder holes tech only applies to towers.
The tech would be more useful if it would apply to all defensive structures (also the case in one of the games this one was inspired from).

Test Plan

Since the buildings have a different footprint, sometimes square, othertimes circular, we need a different minimum distance for each of them!
The exact values could be computed based on these numbers (accounting for 1 clearance of the units).

Diff Detail

Repository
rP 0 A.D. Public Repository
Branch
/ps/trunk
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 911
Build 1434: Vulcan BuildJenkins
Build 1433: arc lint + arc unit

Event Timeline

elexis created this revision.Jan 30 2017, 10:21 AM
elexis updated the Trac tickets for this revision.Jan 30 2017, 10:24 AM
elexis updated this revision to Diff 394.Jan 30 2017, 11:17 AM

Increase minimum distance of defensive structures shortly beyond its footprint and remove it with the murder holes tech.

elexis updated this revision to Diff 396.Jan 30 2017, 11:37 AM

Fix MinRange for the biggest civic center (ptol) and the smallest one (gauls).

(Some structures didn't comply with my math, without these tests, the minRange would have been too low or too big.)








Vulcan added a subscriber: Vulcan.Jan 30 2017, 11:49 AM

Build is green

Updating workspaces.
Build (release)...
Build (debug)...
Running debug tests...
Running cxxtest tests (302 tests)..............................................................................................................................................................................................................................................................................................................OK!

http://jw:8080/job/phabricator/274/ for more details.

Build is green

Updating workspaces.
Build (release)...
Build (debug)...
Running debug tests...
Running cxxtest tests (302 tests)..............................................................................................................................................................................................................................................................................................................OK!

http://jw:8080/job/phabricator/275/ for more details.

fatherbushido edited edge metadata.Jan 30 2017, 1:30 PM
In D111#3725, @elexis wrote:

Increase minimum distance of defensive structures shortly beyond its footprint

You mean that currently the min range has in fact no effect, that's it?

In D111#3725, @elexis wrote:

Increase minimum distance of defensive structures shortly beyond its footprint

You mean that currently the min range has in fact no effect, that's it?

Correct sir, thats why I originally set it to 0 in the prior patch (would leave a misleading tooltip), but why not make it a fun feature

fatherbushido added inline comments.Jan 30 2017, 1:39 PM
binaries/data/mods/public/simulation/data/technologies/attack_tower_murderholes.json
11

mooving Defensive to a VisibleClasses?

binaries/data/mods/public/simulation/templates/template_structure_civic_civil_centre_military_colony.xml
27

ok, it's indeed better to have them in the child template and if ever we want a default we have the one of template_structure_civic_civil_centre
(I guess you keep the generic similar entry in civil_centre to have a default?)

In D111#3731, @elexis wrote:

(Some structures didn't comply with my math, without these tests, the minRange would have been too low or too big.)

I guess you want to let just the room for a normal unit, right?

binaries/data/mods/public/simulation/data/technologies/attack_tower_murderholes.json
11

(or use explicit stuff in the array)

fatherbushido added a comment.EditedJan 30 2017, 2:02 PM
In D111#3755, @elexis wrote:
In D111#3725, @elexis wrote:

Increase minimum distance of defensive structures shortly beyond its footprint

You mean that currently the min range has in fact no effect, that's it?

Correct sir, thats why I originally set it to 0 in the prior patch (would leave a misleading tooltip), but why not make it a fun feature

(Thinking to that, with or without the change, the min distance tooltip will be as misleading or not misleading?)
EDIT: a bit less
EDIT: (I agree with both changes, 0 or murderhole, the second seems more interesting)

elexis updated this revision to Diff 400.Jan 30 2017, 2:08 PM

Change murderholes tooltip to mention that it affects non-towers too.

In D111#3755, @elexis wrote:
In D111#3725, @elexis wrote:

Increase minimum distance of defensive structures shortly beyond its footprint

You mean that currently the min range has in fact no effect, that's it?

Correct sir, thats why I originally set it to 0 in the prior patch (would leave a misleading tooltip), but why not make it a fun feature

(Thinking to that, with or without the change, the min distance tooltip will be as misleading or not misleading?)
EDIT: a bit less

Displaying X meters minimum range when all units are attacked would be misleading.
With the proposed patch applied, it will still be slightly unexpected: 25m minimum range when only units at the buildings footprint are attacked. On the other hand the tooltip doesn't lie, players should just know that the arrows are shot from the center (feels wrong to subtracting the footprint).

binaries/data/mods/public/simulation/data/technologies/attack_tower_murderholes.json
11

Should be done in case we add a generic aura tooltip displaying the affects part, or why were that useful?

11

Should apply to all defensive structures

binaries/data/mods/public/simulation/templates/template_structure_civic_civil_centre_military_colony.xml
27

That default is used for most civic centers besides some, as can be seen by searching for <Footprint> in *template*civ*cen* files or so

Build is green

Updating workspaces.
Build (release)...
Build (debug)...
Running debug tests...
Running cxxtest tests (302 tests)..............................................................................................................................................................................................................................................................................................................OK!

http://jw:8080/job/phabricator/276/ for more details.

fatherbushido added inline comments.Jan 30 2017, 2:25 PM
binaries/data/mods/public/simulation/data/technologies/attack_tower_murderholes.json
11

ok (siege wall, palisade (nothing but in scenario fires arrow iirc), outpost, wooden-sentry tower, walls)

11

Yes, wondered about that, keeping in not visible is ok too

Displaying X meters minimum range when all units are attacked would be misleading.
With the proposed patch applied, it will still be slightly unexpected: 25m minimum range when only units at the buildings footprint are attacked. On the other hand the tooltip doesn't lie, players should just know that the arrows are shot from the center (feels wrong to subtracting the footprint).

sure we agree.

In D111#3731, @elexis wrote:

(Some structures didn't comply with my math, without these tests, the minRange would have been too low or too big.)

well I had reviewed the tooltip part with that funny tooltip 2x2 matrix. I will check it again.

For the min dist, it seems you was misleaded by obstruction vs footprint? Moreover I have some checks to do as most of your structure are square.

Build is green

Updating workspaces.
Build (release)...
Build (debug)...
Running debug tests...
Running cxxtest tests (302 tests)..............................................................................................................................................................................................................................................................................................................OK!

http://jw:8080/job/phabricator/279/ for more details.

mimo added a subscriber: mimo.Jan 30 2017, 7:21 PM
mimo added inline comments.
binaries/data/mods/public/simulation/data/technologies/attack_tower_murderholes.json
9

this tooltip should be changed accordingly

fatherbushido resigned from this revision.Feb 9 2017, 1:16 PM
fatherbushido added a subscriber: fatherbushido.EditedFeb 19 2017, 5:30 PM

As we discussed together, there are some issue with square shape. It depends of what you want to do but you could use for example a formula like sqrt( (w/2)^2+(h/2)^2) + something.

As we discussed together, there are some issue with square shape. It depends of what you want to do but you could use for example a formula like sqrt( (w/2)^2+(h/2)^2) + something.

Yes, your review was posted in the lobby on the day the diff was updated the last time and it encompassed the fact that units can reach the potentially square obstruction shape of the building while the arrows shoot in a circular distance.
Hence we can't have the same distance from the obstruction shape to the min attack range and
have to indeed use minRange = sqrt((width/2)^2 + (height/2)^2) , where width and height are the obstruction size figures extended by the clearance of the units we care about (siege engine size 4 from pathfinder.xml) * 1.5 for example.

Even though every single building was tested manually, a spreadsheet would help making this more consistent.

shookees added inline comments.
binaries/data/mods/public/simulation/data/technologies/attack_tower_murderholes.json
3

changed from singular subject - tower - to plural - buildings. Was this intended?

Also Grugnas and Hannibal noticed that the civic center is also affected and they don't like it. Me neither on first sight, but on second sight I felt it was (a) more consistent and (b) allows players to certainly defeat a player in phase 1 (as the building can be surrounded once all defenders are killed).

binaries/data/mods/public/simulation/data/technologies/attack_tower_murderholes.json
3

It was intended, since the tech now affects multiple building types. The article has to go though (at the foot of defensive buildings)

elexis updated this revision to Diff 969.Mar 27 2017, 1:49 PM

Split the unrelated GUI tooltip code to D267, so that we can focus on the simulation/tech/balancing changes here and because we didn't have a comment on the GUI part here yet.

elexis retitled this revision from Minimum Attack Distance Tooltip to Murder Holes should apply to all defensive buildings.Mar 27 2017, 1:55 PM
elexis edited the summary of this revision. (Show Details)
elexis edited the test plan for this revision. (Show Details)

Build is green

Updating workspaces.
Build (release)...
Build (debug)...
Running release tests...
Running cxxtest tests (305 tests).................................................................................................................................................................................................................................................................................................................OK!
Running debug tests...
Running cxxtest tests (305 tests).................................................................................................................................................................................................................................................................................................................OK!

http://jw:8080/job/phabricator/618/ for more details.

fatherbushido added a comment.EditedApr 21 2017, 8:05 AM

Forget all what I said before, I didn't really understand.
EDIT: the table I had uploaded was for a minimal min distance
If there is no problem with unitAI or things like that (I don't know, that's the thing to check), my feeling is that it's not misleading to have a 0 minRange displayed. Something misleading could be to have a number like 4.0 with a 20.0x20.0 square. I
IIrc the min range is just used in unitAI and buildingAI.
In buildingAI the distance constraint is given by the RangeManager (it's center to center iirc)
So you want to display in the tooltip that you won't fire if a unit is inside the obstruction square? It seems imo useless and anyway it's not possitble as you will avoid the sides (if you take the inner circle) or you will add 4 lunes if you take the outer circle.

The confusing fact is also that those two min range ised in BuildingAI and UnitAI are not the same (despite the fact that they use different range check range manager vs unit motion):

  • the unit one gives a constraint to the distance where the unit should be before attacking
  • the building one gives a constraint to the distance at which targets should be before being attacked

(one could say it's the same, but not so much).

  • the tower siege and the ship ones should be even more confusing in that case :p (with our current system)

Just elements about that.

@fatherbushido @elexis : Regarding Fatherbushido's comment above: this is exactly why I changed this in D13. Now the range checks are in the obstruction manager and anybody can call them with arbitrary shapes, which would allow re-opening this discussion.

IMO right now we just need a temporary fix or something.

Forget all what I said before, I didn't really understand.
EDIT: the table I had uploaded was for a minimal min distance
it's not misleading to have a 0 minRange displayed.

It doesn't display 0 meters, so thats not an issue.
But the civic center tooltip currently displays 8 meters minimum range IIRC but the footprint is always bigger, so _that_ is misleading.

So you want to display in the tooltip that you won't fire if a unit is inside the obstruction square?

This is not a tooltip fix, this is a gameplay change. Murder holes tech should not only apply to the tower but also to fortress and potentiall other buildings.

you will add 4 lunes if you take the outer circle.

Doesn't matter, we already have that for murder holes. The idea is that you must research murder holes tech to reach units standing under the footprint.

Destroying CCs in age 1, eh? I think that won't change strategies too much... after all, kill what's outside the CC and the player is dead already. I think the bigger balance change would be that CCs and military colonies no longer can hold a territory by themselves without murder holes, making it more difficult to take an age II expansion or build a CC near the enemy. Maybe with this change Murder Holes should be an age 1 technology (researchable at the sentry tower and the guard tower) instead of an age 3 tech.

Note: the Crenellations guard tower tech tooltip says it installs "crenellations and murder holes" which is false.

fatherbushido added a comment.EditedMay 30 2017, 4:02 PM
  • Currently a min distance which is not an actual min distance (as it's always checked) is displayed. So we don't need it or we need to make it real. I would be for the 1st thing for the moment. So setting 0 for cc.
  • Making murderhole usefull for fortress is an option. So the tech is ok.
  • Then for the fortress, using only one min distance is imo sufficient (with some really slight benefits for some fortress). A value above 25 will be good (and ok for all fortress, taking into account their obstruction squares). Using the same value will make maintenance easier. EDIT: a value above 22 will be good, something like 25-30 sounds nice.
  • For the roman camp, see comment, your choice.
  • I checked wall towers, the min range 12.0 is ok (checked cart things, ...)
binaries/data/mods/public/simulation/templates/structures/brit_fortress.xml
6

I would set 0

binaries/data/mods/public/simulation/templates/structures/gaul_civil_centre.xml
7

I would remove

binaries/data/mods/public/simulation/templates/structures/ptol_military_colony.xml
7

same

binaries/data/mods/public/simulation/templates/structures/rome_army_camp.xml
19

Something between 26 - 30 if we want an actual min distance.
Else 0

62

If we want it to be affected by murderhole tech then adding the class.

binaries/data/mods/public/simulation/templates/structures/sele_military_colony.xml
8

same

binaries/data/mods/public/simulation/templates/template_structure_civic_civil_centre.xml
22

I would set 0

binaries/data/mods/public/simulation/templates/template_structure_military_fortress.xml
14

I would set something between 25 and 30 here (and don't specify the brit_fortress.xml one)

fatherbushido edited edge metadata.
fatherbushido removed a subscriber: fatherbushido.

I can t care of that

elexis planned changes to this revision.Mar 18 2018, 1:36 PM

With attack range visualization, this is much easier to test now.