From 44292bf77fd20f988d2c69c11e01ef9623ae1b22 Mon Sep 17 00:00:00 2001 From: Chris Bradfield Date: Tue, 3 Oct 2017 12:30:32 -0700 Subject: [PATCH] [DOCS] Update ParticlesMaterial, Particles class ref --- doc/classes/Particles.xml | 16 ++++++++ doc/classes/Particles2D.xml | 20 ++++++++- doc/classes/ParticlesMaterial.xml | 68 +++++++++++++++++++++++++++++++ 3 files changed, 102 insertions(+), 2 deletions(-) diff --git a/doc/classes/Particles.xml b/doc/classes/Particles.xml index e17e60f2bc..1e89d2194c 100644 --- a/doc/classes/Particles.xml +++ b/doc/classes/Particles.xml @@ -1,8 +1,11 @@ + 3D particle emitter. + 3D particle node used to create a variety of particle systems and effects. [code]Particles[/code] features an emitter that generates some number of particles at a given rate. + Use the [code]process_material[/code] property to add a [ParticlesMaterial] to configure particle appearance and behavior. Alternatively, you can add a [ShaderMaterial] which will be applied to all particles. @@ -252,8 +255,10 @@ + Number of particles to emit. + Particle draw order. Uses [code]DRAW_ORDER_*[/code] values. Default value: [code]DRAW_ORDER_INDEX[/code]. @@ -266,36 +271,47 @@ + If [code]true[/code] particles are being emitted. Default value: [code]true[/code]. + Time ratio between each emission. If [code]0[/code] particles are emitted continuously. If [code]1[/code] all particles are emitted simultaneously. Default value: [code]0[/code]. + Amount of time each particle will exist. Default value: [code]1[/code]. + If [code]true[/code] particles use the parent node's coordinate space. If [code]false[/code] they use global coordinates. Default value: [code]true[/code]. + If [code]true[/code] only [code]amount[/code] particles will be emitted. Default value: [code]false[/code]. + [Material] for processing particles. Can be a [ParticlesMaterial] or a [ShaderMaterial]. + Emission randomness ratio. Default value: [code]0[/code]. + Speed scaling ratio. Default value: [code]1[/code]. + Particles are drawn in the order emitted. + Particles are drawn in order of remaining lifetime. + Particles are drawn in order of depth. diff --git a/doc/classes/Particles2D.xml b/doc/classes/Particles2D.xml index d837d6eb62..b2c63ea0c3 100644 --- a/doc/classes/Particles2D.xml +++ b/doc/classes/Particles2D.xml @@ -1,10 +1,11 @@ - 2D Particle emitter + 2D particle emitter. - Particles2D is a particle system 2D [Node] that is used to simulate several types of particle effects, such as explosions, rain, snow, fireflies, or other magical-like shinny sparkles. Particles are drawn using impostors, and given their dynamic behavior, the user must provide a visibility bounding box (although helpers to create one automatically exist). + 2D particle node used to create a variety of particle systems and effects. [code]Particles2D[/code] features an emitter that generates some number of particles at a given rate. + Use the [code]process_material[/code] property to add a [ParticlesMaterial] to configure particle appearance and behavior. Alternatively, you can add a [ShaderMaterial] which will be applied to all particles. @@ -285,46 +286,61 @@ + Number of particles to emit. + Particle draw order. Uses [code]DRAW_ORDER_*[/code] values. Default value: [code]DRAW_ORDER_INDEX[/code]. + If [code]true[/code] particles are being emitted. Default value: [code]true[/code]. + Time ratio between each emission. If [code]0[/code] particles are emitted continuously. If [code]1[/code] all particles are emitted simultaneously. Default value: [code]0[/code]. + Number of horizontal frames in [code]texture[/code]. + Amount of time each particle will exist. Default value: [code]1[/code]. + If [code]true[/code] particles use the parent node's coordinate space. If [code]false[/code] they use global coordinates. Default value: [code]true[/code]. + If [code]true[/code] only [code]amount[/code] particles will be emitted. Default value: [code]false[/code]. + [Material] for processing particles. Can be a [ParticlesMaterial] or a [ShaderMaterial]. + Emission randomness ratio. Default value: [code]0[/code]. + Speed scaling ratio. Default value: [code]1[/code]. + Particle texture. If [code]null[/code] particles will be squares. + Number of vertical frames in [code]texture[/code]. + Particles are drawn in the order emitted. + Particles are drawn in order of remaining lifetime. diff --git a/doc/classes/ParticlesMaterial.xml b/doc/classes/ParticlesMaterial.xml index 1767a19a9f..bebdc44b69 100644 --- a/doc/classes/ParticlesMaterial.xml +++ b/doc/classes/ParticlesMaterial.xml @@ -1,8 +1,11 @@ + Particle properties for [Particles] and [Particles2D] nodes. + ParticlesMaterial defines particle properties and behavior. It is used in the [code]process_material[/code] of [Particles] and [Particles2D] emitter nodes. + Some of this material's properties are applied to each particle when emitted, while others can have a [CurveTexture] applied to vary values over the lifetime of the particle. @@ -294,152 +297,217 @@ + Initial rotation applied to each particle. + Each particle's rotation will be animated along this [CurveTexture]. + Rotation randomness ratio. Default value: [code]0[/code]. + Initial angular velocity applied to each particle. + Each particle's angular velocity will vary along this [CurveTexture]. + Angular velocity randomness ratio. Default value: [code]0[/code]. + If [code]true[/code] animation will loop. Default value: [code]false[/code]. + Particle animation offset. + Each particle's animation offset will vary along this [CurveTexture]. + Animation offset randomness ratio. Default value: [code]0[/code]. + Particle animation speed. + Each particle's animation speed will vary along this [CurveTexture]. + Animation speed randomness ratio. Default value: [code]0[/code]. + Each particle's initial color. If the [Particle2D]'s [code]texture[/code] is defined, it will be multiplied by this color. + Each particle's color will vary along this [GradientTexture]. + The rate at which particles lose velocity. + Damping will vary along this [CurveTexture]. + Damping randomness ratio. Default value: [code]0[/code]. + The box's extents if [code]emission_shape[/code] is set to [code]EMISSION_SHAPE_BOX[/code]. + The number of emission points if [code]emission_shape[/code] is set to [code]EMISSION_SHAPE_POINTS[/code] or [code]EMISSION_SHAPE_DIRECTED_POINTS[/code]. + Particles will be emitted inside this region. Use [code]EMISSION_SHAPE_*[/code] constants for values. Default value: [code]EMISSION_SHAPE_POINT[/code]. + The sphere's radius if [code]emission_shape[/code] is set to [code]EMISSION_SHAPE_SPHERE[/code]. + If [code]true[/code] particles will not move on the z axis. Default value: [code]true[/code] for [Particles2D], [code]false[/code] for [Particles]. + Gravity applied to every particle. Default value: [code](0, 98, 0)[/code]. + Initial hue variation applied to each particle. + Each particle's hue will vary along this [CurveTexture]. + Hue variation randomness ratio. Default value: [code]0[/code]. + Initial velocity for each particle. + Initial velocity randomness ratio. Default value: [code]0[/code]. + Linear acceleration applied to each particle. + Each particle's linear acceleration will vary along this [CurveTexture]. + Linear acceleration randomness ratio. Default value: [code]0[/code]. + Orbital velocity applied to each particle. + Each particle's orbital velocity will vary along this [CurveTexture]. + Orbital velocity randomness ratio. Default value: [code]0[/code]. + Linear acceleration applied to each particle. + Each particle's radial acceleration will vary along this [CurveTexture]. + Radial acceleration randomness ratio. Default value: [code]0[/code]. + Initial scale applied to each particle. + Each particle's scale will vary along this [CurveTexture]. + Scale randomness ratio. Default value: [code]0[/code]. + Each particle's initial direction range from [code]+spread[/code] to [code]-spread[/code] degrees. Default value: [code]45[/code]. + Tangential acceleration applied to each particle. Tangential acceleration is perpendicular to the particle's velocity. + Each particle's tangential acceleration will vary along this [CurveTexture]. + Tangential acceleration randomness ratio. Default value: [code]0[/code]. + Trail particles' color will vary along this [GradientTexture]. + Emitter will emit [code]amount[/code] divided by [code]trail_divisor[/code] particles. The remaining particles will be used as trail(s). + Trail particles' size will vary along this [CurveTexture]. + Use with [method set_param], [method set_param_randomness], and [method set_param_texture] to set initial velocity properties. + Use with [method set_param], [method set_param_randomness], and [method set_param_texture] to set angular velocity properties. + Use with [method set_param], [method set_param_randomness], and [method set_param_texture] to set orbital_velocity properties. + Use with [method set_param], [method set_param_randomness], and [method set_param_texture] to set linear acceleration properties. + Use with [method set_param], [method set_param_randomness], and [method set_param_texture] to set radial acceleration properties. + Use with [method set_param], [method set_param_randomness], and [method set_param_texture] to set tangential acceleration properties. + Use with [method set_param], [method set_param_randomness], and [method set_param_texture] to set damping properties. + Use with [method set_param], [method set_param_randomness], and [method set_param_texture] to set angle properties. + Use with [method set_param], [method set_param_randomness], and [method set_param_texture] to set scale properties. + Use with [method set_param], [method set_param_randomness], and [method set_param_texture] to set hue_variation properties. + Use with [method set_param], [method set_param_randomness], and [method set_param_texture] to set animation speed properties. + Use with [method set_param], [method set_param_randomness], and [method set_param_texture] to set animation offset properties. + Use with [method set_flag] to set [member flag_align_y]. + Use with [method set_flag] to set [member flag_rotate_y] + All particles will be emitted from a single point. + Particles will be emitted in the volume of a sphere. + Particles will be emitted in the volume of a box.