UNPKG

bp-prism-game

Version:
96 lines (95 loc) 1.83 kB
import { GameService } from './game.service'; /** * The Prism Blast service */ export declare class PrismBlastService { private gameService; private ctx; /** * The prism blasts */ private prismBlasts; /** * The prism blast Icons */ private prismBlastIcons; /** * The original prism blast Icons position */ private prismBlastIconsPosition; /** * The can fire */ private canFire; /** * Total Blasts */ private totalBlasts; /** * Blast Counter */ private blastCounter; /** * Blast Angle */ private blastAngle; /** * moves */ private moves; /** * The constructor * * @param gameService The GameService * @param ctx The ctx */ constructor(gameService: GameService, ctx: CanvasRenderingContext2D); /** * If the Prism Blast can be fired */ private canFirePrismBlast; /** * Remove used prism blasts */ private removePrismBlast; /** * Init the service with the listener */ init(): void; /** * Find any unused missiles */ private findUnusedPrismBlastIcons; /** * Add A new Prism Blast Icon */ addPrismBlast(): void; /** * Position the blast * @param event The event coordinates */ private positionBlast; /** * Animate * @param index The index of the blast */ private startAnimation; /** * Animate * @param index The index of the blast */ private stopAnimation; /** * Animate * @param now the current time */ animate(now?: number): void; /** * Launch a Blast */ private launchPrismBlast; /** * Stop the blast */ private defusePrismBlast; }