fixt button and other misc shit

This commit is contained in:
Mashy
2019-03-15 20:39:18 +10:00
parent 56e4c22e05
commit b83c824795
3 changed files with 8 additions and 6 deletions
+5 -3
View File
@@ -44,8 +44,10 @@ class StatSheet extends Phaser.Scene {
updateData(parent, key, data) {
if (key === 'cryps') {
const cryp = data.find(c => c.id === this.cryp.id);
if (key === 'player') {
console.log('grep');
console.log(data);
const cryp = data.cryps.find(c => c.id === this.cryp.id);
this.scene.restart(cryp);
}
}
@@ -83,7 +85,6 @@ class StatSheet extends Phaser.Scene {
];
CRYP_STATS.forEach(crypStat);
this.add.text(X + WIDTH * 0.175, Y, 'Skills', TEXT.HEADER);
const knownSkill = (skill, i) => {
const SKILL_X = X + WIDTH * 0.4 + WIDTH * 0.125 * i;
const SKILL_Y = Y + HEIGHT * 0.15;
@@ -126,6 +127,7 @@ class StatSheet extends Phaser.Scene {
}
return true;
});
return this;
}
displaySkillText(x, y, description, pointer) {