generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripters
Home Search
 

Issues with creating BodyGyro based on camera lookVector

Previous Thread :: Next Thread 
Vexture is online. Vexture
Joined: 27 Jan 2011
Total Posts: 630
23 Apr 2017 01:36 PM
Over the past day or so I've been working on a glider for my game. I want the player's body to both point in the direction of the camera and to move in the direction the camera is pointing. I have managed to get the torso to move in the camera's direction; however, I'm having trouble rotating it with a BodyGyro. I'm trying to base its CFrame off of the camera's lookVector components. Here's my code:

torsogyro.CFrame = CFrame.new(x,y,z); torsogyro.P = 5000

--x, y, and z are the camera's X, Y, and Z lookVector components respectively.

I've very little experience with BodyGyros, so excuse the atrocious P value. If anybody could tell me what I'm doing wrong, I'd really appreciate it. When running this script, the torso does not rotate at all.


Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image