Hello,
I encountered this bug when playing with https://mods.factorio.com/mod/snouz_long_electric_gun_turret. When it selects an entity to fire on, if the entity moves to the left or right of its firing cone, the turret rotates itself to keep the target in the firing cone.
This is easiest to test with Strafers, because they move to the sides. (Harder to get biters to move like that, but I managed to reproduce it by pushing them with belts.)
If I patch the collision_box of the focussed gun turret to be the slightly-rectangular {{-0.71, -0.7}, {0.71, 0.7}} (instead of {{-0.7, -0.7}, {0.7, 0.7}}) and set turret_base_has_rotation=true, then it stops rotating itself.
This feels like unintended behavior to me, as the whole point of a turret with a restricted firing cone is that it can't fire outside of that cone. Also, this case never happens in the vanilla game, because the turrets with restricted turn range (railguns and flamethrowers) happen to have non-square hitboxes; this leads me to believe it is an oversight.
I have attached the log. Thank you!
[2.0.66] Turrets with a limited turn_range and a square hitbox will turn themselves to keep firing at entities
-
- Inserter
- Posts: 27
- Joined: Fri Apr 19, 2024 7:12 pm
- Contact:
[2.0.66] Turrets with a limited turn_range and a square hitbox will turn themselves to keep firing at entities
- Attachments
-
- factorio-current.log
- (11.28 KiB) Downloaded 9 times
Re: [2.0.66] Turrets with a limited turn_range and a square hitbox will turn themselves to keep firing at entities
Duplicate: 121473
I'm an admin over at https://wiki.factorio.com. Feel free to contact me if there's anything wrong (or right) with it.