Talk:Particles In Code

From Valve Developer Community
Jump to: navigation, search
  • More Info
  • Valid attachment types
    • "String Name" for GetAttachTypeFromString :: ParticleAttachment_t enum :: Description
    • "start_at_origin" :: PATTACH_ABSORIGIN :: Create at absorigin, but don't follow
    • "follow_origin" :: PATTACH_ABSORIGIN_FOLLOW :: Create at absorigin, and update to follow the entity
    • "start_at_customorigin" :: PATTACH_CUSTOMORIGIN :: Create at a custom origin, but don't follow
    • "start_at_attachment" :: PATTACH_POINT :: Create on attachment point, but don't follow
    • "follow_attachment" :: PATTACH_POINT_FOLLOW :: Create on attachment point, and update to follow the entity
      • From particle_prase.h

using this as a scratch pad before rolling it into the main article --Grash 18:51, 15 February 2009 (UTC)

clientside particles

I have no clue how to create client-side particles, the examples for client particles on this page don't even work. could someone please explain how it works? --Pfannkuchen 22:19, 9 May 2010 (UTC)

The page explains everything you need to know. Try being more specific than "doesn't work". --TomEdwards 00:54, 11 May 2010 (UTC)
Thats pretty specific Tom. It's as simple as the shit doesn't work.--Gear 10:26, 11 May 2010 (UTC)
when I use DispatchParticleEffect() only red crosses appear, but I made a PrecacheParticleSystem() call already --Pfannkuchen 21:09, 28 May 2010 (UTC)
btw, how to get the new impact effects to work? --Pfannkuchen 22:02, 29 May 2010 (UTC)
It would appear that your particle system is broken, then. Does it work if you create it with info_particle_system? --TomEdwards 22:49, 30 May 2010 (UTC)
the ps worked perfectly and I fixed the precache stuff now, I don't use DispatchParticleEffect() anymore, now I use CNewParticleEffect* pEffect = new CNewParticleEffect( NULL, ParticleName ), with that the Precache call works. you might add that to the page, because sometimes you don't want paricles only in entities and to fix the cl_new_impact_effects you just have to change this:
CSmartPtr<CNewParticleEffect> pEffect = CNewParticleEffect::Create( NULL, pImpactName );

to

CNewParticleEffect* pEffect = new CNewParticleEffect( NULL, pImpactName );


DispatchParticleEffect() on the client

I never had issues with DispatchParticleEffect() on the client since the orangebox beta sdk in 2007. If anyone is still having issues, could you give details where you call the function from, what the result is and which exact sdk you're using? The error particle problem like above usually just means that the particle system can't be found for instance. --Biohazard 01:33, 4 February 2011 (UTC)