Opened 12 years ago

Closed 7 years ago

Last modified 7 years ago

#1487 closed defect (fixed)

[PATCH] Prevent land fauna from attacking ships

Reported by: Peter Owned by:
Priority: Nice to Have Milestone: Alpha 22
Component: UI & Simulation Keywords: patch
Cc: Priqvel@…, knight.erraunt@… Patch:

Description

When ship attack lion, lion reply and attack ship, but he gets "into" the ship, to the core for attack, It causes of graphic issue. Lion just get absorbed by ship. And the second, I wish you could highlight cursos.And made spears a lil bit bigger, cuz sometimes hard to see it when grass on a background

Attachments (8)

templates_land_fauna_ships_cant_touch.diff (2.6 KB ) - added by erraunt 8 years ago.
some_stupid_solution.diff (465 bytes ) - added by erraunt 8 years ago.
bit_better_solution.diff (2.1 KB ) - added by erraunt 8 years ago.
restrictedclassesanimal.diff (10.9 KB ) - added by fatherbushido 8 years ago.
based on erraunt patch, removes useless identity entry, adress defensive animal case
restrictedclassesanimal.2.diff (17.5 KB ) - added by fatherbushido 8 years ago.
merge some elephant templates in the same move
only_elephants_can_attack_siege.patch (4.6 KB ) - added by elexis 7 years ago.
bbox.jpg (1.1 MB ) - added by elexis 7 years ago.
height.jpg (591.6 KB ) - added by elexis 7 years ago.

Download all attachments as: .zip

Change History (32)

comment:1 by Kieran P, 12 years ago

Component: Core engineUI & Simulation
Keywords: lion ship cursor removed
Priority: Should HaveNice to Have

comment:2 by historic_bruno, 12 years ago

Hmm sounds like multiple problems. We should prevent ships from attacking land units and vice versa. And most gaia animals should stay away from water, especially deeper water, I think that could be done with passability classes.

comment:3 by historic_bruno, 12 years ago

Summary: Graphic issues. Lion attack shipPrevent land fauna from attacking ships

comment:4 by erraunt, 8 years ago

comment:5 by erraunt, 8 years ago

The patch mentioned above solves nothing. (will change it as soon as I have a proper one)

Last edited 8 years ago by erraunt (previous) (diff)

by erraunt, 8 years ago

Attachment: some_stupid_solution.diff added

comment:6 by erraunt, 8 years ago

Ok, so I came up with this simple if which prevent's non SeaCreature(s) from attacking Ship(s). This solves the problem from this ticket. Anyways I believe it is extremely ugly, if anyone comes up with a neater idea, express it here and I will be more then glad to execute it (if one wants so of course).

comment:7 by erraunt, 8 years ago

Cc: knight.erraunt@… added
Keywords: rfc patch added

comment:8 by erraunt, 8 years ago

Summary: Prevent land fauna from attacking ships[PATCH] Prevent land fauna from attacking ships

comment:9 by Stan, 8 years ago

Milestone: BacklogAlpha 21

by erraunt, 8 years ago

Attachment: bit_better_solution.diff added

comment:10 by erraunt, 8 years ago

After consulting this with Imarok on the IRC, I prepared an alternative solution - added Ship to the restricted classes of all the animal templates, it has some downside - if someone creates a SeaCreature based on one of these templates, it will not be able to attack Ships (Shark is created like that but it is not able to attack anyways so it is not a problem), or if someone does not used this templates he may create a land animal able to attack a Ship. To me both solutions are not that nice but at the same time both resolve the problem.

by fatherbushido, 8 years ago

based on erraunt patch, removes useless identity entry, adress defensive animal case

comment:11 by fatherbushido, 8 years ago

Keywords: review added; rfc removed

by fatherbushido, 8 years ago

merge some elephant templates in the same move

comment:12 by elexis, 8 years ago

  • It was always fun when gaia elephants destroyed towers, civic centers or ships, because some arrow missed the target and hit the elephant :D

If there is a graphical issue with gaia elephants attacking ships, then there is likely one with war elephants too and many other units?

Does this also occur when just walking to the target instead of attack-moving there?

Why do structures become restricted?

  • IMO it were nice to use relative for Health, Loot, ResourceSupply and where else possible

comment:13 by fatherbushido, 8 years ago

  • Yes, perhaps elephants should still attack structure.
  • The situation is different imo for players units and for animals (gaia animals will be stuck at the coast trying to attack the ship)
  • Indeed (just use addition as there'll be issue with mul and integers for loot and resourcesupply)
Last edited 8 years ago by fatherbushido (previous) (diff)

comment:14 by elexis, 8 years ago

Milestone: Alpha 21Alpha 22

Feel free to correct the milestone with a commit if it's well tested and addresses the comments. Relative templates probably not that crucial.

comment:15 by fatherbushido, 7 years ago

Keywords: review removed

needs to be worked and thought again

comment:16 by elexis, 7 years ago

Keywords: rfc added

The empty identity components were removed already. fb's patch still seems ready to go mostly, so putting this under rfc. Would be nice if he or me finds the time to put it to phabricator or commit it. Also with regards to the attack cursor issue, females shouldn't be able to attack ships.

by elexis, 7 years ago

Attachment: bbox.jpg added

comment:17 by elexis, 7 years ago

As we can see, unifying the Footprint is not advisable: http://trac.wildfiregames.com/raw-attachment/ticket/1487/bbox.jpg

by elexis, 7 years ago

Attachment: height.jpg added

comment:18 by elexis, 7 years ago

http://trac.wildfiregames.com/raw-attachment/ticket/1487/height.jpg

From left to right, current stats:

African Bush (800 food, 300 HP, 75 XP, biggest footprint) Asian (650 food, 250 HP, 60 XP) North African (500 food, 200 HP, 50 XP, smallest footprint)

Loot was added for all eles in r10473

Last edited 7 years ago by elexis (previous) (diff)

comment:19 by elexis, 7 years ago

North African Elephant added without crush damage in r7259, added other damage in r9487 but forgot to add the crush damage. African Bush Elephant added with 10 crush damage in r8363. Asian Elephant added with 20 crush damage in r9900.

comment:20 by elexis, 7 years ago

In 19295:

Merge duplicate elephant templates to a new inherited template. Patch by fatherbushido, refs #1487.

Prevent these elephants from attacking structures, which can happen incidentally if the animal is attacked by garrisoned arrows that were meant to hit attacking players and because that is unexpected to players and had been reported as a bug and cheating players.
Prevent them from attacking ships, because they can't reach them in most cases.

Unifty their Attack stats that had neglible differences, besides the missing Crush damage of the North African Elephant variant, forgotton to make consistent in rP9487 with rP8363.
Add the large passability class to the North African and Asian elephant, which was forgotton by rP16868.

comment:21 by elexis, 7 years ago

Keywords: rfc removed
  • Agreeing to keep the Loot values (removing Loot of the African Bush elephant must have been oversight).
  • Agreeing to add template_unit_fauna_hunt_defensive_elephant.xml to the root tempalte directory, as that contains all inherited ones.
  • Agreeing that changing hp, xp and resource supply stats to additive relative numbers doesn't help, because if someone changes the parent template significantly, the relative numbers in the child templates become wrong too
  • Agreeing that the infant template shouldn't inherit the new parent template, because it only shares Sound
  • Agreeing that Structure should become restricted, because it is unexpected that gaia elephants destroy garrisoned civic centers that incidentally attacked a near elephant when the arrows intended to hit attacking enemies instead. This is commonly perceived as a bug, so it's better to remove that ability from the Gaia elephants.
  • The empty Identity components had been nuked already, so that, besides the Loot part, is the only thing that was rebased / changed from your patch.
  • The non-elephant changes should become a separate diff.

Thanks for the great cleanup patch!

comment:22 by elexis, 7 years ago

In 19296:

Prevent animals from attacking siege engines and ships, prevent females from attacking ships and heroes.
Overviewed by fatherbushido, refs #1487.

comment:23 by elexis, 7 years ago

Resolution: fixed
Status: newclosed

comment:24 by elexis, 7 years ago

In 19303:

Fix an oversight in 19296: Spartan females should remain able to attack heroes.

Differential Revision: D226
Patch By: Grugnas
Refs #1487

Note: See TracTickets for help on using tickets.