Warzone2100 / warzone2100

Command the forces of The Project in a battle to rebuild the world after mankind has been nearly destroyed by nuclear missiles. A 100% free and open source real-time strategy game for Windows, macOS, Linux, BSD+
https://wz2100.net
GNU General Public License v2.0
3.17k stars 525 forks source link

Units ordered to attack at short range refuse to fire until close enough #2620

Open DARwins1 opened 2 years ago

DARwins1 commented 2 years ago

Describe the bug If a unit is set to prefer "Short Range" and it is ordered to attack a target, it will hold fire until the target within its short range radius.

To Reproduce Steps to reproduce the behavior:

  1. Build any attack unit.
  2. Set it to "Short Range".
  3. Order it to attack any distant target.
  4. Notice how it will not fire at all until within the unit's short range radius.

Additional context If given a move order, the unit will still attack targets within its maximum range.

Expected behavior Units set to prefer short ranges should still fire at enemies within their max range while closing the distance.

Screenshots or Videos This Mini-Rocket Pod unit is set to Short Range, and told to move within range of some enemy structures. It begins to fire (as expected). image But when ordered to attack the sensor tower, it approaches the tower but stops firing until it gets within range. image

Your System:

gantsevdenis commented 2 years ago

Doesn't quite look as a bug to me. You gave an explicit "Short range" order, so the unit tries to come closer. You choose "Mini Rocket Pad" for you example, but let's say I have a slow-to-recharge weapon (medium/heavy cannons). If I gave "Short Range", it's presumably, I don't want them to lose ammo while too far from target. So the unit is correctly holding fire until arriving at correct distance.

Chewbakka-Wakka commented 6 days ago

"Units set to prefer short ranges should still fire at enemies within their max range while closing the distance." - Concur. This is how it always used to be.