@galacean/engine-core 0.0.0-experimental-0.9-plus.8 → 0.0.0-experimental-double11.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/main.js +15851 -13975
- package/dist/main.js.map +1 -1
- package/dist/miniprogram.js +15851 -13975
- package/dist/module.js +15837 -13971
- package/dist/module.js.map +1 -1
- package/package.json +3 -3
- package/types/2d/atlas/SpriteAtlas.d.ts +2 -6
- package/types/2d/enums/SpriteDirtyFlag.d.ts +13 -0
- package/types/2d/enums/SpriteDrawMode.d.ts +4 -2
- package/types/2d/index.d.ts +1 -0
- package/types/2d/sprite/Sprite.d.ts +5 -2
- package/types/2d/sprite/SpriteMask.d.ts +0 -11
- package/types/2d/sprite/SpriteRenderer.d.ts +15 -11
- package/types/2d/text/Font.d.ts +2 -7
- package/types/2d/text/TextRenderer.d.ts +0 -11
- package/types/2d/text/index.d.ts +1 -0
- package/types/Camera.d.ts +27 -8
- package/types/Component.d.ts +0 -8
- package/types/ComponentsDependencies.d.ts +17 -9
- package/types/ComponentsManager.d.ts +3 -2
- package/types/DisorderedArray.d.ts +4 -3
- package/types/Engine.d.ts +35 -43
- package/types/Entity.d.ts +2 -2
- package/types/ListenerUpdateFlag.d.ts +12 -0
- package/types/RenderPipeline/Basic2DBatcher.d.ts +6 -7
- package/types/RenderPipeline/BasicRenderPipeline.d.ts +8 -6
- package/types/RenderPipeline/PipelinePass.d.ts +16 -0
- package/types/RenderPipeline/RenderElement.d.ts +8 -8
- package/types/RenderPipeline/RenderPass.d.ts +1 -1
- package/types/RenderPipeline/RenderQueue.d.ts +3 -5
- package/types/RenderPipeline/SpriteMaskBatcher.d.ts +4 -3
- package/types/Renderer.d.ts +3 -12
- package/types/Scene.d.ts +0 -1
- package/types/Script.d.ts +18 -15
- package/types/Transform.d.ts +10 -12
- package/types/Utils.d.ts +28 -0
- package/types/animation/AnimationClip.d.ts +2 -1
- package/types/animation/Animator.d.ts +7 -4
- package/types/animation/AnimatorStateTransition.d.ts +12 -0
- package/types/animation/AnimatorTransitionBase.d.ts +10 -0
- package/types/animation/animationCurve/AnimationFloatArrayCurve.d.ts +0 -1
- package/types/animation/animationCurve/AnimationRectCurve.d.ts +8 -0
- package/types/animation/animationCurve/AnimationRefCurve.d.ts +8 -0
- package/types/animation/enums/LayerState.d.ts +3 -1
- package/types/animation/enums/StateMachineState.d.ts +13 -0
- package/types/animation/index.d.ts +0 -4
- package/types/animation/internal/AnimatorPlayableObject.d.ts +23 -0
- package/types/animation/internal/CrossCurveData.d.ts +1 -0
- package/types/animation/internal/animationCurveOwner/Assembler/BlendShapeWeightsAnimationCurveOwnerAssembler.d.ts +1 -0
- package/types/animation/internal/animationCurveOwner/Assembler/IAnimationCurveOwnerAssembler.d.ts +1 -0
- package/types/animation/internal/animationCurveOwner/Assembler/PositionAnimationCurveOwnerAssembler.d.ts +1 -0
- package/types/animation/internal/animationCurveOwner/Assembler/RotationAnimationCurveOwnerAssembler.d.ts +1 -0
- package/types/animation/internal/animationCurveOwner/Assembler/ScaleAnimationCurveOwnerAssembler.d.ts +1 -0
- package/types/animation/internal/animationCurveOwner/Assembler/UniversalAnimationCurveOwnerAssembler.d.ts +1 -0
- package/types/asset/AssetType.d.ts +16 -16
- package/types/asset/LoadItem.d.ts +16 -9
- package/types/asset/ResourceManager.d.ts +17 -9
- package/types/asset/request.d.ts +7 -3
- package/types/base/Constant.d.ts +2 -1
- package/types/base/EngineObject.d.ts +1 -0
- package/types/base/EventDispatcher.d.ts +2 -15
- package/types/base/Time.d.ts +25 -24
- package/types/base/index.d.ts +0 -2
- package/types/enums/DepthTextureMode.d.ts +7 -0
- package/types/env-probe/CubeProbe.d.ts +0 -7
- package/types/env-probe/Probe.d.ts +0 -6
- package/types/fog/EXP2Fog.d.ts +15 -0
- package/types/fog/Fog.d.ts +14 -0
- package/types/fog/LinearFog.d.ts +22 -0
- package/types/fog/index.d.ts +3 -0
- package/types/graphic/Buffer.d.ts +5 -12
- package/types/graphic/Mesh.d.ts +5 -16
- package/types/graphic/Primitive.d.ts +1 -0
- package/types/graphic/SubPrimitive.d.ts +9 -0
- package/types/index.d.ts +8 -7
- package/types/input/InputManager.d.ts +1 -1
- package/types/input/interface/IInput.d.ts +1 -1
- package/types/lighting/AmbientLight.d.ts +4 -1
- package/types/lighting/DirectLight.d.ts +0 -1
- package/types/lighting/Light.d.ts +0 -1
- package/types/lighting/LightManager.d.ts +1 -0
- package/types/lighting/SpotLight.d.ts +0 -1
- package/types/material/BaseMaterial.d.ts +8 -10
- package/types/material/BlinnPhongMaterial.d.ts +0 -3
- package/types/material/Material.d.ts +3 -6
- package/types/material/PBRMaterial.d.ts +1 -1
- package/types/material/PBRSpecularMaterial.d.ts +1 -1
- package/types/material/UnlitMaterial.d.ts +1 -1
- package/types/mesh/BlendShape.d.ts +1 -1
- package/types/mesh/BlendShapeFrame.d.ts +28 -6
- package/types/mesh/MeshRenderer.d.ts +1 -11
- package/types/mesh/ModelMesh.d.ts +5 -5
- package/types/mesh/PrimitiveMesh.d.ts +4 -2
- package/types/mesh/SkinnedMeshRenderer.d.ts +0 -15
- package/types/particle/ParticleBufferUtils.d.ts +1 -0
- package/types/particle/ParticleGenerator.d.ts +72 -0
- package/types/particle/ParticleMaterial.d.ts +28 -0
- package/types/particle/ParticleRenderer.d.ts +2 -2
- package/types/particle/enums/ParticleCurveMode.d.ts +9 -0
- package/types/particle/enums/ParticleGradientMode.d.ts +9 -0
- package/types/particle/enums/ParticleRandomSubSeeds.d.ts +1 -0
- package/types/particle/enums/ParticleRenderMode.d.ts +17 -0
- package/types/particle/enums/ParticleScaleMode.d.ts +11 -0
- package/types/particle/enums/ParticleSimulationSpace.d.ts +9 -0
- package/types/particle/enums/ParticleStopMode.d.ts +6 -0
- package/types/particle/enums/attributes/BillboardParticleVertexAttribute.d.ts +1 -0
- package/types/particle/enums/attributes/MeshParticleVertexAttribute.d.ts +5 -0
- package/types/particle/enums/attributes/ParticleInstanceVertexAttribute.d.ts +1 -0
- package/types/particle/modules/Burst.d.ts +14 -0
- package/types/particle/modules/ColorOverLifetimeModule.d.ts +20 -0
- package/types/particle/modules/EmissionModule.d.ts +45 -0
- package/types/particle/modules/MainModule.d.ts +68 -0
- package/types/particle/modules/ParticleCompositeCurve.d.ts +56 -0
- package/types/particle/modules/ParticleCompositeGradient.d.ts +55 -0
- package/types/particle/modules/ParticleCurve.d.ts +56 -0
- package/types/particle/modules/ParticleGeneratorModule.d.ts +12 -0
- package/types/particle/modules/ParticleGradient.d.ts +94 -0
- package/types/particle/modules/RotationOverLifetimeModule.d.ts +34 -0
- package/types/particle/modules/SizeOverLifetimeModule.d.ts +34 -0
- package/types/particle/modules/TextureSheetAnimationModule.d.ts +42 -0
- package/types/particle/modules/VelocityOverLifetimeModule.d.ts +34 -0
- package/types/particle/modules/shape/BaseShape.d.ts +12 -0
- package/types/particle/modules/shape/BoxShape.d.ts +11 -0
- package/types/particle/modules/shape/CircleShape.d.ts +17 -0
- package/types/particle/modules/shape/ConeShape.d.ts +28 -0
- package/types/particle/modules/shape/HemisphereShape.d.ts +9 -0
- package/types/particle/modules/shape/ShapeUtils.d.ts +1 -0
- package/types/particle/modules/shape/SphereShape.d.ts +9 -0
- package/types/particle/modules/shape/enums/ParticleShapeArcMode.d.ts +9 -0
- package/types/particle/modules/shape/enums/ParticleShapeType.d.ts +15 -0
- package/types/particle/modules/shape/index.d.ts +6 -0
- package/types/physics/CharacterController.d.ts +0 -2
- package/types/physics/Collider.d.ts +3 -2
- package/types/physics/PhysicsManager.d.ts +5 -22
- package/types/physics/PhysicsScene.d.ts +6 -2
- package/types/physics/joint/HingeJoint.d.ts +2 -2
- package/types/physics/joint/Joint.d.ts +3 -4
- package/types/physics/joint/SpringJoint.d.ts +3 -2
- package/types/physics/shape/BoxColliderShape.d.ts +2 -0
- package/types/physics/shape/CapsuleColliderShape.d.ts +2 -0
- package/types/physics/shape/ColliderShape.d.ts +4 -1
- package/types/physics/shape/PlaneColliderShape.d.ts +1 -0
- package/types/physics/shape/SphereColliderShape.d.ts +2 -0
- package/types/renderingHardwareInterface/index.d.ts +1 -0
- package/types/shader/Shader.d.ts +32 -23
- package/types/shader/ShaderData.d.ts +24 -24
- package/types/shader/ShaderMacro.d.ts +16 -0
- package/types/shader/ShaderPass.d.ts +9 -2
- package/types/shader/ShaderProperty.d.ts +7 -0
- package/types/shader/enums/RenderStateElementKey.d.ts +58 -0
- package/types/shader/index.d.ts +5 -1
- package/types/shaderlib/particle/index.d.ts +14 -0
- package/types/shadow/CascadedShadowCasterPass.d.ts +0 -1
- package/types/shadow/enum/ShadowMode.d.ts +13 -0
- package/types/sky/SkyBoxMaterial.d.ts +27 -9
- package/types/sky/index.d.ts +1 -0
- package/types/texture/RenderTarget.d.ts +2 -6
- package/types/texture/Texture.d.ts +8 -6
- package/types/texture/Texture2D.d.ts +3 -1
- package/types/texture/index.d.ts +1 -0
- package/types/trail/TrailRenderer.d.ts +0 -5
- package/types/SafeLoopArray.d.ts +0 -37
- /package/types/{animation/internal/animationCurveOwner/assembler/BlendShapeWeightsAnimationCurveOwnerAssembler.d.ts → RenderPipeline/CullingResults.d.ts} +0 -0
- /package/types/{animation/internal/animationCurveOwner/assembler/IAnimationCurveOwnerAssembler.d.ts → RenderPipeline/DepthOnlyPass.d.ts} +0 -0
- /package/types/{animation/internal/animationCurveOwner/assembler/PositionAnimationCurveOwnerAssembler.d.ts → RenderPipeline/PipelineUtils.d.ts} +0 -0
- /package/types/animation/{internal/animationCurveOwner/assembler/RotationAnimationCurveOwnerAssembler.d.ts → AnimatorStatePlayData.d.ts} +0 -0
- /package/types/animation/internal/{animationCurveOwner/assembler/ScaleAnimationCurveOwnerAssembler.d.ts → AnimatorStateInfo.d.ts} +0 -0
- /package/types/animation/internal/{animationCurveOwner/assembler/UniversalAnimationCurveOwnerAssembler.d.ts → AnimatorStateMachineData.d.ts} +0 -0
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import { Color } from "@galacean/engine-math";
|
|
2
|
+
/**
|
|
3
|
+
* Particle gradient.
|
|
4
|
+
*/
|
|
5
|
+
export declare class ParticleGradient {
|
|
6
|
+
private _colorKeys;
|
|
7
|
+
private _alphaKeys;
|
|
8
|
+
private _colorTypeArray;
|
|
9
|
+
private _alphaTypeArray;
|
|
10
|
+
private _colorTypeArrayDirty;
|
|
11
|
+
private _alphaTypeArrayDirty;
|
|
12
|
+
/**
|
|
13
|
+
* The color keys of the gradient.
|
|
14
|
+
*/
|
|
15
|
+
get colorKeys(): ReadonlyArray<GradientColorKey>;
|
|
16
|
+
/**
|
|
17
|
+
* The alpha keys of the gradient.
|
|
18
|
+
*/
|
|
19
|
+
get alphaKeys(): ReadonlyArray<GradientAlphaKey>;
|
|
20
|
+
/**
|
|
21
|
+
* Create a new particle gradient.
|
|
22
|
+
* @param colorKeys - The color keys of the gradient
|
|
23
|
+
* @param alphaKeys - The alpha keys of the gradient
|
|
24
|
+
*/
|
|
25
|
+
constructor(colorKeys?: GradientColorKey[], alphaKeys?: GradientAlphaKey[]);
|
|
26
|
+
/**
|
|
27
|
+
* Add a color key to the gradient.
|
|
28
|
+
* @param key - The key
|
|
29
|
+
*/
|
|
30
|
+
addColorKey(key: GradientColorKey): void;
|
|
31
|
+
/**
|
|
32
|
+
* Add a color key to the gradient.
|
|
33
|
+
* @param time - The key time
|
|
34
|
+
* @param color - The key color
|
|
35
|
+
*/
|
|
36
|
+
addColorKey(time: number, color: Color): void;
|
|
37
|
+
/**
|
|
38
|
+
* Add an alpha key to the gradient.
|
|
39
|
+
* @param key - The key
|
|
40
|
+
*/
|
|
41
|
+
addAlphaKey(key: GradientAlphaKey): void;
|
|
42
|
+
/**
|
|
43
|
+
* Add an alpha key to the gradient.
|
|
44
|
+
* @param time - The key time
|
|
45
|
+
* @param alpha - The key alpha
|
|
46
|
+
*/
|
|
47
|
+
addAlphaKey(time: number, alpha: number): void;
|
|
48
|
+
/**
|
|
49
|
+
* Remove a color key from the gradient.
|
|
50
|
+
* @param index - The remove color key index
|
|
51
|
+
*/
|
|
52
|
+
removeColorKey(index: number): void;
|
|
53
|
+
/**
|
|
54
|
+
* Remove an alpha key from the gradient.
|
|
55
|
+
* @param index - The remove alpha key index
|
|
56
|
+
*/
|
|
57
|
+
removeAlphaKey(index: number): void;
|
|
58
|
+
/**
|
|
59
|
+
* Set the keys of the gradient.
|
|
60
|
+
* @param colorKeys - The color keys
|
|
61
|
+
* @param alphaKeys - The alpha keys
|
|
62
|
+
*/
|
|
63
|
+
setKeys(colorKeys: GradientColorKey[], alphaKeys: GradientAlphaKey[]): void;
|
|
64
|
+
private _addKey;
|
|
65
|
+
private _removeKey;
|
|
66
|
+
}
|
|
67
|
+
/**
|
|
68
|
+
* The color key of the particle gradient.
|
|
69
|
+
*/
|
|
70
|
+
export declare class GradientColorKey {
|
|
71
|
+
/** The key time. */
|
|
72
|
+
time: number;
|
|
73
|
+
/** The key color. */
|
|
74
|
+
color: Color;
|
|
75
|
+
constructor(
|
|
76
|
+
/** The key time. */
|
|
77
|
+
time: number,
|
|
78
|
+
/** The key color. */
|
|
79
|
+
color: Color);
|
|
80
|
+
}
|
|
81
|
+
/**
|
|
82
|
+
* The alpha key of the particle gradient.
|
|
83
|
+
*/
|
|
84
|
+
export declare class GradientAlphaKey {
|
|
85
|
+
/** The key time. */
|
|
86
|
+
time: number;
|
|
87
|
+
/** The key alpha. */
|
|
88
|
+
alpha: number;
|
|
89
|
+
constructor(
|
|
90
|
+
/** The key time. */
|
|
91
|
+
time: number,
|
|
92
|
+
/** The key alpha. */
|
|
93
|
+
alpha: number);
|
|
94
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { ShaderMacro } from "../../shader/ShaderMacro";
|
|
2
|
+
import { ShaderProperty } from "../../shader/ShaderProperty";
|
|
3
|
+
import { ParticleCompositeCurve } from "./ParticleCompositeCurve";
|
|
4
|
+
import { ParticleGeneratorModule } from "./ParticleGeneratorModule";
|
|
5
|
+
/**
|
|
6
|
+
* Rotate particles throughout their lifetime.
|
|
7
|
+
*/
|
|
8
|
+
export declare class RotationOverLifetimeModule extends ParticleGeneratorModule {
|
|
9
|
+
static readonly _constantModeMacro: ShaderMacro;
|
|
10
|
+
static readonly _curveModeMacro: ShaderMacro;
|
|
11
|
+
static readonly _isSeparateMacro: ShaderMacro;
|
|
12
|
+
static readonly _isRandomTwoMacro: ShaderMacro;
|
|
13
|
+
static readonly _minConstantProperty: ShaderProperty;
|
|
14
|
+
static readonly _minCurveXProperty: ShaderProperty;
|
|
15
|
+
static readonly _minCurveYProperty: ShaderProperty;
|
|
16
|
+
static readonly _minCurveZProperty: ShaderProperty;
|
|
17
|
+
static readonly _maxConstantProperty: ShaderProperty;
|
|
18
|
+
static readonly _maxCurveXProperty: ShaderProperty;
|
|
19
|
+
static readonly _maxCurveYProperty: ShaderProperty;
|
|
20
|
+
static readonly _maxCurveZProperty: ShaderProperty;
|
|
21
|
+
/** Specifies whether the rotation is separate on each axis, when disabled only z axis is used. */
|
|
22
|
+
separateAxes: boolean;
|
|
23
|
+
/** Rotation over lifetime for z axis. */
|
|
24
|
+
rotationX: ParticleCompositeCurve;
|
|
25
|
+
/** Rotation over lifetime for z axis. */
|
|
26
|
+
rotationY: ParticleCompositeCurve;
|
|
27
|
+
/** Rotation over lifetime for z axis. */
|
|
28
|
+
rotationZ: ParticleCompositeCurve;
|
|
29
|
+
private _rotationMinConstant;
|
|
30
|
+
private _rotationMaxConstant;
|
|
31
|
+
private _enableSeparateMacro;
|
|
32
|
+
private _isCurveMacro;
|
|
33
|
+
private _isRandomTwoMacro;
|
|
34
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { ShaderMacro } from "../../shader/ShaderMacro";
|
|
2
|
+
import { ShaderProperty } from "../../shader/ShaderProperty";
|
|
3
|
+
import { ParticleCompositeCurve } from "./ParticleCompositeCurve";
|
|
4
|
+
import { ParticleGeneratorModule } from "./ParticleGeneratorModule";
|
|
5
|
+
/**
|
|
6
|
+
* Size over lifetime module.
|
|
7
|
+
*/
|
|
8
|
+
export declare class SizeOverLifetimeModule extends ParticleGeneratorModule {
|
|
9
|
+
static readonly _curveModeMacro: ShaderMacro;
|
|
10
|
+
static readonly _isSeparateMacro: ShaderMacro;
|
|
11
|
+
static readonly _isRandomTwoMacro: ShaderMacro;
|
|
12
|
+
static readonly _minCurveXProperty: ShaderProperty;
|
|
13
|
+
static readonly _minCurveYProperty: ShaderProperty;
|
|
14
|
+
static readonly _minCurveZProperty: ShaderProperty;
|
|
15
|
+
static readonly _maxCurveXProperty: ShaderProperty;
|
|
16
|
+
static readonly _maxCurveYProperty: ShaderProperty;
|
|
17
|
+
static readonly _maxCurveZProperty: ShaderProperty;
|
|
18
|
+
/** Specifies whether the Size is separate on each axis. */
|
|
19
|
+
separateAxes: boolean;
|
|
20
|
+
/** Size curve over lifetime for x axis. */
|
|
21
|
+
sizeX: ParticleCompositeCurve;
|
|
22
|
+
/** Size curve over lifetime for y axis. */
|
|
23
|
+
sizeY: ParticleCompositeCurve;
|
|
24
|
+
/** Size curve over lifetime for z axis. */
|
|
25
|
+
sizeZ: ParticleCompositeCurve;
|
|
26
|
+
private _enableSeparateMacro;
|
|
27
|
+
private _isCurveMacro;
|
|
28
|
+
private _isRandomTwoMacro;
|
|
29
|
+
/**
|
|
30
|
+
* Size curve over lifetime.
|
|
31
|
+
*/
|
|
32
|
+
get size(): ParticleCompositeCurve;
|
|
33
|
+
set size(value: ParticleCompositeCurve);
|
|
34
|
+
}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { Vector2 } from "@galacean/engine-math";
|
|
2
|
+
import { ParticleCompositeCurve } from "./ParticleCompositeCurve";
|
|
3
|
+
import { ParticleGeneratorModule } from "./ParticleGeneratorModule";
|
|
4
|
+
/**
|
|
5
|
+
* Texture sheet animation module.
|
|
6
|
+
*/
|
|
7
|
+
export declare class TextureSheetAnimationModule extends ParticleGeneratorModule {
|
|
8
|
+
private static readonly _frameCurveMacro;
|
|
9
|
+
private static readonly _frameRandomCurvesMacro;
|
|
10
|
+
private static readonly _cycleCountProperty;
|
|
11
|
+
private static readonly _tillingParamsProperty;
|
|
12
|
+
private static readonly _frameMinCurveProperty;
|
|
13
|
+
private static readonly _frameMaxCurveProperty;
|
|
14
|
+
/** Start frame of the texture sheet. */
|
|
15
|
+
readonly startFrame: ParticleCompositeCurve;
|
|
16
|
+
/** Frame over time curve of the texture sheet. */
|
|
17
|
+
readonly frameOverTime: ParticleCompositeCurve;
|
|
18
|
+
/** Texture sheet animation type. */
|
|
19
|
+
type: TextureSheetAnimationType;
|
|
20
|
+
/** Cycle count. */
|
|
21
|
+
cycleCount: number;
|
|
22
|
+
private _tiling;
|
|
23
|
+
private _textureSheetMacro;
|
|
24
|
+
/**
|
|
25
|
+
* Tiling of the texture sheet.
|
|
26
|
+
* */
|
|
27
|
+
get tiling(): Vector2;
|
|
28
|
+
set tiling(value: Vector2);
|
|
29
|
+
/**
|
|
30
|
+
* @inheritDoc
|
|
31
|
+
*/
|
|
32
|
+
cloneTo(dest: TextureSheetAnimationModule): void;
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* Texture sheet animation type.
|
|
36
|
+
*/
|
|
37
|
+
export declare enum TextureSheetAnimationType {
|
|
38
|
+
/** Animate over the whole texture sheet from left to right, top to bottom. */
|
|
39
|
+
WholeSheet = 0,
|
|
40
|
+
/** Animate a single row in the sheet from left to right. */
|
|
41
|
+
SingleRow = 1
|
|
42
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { ShaderMacro } from "../../shader";
|
|
2
|
+
import { ShaderProperty } from "../../shader/ShaderProperty";
|
|
3
|
+
import { ParticleSimulationSpace } from "../enums/ParticleSimulationSpace";
|
|
4
|
+
import { ParticleCompositeCurve } from "./ParticleCompositeCurve";
|
|
5
|
+
import { ParticleGeneratorModule } from "./ParticleGeneratorModule";
|
|
6
|
+
/**
|
|
7
|
+
* Velocity over lifetime module.
|
|
8
|
+
*/
|
|
9
|
+
export declare class VelocityOverLifetimeModule extends ParticleGeneratorModule {
|
|
10
|
+
static readonly _constantMacro: ShaderMacro;
|
|
11
|
+
static readonly _curveMacro: ShaderMacro;
|
|
12
|
+
static readonly _randomConstantMacro: ShaderMacro;
|
|
13
|
+
static readonly _randomCurveMacro: ShaderMacro;
|
|
14
|
+
static readonly _minConstantProperty: ShaderProperty;
|
|
15
|
+
static readonly _maxConstantProperty: ShaderProperty;
|
|
16
|
+
static readonly _minGradientXProperty: ShaderProperty;
|
|
17
|
+
static readonly _minGradientYProperty: ShaderProperty;
|
|
18
|
+
static readonly _minGradientZProperty: ShaderProperty;
|
|
19
|
+
static readonly _maxGradientXProperty: ShaderProperty;
|
|
20
|
+
static readonly _maxGradientYProperty: ShaderProperty;
|
|
21
|
+
static readonly _maxGradientZProperty: ShaderProperty;
|
|
22
|
+
static readonly _spaceProperty: ShaderProperty;
|
|
23
|
+
/** Velocity over lifetime for x axis. */
|
|
24
|
+
velocityX: ParticleCompositeCurve;
|
|
25
|
+
/** Velocity over lifetime for z axis. */
|
|
26
|
+
velocityY: ParticleCompositeCurve;
|
|
27
|
+
/** Velocity over lifetime for z axis. */
|
|
28
|
+
velocityZ: ParticleCompositeCurve;
|
|
29
|
+
/** Velocity space. */
|
|
30
|
+
space: ParticleSimulationSpace;
|
|
31
|
+
private _velocityMinConstant;
|
|
32
|
+
private _velocityMaxConstant;
|
|
33
|
+
private _velocityMacro;
|
|
34
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ParticleShapeType } from "./enums/ParticleShapeType";
|
|
2
|
+
/**
|
|
3
|
+
* Base class for all particle shapes.
|
|
4
|
+
*/
|
|
5
|
+
export declare abstract class BaseShape {
|
|
6
|
+
/** The type of shape to emit particles from. */
|
|
7
|
+
shapeType: ParticleShapeType;
|
|
8
|
+
/** Specifies whether the ShapeModule is enabled or disabled. */
|
|
9
|
+
enable: boolean;
|
|
10
|
+
/** Randomizes the starting direction of particles. */
|
|
11
|
+
randomDirectionAmount: number;
|
|
12
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Vector3 } from "@galacean/engine-math";
|
|
2
|
+
import { BaseShape } from "./BaseShape";
|
|
3
|
+
/**
|
|
4
|
+
* Particle shape that emits particles from a box.
|
|
5
|
+
*/
|
|
6
|
+
export declare class BoxShape extends BaseShape {
|
|
7
|
+
private static _tempVector30;
|
|
8
|
+
/** The size of the box. */
|
|
9
|
+
size: Vector3;
|
|
10
|
+
constructor();
|
|
11
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { BaseShape } from "./BaseShape";
|
|
2
|
+
import { ParticleShapeArcMode } from "./enums/ParticleShapeArcMode";
|
|
3
|
+
/**
|
|
4
|
+
* Particle shape that emits particles from a circle.
|
|
5
|
+
*/
|
|
6
|
+
export declare class CircleShape extends BaseShape {
|
|
7
|
+
private static _tempPositionPoint;
|
|
8
|
+
/** Radius of the shape to emit particles from. */
|
|
9
|
+
radius: number;
|
|
10
|
+
/** Angle of the circle arc to emit particles from. */
|
|
11
|
+
arc: number;
|
|
12
|
+
/** The mode to generate particles around the arc. */
|
|
13
|
+
arcMode: ParticleShapeArcMode;
|
|
14
|
+
/** The speed of complete 360 degree rotation. */
|
|
15
|
+
arcSpeed: number;
|
|
16
|
+
constructor();
|
|
17
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { BaseShape } from "./BaseShape";
|
|
2
|
+
/**
|
|
3
|
+
* Cone shape.
|
|
4
|
+
*/
|
|
5
|
+
export declare class ConeShape extends BaseShape {
|
|
6
|
+
private static _tempVector20;
|
|
7
|
+
private static _tempVector21;
|
|
8
|
+
private static _tempVector30;
|
|
9
|
+
private static _tempVector31;
|
|
10
|
+
/** Angle of the cone to emit particles from. */
|
|
11
|
+
angle: number;
|
|
12
|
+
/** Radius of the shape to emit particles from. */
|
|
13
|
+
radius: number;
|
|
14
|
+
/** Length of the cone to emit particles from. */
|
|
15
|
+
length: number;
|
|
16
|
+
/** Cone emitter type. */
|
|
17
|
+
emitType: ConeEmitType;
|
|
18
|
+
constructor();
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* Cone emitter type.
|
|
22
|
+
*/
|
|
23
|
+
export declare enum ConeEmitType {
|
|
24
|
+
/** Emit particles from the base of the cone. */
|
|
25
|
+
Base = 0,
|
|
26
|
+
/** Emit particles from the volume of the cone. */
|
|
27
|
+
Volume = 1
|
|
28
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The emission shape.
|
|
3
|
+
*/
|
|
4
|
+
export declare enum ParticleShapeType {
|
|
5
|
+
/** Emit from the volume of a box. */
|
|
6
|
+
Box = 0,
|
|
7
|
+
/** Emit from a circle. */
|
|
8
|
+
Circle = 1,
|
|
9
|
+
/** Emit from the base of a cone. */
|
|
10
|
+
Cone = 2,
|
|
11
|
+
/** Emit from a half-sphere. */
|
|
12
|
+
Hemisphere = 3,
|
|
13
|
+
/** Emit from a sphere. */
|
|
14
|
+
Sphere = 4
|
|
15
|
+
}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export { BoxShape } from "./BoxShape";
|
|
2
|
+
export { CircleShape } from "./CircleShape";
|
|
3
|
+
export { ConeShape, ConeEmitType } from "./ConeShape";
|
|
4
|
+
export { HemisphereShape } from "./HemisphereShape";
|
|
5
|
+
export { SphereShape } from "./SphereShape";
|
|
6
|
+
export { ParticleShapeArcMode } from "./enums/ParticleShapeArcMode";
|
|
@@ -41,12 +41,10 @@ export declare class CharacterController extends Collider {
|
|
|
41
41
|
/**
|
|
42
42
|
* Add collider shape on this controller.
|
|
43
43
|
* @param shape - Collider shape
|
|
44
|
-
* @override
|
|
45
44
|
*/
|
|
46
45
|
addShape(shape: ColliderShape): void;
|
|
47
46
|
/**
|
|
48
47
|
* Remove all shape attached.
|
|
49
|
-
* @override
|
|
50
48
|
*/
|
|
51
49
|
clearShapes(): void;
|
|
52
50
|
private _setUpDirection;
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import { BoolUpdateFlag } from "../BoolUpdateFlag";
|
|
2
2
|
import { Component } from "../Component";
|
|
3
3
|
import { ColliderShape } from "./shape/ColliderShape";
|
|
4
|
+
import { ICustomClone } from "../clone/ComponentCloner";
|
|
4
5
|
/**
|
|
5
6
|
* Base class for all colliders.
|
|
6
|
-
* @decorator `@dependentComponents(Transform)`
|
|
7
|
+
* @decorator `@dependentComponents(Transform, DependentMode.CheckOnly)`
|
|
7
8
|
*/
|
|
8
|
-
export declare class Collider extends Component {
|
|
9
|
+
export declare class Collider extends Component implements ICustomClone {
|
|
9
10
|
protected _updateFlag: BoolUpdateFlag;
|
|
10
11
|
protected _shapes: ColliderShape[];
|
|
11
12
|
/**
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { IPhysics } from "@galacean/engine-design";
|
|
2
1
|
import { Ray, Vector3 } from "@galacean/engine-math";
|
|
3
2
|
import { Engine } from "../Engine";
|
|
4
3
|
import { Layer } from "../Layer";
|
|
@@ -7,8 +6,10 @@ import { HitResult } from "./HitResult";
|
|
|
7
6
|
* A physics manager is a collection of colliders and constraints which can interact.
|
|
8
7
|
*/
|
|
9
8
|
export declare class PhysicsManager {
|
|
9
|
+
private static _collision;
|
|
10
10
|
private _engine;
|
|
11
11
|
private _restTime;
|
|
12
|
+
private _fixedTimeStep;
|
|
12
13
|
private _colliders;
|
|
13
14
|
private _gravity;
|
|
14
15
|
private _nativePhysicsManager;
|
|
@@ -19,33 +20,15 @@ export declare class PhysicsManager {
|
|
|
19
20
|
private _onTriggerEnter;
|
|
20
21
|
private _onTriggerExit;
|
|
21
22
|
private _onTriggerStay;
|
|
22
|
-
/** The fixed time step in seconds at which physics are performed. */
|
|
23
|
-
fixedTimeStep: number;
|
|
24
|
-
/**
|
|
25
|
-
* The max allowed time step in seconds one frame.
|
|
26
|
-
*
|
|
27
|
-
* @remarks
|
|
28
|
-
* When the frame rate is low or stutter occurs, the maximum execution time of physics will not exceed this value.
|
|
29
|
-
* So physics will slow down a bit when performance hitch occurs.
|
|
30
|
-
*/
|
|
31
|
-
maxAllowedTimeStep: number;
|
|
32
23
|
/**
|
|
33
24
|
* The gravity of physics scene.
|
|
34
25
|
*/
|
|
35
26
|
get gravity(): Vector3;
|
|
36
27
|
set gravity(value: Vector3);
|
|
37
|
-
/**
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
*/
|
|
41
|
-
get maxSumTimeStep(): number;
|
|
42
|
-
set maxSumTimeStep(value: number);
|
|
28
|
+
/** The fixed time step in seconds at which physics are performed. */
|
|
29
|
+
get fixedTimeStep(): number;
|
|
30
|
+
set fixedTimeStep(value: number);
|
|
43
31
|
constructor(engine: Engine);
|
|
44
|
-
/**
|
|
45
|
-
* initialize PhysicsManager.
|
|
46
|
-
* @param physics - Physics Engine
|
|
47
|
-
*/
|
|
48
|
-
initialize(physics: IPhysics): void;
|
|
49
32
|
/**
|
|
50
33
|
* Casts a ray through the Scene and returns the first hit.
|
|
51
34
|
* @param ray - The ray
|
|
@@ -9,6 +9,7 @@ export declare class PhysicsScene {
|
|
|
9
9
|
private static _collision;
|
|
10
10
|
private _scene;
|
|
11
11
|
private _restTime;
|
|
12
|
+
private _fixedTimeStep;
|
|
12
13
|
private _colliders;
|
|
13
14
|
private _gravity;
|
|
14
15
|
private _nativePhysicsScene;
|
|
@@ -18,13 +19,16 @@ export declare class PhysicsScene {
|
|
|
18
19
|
private _onTriggerEnter;
|
|
19
20
|
private _onTriggerExit;
|
|
20
21
|
private _onTriggerStay;
|
|
21
|
-
/** The fixed time step in seconds at which physics are performed. */
|
|
22
|
-
fixedTimeStep: number;
|
|
23
22
|
/**
|
|
24
23
|
* The gravity of physics scene.
|
|
25
24
|
*/
|
|
26
25
|
get gravity(): Vector3;
|
|
27
26
|
set gravity(value: Vector3);
|
|
27
|
+
/**
|
|
28
|
+
* The fixed time step in seconds at which physics are performed.
|
|
29
|
+
*/
|
|
30
|
+
get fixedTimeStep(): number;
|
|
31
|
+
set fixedTimeStep(value: number);
|
|
28
32
|
constructor(scene: Scene);
|
|
29
33
|
/**
|
|
30
34
|
* Casts a ray through the Scene and returns the first hit.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { Joint } from "./Joint";
|
|
2
1
|
import { Vector3 } from "@galacean/engine-math";
|
|
3
|
-
import {
|
|
2
|
+
import { Joint } from "./Joint";
|
|
4
3
|
import { JointLimits } from "./JointLimits";
|
|
4
|
+
import { JointMotor } from "./JointMotor";
|
|
5
5
|
/**
|
|
6
6
|
* A joint which behaves in a similar way to a hinge or axle.
|
|
7
7
|
*/
|
|
@@ -1,15 +1,14 @@
|
|
|
1
1
|
import { IJoint } from "@galacean/engine-design";
|
|
2
2
|
import { Vector3 } from "@galacean/engine-math";
|
|
3
3
|
import { Component } from "../../Component";
|
|
4
|
-
import { Collider } from "../Collider";
|
|
5
4
|
import { Entity } from "../../Entity";
|
|
5
|
+
import { Collider } from "../Collider";
|
|
6
6
|
/**
|
|
7
7
|
* A base class providing common functionality for joints.
|
|
8
|
-
* @decorator `@dependentComponents(Collider)`
|
|
8
|
+
* @decorator `@dependentComponents(Collider, DependentMode.CheckOnly)`
|
|
9
9
|
*/
|
|
10
10
|
export declare class Joint extends Component {
|
|
11
|
-
protected
|
|
12
|
-
protected _collider: JointCollider;
|
|
11
|
+
protected _connectedColliderInfo: JointCollider;
|
|
13
12
|
protected _nativeJoint: IJoint;
|
|
14
13
|
private _force;
|
|
15
14
|
private _torque;
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import { Joint } from "./Joint";
|
|
2
1
|
import { Vector3 } from "@galacean/engine-math";
|
|
2
|
+
import { ICustomClone } from "../../clone/ComponentCloner";
|
|
3
|
+
import { Joint } from "./Joint";
|
|
3
4
|
/**
|
|
4
5
|
* A joint that maintains an upper or lower bound (or both) on the distance between two points on different objects.
|
|
5
6
|
*/
|
|
6
|
-
export declare class SpringJoint extends Joint {
|
|
7
|
+
export declare class SpringJoint extends Joint implements ICustomClone {
|
|
7
8
|
private _minDistance;
|
|
8
9
|
private _maxDistance;
|
|
9
10
|
private _tolerance;
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
+
import { IClone } from "@galacean/engine-design";
|
|
1
2
|
import { PhysicsMaterial } from "../PhysicsMaterial";
|
|
2
3
|
import { Vector3 } from "@galacean/engine-math";
|
|
3
4
|
import { Collider } from "../Collider";
|
|
4
5
|
/**
|
|
5
6
|
* Abstract class for collider shapes.
|
|
6
7
|
*/
|
|
7
|
-
export declare abstract class ColliderShape {
|
|
8
|
+
export declare abstract class ColliderShape implements IClone {
|
|
8
9
|
private static _idGenerator;
|
|
9
10
|
protected _id: number;
|
|
10
11
|
protected _material: PhysicsMaterial;
|
|
@@ -46,6 +47,8 @@ export declare abstract class ColliderShape {
|
|
|
46
47
|
get isTrigger(): boolean;
|
|
47
48
|
set isTrigger(value: boolean);
|
|
48
49
|
protected constructor();
|
|
50
|
+
abstract clone(): ColliderShape;
|
|
51
|
+
cloneTo(target: ColliderShape): void;
|
|
49
52
|
private _setPosition;
|
|
50
53
|
private _setRotation;
|
|
51
54
|
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
export type { IHardwareRenderer } from "./IHardwareRenderer";
|
|
2
|
+
export type { IPlatformBuffer } from "./IPlatformBuffer";
|
|
2
3
|
export type { IPlatformRenderTarget } from "./IPlatformRenderTarget";
|
|
3
4
|
export type { IPlatformTexture } from "./IPlatformTexture";
|
|
4
5
|
export type { IPlatformTexture2D } from "./IPlatformTexture2D";
|