Effect

Spawn or interact with a specified particle effect.

Syntax

Effect [slotnum],[effectname],[attachmentpoint],[xpos],[ypos],[zpos],[lifetime],[hitchup] -- Spawns and sets up a particle effect utilizing all parameters

Effect [slotnum],[reset] -- Reset an existing particle effect

Effect [slotnum],[kill] -- Kill an existing particle effect

Note

The slotnum parameter is used to refer to an existing particle effect if needed.

The hitchup parameter makes it parented to the caller, and makes the position offset relative to the specified attachment point.

The attachmentpoint parameter is any bone name of an NPC for example

The names of existing particle effects correspond to their names in their related .pcf file, located in Postal III\p3\particles. In order to load these particle effects and to view each of the effect names, you will need to load the in-game particle editor in Half-Life 2. Launch Half-Life 2 with the -tools -nop4 launch arguments, and navigate to the particle editor and load one.

Doing reset on a particle effect is basically the same thing as killing it

If you managed to make Hammer++ work somehow, you can view all the particle effects in it's Particle browser.

Example


pt_default
{
    actions
    {
        // Spawn a Tazer_Hit_Smoke_Fx particle effect assigned to slot 4, attached to the pelvis, 
        // with a z position offset, infinite lifetime, and hitched up to to us...
        Effect 4,Tazer_Hit_Smoke_Fx,pelvis,0,0,-12,-1,true

        // Reset the slot 4 particle effect...
        // (This will make the effect disappear immediately)
        Effect 4,reset

        // Kill the slot 4 particle effect...
        // (This too)
        Effect 4,false
    }
}