norbert Posted June 15, 2011 Share Posted June 15, 2011 Hi at all, I have write a new command in the driver.lua file. if KeyDown(KEY_SPACE)==1 then chassis:SetVelocity(Vec3(0,0,0),0) end Ok, but if the car is on a mountain, it still rolls very slowly ??? And the "GetBodyVelocity" command speak not zero. Someone an idea ? Norbert Quote Link to comment Share on other sites More sharing options...
Canardia Posted June 15, 2011 Share Posted June 15, 2011 You need to make a handbrake system for the car, which is controlled by some flag like "handbrakeactive=true". Without that, cars will always roll around terrain slopes freely. It works like a real car. 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...
norbert Posted June 15, 2011 Author Share Posted June 15, 2011 Ok, thank you, but how can I do this ? I have no Idea. Quote Link to comment Share on other sites More sharing options...
Canardia Posted June 15, 2011 Share Posted June 15, 2011 It's very simple really, you just check if handbrake is on, and then apply the opposite Z force what GetBodyVelocity gives. 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.