Search Forums

(Advanced Search)

Latest Threads
Stretching verts uniforml...
Forum: Obi Softbody
Last Post: Aroosh
13-09-2025, 05:32 AM
» Replies: 0
» Views: 95
Scripting rod forces
Forum: Obi Rope
Last Post: chenji
11-09-2025, 01:15 PM
» Replies: 25
» Views: 2,845
Burst error causing crash...
Forum: Obi Rope
Last Post: josemendez
10-09-2025, 07:03 AM
» Replies: 1
» Views: 218
Controlling speed of emit...
Forum: Obi Fluid
Last Post: josemendez
06-09-2025, 06:29 AM
» Replies: 1
» Views: 475
Looks nice on editor but ...
Forum: Obi Fluid
Last Post: josemendez
04-09-2025, 07:20 AM
» Replies: 3
» Views: 717
How to Shorten or Scale t...
Forum: Obi Rope
Last Post: josemendez
02-09-2025, 09:53 AM
» Replies: 5
» Views: 799
The Limitation of Using O...
Forum: Obi Rope
Last Post: josemendez
01-09-2025, 10:30 PM
» Replies: 1
» Views: 538
Bug Where a Straight Segm...
Forum: Obi Rope
Last Post: josemendez
01-09-2025, 08:46 PM
» Replies: 1
» Views: 512
Having an issue with obi ...
Forum: Obi Rope
Last Post: Ben_bionic
29-08-2025, 04:23 PM
» Replies: 4
» Views: 1,010
Non-uniform particle dist...
Forum: Obi Rope
Last Post: chenji
29-08-2025, 09:05 AM
» Replies: 4
» Views: 858

 
Pregunta Instantiating Ropes at runtime
Posted by: Eulenmensch - 09-10-2020, 12:48 PM - Forum: Obi Rope - Replies (2)

Hi, love the asset so far, great UX and really powerful!

I am doing fine with ropes that I author and place in the scene but am running into some issues/questions now that I'm attempting to instantiate them at runtime.

My usecase is that I have a Helium Balloon(rigidbody with up force applied) that spawns and attaches to other rigidbodies on collision. I want this attachment to be an Obi Rope to simulate the string of the balloon.
For that I would need to set the start and end nodes of a rope to the balloons position and the impact point respectively.

Do I need to create a blueprint at runtime for each of the ropes to do so? 

How do I know which index each particle group of a rope has?

Thanks for the great asset!

Print this item

  Two ropes use same blueprint and use different phase
Posted by: Tonyqu - 09-10-2020, 02:09 AM - Forum: Obi Rope - Replies (1)

I wanna two rope collide with each other

Print this item

Sonrisa Multiple Particle Attachment ?
Posted by: VincentAbert - 07-10-2020, 09:16 PM - Forum: Obi Rope - Replies (3)

Hello !

I just wanted to make sure that there was no problem with using multiple particle attachment components on a single particle group. I am also not sure about how to set the particle group by script, how can I choose it by name for example ?

I have a ton of other questions, but I'll try and search a bit more in the docs before flooding the forum Sonrisa

I hope I made myself clear, english is not my first language.

Cheers,

Vincent

Print this item

Información Collision Detect
Posted by: sahin49 - 07-10-2020, 10:26 AM - Forum: Obi Fluid - Replies (3)

I'm sorry for my bad english.
This is my first time using this package.
I want to detect particle and object collision. 

How can I do this? Or how can I tell if an empty glass is full?

As an example video: https://youtu.be/-rVaEEb4-vI?t=80

Print this item

Triste 3 fps with only 1 softbody meshes
Posted by: manurocker95 - 05-10-2020, 10:22 PM - Forum: Obi Softbody - Replies (1)

Hi! I'm updating my project to latest obi and unity, and the newest version has way worse performance than it had before.

In my scene I just have a softbody object with the mesh of a torus with 2160 vertices (1512 tris), the static dragon environment with obi collider and 4 poles with just obi collider (and box collider) made with the barrel meshes.

With a previous version (dunno exactly the version right now) I reached 120 fps in this exact scene and project configuration (Max particle timestep 0.004) and now i drops to 2-3fps with Oni backend. Burst compiler completely freezes Unity 2020.1.7f1 + latest Burst (1.3.7) + latest jobs (0.5.0 preview 14). Same issue I had with Obi rope.

Obi distance Field colliders are completely ignored independently of the input mesh and setup in the SO. Collisions are not applied at all.

I can't send the project, but the torus itself.


Edit: The FPS are estimated in Editor. Build crashes with Burst, but Oni backend gets 60fps.

Print this item

  Burst not working at all
Posted by: manurocker95 - 05-10-2020, 06:00 PM - Forum: Obi Rope - Replies (20)

Hi! I'm using Unity 2020.1.7f1 + Burst 1.3.7 + Jobs 0.5.0-preview 14 and when setting any solver to Burst, Unity completely freezes. This is common to all Obi assets. In case of Softbody, Oni mode works just fine excepting the scene "Deformable Barrels" that runs at 3fps after instancing. 

Any idea? Should I downgrade Jobs package?

Thanks in advance

Print this item

  Add force to particle
Posted by: flaurens - 05-10-2020, 01:00 PM - Forum: Obi Rope - Replies (1)

Hi!

I have the next scenario:

One ObiSolver that contains a few ropes. What I want is that once I cut one of that ropes (using the ObiRope.Tear function), I want to apply a certain amount of force to each extreme of the particles in order to add some juice to the cut action.

In the past, I was using ObiSolver.externalforces, using as an index the element that contains the particle that I get from e.contacts (being e ->ObiSolver.ObiCollisionEventArgs). At that time I was using One ObiSolver per rope so there wasn't any problem.

Now I'm using one ObiSolver for different ropes. Is there any way to get the global number of the element that contains the particle?
Because if I'm using the old way the force is applied to a different rope than the one that I'm tearing it.

Regards!

Print this item

  Detect specific rope collision.
Posted by: flaurens - 05-10-2020, 08:45 AM - Forum: Obi Rope - Replies (23)

Good morning,

I was wondering If it's possible to detect which rope has received a collision when having multiple ropes in an Obi Solver.
Right now I use the OnCollision event from the ObiSolver but I don't find a way to detect which specific rope is receiving the collision.

Regards!

Print this item

  Grab Obi Rope with Playmaker & VR
Posted by: NinjaPlayground - 03-10-2020, 02:25 PM - Forum: Obi Rope - Replies (1)

I've searched the forum with no luck with anyone being able to grab the middle of an obi rope with Playmaker or with VR.  I've found scripts (ObiContactGrabber.cs) to grab any particle automatically using Grab & Release functions, but this can't exactly be used well with Playmaker without some additional modifications and I am not a programmer.  While I understand Obi Rope isn't designed with Playmaker in mind, you can usually use Playmaker to access any publicly exposed variables, bools, methods, properties, etc. in order to get most things to work.  My largest problem is trying to detect collisions with the ObiSolver. Grabbing the ends of a rope is no problem because that doesn't rely collisions with the ObiSolver, but that doesn't allow me to climb a rope. 

While I've tried to adapt the ObiContactGrabber script to add bools to allow me to detect if a collision has been made with an ObiSolver this doesn't allow me to do a few things:

  • I need to be able to detect what solvers an ObiCollider has made contact with to allow the player to climb multiple ropes. ObiContactGrabber allows you to define only 1 solver.

So I need help or minor programming tips on how to expose some things in order for me to be able to use Playmaker. I need to be able to expose functions or variables to achieve this and would rather try to use ObiRope due to its efficiency as opposed to using a heavier rope solution from the Unity Asset Store.

EDIT:

So I've managed to grab the mid point of a ObiRope using the ObiContactGrabber script by simply connecting the Grab & Release functions to the "Grabbing" of an Oculus Controller. Which by default only grabs when the collision with the ObiSolver is happening. My only problem now is getting access to which ObiSolver is colliding with the ObiContactGrabber script AND a bool letting me know that the collision IS TRUE.  I can use this bool as a switch to make sure I can trigger the vertical climbing when the ObiCollider is actually in contact with the ObiSolver particles.

EDIT:

Managed to add a bool collision check in the "ObiSolver.cs". Allows me to check if collision is happening on the particle. I can now climb an obi rope in VR & Playmaker. Would still love to hear any thoughts on how to do this better or in a different way.



Attached Files
.cs   ObiContactGrabber.cs (Size: 5.67 KB / Downloads: 11)
Print this item

Bug [Burst] Lots of errors after adding to solver in some cases
Posted by: mmortall - 01-10-2020, 06:15 PM - Forum: Obi Cloth - Replies (3)

I cannot provide my project because it is under NDA. I was using Obi Cloth and generating all stuff in runtime and I am using several solvers in the scene to simulate differently stuff. It is working totally fine with Oni backend. But with Burst I have these errors sometimes. It is rare errors and it happens 100% times in some specific cases in some special conditions I cannot reveal yet. Because I do scene snapshotting in my app and so I can get the case when it is reproducing 100% but I cannot tell what leads to this in the low level. Could be some mesh for simulation is null or corrupted or something like that. But Obi should handle these cases instead of crashing with unhandled errors. This issue also leads to a hang on iOS device.
Could you look into it?

It seems when the actor is added to Solver simulation not started and I got this exception in the console
First I got this error:

Quote:InvalidOperationException: The NativeContainer ApplyVolumeConstraintsBatchJob.particleIndices has not been assigned or constructed. All containers must be valid when scheduling a job.
Unity.Jobs.LowLevel.Unsafe.JobsUtility.ScheduleParallelFor (Unity.Jobs.LowLevel.Unsafe.JobsUtility+JobScheduleParameters& parameters, System.Int32 arrayLength, System.Int32 innerloopBatchCount) (at <8691ad7005ed4755a1828378ff0b52b1>:0)
Unity.Jobs.IJobParallelForExtensions.Schedule[T] (T jobData, System.Int32 arrayLength, System.Int32 innerloopBatchCount, Unity.Jobs.JobHandle dependsOn) (at <8691ad7005ed4755a1828378ff0b52b1>:0)
Obi.BurstVolumeConstraintsBatch.Apply (Unity.Jobs.JobHandle inputDeps, System.Single deltaTime) (at Assets/Plugins/Obi/Scripts/Common/Backends/Burst/Constraints/Volume/BurstVolumeConstraintsBatch.cs:79)
Obi.BurstConstraintsImpl`1[T].EvaluateParallel (Unity.Jobs.JobHandle inputDeps, System.Single deltaTime) (at Assets/Plugins/Obi/Scripts/Common/Backends/Burst/Constraints/BurstConstraintsImpl.cs:136)
Obi.BurstConstraintsImpl`1[T].Project (Unity.Jobs.JobHandle inputDeps, System.Single deltaTime) (at Assets/Plugins/Obi/Scripts/Common/Backends/Burst/Constraints/BurstConstraintsImpl.cs:97)
Obi.BurstSolverImpl.ApplyConstraints (Unity.Jobs.JobHandle inputDeps, System.Single deltaTime) (at Assets/Plugins/Obi/Scripts/Common/Backends/Burst/Solver/BurstSolverImpl.cs:765)
Obi.BurstSolverImpl.Substep (System.Single substepTime) (at Assets/Plugins/Obi/Scripts/Common/Backends/Burst/Solver/BurstSolverImpl.cs:658)
Obi.ObiSolver.Substep (System.Single substepTime) (at Assets/Plugins/Obi/Scripts/Common/Solver/ObiSolver.cs:1425)
Obi.ObiUpdater.Substep (System.Single substepDeltaTime) (at Assets/Plugins/Obi/Scripts/Common/Updaters/ObiUpdater.cs:77)
Obi.ObiFixedUpdater.FixedUpdate () (at Assets/Plugins/Obi/Scripts/Common/Updaters/ObiFixedUpdater.cs:62)

InvalidOperationException: The previously scheduled job BurstParticleCollisionConstraintsBatch:UpdateParticleContactsJob reads from the NativeArray UpdateParticleContactsJob.velocities. You are trying to schedule a new job ApplyInertialForcesJob, which writes to the same NativeArray (via ApplyInertialForcesJob.velocities). To guarantee safety, you must include BurstParticleCollisionConstraintsBatch:UpdateParticleContactsJob as a dependency of the newly scheduled job.
Unity.Jobs.LowLevel.Unsafe.JobsUtility.ScheduleParallelFor (Unity.Jobs.LowLevel.Unsafe.JobsUtility+JobScheduleParameters& parameters, System.Int32 arrayLength, System.Int32 innerloopBatchCount) (at <8691ad7005ed4755a1828378ff0b52b1>:0)
Unity.Jobs.IJobParallelForExtensions.Schedule[T] (T jobData, System.Int32 arrayLength, System.Int32 innerloopBatchCount, Unity.Jobs.JobHandle dependsOn) (at <8691ad7005ed4755a1828378ff0b52b1>:0)
Obi.BurstSolverImpl.ApplyFrame (System.Single worldLinearInertiaScale, System.Single worldAngularInertiaScale, System.Single deltaTime) (at Assets/Plugins/Obi/Scripts/Common/Backends/Burst/Solver/BurstSolverImpl.cs:251)
Obi.ObiSolver.UpdateTransformFrame (System.Single dt) (at Assets/Plugins/Obi/Scripts/Common/Solver/ObiSolver.cs:1359)
Obi.ObiSolver.BeginStep (System.Single stepTime) (at Assets/Plugins/Obi/Scripts/Common/Solver/ObiSolver.cs:1386)
Obi.ObiUpdater.BeginStep (System.Single stepDeltaTime) (at Assets/Plugins/Obi/Scripts/Common/Updaters/ObiUpdater.cs:47)
Obi.ObiFixedUpdater.FixedUpdate () (at Assets/Plugins/Obi/Scripts/Common/Updaters/ObiFixedUpdater.cs:54)


Then console is spamming these errors:
Quote:InvalidOperationException: The previously scheduled job ApplyCollisionConstraintsBatchJob writes to the NativeArray ApplyCollisionConstraintsBatchJob.positions. You are trying to schedule a new job InterpolationJob, which reads from the same NativeArray (via InterpolationJob.positions). To guarantee safety, you must include ApplyCollisionConstraintsBatchJob as a dependency of the newly scheduled job.
Unity.Jobs.LowLevel.Unsafe.JobsUtility.ScheduleParallelFor (Unity.Jobs.LowLevel.Unsafe.JobsUtility+JobScheduleParameters& parameters, System.Int32 arrayLength, System.Int32 innerloopBatchCount) (at <8691ad7005ed4755a1828378ff0b52b1>:0)
Unity.Jobs.IJobParallelForExtensions.Schedule[T] (T jobData, System.Int32 arrayLength, System.Int32 innerloopBatchCount, Unity.Jobs.JobHandle dependsOn) (at <8691ad7005ed4755a1828378ff0b52b1>:0)
Obi.BurstSolverImpl.ApplyInterpolation (Obi.ObiNativeVector4List startPositions, Obi.ObiNativeQuaternionList startOrientations, System.Single stepTime, System.Single unsimulatedTime) (at Assets/Plugins/Obi/Scripts/Common/Backends/Burst/Solver/BurstSolverImpl.cs:800)
Obi.ObiSolver.Interpolate (System.Single stepTime, System.Single unsimulatedTime) (at Assets/Plugins/Obi/Scripts/Common/Solver/ObiSolver.cs:1492)
Obi.ObiUpdater.Interpolate (System.Single stepDeltaTime, System.Single accumulatedTime) (at Assets/Plugins/Obi/Scripts/Common/Updaters/ObiUpdater.cs:115)
Obi.ObiFixedUpdater.Update () (at Assets/Plugins/Obi/Scripts/Common/Updaters/ObiFixedUpdater.cs:79)

InvalidOperationException: The previously scheduled job PredictPositionsJob reads from the NativeArray PredictPositionsJob.activeParticles. You must call JobHandle.Complete() on the job PredictPositionsJob, before you can write to the NativeArray safely.
Unity.Collections.LowLevel.Unsafe.AtomicSafetyHandle.CheckWriteAndBumpSecondaryVersion (Unity.Collections.LowLevel.Unsafe.AtomicSafetyHandle handle) (at <8691ad7005ed4755a1828378ff0b52b1>:0)
Unity.Collections.NativeList`1[T].Resize (System.Int32 length, Unity.Collections.NativeArrayOptions options) (at Library/PackageCache/com.unity.collections@0.8.0-preview.5/Unity.Collections/NativeList.cs:593)
Unity.Collections.NativeList`1[T].ResizeUninitialized (System.Int32 length) (at Library/PackageCache/com.unity.collections@0.8.0-preview.5/Unity.Collections/NativeList.cs:605)
Obi.BurstSolverImpl.SetActiveParticles (System.Int32[] indices, System.Int32 num) (at Assets/Plugins/Obi/Scripts/Common/Backends/Burst/Solver/BurstSolverImpl.cs:270)
Obi.ObiSolver.PushActiveParticles () (at Assets/Plugins/Obi/Scripts/Common/Solver/ObiSolver.cs:1253)
Obi.ObiSolver.BeginStep (System.Single stepTime) (at Assets/Plugins/Obi/Scripts/Common/Solver/ObiSolver.cs:1379)
Obi.ObiUpdater.BeginStep (System.Single stepDeltaTime) (at Assets/Plugins/Obi/Scripts/Common/Updaters/ObiUpdater.cs:47)
Obi.ObiFixedUpdater.FixedUpdate () (at Assets/Plugins/Obi/Scripts/Common/Updaters/ObiFixedUpdater.cs:54)

Unity 2019.4.11f1
Obi Cloth v.5.6
Packages manifest:
Code:
{
  "dependencies": {
    "com.unity.2d.sprite": "1.0.0",
    "com.unity.2d.tilemap": "1.0.0",
    "com.unity.addressables": "1.8.5",
    "com.unity.ads": "3.4.9",
    "com.unity.analytics": "3.3.5",
    "com.unity.burst": "1.3.7",
    "com.unity.collab-proxy": "1.2.16",
    "com.unity.collections": "0.9.0-preview.6",
    "com.unity.ide.rider": "1.1.4",
    "com.unity.ide.vscode": "1.2.1",
    "com.unity.inputsystem": "1.0.0",
    "com.unity.mathematics": "1.2.1",
    "com.unity.multiplayer-hlapi": "1.0.6",
    "com.unity.postprocessing": "2.2.2",
    "com.unity.purchasing": "2.1.0",
    "com.unity.quicksearch": "1.4.1",
    "com.unity.test-framework": "1.1.16",
    "com.unity.textmeshpro": "2.0.1",
    "com.unity.timeline": "1.2.6",
    "com.unity.ugui": "1.0.0",
    "com.unity.xr.legacyinputhelpers": "2.1.4",
    "com.unity.modules.ai": "1.0.0",
    "com.unity.modules.androidjni": "1.0.0",
    "com.unity.modules.animation": "1.0.0",
    "com.unity.modules.assetbundle": "1.0.0",
    "com.unity.modules.audio": "1.0.0",
    "com.unity.modules.cloth": "1.0.0",
    "com.unity.modules.director": "1.0.0",
    "com.unity.modules.imageconversion": "1.0.0",
    "com.unity.modules.imgui": "1.0.0",
    "com.unity.modules.jsonserialize": "1.0.0",
    "com.unity.modules.particlesystem": "1.0.0",
    "com.unity.modules.physics": "1.0.0",
    "com.unity.modules.physics2d": "1.0.0",
    "com.unity.modules.screencapture": "1.0.0",
    "com.unity.modules.terrain": "1.0.0",
    "com.unity.modules.terrainphysics": "1.0.0",
    "com.unity.modules.tilemap": "1.0.0",
    "com.unity.modules.ui": "1.0.0",
    "com.unity.modules.uielements": "1.0.0",
    "com.unity.modules.umbra": "1.0.0",
    "com.unity.modules.unityanalytics": "1.0.0",
    "com.unity.modules.unitywebrequest": "1.0.0",
    "com.unity.modules.unitywebrequestassetbundle": "1.0.0",
    "com.unity.modules.unitywebrequestaudio": "1.0.0",
    "com.unity.modules.unitywebrequesttexture": "1.0.0",
    "com.unity.modules.unitywebrequestwww": "1.0.0",
    "com.unity.modules.vehicles": "1.0.0",
    "com.unity.modules.video": "1.0.0",
    "com.unity.modules.vr": "1.0.0",
    "com.unity.modules.wind": "1.0.0",
    "com.unity.modules.xr": "1.0.0"
  }
}

Print this item