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
 

Re: Position Help

Previous Thread :: Next Thread 
Alexware is not online. Alexware
Joined: 07 May 2010
Total Posts: 661
26 Jun 2017 05:20 PM
I have it so
local Request = Mouse.Hit.p
However, I don't understand why I'm getting a "Vector3 expected, got CFrame" error because Mouse.Hit.p is a Position... right? How can I get around this? Any more info needed?
Report Abuse
Jonah13249 is not online. Jonah13249
Joined: 09 Oct 2009
Total Posts: 2105
26 Jun 2017 05:28 PM
I believe it is a CFrame, not a Position.
Report Abuse
ahwz is not online. ahwz
Joined: 01 Apr 2010
Total Posts: 3230
26 Jun 2017 05:34 PM
Mouse.Hit is a cframe

Mouse.Hit.p is a Vector3

are you sure its from that code?


Report Abuse
Alexware is not online. Alexware
Joined: 07 May 2010
Total Posts: 661
26 Jun 2017 05:35 PM
Are you sure it's from that code
yes i'm 100% sure, it's the only script and it even said the line
i changed it to
local Request = Vector3.new(Mouse.Hit.x, Mouse.Hit.y, Mouse.Hit.z)
and it's working fine, now.
Report Abuse
Jonah13249 is not online. Jonah13249
Joined: 09 Oct 2009
Total Posts: 2105
26 Jun 2017 05:37 PM
wiki.roblox.com/index.php?title=API:Class/Mouse/Hit
Returns a CFrame value

You can get the position of a CFrame value by adding '.p' to the end
Report Abuse
ahwz is not online. ahwz
Joined: 01 Apr 2010
Total Posts: 3230
26 Jun 2017 05:38 PM
Vector3.new(Mouse.Hit.x, Mouse.Hit.y, Mouse.Hit.z)

and

Mouse.Hit.p

are the same thing.
you are just getting the position values of the CFrame and converting them to a vector3.

I am still convinced that it was something else you were doing as you only showed 1 line of code.


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