Problem with characters moving (solved)

hello,

I’m developing my game and I was testing it in one computer, and it works well!! I mean ‘‘when characters are moving’’

but when I tested it in another machine it worked really bad. the characters move away without control!!

I don’t understand what happened here because the code is the same.

Also, I tried with a MacBook Pro, and same happens (bad moving)




  1. Machine:

    http://www.youtube.com/watch?v=dpNvpwjzoxA&feature=channel&list=UL


features:
Intel Xeon CPU E5440
2.53Ghz
4.00Gb Ram
64bits

2. Machine:
http://www.youtube.com/watch?v=roT0iYuAdsc&feature=channel&list=UL


AMD Phenom II P820 - Triple core 1.80ghz
4Gb ram
64bits

Please I hope somebody can give me some advice to fix that!!
Thank you in advance

Apparently you are doing it wrong. Do you couple your movespeeds to tpf? Show the update code.

I’m sorry I forgot to explain that I’m using motionPath to move the characters.

I mean the game uses an A* algorithm to find a route between 2 points (‘path’ variable)

then each step in the route is added to the motion path like a ‘wayPoint’

and finally I set it to ‘play’ to start moving each character



[java]

Path path = null;

operator.setMotionPath(new MotionPath());

path = pathfinder.findPath(operator.getCurrentLocationX(), operator.getCurrentLocationZ(), finalPosX, finalPosZ);

for (Step s : path.getSteps()) {

operator.getMotionPath().addWayPoint(new Vector3f(s.getX() , 6f, s.getY() ));

}

operator.getMotionControl().play();

[/java]



also… I use the code below to control each step of the character.



[java]

operator.getMotionPath().addListener(new MotionPathListener() {

public void onWayPointReach(MotionTrack control, int wayPointIndex) {

operator.setPhysicsLocation(control.getPath().getWayPoint(wayPointIndex));

if (control.getPath().getNbWayPoints() == wayPointIndex + 1) {

operator.setCurrentLocationX(finalPosX);

operator.setCurrentLocationZ(finalPosZ);

operator.updatePhysicsLocation();

operator.setIsMoving(false);

}

}

});

[/java]



thank you for your answer @Dodikles

I performed the last updates in the jMonkeyEngine. I mean with the ‘‘nightly updates’’, after that I cleaned and builded many times and now… finally it is working good in both machines!!!

So solution is: ‘‘update jMonkeyEngine SDK Nightly’’. that is all!!