More code removal
This commit is contained in:
parent
5a3668a12e
commit
4e745f20f7
@ -14,14 +14,6 @@ export class Point implements PointInterface{
|
||||
this.y = y;
|
||||
this.direction = direction;
|
||||
}
|
||||
|
||||
toJson(){
|
||||
return {
|
||||
x : this.x,
|
||||
y: this.y,
|
||||
direction: this.direction
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
export class MessageUserPosition extends Message{
|
||||
@ -31,14 +23,4 @@ export class MessageUserPosition extends Message{
|
||||
super(message);
|
||||
this.position = new Point(message.position.x, message.position.y, message.position.direction);
|
||||
}
|
||||
|
||||
toString() {
|
||||
return JSON.stringify(
|
||||
Object.assign(
|
||||
super.toJson(),
|
||||
{
|
||||
position: this.position.toJson()
|
||||
})
|
||||
);
|
||||
}
|
||||
}
|
||||
|
@ -2,5 +2,4 @@ export interface PointInterface {
|
||||
x: number;
|
||||
y: number;
|
||||
direction: string;
|
||||
toJson() : object;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user