Cutout Wall with a Part

With the right calculations, it’s possible to punch a hole through a part and create space for a window or a door dynamically given two parts: a wall part, and a cutter part. So far, I’ve already done the calculations for a wall along the X axis. Below is what it looks like, along with a studio place example. To see it in action, just run in studio and move the cutter around.

This doesn’t use glass, or unions.

Important
Since this is currently only supporting the X Axis, if you’re able to modify and support cutting on the Y axis and wanna share an updated place, that would be much appreciated by me and others. I’m sure I’ll get around to it eventually if no one else does it.

Also doesn’t support rotated parts

CutoutWallExample.rbxl (36.2 KB)

93 Likes

That is very interesting. I’m excited to learn how it works, without unions. Nice!

5 Likes

I’m kinda busy right now, so I can’t investigate, however I’m very curious if this uses Bones? Anyways, cool creation, I will check this out when I have more time!

1 Like

There are no bones. It’s just math

2 Likes

You could just use I think the tool is negative or what ever it is to cut open a part.

Someone should expand apon this and make it a full on plugin with support for rotated parts all axis etc would love to see that!

1 Like

Would it be okay if I developed a plugin using your module?
@Hanfian

1 Like

Yes that would be fine. That would be incredibly useful for many developers.

Would you please explain how this works?
I did not know yo could set the vertices of a part and keep accurate collission.
* just realised the place file was right there gonna go take a look then *

Yo, the system works by using math to calculate where the cutterObject is and how to split the part you’re cutting into a few different parts. Then it puts these parts into a model, and that’s about it!

ooh, that makes sense, reminds me of that plugin that let you bevel parts.

1 Like

Yeah, it’s actually pretty cool.

This is super cool! Becoming the next union.

1 Like

Have you developed the plugin yet?

What do you mean? This plugin is already available.

1 Like

Where is the plugin? I can’t seem to find it

1 Like

Here’s a link to the official plugin post.

1 Like

Sorry if I’m wrong, but I think you need to replace lines 86 and 94 of your ModuleScript “CutoutWall” to v.OffsetStudsV = -(part.Position.Y + part.Size.Y/2)%StudsPerTileV so it can suport the Y axis.

1 Like

Just updated the file. Thanks for catching that

@Hanfian, does your module support the Y axis now? If it does, I can update the plugin.