Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Help  Replace pin constraint in runtime?
#5
(11-04-2018, 01:24 PM)Karlanton Wrote: https://gyazo.com/1209171286ff574f67ac3cecb6e3a6f9


With this code the pin constraint gets removed from the seleted particle in the "edit particle" tab.

However, the rope is still attached to the gameobject. why is that?


[quote pid='1571' dateline='1523449457']
i also found this:
http://obi.virtualmethodstudio.com/forum...d-229.html

They seem to have the same issue as i do.

[/quote]

You must remove the constraints component (constraints.RemoveFromSolver(null)) from the solver and re-add them (constraints.AddToSolver(null)) after. If you just remove, add or modify constraints while they're in the solver, the changes won't be pushed to the solver. Please read the docs:
http://obi.virtualmethodstudio.com/tutor...aints.html
Reply


Messages In This Thread
Replace pin constraint in runtime? - by Karlanton - 09-04-2018, 12:53 PM
RE: Replace pin constraint in runtime? - by josemendez - 11-04-2018, 02:31 PM