What is the best way to build an game around JME?

I have looked at the Flag Rush tutorials, but one thing has become apparent to me. For a large game, like a 3d platformer, what is the best way to oranize things such as Entities, Effects, Map Loading, Gui Classes, Input classes, Sound effects, etc, into a game framework.

I understand the pieces fine, but how can I put them all together without creating a codemonster than is impossible to update and change without changing things in 100 places.

Well there are 100+ answers to your question, as your question could be rephrased: "What is good software design?"

And one of the short answers is: you need to find out yourself! :stuck_out_tongue:

Best thing is to experiment by starting to code the basics of your game, if you're like me, you'll reiterate the code over and over again until you wont even recognise it. Abstracting this and that and dropping bits you once thought were vital.

Personally I think the best way of getting to know the engine is building simple apps that are pieces of your game. After testing out all the stuff JME provides you can think about the infrastructure that should enable all this tiny pieces to work together. You have to code them again to match the needs of your application, but unless you really get into programming you don't need a framework. Exactly like adamgp said before.

But if you already know every tiny bit of JME, you can start right away with the overall structure, the interfaces, the classes, the management stuff that loads your data… and after that's finished, you can write the remaining code that sets up your game.

This is what I did:

  • Followed the FlagRush tutorial

  • Tried to build my own terrain with a SkyBox

  • Added a moveable gray box to it

  • Added a ThirdPersonHandler to control it

  • Loaded a 3ds model instead of the gray box

Now I'm trying to build some tools for myself, like a very basic terrain editor based on heightmaps (like in Sim City-style games). Until that is finished I try to read about Project Darkstar, the game server technology by SUN. When I'm comfortable with the server I will start over again with implementing a simple grey-box moving game with 2 users connected to the server. This should lead to a chasing game where 2 player can chase each other when they are connected to the server.

What I still have to figure out is (for the client) a good way to load terrain data, models, sounds... and keep them in memory! And for the server part how to organize the background tasks like positional calculations and data exchange between players. But there I will follow my own routine: Follow the server tutorials. Adapt the tutorials to build a simple chat-like interface. Then put JME on top, allowing to receive messages from the server... ;)

I have to say: I'm not doing this to earn any money, I just like to play with JME and getting to know game technologies. So I can lay back and figure out what to do by myself.

Personally, I think the best way is to code on demand, in a sense  :smiley:

You start with SimpleGame which does almost everything for you, and then you can concentrate in game logic. When you discover you need more, then you start writing the managers yourself, until you are managing all the resources in an efficient and familiar way.

Java Maps, ArrayLists, and such will be your friends  :wink:

in general there r two ways. bottom up or top down.

i prefer the bottome up way. start from the most basic things.

environment(skybox, light, and etc.) -> a basic player -> controllers

and once u have a really simple basic working game. start filling out the details, such as models, more controllers, more functions and etc.

Thanks for the ideas guys!

I will use the tried and true method "trial and error"

refactor city, here I come :smiley: