JME Project in Scala, How to get the Assets Folder?

Hi, I’m trying to set up a small jME3 Project with the SDK.

My Classes are in Scala, so I started a Scala Project to have all the compiler settings right.

I just don’t know how I can get the nice Project Assets Folder that is automatically generated when I start a new JME Project.

Is there any configuration File I have to edit to get this Folder?

Will I generally run into configuration Problems building the whole thing without having started a JME project?



The issue is that if you create the asset folder manually then you won’t be able to access many of jMP’s features.

I’m currently using a the dirty manually created folder solution for my projects. The only issue though is that files in that folder doesn’t have a correct right click menu and don’t open in scene editor, … So I created a dummy project to manage my assets and a symbolic link. I will look at what I did if needed, I doesn’t remember exactly what files where edited.

I’ve created another project, this time using git. So here is a diff of the files located in “nbproject”.


diff --git a/nbproject/build-impl.xml b/nbproject/build-impl.xml

index 63c2c3a…bc5241b 100644

— a/nbproject/build-impl.xml

+++ b/nbproject/build-impl.xml

@@ -21,6 +21,7 @@ is divided into following sections:


<project xmlns:jaxrpc=“” xmlns:scalaProject1=“” basedir="…" default=“default” name=“SwingNodes-impl”>

  • <import file="assets-impl.xml"/>

    <target depends="test,jar,javadoc" description="Build and test whole project." name="default"/>



    @@ -144,6 +145,7 @@ is divided into following sections:

    <!-- You can override this target in the …/build.xml file. -->


    <target depends="-pre-init,-init-private,-init-user,-init-project,-do-init" name="-init-check">
  •    &lt;fail unless=&quot;src.assets2.dir&quot;&gt;Must set src.assets2.dir&lt;/fail&gt;<br />

<fail unless="src.dir">Must set src.dir</fail>

<fail unless="test.src.dir">Must set test.src.dir</fail>

<fail unless="build.dir">Must set build.dir</fail>

@@ -403,6 +405,7 @@ is divided into following sections:



<copy todir="${build.classes.dir}">

  •        &lt;fileset dir=&quot;${src.assets2.dir}&quot; excludes=&quot;${build.classes.excludes},${excludes}&amp;#10;                        &quot; includes=&quot;${includes}&quot;/&gt;<br />

<fileset dir="${src.dir}" excludes="${build.classes.excludes},${excludes}&#10; " includes="${includes}"/>



diff --git a/nbproject/ b/nbproject/

index 4998439…eb7cbe0 100644

— a/nbproject/

+++ b/nbproject/

@@ -64,5 +64,8 @@ scalac.compilerargs=








No newline at end of file

diff --git a/nbproject/project.xml b/nbproject/project.xml

index ad4b41a…c29431a 100644

— a/nbproject/project.xml

+++ b/nbproject/project.xml

@@ -6,6 +6,7 @@




  •            &lt;root id=&quot;src.assets2.dir&quot;/&gt;<br />

<root id="src.dir"/>




And you will need to create this file in nbproject folder:



<?xml version="1.0" encoding="UTF-8"?>

<!–assets-impl.xml v1.0–>

<project name="assets-impl" basedir="…">

<target name="-init-assets">

<jar jarfile="${build.dir}/${}" excludes="${assets.excludes}" basedir="${}" compress="${assets.compress}"/>

<property location="${}" name="assets.dir.resolved"/>

<property location="${build.dir}/${}" name="assets.jar.resolved"/>

<property location="${build.classes.dir}" name="build.classes.dir.resolved"/>

<pathconvert property="">

<path path="${run.classpath}"/>

<map from="${build.classes.dir.resolved}" to=""/>

<map from="${assets.dir.resolved}" to="${assets.jar.resolved}"/>





You can edit any projects assets by using “File->Import->External Project Assets” but only the default java/ant “BasicGame” project will give you all deployment etc. options. To keep this functionality I suggest creating a normal BasicGame project for your game and then creating a Scala project for the central classes, importing that to the BasicGame project and starting the scala-based “kernel” from there.

How can you import a Scala project into the BasicGame ?

You create a jar from it and include it to the project class path.