FxVoxelCapsule โ
This module contains functions for nodes that inherit from VoxelCapsule, which are nodes of type VoxelSceneReference, VoxelHeightmapReference and VoxelMovieReference.
Load โ
FxVoxelCapsule = require "FxVoxelCapsule";Functions โ
| Function | Description |
|---|---|
| Convert (NodeID) | Converts a VoxelCapsule node into a VoxelLayer node. |
| Flip (NodeID, Axis) | Flips the voxel grids of a voxel capsule node |
| Rotate90 (NodeID, Axis, Steps) | Rotates the voxel grids of a voxel capsule node in 90ยฐ steps. |
Convert (NodeID) โ
This function converts the given VoxelCapsule node into a VoxelLayer node, making its voxel grids editable. The NodeID of the converted node remains the same.
Parameters โ
- NodeID: The NodeID of the VoxelCapsule node to convert
Errors โ
Possible errors include FX_REQUIRED_ASSET_UNAVAILABLE, FX_NODE_NOT_FOUND
Since โ
Version 1.0
Example โ
-- convert "Reference1" to a VoxelLayer
FxVoxelCapsule.Convert("Reference1");Flip (NodeID, Axis) โ
This function flips the voxel grids of the given VoxelCapsule node along the given axis.
Parameters โ
Errors โ
Possible errors include FX_REQUIRED_ASSET_UNAVAILABLE, FX_NODE_NOT_FOUND, FX_VALUE_INVALID
Since โ
Version 1.0
Example โ
-- flip along y-axis
FxVoxelCapsule.Flip("Reference1", 1);Rotate90 (NodeID, Axis, Steps) โ
This function rotates the voxel grid of the given VoxelCapsule node around the given axis in 90ยฐ steps.
Parameters โ
- NodeID: The NodeID to identify the VoxelCapsule nodes to rotate
- Axis: The rotation Axis3D
- Steps: The number of 90ยฐ rotation steps
Errors โ
Possible errors include FX_REQUIRED_ASSET_UNAVAILABLE, FX_NODE_NOT_FOUND, FX_VALUE_INVALID
Since โ
Version 1.0
Example โ
-- rotate 90ยฐ counter clockwise around z-axis
FxVoxelCapsule.Rotate90("Reference1", 2, -1);