Skip to content

jengine-particles

Particle system package for jEngine — 2D particle emitters and simulation.

KindBuilt-in: linked into the stock runtime and editor viewport
Sourcepackages/jengine-particles
Version0.1.0
Entry pointjengine_particles::ParticlesPackage

The stock runtime, web build and editor viewport are compiled with this package, so there is nothing to link. A project that has a settings.enabled_packages list must name it there, since that list is an allow-list once it exists; a project without the key gets every built-in.

{ "settings": { "enabled_packages": ["jengine-particles"] } }

Its components are also core components, so v1 and v2 scenes both carry them.

Scene keyRust type
particle_emitterParticleEmitteralso registered by core
  • projects/arcade-classics/assets/scenes/breakout.scene
  • projects/arcade-classics/assets/scenes/lemonrow.scene
  • projects/arcade-classics/assets/scenes/pong.scene
  • projects/car-classics/assets/scenes/climb.scene
  • projects/car-classics/assets/scenes/hunter.scene
  • projects/car-classics/assets/scenes/kart.scene
  • projects/car-classics/assets/scenes/micro.scene
  • projects/car-classics/assets/scenes/micro_online.scene
  • projects/car-classics/assets/scenes/outrun.scene
  • projects/car-classics/assets/scenes/parking.scene
  • projects/car-classics/assets/scenes/pursuit.scene
  • projects/car-classics/assets/scenes/rally.scene
  • …and 211 more

From packages/jengine-particles/README.md.

Particle emitters: fire, smoke, sparks, rain.

This is a built-in package: the native runtime, the web runtime and the editor viewport are compiled with it. It registers the component; the simulation is core’s particles::tick_particles, which every runtime calls once a frame, so emitters behave the same everywhere.

ComponentIs
particle_emitterAn emitter: emission_rate, max_particles, lifetime, speed, angle, start / end colour and size, gravity_modifier, emit_shape, blend_mode, world_space, z_order - and the newer fields: drag, turbulence, colour and size curves, stretch, collision with colliders and sub_emitters.

particle_emitter is also a core component, so it works in v1 and v2 scenes. An emitter can name a shared definition instead of carrying every field: { "particle_source": "particles/fire.particle" } loads one.

For hundreds of thousands of particles drawn by the GPU, use core’s gpu_particles component instead.

Scripts use core’s Particles namespace in every runtime: Particles.emit_burst, Particles.set_active, Particles.set_rate, Particles.get_count, and Particles.set(e, field, value) for any emitter field by name. See the Particles guide.

The package’s own particle_* script descriptors are metadata only; no runtime installs them as globals.