Implement Distance Merge Request
This commit is contained in:
parent
c907048c12
commit
881bb04eb0
3 changed files with 27 additions and 8 deletions
|
@ -27,10 +27,9 @@ export class Point implements PointInterface{
|
|||
export class MessageUserPosition extends Message{
|
||||
position: PointInterface;
|
||||
|
||||
constructor(message: string) {
|
||||
constructor(message: any) {
|
||||
super(message);
|
||||
let data = JSON.parse(message);
|
||||
this.position = new Point(data.position.x, data.position.y, data.position.direction);
|
||||
this.position = new Point(message.position.x, message.position.y, message.position.direction);
|
||||
}
|
||||
|
||||
toString() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue