Page 1 of 1
Ghost entity placement event?
Posted: Mon Jan 04, 2021 8:25 am
by Omnifarious
There is an event for when the player (not a bot) builds an entity. Is there a way to detect when a player places a ghost? Not a blueprint, but a single entity ghost. My LD Circuit mod automatically adds circuit wires when the player places a long-distance power pole with a small supply range. I would like to be able to do this on ghost placement as well.
Thank you in advance (and likely afterwards too).
Re: Ghost entity placement event?
Posted: Mon Jan 04, 2021 9:24 am
by boskid
Ghosts are just another type of Entity so all the standard events should apply. When you build a ghost of electric pole you will get `on_built_entity` event with created_entity pointing to the entity-ghost for which ghost_name=<pole name>.
Re: Ghost entity placement event?
Posted: Mon Jan 04, 2021 4:22 pm
by Omnifarious
boskid wrote: ↑Mon Jan 04, 2021 9:24 am
Ghosts are just another type of Entity so all the standard events should apply. When you build a ghost of electric pole you will get `on_built_entity` event with created_entity pointing to the entity-ghost for which ghost_name=<pole name>.
Oh, nifty! Thank you. That definitely solves my problem.