Knuckle Cracker

Particle Fleet => Map Makers, Ship Builders, and Coders => Topic started by: Keeper Decagon on February 10, 2017, 09:27:11 AM

Title: Custom Stunner Spawner
Post by: Keeper Decagon on February 10, 2017, 09:27:11 AM
I'm basically looking for a structure that spawns stunners but only targets ships within a certain radius of the spawner. Is this possible, and if so, can somebody help me out with a script?
Title: Re: Custom Stunner Spawner
Post by: Nicant on February 10, 2017, 04:14:10 PM
It's possible to make the script find a ship in a radius and spawn a stunner, but i do not think you can change the stunner's target. Stunners seem to find a random target and will continue to pursue that target until destroyed. Interestingly enough, when making the overcharge module, stunners will still pursue their original target even after they have switched teams.

So sadly, i don't think there is a way, but who knows!
Title: Re: Custom Stunner Spawner
Post by: GoodMorning on February 10, 2017, 06:40:21 PM
This may be doable, I think planetfall's map sudo rm lathe had stunner generation/targeting code. Managing the radius might involve DestroyUnit for Stunners which wander too far.