Rick Posted December 29, 2009 Share Posted December 29, 2009 I can't seem to get the physics to work with a controller that I create in code. What am I missing? The controller is created and positioned at the object location, but I'm expecting it to drop to the terrain but it floats in the air. The color of the controller is red and the physics button is on Play. function class:CreateObject(model) local object=self.super:CreateObject(model) object.controller = CreateController(height, radius, step, slope) EntityType(object.controller, 1) object.controller:SetPosition(object.model:GetPosition()) end Now I know SetPosition() stops physics, but it only gets called once in the create so after that initial setting of the position shouldn't it then play the physics? Quote Link to comment Share on other sites More sharing options...
Marleys Ghost Posted December 29, 2009 Share Posted December 29, 2009 mass? Quote AMD Bulldozer FX-4 Quad Core 4100 Black Edition 2 x 4GB DDR3 1333Mhz Memory Gigabyte GeForce GTX 550 Ti OC 1024MB GDDR5 Windows 7 Home 64 bit BlitzMax 1.50 • Lua 5.1 • MaxGUI 1.41 • UU3D Pro • MessiahStudio Pro • Silo Pro 3D Coat • ShaderMap Pro • Hexagon 2 • Photoshop, Gimp & Paint.NET LE 2.5/3.4 • Skyline • UE4 • CE3 SDK • Unity 5 • Esenthel Engine 2.0 Marleys Ghost's YouTube Channel • Marleys Ghost's Blog "I used to be alive like you .... then I took an arrow to the head" Link to comment Share on other sites More sharing options...
Rick Posted December 29, 2009 Author Share Posted December 29, 2009 Bah. Thanks. I swear I didn't do that when programming in C++ Quote Link to comment Share on other sites More sharing options...
Canardia Posted December 29, 2009 Share Posted December 29, 2009 Swearing is not allowed on these forums. Quote ■ Ryzen 9 ■ RX 6800M ■ 16GB ■ XF8 ■ Windows 11 ■ ■ Ultra ■ LE 2.5 ■ 3DWS 5.6 ■ Reaper ■ C/C++ ■ C# ■ Fortran 2008 ■ Story ■ ■ Homepage: https://canardia.com ■ Link to comment Share on other sites More sharing options...
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.