Aerion Posted April 15, 2019 Share Posted April 15, 2019 Can someone please tell me why this is moving my Character in the +Y direction instead of the +Z direction? // Forward local direction is '+Z' this.__tempVec.set ( 0.0, 0.0, this.__currentVelZ ); this.__entity.localToWorld ( this.__tempVec ); this.__entity.setLinearVelocity ( this.__tempVec ); Thank you! ~Aerion Quote Link to comment Share on other sites More sharing options...
CrspyCrust Posted June 21, 2019 Share Posted June 21, 2019 are you using three.js to fully develop your game? Quote Link to comment Share on other sites More sharing options...
Aerion Posted June 26, 2019 Author Share Posted June 26, 2019 @CrspyCrust : Yes Quote Link to comment Share on other sites More sharing options...
x1911 Posted December 11, 2019 Share Posted December 11, 2019 so far i know, there is no setLinearVelocity in three js are you using physijs? Quote Link to comment Share on other sites More sharing options...
stevediaz Posted July 24, 2023 Share Posted July 24, 2023 Hello To move the character in the '+Z' direction, please use the following code: this.__tempVec.set(0.0, 0.0, this.__currentVelZ); this.__entity.setLinearVelocity(this.__tempVec); This should now move your character correctly in the intended direction. Quote 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.