UNPKG

@natewilcox/zelda-server

Version:

Server application for zelda multiplayer game

20 lines (19 loc) 637 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.PatchStateComponent = void 0; class PatchStateComponent { constructor(scene) { this.scene = scene; } init(go) { this.player = go; console.log(`player ${this.player.id} will be patched.`); } update(dt, t) { this.player.playerState.x = this.player.x; this.player.playerState.y = this.player.y; //console.log(`patching player ${this.player.playerState.id} at ${this.player.playerState.x}, ${this.player.playerState.y}.`); } ; } exports.PatchStateComponent = PatchStateComponent;