import { MeshHandle, gameCmd } from '../middle/babyengine'; import { Scene } from 'babylonjs'; import { PhysicsImpostor } from 'babylonjs'; export declare const dynamicX = 1048; export declare const dynamicY = 1048; /** if you want to add a shape, then you must implement this interface */ export interface Thing { } export declare class ThingCommon { scene: Scene; handle: MeshHandle; params: Object; impostorString: string; constructor(cmd: gameCmd, handle: MeshHandle, scene: Scene); standardMeshSetup(): void; /** if Ammo tells us a collision happened, this cleans up and notifies the parties */ onCollisionHelper(a: PhysicsImpostor, b: PhysicsImpostor): void; /** setup collider for a shape */ setupCollider(): void; /** dispose of a mesh (and its physics impostor) */ dispose(): void; /** create physics impostor for this shape */ createPhysicsImpostor(): void; /** dispose of the physics impostor belonging to a mesh */ disposeImpostor(): void; /** can't resize an impostor, so drop it and recreate */ recreatePhysicsImpostor(): void; showDebugImpostor(): void; setShapeMass(): void; } export declare class Cube extends ThingCommon implements Thing { constructor(cmd: gameCmd, handle: MeshHandle, scene: Scene); } export declare class Sphere extends ThingCommon implements Thing { constructor(cmd: gameCmd, handle: MeshHandle, scene: Scene); } export declare class Cylinder extends ThingCommon implements Thing { constructor(cmd: gameCmd, handle: MeshHandle, scene: Scene); } export declare class Cone extends ThingCommon implements Thing { constructor(cmd: gameCmd, handle: MeshHandle, scene: Scene); } export declare class Torus extends ThingCommon implements Thing { constructor(cmd: gameCmd, handle: MeshHandle, scene: Scene); } export declare class Point extends ThingCommon implements Thing { constructor(cmd: gameCmd, handle: MeshHandle, scene: Scene); } export declare class Capsule extends ThingCommon implements Thing { constructor(cmd: gameCmd, handle: MeshHandle, scene: Scene); } declare type printable = { char: number; color: string; }; export declare class VT52 extends ThingCommon implements Thing { ctx: CanvasRenderingContext2D; printBuffer: printable[]; displayCharBuffer: number[]; displayColorBuffer: string[]; cursorX: number; cursorY: number; vt52print: Function; vt52input: Function; inputBuffer: string; cursorSuppress: boolean; halfSeconds: number; cursorOn: boolean; constructor(cmd: gameCmd, handle: MeshHandle, scene: Scene); setCursor(x: number, y: number): void; cursorDaemon(): void; printDaemon(): void; print(text: string, color: string): void; drawScreen(): void; printChar(charCode: number, charColor: string): void; printCRLF(): void; input(data: object): void; } export declare class GRAPH extends ThingCommon implements Thing { ctx: CanvasRenderingContext2D; scaleX: number; scaleY: number; sX: number; sY: number; zeroX: number; zeroY: number; constructor(cmd: gameCmd, handle: MeshHandle, scene: Scene); /** figures out how to draw a nice grid */ drawGrid(x: number, y: number): void; /** writes text, perhaps slightly offset right and above, like grid markings */ textAt(text: string, x: number, y: number, offsetX?: number, offsetY?: number): void; /** x,y is start, rest is a JSON string of array of subsequent points */ drawLine(markerSymbol: string, x: number, y: number, restOfLine: string): void; drawCircle(point: [number, number], radius: number): void; drawRect(point1: [number, number], point2: [number, number]): void; localXY(point: [number, number]): [number, number]; localMoveTo(point: [number, number]): void; localLineTo(point: [number, number]): void; } export declare class CameraThing extends ThingCommon implements Thing { constructor(cmd: gameCmd, handle: MeshHandle, scene: Scene); } export declare class Floor extends ThingCommon implements Thing { constructor(cmd: gameCmd, handle: MeshHandle, scene: Scene); } export {};