Please or Register to create posts and topics.

[SOLVED]Can you fizzle/Dissolve Turrets on demand?

Page 1 of 2Next

I have a button in my map that when pressed (re) spawns a turret, using a env_entity_maker and point template.

simple question, I need to re-spawn a turret in my map, and I would like to fizzle the old turret first when the new one enters the scene, just like what would happen with a cube dropper. Now I have been able to kill the turret but the "dissolve" option is not available to me... It just does not "work" properly in the map and I would like to change this, but have been unsuccessful...

I've been trawling through tutorials and this site as well, but not found anything concrete to help me... I know that Turrets can dissolve though, walking though a trigger_portal_cleanser doe the job (how does the trigger_portal_cleanser call the fizzle procedure anyway, surely some animations and the sound must be called - so it is already programmed / setup) please let me know if you have an idea.. and maybe a hint on where I could have found this information in the first place.

many thanks!

At your Service

I have an idea... not sure if it's the most efficient one. Just parent a trigger_portal_cleanser to the turret, set it to start deactivated, and activate it when you want the turret fizzled. Make sure to set the "Physics Objects" flag on the trigger_portal_cleanser and deactivate the "Clients" flag.

Released Maps
[spoiler]WOM Test 1
Laser Cube Quest
Mho' Power - Community Spotlight!
Four Corners[/spoiler]

The strange thing is that turrets can fire an OnFizzled output; Hammer doesn't recognize it as valid, but it works when you throw a turret in a portal cleanser.

If you're going to make a trigger_portal_cleanser and parent it to the turret I would suggest adding a filter so that only turrets get dissolved (otherwise a cube next to the turret might become a casualty)

Another alternative is calling SelfDestruct or SelfDestructImmediately on the turret. It's not aesthetically the same as a fizzler dissolve, but personally I find it more satisfying

interesting idea, I tried it and it seems at first glance that the trigger_portal_cleanser does not want to be parented to the turret. e.g. if I leave the turret where it is the fizzle action works fine, if I move the turret the invisible cleanser does not move with it. I then tried using a normal brush with texture and parented that to the turret, and this did follow the turret around... its all a bit weird really... but I will run some more tests..

tnx for your comments narsqrd, I was already on the filtered outputs, but that is the least of my worries; I gave the cleanser fields a texture for testing, and it is hilarious to see what is going on. The first Turret that spawns will not fizzle, it refuses. Any subsequent turret has the ability to fizzle when in contact with the field. The best thing is though that all the fizzle fields are parented to the turret that does not want to die, I can pick up this turret and I have all these fizzle textures following it where ever it goes. So something is still amiss... weather it is a "rule" that a child cannot kill its parent (getting philosophical, at this time of night this can't bode well...) or is there something else going on... I might need to use thesee nifty console commands to see what name my NPC turret really has been given by the game, and why it won't fizzle when told to!

At your Service

What you're trying to accomplish reminds me of how Valve set up their cube droppers: a cube falls through a corridor and after touching a trigger, that cube is "marked" to be destroyed later (on demand)...

The idea would be to "mark" the spawned turret like so:

OnTrigger > spawned_turret > AddOutput > OnUser1 !self:Kill::0:1

(you could make a trigger filtered by name for example, right where the turret is spawned (where you have your env_entity_maker) and this way, every turret spawned will trigger it and will be marked)

Then, all that you have to do is fire the output FireUser1 whenever you need to kill your turret. If it's a button that kill it and then spawn another one, then use this settings for the button:

OnPressed > spawned_turret > FireUser1 / delay 0:00

OnPressed > turret_maker > ForceSpawn / delay 0:25

ImageImageImageImageImageuseful tools and stuff here on TWP :thumbup:
[spoiler]ImageImageImageImageImage[/spoiler]

I had a problem similar to this before. It seems that triggers don't work on their parent.

Call "ClearParent" on the trigger when you enable it, and see if that works.
(Also, to prevent unexpected fizzling of future turrets, remove (kill) the trigger after 0.1 seconds.)

Sendificate series: Sendificate | A Beam Too Far | Airtime | 302
Other Portal 2 maps: Medusa Glare
Portal 1 maps: Try Anything Twice | Manic Mechanic

You could parent a brush to the turret and a trigger to the brush.

Habzs wrote:
You could parent a brush to the turret and a trigger to the brush.

Nice one, this works! I must warn people that use this route that the brush should be tiny and should be slightly higher than the turret. Otherwise it will behave very odd at times when handling it.

I now need to fine-tune some logic behind the whole process but the main thing is achieved now :) Cheers!

At your Service
The_Butler wrote:
I must warn people that use this route that the brush should be tiny and should be slightly higher than the turret. Otherwise it will behave very odd at times when handling it.

Set the Solidity of the brush to Never Solid and texture it with a Nodraw texture.

That should fix the odd behavior when handling it.

you could simply have a large brush that encompasses the entire area where the turrets will be during play. That brush would be set to kill the turret. Basically, you are creating a large brush based fizzler. You can set it up to only fizzle certain objects. That way you don't have to muck about with parenting stuff.

Wow! That was...uh, yeah. Just, yeah.
Page 1 of 2Next