Deleting enemy created by Emitter Trap. - by Kurhhan
Kurhhan on 29/11/2015 at 20:26
Hello,
how to delete/destroy by some signal/script, enemy who was created by Emitter Trap ? With "normal" enemy with "number" no problem, but how to do this with "emittertrap" kind ?
LarryG on 29/11/2015 at 21:47
You could pre-create the AI in a blue room and then teleport instead of emitting.
FireMage on 29/11/2015 at 22:31
Maybe he wanted to do a spawner?
In this case, emit a special guard what you will create in your archetype and set him a pre disabled delete tweq and then activate it by a situmulis that you may emit in the area with other emiters to destroy your guard. Don't forget to add a receptrons to your guards that will activate the tweq delete once they will receive the stimulis in question.
Or maybe with some special magical scripts but I don't know what script may do that.
NV script?
R Soul on 29/11/2015 at 22:48
Quote Posted by FireMage
Or maybe with some special magical scripts but I don't know what script may do that.
NV script?
Yes. Make sure there's an archetype just for this AI, and give it the script NVNameOnCreation.
Design note: NVSymName="MagicGuard"
On some marker, use NVDeleteTrap
Design note: NVDeleteTrapTarget="MagicGuard"
Kurhhan on 29/11/2015 at 23:32
@LarryG
Yes, I try this but then AI have patrolling problems. When teleported to TrolPt, AI don't want to start patrolling. The same "custom" AI created from Emitter Trap near the same TrolPt, starts patrol normally.
Thanks @FireMage.
@R Soul
Yes, this is what I wanted, works perfect. Great knowledge of scripting R Soul, thanks.
john9818a on 3/12/2015 at 08:33
If you want the AI to start patrolling after being teleported make sure he is in solid space and not the blue room. Doing so prevents the AI from trying to pathfind to a TrolPt from his position (the blue room) which would result in an error and would cause the AI to stop patrolling immediately.
Nameless Voice on 3/12/2015 at 13:07
Quote Posted by R Soul
Yes. Make sure there's an archetype just for this AI, and give it the script NVNameOnCreation.
Design note: NVSymName="MagicGuard"
On some marker, use NVDeleteTrap
Design note: NVDeleteTrapTarget="MagicGuard"
That will only work if there's only one guard, not if there are multiple which should all be deleted.
If you want to have multiple, then instead of using NVNameOnCreation to give the specific object a unique name, you can point the NVDeleteTrapTarget to delete all objects of a certain archetype, or the nearest one, or all within a certain radius. Check the NVScript documentation for more information.
Kurhhan on 19/12/2015 at 01:06
I don't know what is going on. Deleted enemy from #5 is making sounds in weird places now! : D
When I use other Emitter Trap or when I stick rope arrow to wooden obj (?!?!) I hear his voice. Also when doing this things, sometimes, long ago deleted by destroytrap random soundtrap starting playing again. I'm looking for connections for this weird s... but nothing. Someone once had something similar ?
john9818a on 19/12/2015 at 09:20
Yes! In my upcoming mission I have a pagan child with the voice of a frogbeast, and I used S&R to destroy the pagan child but sometimes the frogbeast voice remains and sometimes follows me to random places.
Kurhhan on 19/12/2015 at 09:36
Damm, this is weird John.
Fixed "enemy" voice. Just deleted Emitter Trap "MagicGuard" and replace it with "normal" enemy teleported from solid like you said in #6.
Now looking why when using other Emitter Trap and using rope arrow on wooden obj, sometimes long time ago deleted by destroy trap soundtraps, randomly starting playing again.