Jme 1 to jme 2 transition

Hi

I'm new in game programming and 3D and I'm not familiarized with jME too.

Recently I've been inherited 2d game project and it's based in jme 1.

And there are no old member that could can help me(yea, i think i'm in trouble :frowning: )



The main problem is it has been developed on ubuntu and when I tried to run in windows, on some point of the game it hangs… well… about this problem I think I should open new topic in troubleshooting section.



My question is : According to http://www.jmonkeyengine.com/wiki/doku.php?id=jme_to_jme2_changes  ,  It doesn't specify if I should re-structure the project code or just replacing code as specified in the link above will work properly.



I don't know if  the jme design has changed that possibly would lead to re-structuring the project code.



Or if I don't need to be worried about it?



I'll be appreciated with all the suggestion :slight_smile:







Regards,





yeonhoo

You only need to substitute the changed methods and references, no restructuring required. You'll know you have it right when it compiles without error. :wink:



Good luck with your new project! Can you tells us a little more about it?

the jme1 to jme2 changes are mostly painless.

Only a few classes have been renamed (Alphastate -> BlendState) and a few methods or constructors have a few parameters more or less.

It should be no problem to convert any project from jme1 to 2.

yeonhoo said:

The main problem is it has been developed on ubuntu and when I tried to run in windows, on some point of the game it hangs...

Make sure you have all the required native libraries (for windows these are *.dll files) in your java library path. But if the game starts and dies during gameplay, then its likely something else.
nymon said:

yeonhoo said:

The main problem is it has been developed on ubuntu and when I tried to run in windows, on some point of the game it hangs...

Make sure you have all the required native libraries (for windows these are *.dll files) in your java library path. But if the game starts and dies during gameplay, then its likely something else.


Yes. I set up libraries properly and Yes. It hangs during gameplay.
It hangs on GameStateManager.getInstance().activateChildNamed("jogoState");
It doesn't crash but it freezes.

I have to look deeply in source code how it is structured.

I have two supposition about the problem :

1. It could be the bug of jme 1 version : I think it can be checked doing all transition to jme 2. But not guaranteed
2. It could be the bad-structured project problem : After checking the 1. if it doesn't work, I have to look deeply the in source code. But it runs on ubuntu but it freezes during the gameplay on windows.



This game is educational program about human body.
It's totally 2D and It does use just little part of jme.(according to the ex-member that told me)

I'm trying to familiarize with jme looking and studying docs.

and Thanks to all for responding so quickly.


Regards,


Yeonhoo

I don't want to create a separate topic, but since this one is very similar I will ask my question here:

So is there any guide or a table listing what are the equivalent method between jMe 1 and jMe 2.

I'm starting to learn jMe from official tutorials and for me - a person who has no experience at all with jMe - it's really hard to figure out thing like:

AlphaState alpha = display.getRenderer().createAlphaState();

should be:

BlendState blend = display.getRenderer().createBlendState();



or what is the equivalence of alpha.setSrcFunction(AlphaState.SB_SRC_ALPHA);



Regards

gnom - did you check the wiki entry linked in the first post? I think that has the information you describe.