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: Sawing/Cutting parts

Previous Thread :: Next Thread 
MujahidArno is not online. MujahidArno
Joined: 17 Feb 2010
Total Posts: 2893
22 May 2016 08:59 AM
How would one find the correct coordinates when you'd like to cut two parts? I'm trying to make a saw wich cuts the part in two.
Report Abuse
pketny is not online. pketny
Joined: 27 Dec 2010
Total Posts: 1162
22 May 2016 09:03 AM
Basic logic:

local partThatWillBeCut = workspace.Part


local pos = partThatWillBeCut.Position


local half1 = Instance.new("Part")
half1.CFrame = partThatWillBeCut.CFrame + Vector3.new(pos.X + partThatWillBeCut.Size.X, 0, pos.Z + partThatWillBeCut.Size.Z)

local half2 = Instance.new("Part")
half2.CFrame = partThatWillBeCut.CFrame - Vector3.new(pos.X + partThatWillBeCut.Size.X, 0, pos.Z + partThatWillBeCut.Size.Z)


half1.Parent = workspace
half2.Parent = workspace
Report Abuse
pketny is not online. pketny
Joined: 27 Dec 2010
Total Posts: 1162
22 May 2016 09:04 AM
I'm sorry, I ment:

pos.X + partThatWillBeCut.Size.X/4, 0, pos.Z + partThatWillBeCut.Size.Z/4
Report Abuse
pketny is not online. pketny
Joined: 27 Dec 2010
Total Posts: 1162
22 May 2016 09:06 AM
Ignore that...

I ment this:


Vector3.new(partThatWillBeCut.Size.X/4, 0, 0)


Sorry for the corrects...


This is assuming that the part will be cut through the Z axis.
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