ulong MeshGroupMask { get; set; }

book_4_sparkGenerated
code_blocksInput

Description

The MeshGroupMask property of a SceneObject represents the state of all bodygroups of the object's model. This property is useful for managing and querying the different bodygroups that a model might have, allowing for dynamic changes to the model's appearance based on the bodygroup configuration.

Usage

To use the MeshGroupMask property, you can access it directly from an instance of SceneObject. This property is a UInt64 value, which means it can represent a large number of possible bodygroup states. You can read this property to get the current state of the bodygroups or set it to change the state.

If you need to modify a specific bodygroup, consider using the SetBodyGroup method on the SceneModel class, which provides a more direct way to manipulate individual bodygroups.

Example

// Example of accessing the MeshGroupMask property
SceneObject mySceneObject = new SceneObject();

// Get the current mesh group mask
ulong currentMask = mySceneObject.MeshGroupMask;

// Set a new mesh group mask
mySceneObject.MeshGroupMask = 0x0000000000000001; // Example mask value

// If you need to change a specific bodygroup, use the SceneModel method
SceneModel model = mySceneObject.Model;
model.SetBodyGroup("bodygroup_name", 1);