2018-05-12 07:38:00 +00:00
<?xml version="1.0" encoding="UTF-8" ?>
<class name= "CSGShape" inherits= "VisualInstance" category= "Core" version= "3.1" >
<brief_description >
2018-07-19 09:31:12 +00:00
The CSG base class.
2018-05-12 07:38:00 +00:00
</brief_description>
<description >
2018-07-19 09:31:12 +00:00
This is the CSG base class that provides CSG operation support to the various CSG nodes in Godot.
2018-05-12 07:38:00 +00:00
</description>
<tutorials >
</tutorials>
<demos >
</demos>
<methods >
<method name= "is_root_shape" qualifiers= "const" >
<return type= "bool" >
</return>
<description >
2018-07-19 09:31:12 +00:00
Returns true if this is a root shape and is thus the object that is rendered.
2018-05-12 07:38:00 +00:00
</description>
</method>
</methods>
<members >
2018-11-16 11:56:12 +00:00
<member name= "calculate_tangents" type= "bool" setter= "set_calculate_tangents" getter= "is_calculating_tangents" >
Calculate tangents for the CSG shape which allows the use of normal maps. This is only applied on the root shape, this setting is ignored on any child.
</member>
2018-05-12 07:38:00 +00:00
<member name= "operation" type= "int" setter= "set_operation" getter= "get_operation" enum= "CSGShape.Operation" >
2018-07-19 09:31:12 +00:00
The operation that is performed on this shape. This is ignored for the first CSG child node as the operation is between this node and the previous child of this nodes parent.
2018-05-12 07:38:00 +00:00
</member>
<member name= "snap" type= "float" setter= "set_snap" getter= "get_snap" >
</member>
<member name= "use_collision" type= "bool" setter= "set_use_collision" getter= "is_using_collision" >
2018-07-19 09:31:12 +00:00
Adds a collision shape to the physics engine for our CSG shape. This will always act like a static body. Note that the collision shape is still active even if the CSG shape itself is hidden.
2018-05-12 07:38:00 +00:00
</member>
</members>
<constants >
<constant name= "OPERATION_UNION" value= "0" enum= "Operation" >
2018-07-19 09:31:12 +00:00
Geometry of both primitives is merged, intersecting geometry is removed.
2018-05-12 07:38:00 +00:00
</constant>
<constant name= "OPERATION_INTERSECTION" value= "1" enum= "Operation" >
2018-07-19 09:31:12 +00:00
Only intersecting geometry remains, the rest is removed.
2018-05-12 07:38:00 +00:00
</constant>
<constant name= "OPERATION_SUBTRACTION" value= "2" enum= "Operation" >
2018-07-19 09:31:12 +00:00
The second shape is susbtracted from the first, leaving a dent with it's shape.
2018-05-12 07:38:00 +00:00
</constant>
</constants>
</class>