I develop a custom scenario with roaming enemy spidertrons.
I've encountered a situation where an enemy spidertron fails to shoot hostile targets that are within its weapons range.
In the attached save game, the spidertron can be found dancing near GPS 900, 330
If you watch for a while, you should observe that it starts shooting again by itself after 2 minutes. Then its behavior goes back to normal.
Spidertrons have a weapons range of 32.
In the above screenshot, the spider is well within the range of player laser turrets, so I expected that it would shoot them, but it does not shoot at them.
It also does not shoot rockets at passing player construction robots.
No mods are used, this is all runtime stage script.
The spidertron has both auto-targeting boxes ticked.
Several targets are within its range.
It has ammo in its launchers.
After 2 minutes, player construction robots rebuild a nearby flame turret, and somehow this causes the spidertron to start shooting rockets again.
Further info:
The spider is "dancing" because it proceeds to the next waypoint in its route, sees a turret within 32, then goes back to the previous waypoint while its rocket launchers should be killing the turret. Repeat. In this case, the launchers aren't firing when I expected they would, so it just dances.
There is also a simple-entity-with-force within 32 of the spider. I expected the enemy spidertron should be shooting rockets at this too, but it does not shoot it.
These are created automatically by my script to cause the spiders to shoot rockets toward non-military targets such as walls, damaging them with Explosive Rockets.
These are created and rendered only to the "enemy" force, so that they are invisible to the player.
They are created for a "fake-player" force so that they don't appear in the player's kills statistics.
Normally this all works perfectly. I describe this just to add extra info that may not be immedietely visible, but could be related to the problem.
[1.1.104] Spider with auto-targeting does not shoot
- BattleFluffy
- Fast Inserter
- Posts: 204
- Joined: Sun Mar 31, 2019 4:58 pm
- Contact:
[1.1.104] Spider with auto-targeting does not shoot
- Attachments
-
- bugged spider.zip
- (27.72 MiB) Downloaded 37 times
-
- factorio-current.log
- (24.08 KiB) Downloaded 34 times
Re: [1.1.104] Spider with auto-targeting does not shoot
Thanks for the report. At this point I don't want to poke this in 1.1 so I've fixed it for 2.0. The issue was with the spidertrons internal logic to check if the current target was still in range not being the same as the shooter logic in-range check.
If you want to get ahold of me I'm almost always on Discord.
- BattleFluffy
- Fast Inserter
- Posts: 204
- Joined: Sun Mar 31, 2019 4:58 pm
- Contact: