Jmonkey CookBook

@rickard said: Hi.

I’m sorry you’re having trouble with this example. Still, thanks for posting about it so that it can be resolved.
Unfortunately, I don’t have access to the latest code here (away over christmas). However, I have a hunch.
One of the last things that were done before release was to change the format of the package naming to chapter01 02 03 etc.
Since refactoring doesn’t work on xmls that was done by hand and there is a risk one or two files were missed.

Long story short:
Check and see if gameScreen.xml has the following line:


<screen id="gameScreen" controller="gui.controller.GameScreenController">

“gui.controller.GameScreenController” should in that case be replaced with “chapter06.controller.GameScreenController”

If that is the error, I hope it’s the only file where the problem occurs. But I’ll make sure to check it when I get home and update the example code base in that case.

I hope it helps and that you still find enjoyment in the book!

@SteveDay
If you’re also having problems, maybe you can share where the errors are so they can be fixed?

There’s always a risk with writing examples for a changing code base that the example code will eventually be obsolete. Not to say that there might not have been issues with the examples, but I know that they worked at the time of writing.

Example work!

There are also other errors, it would be nice to have all the working examples. It would be very nice if you can try the examples and update the code.

Congratulations on the book is proving crucial for people like me.

1 Like