Send event and play animation with user frame
This commit is contained in:
parent
b51ce51847
commit
5a6415607d
12 changed files with 128 additions and 84 deletions
|
@ -2,6 +2,7 @@ export class Message {
|
|||
userId: string;
|
||||
roomId: string;
|
||||
name: string;
|
||||
frame: string;
|
||||
|
||||
constructor(data: any) {
|
||||
if (!data.userId || !data.roomId) {
|
||||
|
@ -10,13 +11,15 @@ export class Message {
|
|||
this.userId = data.userId;
|
||||
this.roomId = data.roomId;
|
||||
this.name = data.name;
|
||||
this.frame = data.frame;
|
||||
}
|
||||
|
||||
toJson() {
|
||||
return {
|
||||
userId: this.userId,
|
||||
roomId: this.roomId,
|
||||
name: this.name
|
||||
name: this.name,
|
||||
frame: this.frame
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue