new ViewToken(p_pixi_app, p_model, p_config, p_resources)
Parameters:
| Name | Type | Description | ||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
p_pixi_app |
Object | |||||||||||||||||||||
p_model |
ModelToken | |||||||||||||||||||||
p_config |
Object |
Properties
|
||||||||||||||||||||
p_resources |
Object |
- Source:
Extends
Members
-
border :Object
-
The border width and height of the board view.
Type:
- Object
- Inherited From:
- Overrides:
- Source:
-
gap :number
-
The vertical and horizontal gap between two tokens.
Type:
- number
- Inherited From:
- Overrides:
- Source:
-
image :string
-
The resource name of the image to be used as texture of the rectangle.
Type:
- string
- Inherited From:
- Overrides:
- Source:
-
model :ModelRectangle
-
The model to be visualized.
Type:
- Inherited From:
- Source:
-
sprite :PIXI.Sprite
-
The sprite object that visualizes the model.
Type:
- PIXI.Sprite
- Inherited From:
- Source:
Methods
-
addEventListener(p_event, f_listener)
-
Adds a listener to PixiJS events dispatched by
this.sprite.Parameters:
Name Type Description p_eventstring the name of the PixiJS event to be listened to f_listenerfunction the listener - Inherited From:
- Source:
- See:
-
render()
-
Renders the token.
- Overrides:
- Source: