- Home /
How can I tell Unity's parenting system: "For this frame, don't make this parent's translations affect its children's transforms"?
I'm making my own physically-moving-rag-doll-kinda character, and I want his one (so far) foot to move freely yet receive all of the pelvis's (the parent) translations, but sometimes I want the foot to be still (when he's making a run-step forward, adding impulse to himself). If I could tell Unity that I don't want a parent not to affect a child for a specific frame (in this case all the frames in which he's making the stride), it would be nice. I know I can make it with code, by making the foot receive all of the pelvis's translations When I want it, or, if I parent them, by making the foot have a fixedPosition vector and use it when needed to cancel the parent's movement When I want it, so there's no need to show me solution examples, I was just wondering if I can use something Unity has and I'm not aware of.
Answer by Brian-Kehrer · Jan 30, 2010 at 07:20 PM
Just set position, rotation directly:
Transform.position
Transform.rotation
as separate from:
Transform.localPosition
Transform.localRotation
The local ones take into account parent transforms, the normal ones are relative to worldspace.
I'm already aware of that, I was just wondering if I could do it without setting things myself. Thanks anyway :)
I guess the answer is, no, not really, you have to set it yourself (and probably would want to anyway).
Your answer
Follow this Question
Related Questions
Unable to launch unity 5.6.x in MacOS big sur 1 Answer
Adding a script in Editor moves GameObjects back to Origin. 1 Answer
Editor movement suddenly became very slow 2 Answers
Making a bubble level (not a game but work tool) 1 Answer
The name 'Joystick' does not denote a valid type ('not found') 2 Answers