private void OnEnable() { voxelDeformer = (RandomDeformer) target; if (voxelDeformer.ConstrainBox == null) voxelDeformer.ConstrainBox = new PicaVoxelBox(0, 0, 0, voxelDeformer.GetComponent<Volume>().XSize, voxelDeformer.GetComponent<Volume>().YSize, voxelDeformer.GetComponent<Volume>().ZSize); constrainBox = voxelDeformer.ConstrainBox; constrainToBox = voxelDeformer.ConstrainToBox; add = voxelDeformer.AddVoxels; num = voxelDeformer.NumVoxels; interval = voxelDeformer.Interval; }
private void OnEnable() { voxelDeformer = (RandomDeformer)target; if (voxelDeformer.ConstrainBox == null) { voxelDeformer.ConstrainBox = new PicaVoxelBox(0, 0, 0, voxelDeformer.GetComponent <Volume>().XSize, voxelDeformer.GetComponent <Volume>().YSize, voxelDeformer.GetComponent <Volume>().ZSize); } constrainBox = voxelDeformer.ConstrainBox; constrainToBox = voxelDeformer.ConstrainToBox; add = voxelDeformer.AddVoxels; num = voxelDeformer.NumVoxels; interval = voxelDeformer.Interval; }