Hi all. Have issue with simulate rigid bodies and states. It simply doesn't work, though Simulate Rigid Bodies connected to Execute Every Frame slot.
Does anybody know the solution.
P.S. It works with "if" structure, but I want the "States" solution.
Thank You.
States and Rigid Bodies question
Re: States and Rigid Bodies question
The state compounds weren't designed for rigid bodies, so you'll need to set up your own state system. At its core a state is just really an integer attribute used to control which branches get executed on which particles.
I've also discovered that the Simulate Rigid Bodies node will keep simulating any particle that it has already simulated, so instead of having a Simulate Rigid Bodies node for each state, you should use only one for the whole tree. For example, use a Select Case node based on state_id to control state switching behaviour, another Select Case to set forces and other attributes based on state_id, then one Simulate Rigid Bodies node for all particles.
I've also discovered that the Simulate Rigid Bodies node will keep simulating any particle that it has already simulated, so instead of having a Simulate Rigid Bodies node for each state, you should use only one for the whole tree. For example, use a Select Case node based on state_id to control state switching behaviour, another Select Case to set forces and other attributes based on state_id, then one Simulate Rigid Bodies node for all particles.
Re: States and Rigid Bodies question
Thank You for answer. It is not very coomfortable, but I'll use ''case".
Re: States and Rigid Bodies question
You could, if you wanted to, explore inside the "state" node. Within the state node there's a Simulate Particles node built in. You can replace that with Simulate Rigid Bodies and whichever collision objects you need plugged into it.
some cons to this approach though:
- You'd have to do this for each state you use
- you can't mix rigid body and particle simulation nodes (must be either one or the other)
- collisions are a bit less reliable. Not sure why...
some cons to this approach though:
- You'd have to do this for each state you use
- you can't mix rigid body and particle simulation nodes (must be either one or the other)
- collisions are a bit less reliable. Not sure why...
Who is online
Users browsing this forum: No registered users and 47 guests