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 » Scripting Helpers
Home Search
 

Re: how would i made a part(torso)s CFrame

Previous Thread :: Next Thread 
islandmaker2012 is not online. islandmaker2012
Joined: 07 Nov 2012
Total Posts: 9327
03 Mar 2014 07:49 PM
rotation be the OPPOSITE of something?

ex:
Workspace.Part.Rotation = -Workspace.Part2.Rotation
this sort of thing works,but how would I use CFrame with this instead??
helpp
Report Abuse
dave2011 is not online. dave2011
Joined: 02 Oct 2010
Total Posts: 10581
03 Mar 2014 07:51 PM
Workspace.Part.Rotation = -1*Workspace.Part2.Rotation

Report Abuse
Azirux is not online. Azirux
Joined: 18 Feb 2014
Total Posts: 232
03 Mar 2014 07:53 PM
-1*CFrame.new(blah)
Report Abuse
islandmaker2012 is not online. islandmaker2012
Joined: 07 Nov 2012
Total Posts: 9327
03 Mar 2014 07:53 PM
with CFrame..how would I do it with CFRAME!!!
sorry,just a little upset here..:\
using rotation with a torso will make it fall apart :\
Report Abuse
dave2011 is not online. dave2011
Joined: 02 Oct 2010
Total Posts: 10581
03 Mar 2014 07:53 PM
whoops didnt read the entire question lol derp
Report Abuse
islandmaker2012 is not online. islandmaker2012
Joined: 07 Nov 2012
Total Posts: 9327
03 Mar 2014 07:53 PM
@az
if that really works..im probably gonna hit my head on the wall
several times..
over and over...
Report Abuse
Azirux is not online. Azirux
Joined: 18 Feb 2014
Total Posts: 232
03 Mar 2014 07:55 PM
I enjoy banging my head on the wall.
Report Abuse
islandmaker2012 is not online. islandmaker2012
Joined: 07 Nov 2012
Total Posts: 9327
03 Mar 2014 07:56 PM
same,unfortunately,its not working...

P.S
im making kinda like a mirror..

18:55:35.976 - Workspace.Player1.Follow:8: bad argument #1 to '?' (CFrame expected, got number)
Report Abuse
Azirux is not online. Azirux
Joined: 18 Feb 2014
Total Posts: 232
03 Mar 2014 07:57 PM
Ohh, of course.

CFrame.new(-1*(blah.Position))

Try that
Report Abuse
islandmaker2012 is not online. islandmaker2012
Joined: 07 Nov 2012
Total Posts: 9327
03 Mar 2014 07:57 PM
current script


while wait() do
pos = Workspace[script.follower.Value].Torso.Position
pos2 = script.Parent.Parent.Part.Position
pos3 = script.Parent.Parent.Part2.Position
newpos = pos-pos2
script.Parent:MoveTo(-newpos+pos3)
script.Parent.Torso.CFrame = -1*script.Parent.Torso.CFrame*Workspace[script.follower.Value].Torso.CFrame
end
Report Abuse
islandmaker2012 is not online. islandmaker2012
Joined: 07 Nov 2012
Total Posts: 9327
03 Mar 2014 07:58 PM
@az
testing
Report Abuse
Azirux is not online. Azirux
Joined: 18 Feb 2014
Total Posts: 232
03 Mar 2014 07:59 PM
.CFrame expects CFrame.new() right after, so try the one I posted.
Report Abuse
islandmaker2012 is not online. islandmaker2012
Joined: 07 Nov 2012
Total Posts: 9327
03 Mar 2014 08:02 PM
well,its working
but absolutely nothing like I expected...

http://www.roblox.com/item.aspx?id=148438138--uncopylocked

please help:(
(youll see what happens when you test it :\)
Report Abuse
islandmaker2012 is not online. islandmaker2012
Joined: 07 Nov 2012
Total Posts: 9327
03 Mar 2014 08:03 PM
(Working as in not erroring)
Report Abuse
islandmaker2012 is not online. islandmaker2012
Joined: 07 Nov 2012
Total Posts: 9327
03 Mar 2014 08:05 PM
I just want it to rotate the opposite..
BUMP
Report Abuse
Azirux is not online. Azirux
Joined: 18 Feb 2014
Total Posts: 232
03 Mar 2014 08:10 PM
Rotate the opposite as in? Can you specify?
Report Abuse
islandmaker2012 is not online. islandmaker2012
Joined: 07 Nov 2012
Total Posts: 9327
03 Mar 2014 08:11 PM
like I said,its like a mirror,when you walk towards the backwall,the clone should walk towards the otherwall(mirrored)
"ex:
Workspace.Part.Rotation = -Workspace.Part2.Rotation"

as in it faces the opposite way..please help :(
Report Abuse
Azirux is not online. Azirux
Joined: 18 Feb 2014
Total Posts: 232
03 Mar 2014 08:15 PM
UGHHH, WOW

um ok...

i gotta calm down...

3
2
1

okkk

soo

CFrame.new(-1*Position.X,Y,Z)

or inverse the 'Z'

which ever one that would work.
Report Abuse
islandmaker2012 is not online. islandmaker2012
Joined: 07 Nov 2012
Total Posts: 9327
03 Mar 2014 08:20 PM
-_-
its making the clone farther away,and always facing one point..
current script:

while wait() do
pos = Workspace[script.follower.Value].Torso.Position
pos2 = script.Parent.Parent.Part.Position
pos3 = script.Parent.Parent.Part2.Position
newpos = pos-pos2
Y = script.Parent.Torso.Position.Y
Z = script.Parent.Torso.Position.Z
script.Parent:MoveTo(-newpos+pos3)
script.Parent.Torso.CFrame = CFrame.new(-1*pos.X,Y,Z)
end
Report Abuse
islandmaker2012 is not online. islandmaker2012
Joined: 07 Nov 2012
Total Posts: 9327
03 Mar 2014 08:23 PM
I never thought this would be this hard..
*crys
Report Abuse
Azirux is not online. Azirux
Joined: 18 Feb 2014
Total Posts: 232
03 Mar 2014 08:25 PM
Um... I feel dumb

CFrame.new(pos) * CFrame.Angles(90,0,0)

or (0,0,90)
Report Abuse
islandmaker2012 is not online. islandmaker2012
Joined: 07 Nov 2012
Total Posts: 9327
03 Mar 2014 08:44 PM
..
I want it to always mirror the player,not always be facing a certain way..
Report Abuse
islandmaker2012 is not online. islandmaker2012
Joined: 07 Nov 2012
Total Posts: 9327
03 Mar 2014 08:56 PM
well,i have it working now /\_/\
well,it could be better,but it rotates correctly
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • 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