|View Issue Details|
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0005191||Spring engine||public||2016-04-01 18:31||2016-04-01 20:11|
|Target Version||Fixed in Version|
|Summary||0005191: Attacking unit stops following target if it has another weapon of bigger range|
|Description||Attacking unit stops chasing fleeing target if it has another weapon of bigger range, that cannot hit a target|
|Steps To Reproduce||Create an amphib unit. Assign it two weapons:|
 1000 elmo range cannon (waterWeapon = false)
 500 elmo range torpedo launcher (waterWeapon = true)
1) Get it into the water.
2) Spawn some enemy amph unit as a target somewhere well outside of torpedo range, but in the water
3) Order an attack command for the unit.
4) Observe the unit sets its course towards target, stops around the 500 elmo distance and starts firing.
5) Now move the target (godmode) outside of torpedo range. Observe the unit stopped firing (due to out of range) and NOT moving to chase fleeing target.
6) Now move target further outside of weapon (1000 elmo). Now the unit behaves correctly.
|Additional Information||The issue is probably due to the check if target is within primary weapon range (first WeaponDef), which is ok most of the time with land units. However the case when primary weapon cannot target/hit unit is not fully taken into account.|
|Tags||No tags attached.|
|Checked infolog.txt for lua Errors|
Issue could be tested with ZKE: http://zke.repo.springrts.com/builds/zke-0.02.sdz
/give amphartillery (the unit)
/give amphriot 1 (a target)
|2016-04-01 18:31||lhog||New Issue|
|2016-04-01 20:11||lhog||Note Added: 0016149|