Projektmanagement-Game/Webservice/Player.js
2021-06-18 13:27:53 +02:00

13 lines
216 B
JavaScript

class Player {
constructor(name) {
this.name = name;
this.position = 0;
this.isAlive = true;
}
move_by(amount) {
this.position += amount;
}
}
module.exports = Player;