Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Please check out this model, I can't generate Full Body data for it
#1
Pregunta 
Softbody version 6.5.4
I have test with another character, it can generate just fine.
But this Slime model can not, I have no idea.
This is the error shown:
Code:
IndexOutOfRangeException: Index was outside the bounds of the array.
Obi.ObiSoftbodySurfaceBlueprint+<InsertParticlesIntoVoxels>d__42.MoveNext () (at Assets/Obi/Scripts/Softbody/Blueprints/ObiSoftbodySurfaceBlueprint.cs:323)
Obi.ObiSoftbodySurfaceBlueprint+<Initialize>d__37.MoveNext () (at Assets/Obi/Scripts/Softbody/Blueprints/ObiSoftbodySurfaceBlueprint.cs:168)

Code:
NullReferenceException: Object reference not set to an instance of an object
Obi.ObiActorBlueprintEditor.Refresh () (at Assets/Obi/Editor/Common/Blueprints/ObiActorBlueprintEditor.cs:416)
Obi.ObiActorBlueprintEditor.Generate () (at Assets/Obi/Editor/Common/Blueprints/ObiActorBlueprintEditor.cs:132)

I have created a thread like this in a long time, but I think this is new error, since the old error is patched I supposed.

Link https://drive.google.com/file/d/13TqlniB...sp=sharing
Reply
#2
Hi!

Just tried your slime mesh on Obi 6.5.4, but I'm unable to reproduce this. It generates the blueprint just fine for me (using default blueprint settings).

Could you share the settings you're using?

kind regards
Reply
#3
Could reproduce the issue by adding a root bone to the skeleton in the blueprint editor, then clicking generate.

The issue happens because most bones in your Slime character are far outside of the mesh, and the sampler fails to assign a particle to voxels in the voxelized mesh because they're very far from the voxel mesh bounds.

This can be prevented by performing a bounds check, with no ill effects. Please find attached a patched version of ObiSoftbodySurfaceBlueprint.cs.

let me know how it goes,

kind regards,


Attached Files
.cs   ObiSoftbodySurfaceBlueprint.cs (Size: 31.51 KB / Downloads: 2)
Reply
#4
(29-04-2024, 09:00 AM)josemendez Wrote: Could reproduce the issue by adding a root bone to the skeleton in the blueprint editor, then clicking generate.

The issue happens because most bones in your Slime character are far outside of the mesh, and the sampler fails to assign a particle to voxels in the voxelized mesh because they're very far from the voxel mesh bounds.

This can be prevented by performing a bounds check, with no ill effects. Please find attached a patched version of ObiSoftbodySurfaceBlueprint.cs.

let me know how it goes,

kind regards,
Yes I did have a root bone set.
The patch you sent does fixed the issue, thank you!
Btw the character Full Body Soft Body and the Obi Bone is somewhat having the same functionality, that is letting character does 2-ways contact with the environment colliders.
If you have to choose for your project, what is your go-to solution?
Reply
#5
(29-04-2024, 10:13 AM)spikebor Wrote: Yes I did have a root bone set.
The patch you sent does fixed the issue, thank you!
Btw the character Full Body Soft Body and the Obi Bone is somewhat having the same functionality, that is letting character does 2-ways contact with the environment colliders.
If you have to choose for your project, what is your go-to solution?

Hi,

They're meant for completely different use cases.

Full body softbodies are meant for volumetric objects that can deform, like a character's belly.

ObiBones are meant for thin, long hierarchical structures that can move, but can't deform. Like tails, tentacles, braids, etc. These can move, but you can't squash/compress them like you can with a softbody. They're essentially a solid tube.

kind regards,
Reply