physics_cannister
Jump to navigation
Jump to search
Code classes:
CPhysicsCannister
CBaseCombatCharacter
CBaseFlex
CBaseAnimatingOverlay
CBaseAnimating
(models)CBaseEntity
(all ents)
physics_cannister
is a point entity present in all Source games. It's a regular physics object that acts like a gas canister. When hurt, the cannister will fly off cartoonishly. If it takes enough damage, it will explode.
Note: The model should have a nozzle
attachment point, which is where gas will escape and thrust will be produced from.
To do: How does the engine differentiate between shots on the nozzle and on the body of the canister model used in HL2?
Flags[edit | edit source]
- 1: Start Asleep - Canister will not move until a force acts upon it.
- 2:
Explodes- Does nothing.
Keyvalues[edit | edit source]
- Health
(health)
<integer>
- How much damage the canister can take before exploding.
- Explosion Damage
(expdamage)
<float>
- Maximum damage when exploding.
- Explosion Radius
(expradius)
<float>
- Maximum range of explosion.
- Fuel Seconds
(fuel)
<float>
- How long to fly around for.
- Thrust
(thrust)
<float>
- How much force to fly around with.
- Thruster Sound
(gassound)
<sound>
- The sound played when the gas is escaping from the canister.
- Smoke Color
(rendercolor)
<color255>
- Color of gas.
- Smoke Alpha
(renderamt)
<integer>
- Opacity of gas.
Inputs[edit | edit source]
- Activate
- Makes the canister start flying.
- Deactivate
- Makes the canister stop flying.
- Explode
- Makes the canister explode.
- Wake
- Wakes the object if it was sleeping.
Outputs[edit | edit source]
- OnActivate
- Fires whenever the canister is activated.
- OnAwakened
- Fires the first time that the entity moves, if Start Asleep was set.