@@ -4,7 +4,7 @@ export class MainMenu extends Scene
44{
55 background : GameObjects . Image ;
66 logo : GameObjects . Image ;
7- title : GameObjects . Text ;
7+ playB : GameObjects . Image ;
88
99 constructor ( )
1010 {
@@ -15,20 +15,17 @@ export class MainMenu extends Scene
1515 {
1616 this . background = this . add . image ( 512 , 384 , 'background' ) ;
1717
18- this . logo = this . add . image ( 512 , 300 , 'logo ' ) ;
18+ this . logo = this . add . image ( 512 , 300 , 'title ' ) ;
1919
20- this . title = this . add . text ( 512 , 460 , 'Play Game' , {
21- fontFamily : 'Arial Black' , fontSize : 38 , color : '#ffffff' ,
22- stroke : '#000000' , strokeThickness : 8 ,
23- align : 'center'
24- } ) . setOrigin ( 0.5 )
20+ this . playB = this . add . image ( 512 , 400 , 'startB' ) . setOrigin ( 0.5 )
2521
26- this . title . setInteractive ( ) . on ( 'pointerdown' , ( ) => {
22+ this . playB . setInteractive ( ) . on ( 'pointerdown' , ( ) => {
2723 this . scene . start ( 'Game' ) ;
28- } ) . on ( 'pointerover' , ( ) => {
29- this . title . setFill ( "#ff4444" )
30- } ) . on ( 'pointerout' , ( ) => {
31- this . title . setFill ( "#ffffff" )
32- } ) ;
24+ } )
25+ //.on('pointerover', () => {
26+ // this.playB.setFill("#ff4444")
27+ // }).on('pointerout', () => {
28+ // this.playB.setFill("#ffffff")
29+ // });
3330 }
3431}
0 commit comments