MultiplayerMinesweeper/scripts/server/illegalAction.mjs

12 lines
244 B
JavaScript
Raw Normal View History

2022-06-22 01:51:09 +00:00
import {io} from "./io.mjs"
export class IllegalAction {
constructor(id, action){
this.action = action
this.id = id
this.sendIllegalAction();
}
sendIllegalAction() {
io.to(this.id).emit('illegalAction', this.action)
}
}