25 lines
563 B
JavaScript
25 lines
563 B
JavaScript
const Phaser = require('phaser');
|
|
const { POSITIONS: { MENU_MAIN }, TEXT } = require('./constants');
|
|
|
|
const X = MENU_MAIN.x();
|
|
const Y = MENU_MAIN.y();
|
|
const WIDTH = MENU_MAIN.width();
|
|
const HEIGHT = MENU_MAIN.height();
|
|
|
|
class HomeNews extends Phaser.Scene {
|
|
constructor() {
|
|
super({ key: 'HomeNews' });
|
|
}
|
|
|
|
create() {
|
|
this.add.text(X, Y, 'News Scene', TEXT.HEADER);
|
|
this.add.text(X, Y + HEIGHT * 0.1, 'some other stuff here', TEXT.NORMAL);
|
|
}
|
|
|
|
cleanUp() {
|
|
this.scene.remove();
|
|
}
|
|
}
|
|
|
|
module.exports = HomeNews;
|