Shape.destroyPart

Destroy a part

Kind: Function

Environments: Game

Game

shape:destroyPart(
    attackLevel,
    destructionType,
    destructionPosition,
    destructionNormal
)

Open the full Game reference

Availability: Server only

Deprecated: use Shape.destroyShape

Parameters:

Name Type Description
shape Shape The part.
attackLevel integer Determines which quality level of parts the attack can destroy. Setting it to 0 (default) will destroy any part.
destructionType (optional) integer The type of destruction (Optional). (See sm.shape.destructionType). (Defaults to sm.shape.destructionType.none)
destructionPosition (optional) Vec3 The position of the destruction would hit the part (Optional)
destructionNormal (optional) Vec3 The normal direction of where the destruction would hit the part (Optional)