Garry's Mod

Garry's Mod

51 ratings
[E2] Particle Core
2
   
Award
Favorite
Favorited
Unfavorite
Content Type: Addon
Addon Type: Effects
Addon Tags: Build, Realism
File Size
Posted
Updated
4.059 KB
3 Jan, 2017 @ 2:35pm
10 Dec, 2017 @ 8:18am
2 Change Notes ( view )

Subscribe to download
[E2] Particle Core

Description
Adds in particle functionality to Expression 2.
Reupload to workshop.

Thanks to 343N (Malcolm Turnbull) for updating and fixing parts of the code to reduce the footprint of the extension and to minimize crashes.

Function list: (NOTE: I honestly can't be bothered right now to get all the arguments here, but everything is fully explained in E2helper.)

- particleSetStartSize: Sets the size of the particle at creation (Default: 16)
- particleSetDuration: Sets the particle duration (Default: 1)
- particleCreate: Creates a particle with previously defined settings. (All settings are persistent)
- particleSetVelocity: Sets the particle's velocity upon creation, independent from gravity. (Default: 0, 0, 0)
- particleSetStartAlpha: Sets the Alpha of the particle at creation (Default: 255)
- particleSetColor: Sets the particle color (Default: 255, 255, 255)
- particleBounce: Sets the bounciness of particles. (Default: 0.3)
- particleSetEndSize: Sets the size of the particle at deletion (Default: 16)
- particleGravity: Sets the gravity of particles. (Default: 0, 0, -9.8)
- particleCanCreate: Returns 1 when particle() will successfully spawn a particle until the limit is reached.
- particlesList: Returns an array of material paths for use with particle functions.
- particleSetEndLength: Sets the length of the particle at deletion. MUST BE SET AFTER SETSIZE. Length always points towards direction of velocity. (Default: nil)
- particleCollision: Enables or disables particle collision. (Default: true)
- particleSetPitch: Sets the particle's pitch (Default: 0)
- particleSetPosition: Sets the particle position (Default: 0, 0, 0)
- particleSetStartLength: Sets the length of the particle at creation. MUST BE SET AFTER SETSIZE. Length always points towards direction of velocity. (Default: nil)
- particleSetEndAlpha: Sets the Alpha of the particle at deletion (Default: 255)
- particleSetMaterial: Sets the particle material path (works with PNGs now!)
- particleSetMaterialList: Sets the particle to use a list and select a random material from it, use an array of path strings.
102 Comments
SniperGnome 28 May, 2023 @ 7:52am 
@Tumble Trash Official
https://pastebin.com/Yg717TVT
Vurv 6 Sep, 2022 @ 12:29am 
This is a notice that some functionality this extension will likely be broken by wiremod/wire#2399 if you don't convert your ``e2function``s to return proper ``Vector`` and ``Angle`` userdata rather than tables of three numbers.

This is a copy pasted message, I cba to download the addon and check myself if it does contain use of these. Feel free to delete if this is non-applicable.
DaCat001 30 Sep, 2021 @ 1:01pm 
why is there no example chips or tutorials anywhere
Napalm (OOF) 1 Aug, 2021 @ 1:26pm 
Hey did anyone ever do an example E2?
Tumble Trash᠌ ⁧⁧ Official 8 Dec, 2020 @ 5:53pm 
can someone remake this E2? https://www.youtube.com/watch?v=yavq8dzPIiU
Business Cat 19 Aug, 2019 @ 3:27pm 
is there any e2 plugin that can? would be much appreciated
Xyvoracle  [author] 19 Aug, 2019 @ 5:02am 
Not that I know of.
Business Cat 18 Aug, 2019 @ 7:50pm 
is there a way to call up existing particle systems from pcf files? that would be much more useful than creating new particle systems inside of the e2 for what i need
DeHelleman 27 Apr, 2019 @ 3:01am 
i found an older version of the addon and that one works fine, it was an old e2 based on the ParticleCore so likely during some update, it started f*cking up, although thank you for trying anyways my dude, i barely know how to make an E2 work myself, let stand with an extension that i havent touched in years, so i was just plain confused with what would be a good replacement for the particle() that no longer exists, but the older version i found still has that piece so it works now
Xyvoracle  [author] 26 Apr, 2019 @ 4:36pm 
It's been so long since I worked on this I honestly don't know what works, what doesn't, and what isn't included at all. If I remember rightly you can still use particleCreate() with all the other functions to set one up. I might look into particle() soon but chances are slim since I don't play GMod often anymore.