File tree 2 files changed +11
-0
lines changed
2 files changed +11
-0
lines changed Original file line number Diff line number Diff line change
1
+ class TestScreen extends Engine . Screen {
2
+ draw ( context ) {
3
+ // A 20px sized "Georgia" font (Available natively)
4
+ context . font = "20px Georgia" ;
5
+ // The text should be colored white
6
+ context . fillStyle = "white" ;
7
+ // Draw the following message 50px from the left and 50px from the top
8
+ context . fillText ( "This is a Test Screen" , 50 , 50 ) ;
9
+ }
10
+ } ;
Original file line number Diff line number Diff line change 14
14
< script type ="text/javascript " src ="/scripts/engine/screen.js "> </ script >
15
15
< script type ="text/javascript " src ="/scripts/engine/assets_loader.js "> </ script >
16
16
< script type ="text/javascript " src ="/scripts/engine/game.js "> </ script >
17
+ < script type ="text/javascript " src ="/scripts/test_screen.js "> </ script >
17
18
< script type ="text/javascript " src ="/scripts/main.js "> </ script >
18
19
19
20
<!-- Styles -->
You can’t perform that action at this time.
0 commit comments