Constructor
new hudComponent(game, player)
Create the hudComponent instance
Parameters:
Name | Type | Description |
---|---|---|
game |
SpaceInvaders | The main game instance. |
player |
Player | The player instance. |
Properties:
Name | Type | Description |
---|---|---|
game |
SpaceInvaders | The current game instance |
player |
Player | The current player |
domElement |
Object | The DOM element for this component on screen |
- Source:
Methods
update() → {boolean}
Update loop
- Source:
Returns:
- Type
- boolean