Attention: Here be dragons
This is the latest
(unstable) version of this documentation, which may document features
not available in or compatible with released stable versions of Godot.
Checking the stable version of the documentation...
GPUParticlesAttractorVectorField3D¶
Inherits: GPUParticlesAttractor3D < VisualInstance3D < Node3D < Node < Object
A box-shaped attractor with varying directions and strengths defined in it that influences particles from GPUParticles3D nodes.
描述¶
A box-shaped attractor with varying directions and strengths defined in it that influences particles from GPUParticles3D nodes.
Unlike GPUParticlesAttractorBox3D, GPUParticlesAttractorVectorField3D uses a texture to affect attraction strength within the box. This can be used to create complex attraction scenarios where particles travel in different directions depending on their location. This can be useful for weather effects such as sandstorms.
Particle attractors work in real-time and can be moved, rotated and scaled during gameplay. Unlike collision shapes, non-uniform scaling of attractors is also supported.
Note: Particle attractors only affect GPUParticles3D, not CPUParticles3D.
属性¶
|
||
Property Descriptions¶
Vector3 size = Vector3(2, 2, 2)
The size of the vector field box in 3D units.
Texture3D texture
The 3D texture to be used. Values are linearly interpolated between the texture's pixels.
Note: To get better performance, the 3D texture's resolution should reflect the size of the attractor. Since particle attraction is usually low-frequency data, the texture can be kept at a low resolution such as 64×64×64.