Ported server code to nodeJS
This commit is contained in:
@@ -141,7 +141,7 @@ export default {
|
||||
|
||||
this.player.targetAngle = Math.atan2(dy, dx)
|
||||
this.player.angle = this.player.targetAngle
|
||||
send({ message: this.player, type: 'update' })
|
||||
send({ player: this.player, type: 'update' })
|
||||
},
|
||||
updatePlayer (player) {
|
||||
player.x += this.settings.playerSpeed * Math.cos(player.angle)
|
||||
|
||||
Reference in New Issue
Block a user