Merge branch 'master' of ssh://cryps.gg:40022/~/cryps
This commit is contained in:
commit
4f1bd34ca6
@ -26,7 +26,7 @@ const menuNavigationY = () => Math.floor(CANVAS_HEIGHT() * 0.7);
|
||||
|
||||
const menuMainWidth = () => Math.floor(CANVAS_WIDTH() * 0.4);
|
||||
const menuMainHeight = () => Math.floor(CANVAS_HEIGHT() * 0.5);
|
||||
const menuMainX = () => Math.floor(CANVAS_WIDTH() * 0.6);
|
||||
const menuMainX = () => Math.floor(CANVAS_WIDTH() * 0.65);
|
||||
const menuMainY = () => headerHeight();
|
||||
|
||||
const homeMainWidth = () => Math.floor(CANVAS_WIDTH() * 0.6);
|
||||
|
||||
@ -5,10 +5,10 @@ const { TEXT, COLOURS, POSITIONS: { CRYP_LIST } } = require('./constants');
|
||||
const genAvatar = require('./avatar');
|
||||
const { LineGroup, LineBox } = require('./elements/outline.rotate');
|
||||
|
||||
const ROW_HEIGHT = CRYP_LIST.height() * 0.2;
|
||||
const ROW_HEIGHT = CRYP_LIST.height() * 0.1;
|
||||
const ROW_WIDTH = CRYP_LIST.width();
|
||||
|
||||
const menuY = CRYP_LIST.height() * 1.6;
|
||||
const menuY = CRYP_LIST.height() * 0.8;
|
||||
|
||||
const KEY_MAP = [
|
||||
'keydown-ONE',
|
||||
|
||||
@ -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) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user