Summary

Methods

Detonates the breach, removes it and fires the EntityBreached hook for the attached entity.
Spawns a broken padlock prop at the breach that decays after 30 seconds.
Draw()client
Draws the breach model.
Explode()server
Plays the breach detonation effect and impact sound at the breach position.
Draws the breach name and usage hint as the target ID.
Sets up the breach padlock model and physics.
Subtracts the damage from the breach's health and breaches the entity when it reaches 0.
Attaches the breach to an entity at the traced hit position.
Always transmits the breach to every client.

Methods

Detonates the breach, removes it and fires the EntityBreached hook for the attached entity.

Parameters

  • activator Entity Whoever set off the breach, usually the attacker that destroyed it

Spawns a broken padlock prop at the breach that decays after 30 seconds.

Draws the breach model.

Plays the breach detonation effect and impact sound at the breach position.

Draws the breach name and usage hint as the target ID.

Parameters

  • x
  • y
  • alpha

Sets up the breach padlock model and physics.

Subtracts the damage from the breach's health and breaches the entity when it reaches 0.

Parameters

  • damageInfo

ENT:SetBreachEntity(entity, trace)

server gamemodes/cwhl2rp/schema/entities/entities/cw_breach/init.lua:57

Attaches the breach to an entity at the traced hit position.

The breach is parented to the entity, faces along the hit normal, is removed together with the entity and gets 5 health. The entity's breach field is set to the breach.

Parameters

  • entity Entity The door or entity to breach
  • trace Map Trace result whose HitPos and HitNormal place the breach

Always transmits the breach to every client.

Defined in