@spibo-studio/spibo-studio
Version:
Spibo Studio is an HTML Canvas Library for creating adventure games
24 lines (23 loc) • 749 B
TypeScript
import Character from './Character';
import Background from './Background';
import Boundaries from './Boundaries';
declare class Canvas {
background: Background | null;
mainCharacter: Character | null;
boundaries: Boundaries;
protected canvas: HTMLCanvasElement;
protected context: CanvasRenderingContext2D | null;
private _framerate;
private refreshInterval;
private refreshIntervalTime;
private keyboardInteractions;
constructor(width: number, height: number, boundaries?: Boundaries, framerate?: number);
reset(): void;
draw(): void;
refresh(): void;
get height(): number;
get width(): number;
set framerate(framerate: number);
get framerate(): number;
}
export default Canvas;