Default Build Script

If you use jME3 together with the jMonkeyPlatform (recommended) then you benefit from the provided build script. Every new project comes with a default Ant script. The toolbar buttons and clean/build/run actions in the jMonkeyPlatform are already pre-configured.

Default Targets

The build script includes targets for the following tasks:

Usage on the command line:

ant clean
ant jar
ant run

Recommended Usage: Use the menu items or toolbar buttons in the jMonkeyPlatform to trigger clean, build, and run actions.

Browsing the Build Script

To see the build script and the predefined tasks

  1. Open your project in the jMonkeyPlatform if it isn't already open (File > Open Project…)
  2. Open the Files window (Window > Files)
  3. Open the project node. You see build.xml listed.
    1. Double-click build.xml to see how the jme3-specify build targets were defined. You typically do not need to edit the existing ones, but you can.
    2. Click the triangle next to build.xml to see all targets.
      1. Double-click a target in the Files window, or the Navigator, to see how the target was defined.
        You will notice that the file nbproject/build-impl.xml opens. It contains very generic targets that you typically will never need to edit. Note that build.xml includes build-impl.xml!

Adding Custom Targets

The build script is a non-proprietary Apache Ant script. It will work out-of-the-box, but if necessary, you can extend and customize it.

Read the comments in build.xml, they explain how to override targets, or extend them, to customize the build process without breaking the existing functionality.

view online version