Options
All
  • Public
  • Public/Protected
  • All
Menu

小游戏框架

Index

References

Audio Namespaces

Other Namespaces

Other Enumerations

Physics Enumerations

Asset Classes

Audio Classes

Other Classes

Physics Classes

Render Classes

System Classes

Worker Classes

Audio Interfaces

Other Interfaces

Physics Interfaces

Render Interfaces

Other Type aliases

Physics Type aliases

Properties

Variables

Functions

References

Playable

Renames and exports PlayableClass

TimelineClipAsset

Re-exports TimelineClipAsset

Other Type aliases

EWorkerJobStatus

EWorkerJobStatus: "init" | "starting" | "running" | "suspended" | "destroying" | "destroyed" | "invalid"

EWorkerStatus

EWorkerStatus: "init" | "running" | "terminated" | "invalid"

Entity2D

Entity2D: internalEntity2D

Entity3D

Entity3D: internalEntity3D

TCompressTexture

TCompressTexture: "etc1" | "etc2" | "astc" | "pvrtc" | "s3tc"

压缩纹理类型。

TTextureSource

TTextureSource: ArrayBuffer | ArrayBufferView | IImage

可用于纹理的资源。

TouchInputEvent

TouchInputEvent: internalTouchInputEvent

Physics Type aliases

PhysicsDelegateHandler

PhysicsDelegateHandler<E>: (e: E) => void

Type parameters

  • E

    事件回调接收的参数类型。

Type declaration

    • (e: E): void
    • 物理Delegate注册的事件回调类型。

      Parameters

      • e: E

      Returns void

Properties

renderEnv

renderEnv: RenderEnv

Variables

Const AmbientMode

AmbientMode: typeof AmbientModeEnum = ...

Const BuildInTextures

BuildInTextures: { babyblue: Texture2D; babygreen: Texture2D; babyred: Texture2D; black: Texture2D; blue: Texture2D; bump: Texture2D; green: Texture2D; red: Texture2D; transparent: Texture2D; white: Texture2D; yellow: Texture2D } = ...

Type declaration

Let EnumUniformType

EnumUniformType: typeof EUniformType | undefined

Let EnumVertexFormat

EnumVertexFormat: typeof EVertexFormat | undefined

Const Environment

Environment: typeof EnvironmentEnum = ...

Const FogMode

FogMode: typeof FogModeEnum = ...

Const ForwardBaseUniformBlockDesc

ForwardBaseUniformBlockDesc: {} = ...

Type declaration

Const GroupPlatform

GroupPlatform: typeof GroupPlatformEnum = ...

Const HDR_PIXEL_FORMAT

HDR_PIXEL_FORMAT: ETextureFormat = ...

Image

Image: { IS: any }

Type declaration

  • IS: function
    • Parameters

      • obj: any

      Returns obj is IImage

KANATA_VERSION

KANATA_VERSION: "1.0.3"

Const Platform

Platform: typeof PlatformEnum = ...

Const TypeNames

TypeNames: { ActivationPlayableAsset: string; ActivationTrackAsset: string; Animation: string; AnimationClip: string; AnimationPlayableAsset: string; AnimationTrackAsset: string; Animator: string; AnimatorController: string; Atlas: string; AudioAttenuationNode: string; AudioBiquadFilterNode: string; AudioClip: string; AudioDistortion: string; AudioDistortionNode: string; AudioDuckNode: string; AudioEcho: string; AudioEchoNode: string; AudioHighPassFilter: string; AudioHighPassFilterNode: string; AudioListener: string; AudioListenerNode: string; AudioLowPassFilter: string; AudioLowPassFilterNode: string; AudioMixerAsset: string; AudioPannerNode: string; AudioPlayableAsset: string; AudioReceiveNode: string; AudioSendNode: string; AudioSource: string; AudioSourceNode: string; AudioTrackAsset: string; Avatar: string; AvatarMask: string; BitmapFont: string; Boolean: string; BooleanVector3: string; BoundBall: string; BoundBox: string; BoxCollider: string; Camera: string; Canvas2D: string; CapsuleCollider: string; CharacterController: string; Color: string; Component: string; Constant: string; ControlPlayableAsset: string; ControlTrackAsset: string; CullingMask: string; Curve: string; DirectionalLight: string; Effect: string; Entity: string; Font: string; Gradient: string; GradientColor: string; GroupTrackAsset: string; HermiteCurve: string; KeyboardInput: string; LODGroup: string; Layout: string; LineRenderer: string; Material: string; Mesh: string; MeshCollider: string; MeshRenderer: string; Number: string; Object: string; OneColor: string; OpenDataContainer: string; Particle: string; ParticleBoxShape: string; ParticleCircleShape: string; ParticleColorByLife: string; ParticleCommon: string; ParticleConeShape: string; ParticleEmitter: string; ParticleEmitterBurst: string; ParticleEmitterShape: string; ParticleHemiSphereShape: string; ParticleRenderer: string; ParticleRotationByLife: string; ParticleSizeByLife: string; ParticleSpeedByLife: string; ParticleSpeedLimitByLife: string; ParticleSphereShape: string; ParticleTextureSheetAnimation: string; PhysicMaterial: string; Playable: string; PlayableDirector: string; PointLight: string; PostProcess: string; Prefab: string; Quaternion: string; Raw: string; RawResourceCollection: string; Rect: string; RenderTexture: string; Renderable2D: string; Rigidbody: string; Scene: string; ScriptableAsset: string; Skeleton: string; SkinnedAnimationRenderer: string; SkinnedMeshRenderer: string; SphereCollider: string; SpotLight: string; SpriteFrame: string; StreamingLoadingComponent: string; String: string; Texture2D: string; TextureCube: string; TimelineClip: string; TouchInput: string; TrackAsset: string; TrailRenderer: string; Transform2D: string; Transform3D: string; TransformBase: string; Tutorial: string; TutorialPage: string; TutorialSection: string; TutorialWelcome: string; TwoColors: string; TwoConstants: string; TwoCurves: string; TwoGradients: string; UIAnchor: string; UIButton: string; UICamera: string; UICanvas: string; UIFrameAnimation: string; UIGraphic: string; UIGrid: string; UILabel: string; UILayer: string; UIMask: string; UIMesh: string; UIRichText: string; UIScrollView: string; UISprite: string; UITextInput: string; UIToggle: string; UIToggleGroup: string; UIWidget: string; Variant: string; Vector2: string; Vector3: string; Vector4: string } = ...

Type declaration

  • ActivationPlayableAsset: string
  • ActivationTrackAsset: string
  • Animation: string
  • AnimationClip: string
  • AnimationPlayableAsset: string
  • AnimationTrackAsset: string
  • Animator: string
  • AnimatorController: string
  • Atlas: string
  • AudioAttenuationNode: string
  • AudioBiquadFilterNode: string
  • AudioClip: string
  • AudioDistortion: string
  • AudioDistortionNode: string
  • AudioDuckNode: string
  • AudioEcho: string
  • AudioEchoNode: string
  • AudioHighPassFilter: string
  • AudioHighPassFilterNode: string
  • AudioListener: string
  • AudioListenerNode: string
  • AudioLowPassFilter: string
  • AudioLowPassFilterNode: string
  • AudioMixerAsset: string
  • AudioPannerNode: string
  • AudioPlayableAsset: string
  • AudioReceiveNode: string
  • AudioSendNode: string
  • AudioSource: string
  • AudioSourceNode: string
  • AudioTrackAsset: string
  • Avatar: string
  • AvatarMask: string
  • BitmapFont: string
  • Boolean: string
  • BooleanVector3: string
  • BoundBall: string
  • BoundBox: string
  • BoxCollider: string
  • Camera: string
  • Canvas2D: string
  • CapsuleCollider: string
  • CharacterController: string
  • Color: string
  • Component: string
  • Constant: string
  • ControlPlayableAsset: string
  • ControlTrackAsset: string
  • CullingMask: string
  • Curve: string
  • DirectionalLight: string
  • Effect: string
  • Entity: string
  • Font: string
  • Gradient: string
  • GradientColor: string
  • GroupTrackAsset: string
  • HermiteCurve: string
  • KeyboardInput: string
  • LODGroup: string
  • Layout: string
  • LineRenderer: string
  • Material: string
  • Mesh: string
  • MeshCollider: string
  • MeshRenderer: string
  • Number: string
  • Object: string
  • OneColor: string
  • OpenDataContainer: string
  • Particle: string
  • ParticleBoxShape: string
  • ParticleCircleShape: string
  • ParticleColorByLife: string
  • ParticleCommon: string
  • ParticleConeShape: string
  • ParticleEmitter: string
  • ParticleEmitterBurst: string
  • ParticleEmitterShape: string
  • ParticleHemiSphereShape: string
  • ParticleRenderer: string
  • ParticleRotationByLife: string
  • ParticleSizeByLife: string
  • ParticleSpeedByLife: string
  • ParticleSpeedLimitByLife: string
  • ParticleSphereShape: string
  • ParticleTextureSheetAnimation: string
  • PhysicMaterial: string
  • Playable: string
  • PlayableDirector: string
  • PointLight: string
  • PostProcess: string
  • Prefab: string
  • Quaternion: string
  • Raw: string
  • RawResourceCollection: string
  • Rect: string
  • RenderTexture: string
  • Renderable2D: string
  • Rigidbody: string
  • Scene: string
  • ScriptableAsset: string
  • Skeleton: string
  • SkinnedAnimationRenderer: string
  • SkinnedMeshRenderer: string
  • SphereCollider: string
  • SpotLight: string
  • SpriteFrame: string
  • StreamingLoadingComponent: string
  • String: string
  • Texture2D: string
  • TextureCube: string
  • TimelineClip: string
  • TouchInput: string
  • TrackAsset: string
  • TrailRenderer: string
  • Transform2D: string
  • Transform3D: string
  • TransformBase: string
  • Tutorial: string
  • TutorialPage: string
  • TutorialSection: string
  • TutorialWelcome: string
  • TwoColors: string
  • TwoConstants: string
  • TwoCurves: string
  • TwoGradients: string
  • UIAnchor: string
  • UIButton: string
  • UICamera: string
  • UICanvas: string
  • UIFrameAnimation: string
  • UIGraphic: string
  • UIGrid: string
  • UILabel: string
  • UILayer: string
  • UIMask: string
  • UIMesh: string
  • UIRichText: string
  • UIScrollView: string
  • UISprite: string
  • UITextInput: string
  • UIToggle: string
  • UIToggleGroup: string
  • UIWidget: string
  • Variant: string
  • Vector2: string
  • Vector3: string
  • Vector4: string

Const WrapMode

WrapMode: typeof WrapModeEnum = ...

Const adaptation

adaptation: Adaptation = ...

Const buildInVertexLayoutFactory3D

buildInVertexLayoutFactory3D: BuildInVertexLayoutFactory = ...

Const buildin2DVertexLayout

buildin2DVertexLayout: VertexLayout = ...

Let cache

cache: CacheManager

Let canvas

canvas: HTMLCanvasElement

Const crossContextDataBus

crossContextDataBus: ICrossContextDataBus = ...

Const decorators

decorators: { audioEffectComponentConfig: (options: IAudioEffectComponentConfig) => ClassDecorator; audioSideChainInterface: (options: ISideChainConfig) => PropertyDecorator; componentDimensionType: (dimensionType: EComponentDimensionType) => (classCtor: Function) => void; context: (aliasTable: {}) => (classCtor: SerializableCtor) => void; property: { array: any; enum: any; multi: any }; serialize: (typeName: string, isValueType?: boolean) => ClassDecorator; snapshotParameter: (options: ISnapshotParamConfig) => PropertyDecorator; trackAssetConfig: (__namedParameters: ITrackConfig) => ClassDecorator; writable: (value: boolean) => (target: any, propertyKey: string, descriptor: PropertyDescriptor) => void; CreateAssetMenu: any; Criterion: any; CustomBuildComponent: any; CustomComponentInspector: any; CustomPropertyInspector: any; EditorWindow: any; InsepctorName: any; Inspector: any; PropInspector: any; SerializedData: any; UseSerializedData: any } = ...

Type declaration

  • audioEffectComponentConfig: (options: IAudioEffectComponentConfig) => ClassDecorator
      • (options: IAudioEffectComponentConfig): ClassDecorator
      • Parameters

        • options: IAudioEffectComponentConfig

        Returns ClassDecorator

  • audioSideChainInterface: (options: ISideChainConfig) => PropertyDecorator
      • (options: ISideChainConfig): PropertyDecorator
      • Parameters

        • options: ISideChainConfig

        Returns PropertyDecorator

  • componentDimensionType: (dimensionType: EComponentDimensionType) => (classCtor: Function) => void
      • (dimensionType: EComponentDimensionType): (classCtor: Function) => void
      • Parameters

        • dimensionType: EComponentDimensionType

        Returns (classCtor: Function) => void

          • (classCtor: Function): void
          • Parameters

            • classCtor: Function

            Returns void

  • context: (aliasTable: {}) => (classCtor: SerializableCtor) => void
      • (aliasTable: {}): (classCtor: SerializableCtor) => void
      • Parameters

        • aliasTable: {}
          • [key: string]: string

        Returns (classCtor: SerializableCtor) => void

          • (classCtor: SerializableCtor): void
          • Parameters

            • classCtor: SerializableCtor

            Returns void

  • property: { array: any; enum: any; multi: any }
      • (config: IPropertyConfig): PropertyDecorator & ParameterDecorator
      • Parameters

        • config: IPropertyConfig

        Returns PropertyDecorator & ParameterDecorator

    • array: function
      • array(index: number, config: IPropertyConfig & { type: string }): PropertyDecorator & ParameterDecorator
      • Parameters

        • index: number
        • config: IPropertyConfig & { type: string }

        Returns PropertyDecorator & ParameterDecorator

    • enum: function
      • enum(config: IPropertyEnumConfig): PropertyDecorator & ParameterDecorator
      • Parameters

        • config: IPropertyEnumConfig

        Returns PropertyDecorator & ParameterDecorator

    • multi: function
      • multi(config: IPropertyMultiConfig): PropertyDecorator & ParameterDecorator
      • Parameters

        • config: IPropertyMultiConfig

        Returns PropertyDecorator & ParameterDecorator

  • serialize: (typeName: string, isValueType?: boolean) => ClassDecorator
      • (typeName: string, isValueType?: boolean): ClassDecorator
      • Parameters

        • typeName: string
        • isValueType: boolean = false

        Returns ClassDecorator

  • snapshotParameter: (options: ISnapshotParamConfig) => PropertyDecorator
      • (options: ISnapshotParamConfig): PropertyDecorator
      • Parameters

        • options: ISnapshotParamConfig

        Returns PropertyDecorator

  • trackAssetConfig: (__namedParameters: ITrackConfig) => ClassDecorator
      • (__namedParameters: ITrackConfig): ClassDecorator
      • Parameters

        • __namedParameters: ITrackConfig

        Returns ClassDecorator

  • writable: (value: boolean) => (target: any, propertyKey: string, descriptor: PropertyDescriptor) => void
      • (value: boolean): (target: any, propertyKey: string, descriptor: PropertyDescriptor) => void
      • Parameters

        • value: boolean

        Returns (target: any, propertyKey: string, descriptor: PropertyDescriptor) => void

          • (target: any, propertyKey: string, descriptor: PropertyDescriptor): void
          • Parameters

            • target: any
            • propertyKey: string
            • descriptor: PropertyDescriptor

            Returns void

  • CreateAssetMenu: function
    • CreateAssetMenu(fileName?: string, menuName?: string, order?: number): ClassDecorator
    • ceated by janzen
      主要是给工具用的decorators。
      虽然是给工具用的,实际上是调用的是工具的代码。在真机上是空实现。
      但是因为要写在用户的scripts里面,用户的脚本需要调用这个接口,所以要保证真机也能运行,这个接口就要通过engine来暴露,只不过在真机是空实现。

      Parameters

      • fileName: string = "New File"
      • menuName: string = "assetMenu"
      • order: number = 999

      Returns ClassDecorator

  • Criterion: function
    • Criterion(criterionName?: string): ClassDecorator
    • 给tutorial检查器用的

      Parameters

      • criterionName: string = 'DemoCriterion'

      Returns ClassDecorator

  • CustomBuildComponent: function
    • CustomBuildComponent(typeName: string): ClassDecorator
    • Parameters

      • typeName: string

      Returns ClassDecorator

  • CustomComponentInspector: function
    • CustomComponentInspector(typeName: string): ClassDecorator
    • Parameters

      • typeName: string

      Returns ClassDecorator

  • CustomPropertyInspector: function
    • CustomPropertyInspector(typeName: string): ClassDecorator
    • Parameters

      • typeName: string

      Returns ClassDecorator

  • EditorWindow: function
    • EditorWindow(name: string, windowLabel: string): ClassDecorator
    • Parameters

      • name: string
      • windowLabel: string

      Returns ClassDecorator

  • InsepctorName: function
    • InsepctorName(typeName: string): (classCtor: any) => void
    • Parameters

      • typeName: string

      Returns (classCtor: any) => void

        • (classCtor: any): void
        • Parameters

          • classCtor: any

          Returns void

  • Inspector: function
    • Inspector(typeName: string): ClassDecorator
    • Parameters

      • typeName: string

      Returns ClassDecorator

  • PropInspector: function
    • PropInspector(name: string): ClassDecorator
    • 在scriptComponent 的property上面标示这是一个使用特定名字的自定义vue的标记

      Parameters

      • name: string

        标示使用的自定义vue的name

      Returns ClassDecorator

  • SerializedData: function
    • SerializedData(typeName: string): ClassDecorator
    • Parameters

      • typeName: string

      Returns ClassDecorator

  • UseSerializedData: function
    • UseSerializedData(typeName: string): ClassDecorator
    • Parameters

      • typeName: string

      Returns ClassDecorator

Const device

device: Device = ...

Let game

game: Game

Let gctx

gctx: typeof InternalGctx | undefined

Let host

host: string = ""

Let lanDebugHost

lanDebugHost: { ip: string; port: number } | undefined

Let loader

loader: Loader = ...

Const ppEffectMap

ppEffectMap: { 0: string; 1: string; 2: string; 3: string; 4: string } = ...

Type declaration

  • 0: string
  • 1: string
  • 2: string
  • 3: string
  • 4: string

Let renderer

renderer: RenderSystem

Const settings

settings: Settings = ...

Let timer

timer: Timer

Const version

version: string = ...

Const workerVersion

workerVersion: "1.1" = "1.1"

Functions

Serialize

  • Serialize(target: any | any, context?: {}, targetIsResource?: boolean): ISerializedObject | ISerializedObject["data"]
  • export

    Parameters

    • target: any | any
    • Optional context: {}
      • [key: string]: any
    • Optional targetIsResource: boolean

    Returns ISerializedObject | ISerializedObject["data"]

Const createNativeSUMap

  • createNativeSUMap(): INativeMap<string>
  • Returns INativeMap<string>

Const createNativeULUMap

  • createNativeULUMap(): ILongIntNativeMap
  • Returns ILongIntNativeMap

Const createNativeUUMap

  • createNativeUUMap(): INativeMap<number>
  • Returns INativeMap<number>

executeInAllMode

  • executeInAllMode(): ClassDecorator
  • Returns ClassDecorator

executeInEditMode

  • executeInEditMode(): ClassDecorator
  • Returns ClassDecorator

executeInGameMode

  • executeInGameMode(): ClassDecorator
  • Returns ClassDecorator

getGlobalFloat

  • getGlobalFloat(key: string): number | undefined
  • Parameters

    • key: string

    Returns number | undefined

getGlobalMatrix

  • Parameters

    • key: string

    Returns Matrix3 | Matrix4 | undefined

getGlobalTexture

  • getGlobalTexture(key: string): Texture | undefined
  • Parameters

    • key: string

    Returns Texture | undefined

getGlobalVector

  • Parameters

    • key: string

    Returns Vector2 | Vector3 | Vector4 | undefined

init

  • init(): void
  • deprecated

    Returns void

setGlobalFloat

  • setGlobalFloat(key: string, value: number): void
  • Parameters

    • key: string
    • value: number

    Returns void

setGlobalMatrix

  • Parameters

    Returns void

setGlobalTexture

  • setGlobalTexture(key: string, value: Texture): void
  • Parameters

    • key: string
    • value: Texture

    Returns void

setGlobalVector

  • Parameters

    Returns void

Generated using TypeDoc