Creep mod - Turret Target Control
Posted: Mon Apr 15, 2019 10:18 pm
I'm working on a mod that adds "creep" to the biters. Think Creeper World or Starcraft creep. My intention is to give the player a threat that behaves like a rising tide that strongly motivates you to build robust defenses.
I've got a decently efficient algorithm to spread the creep across the map using simple perlin noise however the problem I've run into is an efficient way to get turrets to attack the spread. The thing I've tried to far is to clone a biter and set its movement to 0 or scale down a worm and distribute them with the creep. The performance of this is obviously terrible.
https://i.imgur.com/hNXIY9m.gifv
Is their a more optimal API to interact with turret targeting? My immediate idea is to maintain a ring of "special" biter's along the advancing edge of the creep to give turrets something to shoot, which is very hacky.
Suggestions/Thoughts/Ideas appreciated.
I've got a decently efficient algorithm to spread the creep across the map using simple perlin noise however the problem I've run into is an efficient way to get turrets to attack the spread. The thing I've tried to far is to clone a biter and set its movement to 0 or scale down a worm and distribute them with the creep. The performance of this is obviously terrible.
![Image](https://forums.factorio.com/images/ext/53fd10157cefa204de6813a9f0f5b634.png)
Is their a more optimal API to interact with turret targeting? My immediate idea is to maintain a ring of "special" biter's along the advancing edge of the creep to give turrets something to shoot, which is very hacky.
Suggestions/Thoughts/Ideas appreciated.