Entity.StopParticleEmission

From GMod Wiki

Jump to: navigation, search
Function
Syntax Entity:StopParticleEmission( String Name )
Description:
Removes a particle effect on the entity.
Returns: nil
In Object: Entity
Realm: NewerClient.png
BBCode Link: [b][url=http://wiki.garrysmod.com/?title=Entity.StopParticleEmission]Entity.StopParticleEmission [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b]



Examples

DescriptionCreates a blue TF2 medigun beam between the local player's feet and whatever they're aiming at, and removes after 5 seconds.
Used onNewerClient.png
Code
local pl = LocalPlayer()
local tr = pl:GetEyeTraceNoCursor()
PrecacheParticleSystem("medicgun_beam_blue")
--Control Points
local CPoint0 = {
	["entity"] = pl,
	["attachtype"] = PATTACH_ABSORIGIN_FOLLOW,
	}
local CPoint1 = {
	["entity"] = tr.Entity,
	["attachtype"] = PATTACH_ABSORIGIN_FOLLOW,
	}
 
--Create the particle effect!
pl:CreateParticleEffect("medicgun_beam_blue",{CPoint0,CPoint1})
timer.Simple(5,function() pl:StopParticleEmission("medicgun_beam_blue") end)
 
OutputN/A


Additional Notes

See Also

Personal tools
Namespaces
Variants
Actions
Navigation
Lua Scripting
Functions
Hooks
Toolbox