Add basic multiplayer
This commit is contained in:
parent
0f0a1eaf67
commit
46a48e7c15
113 changed files with 1362 additions and 754 deletions
12
shared/src/objects/game-object.ts
Normal file
12
shared/src/objects/game-object.ts
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
import { CommandReceiver } from '../commands/command-receiver';
|
||||
import { Id } from '../transport/identity';
|
||||
|
||||
export abstract class GameObject extends CommandReceiver {
|
||||
public get type(): string {
|
||||
return (this as any).constructor.type;
|
||||
}
|
||||
|
||||
constructor(public readonly id: Id) {
|
||||
super();
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue