Player controller problems

A place to discuss everything related to Newton Dynamics.

Moderators: Sascha Willems, walaber

Player controller problems

Postby ItBurn » Sat Jul 02, 2011 7:21 pm

Hi.

I'm new around here and am trying to make a simple engine with Newton objects.

I've copied the player controller tutorial and integrated it rather easily, until I got two problems...

1 - Deleting a newton body with NewtonDestroyBody crashes when the body has a CustomPlayerController with a max stair step factor of 0.
This is very easy to reproduce. The problem is that I need to have the step factor of 0. My player is a sphere and not a cylinder. When it collides with enemies, which are also spheric CustomPlayerControllers, they climb on top of each other regardless of height. The tutorial uses a cylinder, which I expect, fixes the climbing problem, but this brings me to problem 2, which is the reason I use the sphere.

2 - I can't move a player with a cylinder body in a world where Z is up (towards the sky or ground).
When I create the cylinder with NewtonCreateCylinder, it's laying on the ground like a sewer pipe instead of standing upright like a telephone pole. I suspect that it's because I use Z for up. So, I rotated the matrix. Now it's properly orientated, but whatever I do (changing the CustomPlayerController orientation), the player refuses to move. If I leave it on the ground, with no rotation, the player moves fine (except that the edges of the cylinder scratch the walls...).

What's the proper way of doing all this? Can anyone help?
ItBurn
 

Re: Player controller problems

Postby KingSnail » Wed Jul 06, 2011 9:20 pm

It seems there are some problems with the character controller, although I havent had those exact problems.
It works more or less ok, but can get stuck and I had the bug where two controllers can climb on each other.
That was fixed by editing the source of the custom character controller to make sure 2 controllers dont collide at all.
There is a thread about the fix somewhere, it was meant to be added to the source as a fix but I dont think Julio added it yet.
I am still waiting for his new proxy based character controller which he said will fix a lot of bugs.
Working on an MMORPG powered by Newton Dynamics.
User avatar
KingSnail
 
Posts: 112
Joined: Sat Jan 02, 2010 9:55 pm


Return to General Discussion

Who is online

Users browsing this forum: No registered users and 0 guests