Files
blender-portable-repo/extensions/blender_org/bool_tool/properties.py
T
2026-03-17 14:30:01 -06:00

57 lines
1.2 KiB
Python

import bpy
#### ------------------------------ PROPERTIES ------------------------------ ####
class OBJECT_PG_booleans(bpy.types.PropertyGroup):
# OBJECT-level Properties
canvas: bpy.props.BoolProperty(
name = "Boolean Canvas",
options = set(),
default = False,
)
cutter: bpy.props.StringProperty(
name = "Boolean Cutter",
options = set(),
)
slice: bpy.props.BoolProperty(
name = "Boolean Slice",
options = set(),
default = False,
)
slice_of: bpy.props.PointerProperty(
name = "Slice of...",
type = bpy.types.Object,
options = set(),
)
carver: bpy.props.BoolProperty(
name = "Is Carver Cutter",
options = set(),
default = False,
)
#### ------------------------------ REGISTRATION ------------------------------ ####
classes = [
OBJECT_PG_booleans,
]
def register():
for cls in classes:
bpy.utils.register_class(cls)
# PROPERTY
bpy.types.Object.booleans = bpy.props.PointerProperty(type=OBJECT_PG_booleans, name="Booleans")
def unregister():
for cls in reversed(classes):
bpy.utils.unregister_class(cls)
# PROPERTY
del bpy.types.Object.booleans