b20357c1ee
Taking advantage of the TypeScript Constructor Assignment too to reduce the amount of code!
13 lines
396 B
TypeScript
13 lines
396 B
TypeScript
import {Message} from "./Message";
|
|
import {PointInterface} from "./PointInterface";
|
|
|
|
export class Point implements PointInterface{
|
|
constructor(public x : number, public y : number, public direction : string = "none") {
|
|
}
|
|
}
|
|
|
|
export class MessageUserPosition {
|
|
constructor(public userId: string, public name: string, public character: string, public position: PointInterface) {
|
|
}
|
|
}
|