This is the result I want, is there a way this can be done in playcanvas? Any help/information would be appreciated! Thank you for reading.
Hi @Jacob_McBride2!
No idea how exactly, but maybe you can rotate the sphere instead of moving the player?
Hi, I have a ready-made solution for a kinematic controller.
Set gravity to zero and give a constant rigidbody force towards the sphere.
In the current implementation of Ammo, it is not possible to remove gravity for a dynamic body, it will only work for kinematics.
You are going to turn off gravity for the whole project, it still wonāt work, try it.
well idk this isnt my project
I found this:
I canāt remember why, but I couldnāt get it to work. If you get it to work, please let me know!
Ammo allows per body gravity control. It is simply not exposed in PlayCanvas. Feel free to upvote the feature PR:
@LeXXik that would be a GREAT feature!!!
-
We are talking about the current implementation, without library updatesā¦
-
If you control gravity, then you need to move away from the standard update in favor of fixedUpdate, because the capsule has a dynamic body, with lags, gravity will be incorrect, which will lead to twitching of the character, so the approach itself is wrong.
(That is, every frame we need to correct gravity relative to the center of the character and the planet.)
Is there a reason you need to use the first person movement script?
Yes I want to make a first person space/planet/solar system exploration game
Which would cause lag, possible for kenimatic to be able to jump and stay aligned though?
Iāll definitely do so.
Have you watched the demo project of kinematic character system ?
Yes and I want to use it but no link to the editor, if I did use the code I would credit the author within my game as well. If you know the editor link or where I can find the code that would be appreciated! The system looks perfect for my idea.
Is there a way you could provide the code/editor for the system? I would want to make it first person as well if you wouldnāt mind helping. (I will give full credits to you as the author of the system) your system is perfect for what I started this thread about. Thanks for reading.
Yeah I found this one too but I think it may be old or some of the code is now redacted, thatās probably why itās no longer functional.