dacha
    Preparing search index...

    Class PixiView

    Draws a pixi.js object that you create in code.

    actor.setComponent(
    new PixiView({
    createView: () => new Graphics().circle(0, 0, 50).fill(0xffffff),
    }),
    );

    Hierarchy (View Summary)

    Index
    actor?: Actor

    The actor that has this component. It is undefined until the component is added to an actor.

    createView?: () => ViewContainer

    Function to create a custom pixi.js view

    sortingLayer: string

    Sorting layer of the pixi view

    sortOffset: Point

    Center point of the pixi view

    • get view(): ViewContainer<any> | undefined

      The pixi.js view. It is available only after the actor with this component is added to a scene

      Returns ViewContainer<any> | undefined

    • Returns the component of the same class on the parent actor.

      Returns Component<object> | undefined

      The component, or undefined if the actor has no parent actor or the parent has no such component.