Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How would you go about cutting a part in half across a certain plane?

Asked by 5 years ago

I was looking through snack break once again, trying to improve in scripting with lua. I came across a topic that looked easy until the last one. The topic was cutting a part relative to where another part was slicing through it. I assumed the first one would be easy, all I had to do was get the difference in position between the two points and then subtract that number from one half of the size of the part. All that was left was the positioning, and then I saw the third part of the challenge. The part was getting cut diagonally. This amazed me, I didn't think you could create a triangle part without negations, and I know you can't negate anything in a script. My question is, how could you cut a part across a diagonal plane with a script?

Note: I'm not expecting a full code answer, as that would take quite a while. I'm simply asking for an explanation on how this would work, and what API I could use to get this effect.

1
The snack break didn't allow to use the CSG API, but it's too late to submit one now. You can just use the CSG API for your own project. User#24403 69 — 5y
0
@sjr04Alt any links on where I can learn this, never knew that roblox had something like that cmgtotalyawesome 1418 — 5y
0
^ Since sjr04Alt hasn’t responded, here’s a link that should teach you how to use the API : https://developer.roblox.com/articles/in-game-solid-modeling User#20279 0 — 5y

Answer this question