Game Development Reference
In-Depth Information
As you can see in the figure, NetBeans has written the
package
statement, seven
JavaFX
import
statements, the
class
declaration, and the
.start()
and
.main()
methods
. NetBeans 8.0 colors Java key programming
statement words
blue and com-
ments gray. Data values are orange and input/output is green.
Before you can
run
this bootstrap code, to make sure that NetBeans 8.0 wrote code
for you that actually works, you will need to
compile
it into an
executable
format,
which is run in your system memory.
Compiling Your Java 8 Game Project in
NetBeans 8.0
In showing you how to compile your Java 8 code before you run (test) it, I am demon-
strating the “long way” here so that you are exposed to every step of the compile/run
Java 8 code-testing process. Click the
Run
menu, and then select
Compile File
(the el-
eventh menu item) to compile your Java code, or use the
F9
keyboard shortcut, as in-
dicated at the right of the selection, as seen in
Figure 2-8
. Now your project is ready to
run!