Announcement

Collapse
No announcement yet.

auto-attack, cruise missiles etc

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • auto-attack, cruise missiles etc

    Has anyone noticed that auto-attack does some odd things?

    I've looked at the code and from what I can see, auto-attacking units can attack enemies they cannot see. They can also move to attack an enemy which they cannot actually attack.

    This is most noticeable with cruise missiles.

    Imagine a scenario with two late-stage fairly large civs on separate continents with 5 or 6 ocean squares between their lands. Cities on those shores cannot see each other, even with 2 squares of vision.

    Yet if either of those civs decides to build cruise missiles in those cities and put them on auto-attack against land units, they will find their cruise missiles zipping off deep into the heart of their enemy's lands to engage e.g. engineers that are busy clearing pollution! Engineers 12 squares away on a continent that cannot be seen. This does not seem very realistic.

    In addition, cruise missiles on auto-attack seem to do other odd things. They will leave a city to engage a bomber passing by 12 squares away, only to find that they cannot attack the bomber. The missile is then wasted with no target and is left to fall in the sea.

    Now, perhaps you could say that the fix to this is to never put cruise missiles on auto-attack. But that doesn't seem to be too great: it seems like cruise missiles would be useful on auto-attack against ships and some advancing ground units. That also doesn't fix the problem of units being able to auto-attack enemies the player cannot see.

    So, if there are any freeciv developers reading can you say why auto-attack works like this? Would a patch be accepted that:
    • Only allows auto-attack against enemies that the player can see
    • Picks an attacking unit that can actually engage the enemy?

    Some other thoughts:

    Thinking about auto-attack it would be nice if it had a few more controls. For example, setting auto-attack against ground units means that you can waste missiles on:
    • Settlers/Engineers
    • Diplomats/Spies
    • Caravans/Freight

    Of course maybe you really do want to kill those units, but I think the majority of the time you don't really care about anything but diplomats/spies.

    Some other people I play with have remarked that it would be nice to be able to tell each of your own units what sort of enemies they would like it to auto-attack. I can't really see how that could be implemented cleanly in current clients with leading to endless micromanagement, but perhaps it is something for you to think about.

  • #2
    The autoattack code is just horrible. Patches to clean it up and improve it would be welcome. I do not think adding further customization/micromanagement of auto-attack is a good idea, though. It is already an ugly kludge design- and user-interface-wise.

    I wrote a patch to add immediate autoattack, which attacked the moment another unit moved up adjacent to your unit, and which used a lot better algorithm, but it was not very popular and did not go in.

    Comment


    • #3
      OK, thanks for the response. I guess I will start to discuss this on the freeciv-dev list and see what people think.

      I do think that these problems either should be fixed or auto-attack disabled, since attacking units you can't see is highly unrealistic/unfair, and having your missiles wasted is annoying.

      Comment


      • #4
        The autoattack code is just horrible. Patches to clean it up and improve it would be welcome.
        I always favored patches to remove it . (seriously)
        http://www.hardware-wiki.com - A wiki about computers, with focus on Linux support.

        Comment

        Working...
        X