tjheldna Posted March 12, 2013 Posted March 12, 2013 Hi Josh, I'm trying to create a CharacterController Object and spawn a character dynamically in code, but having some trouble. (C++) Is the below code correct? playerEntity = Model::Load("Models/Characters/Barbarian/Barbarian.mdl"); CharacterController *controller = CharacterController::Create(playerEntity, 1.6F, kPlayerHeight, 0.5F, 45.0F); playerEntity->SetMass(10); controller->Release(); I load the level an turn on physics debugging but there is no collision shape. If I replace the CharacterController Line to playerEntity->SetPhysicsMode(Entity::CharacterPhysics); I do get a collision cylinder, but I don't think that's the right way. Any pointers would be great! (excuse the pun =) ). Quote
AggrorJorn Posted March 13, 2013 Posted March 13, 2013 I didn't know there was a character controller available yet. Did you find a documentation page of it? Quote
f13rce Posted March 13, 2013 Posted March 13, 2013 I didn't know there was a character controller available yet. Did you find a documentation page of it? Maybe that's why I got stuck as well. I couldn't find a page of it either. Quote Using Leadwerks Professional Edition (Beta), mainly using C++. Windows 10 / Linux Mint, Visual Studio 2017. GPU: NVidia GeForce GTX970, CPU: Intel i7 7700K @ 4.20 GHz Previously known as Evayr.
Admin Posted March 13, 2013 Posted March 13, 2013 All entities can be either a rigid body or a character controller now. See the physics commands in the entity class. 2 Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.