Posts

Showing posts from February, 2020

Animating with null objects

Good news dearest readers, Although the positions of mixamo animations can be adjusted using pivot objects, these said objects are very difficult to keyframe in an animation sequence. Instead I am now using null (empty) objects to move my character while he moves simultaneously according to his mixamo sequence. Having separate null position controllers allows me to have a much cleaner workflow and better visualize the animation sequence in C4D's timeline. 1

HUGE UPDATE: I CAN ANIMATE IN C4D

I have no idea why this never occured to me. But guess what. I can animate my character in cinema4d baby!!! This is gonna make the animation so so so much easier. I know it. Unity is incredibly annoying, probably because I'm so new to it, when it comes to animating my character. What's cool is that once I render the animation in c4d, I can import it along with my character into Unity and still have my outfit selection script play on command using Unity's built in timeline. Unity's playable director keeps track of the time, so I can trigger the outfit selector whenever I want using a trigger object like in the last post, or by using playableDirector.time. Yay!

Using triggers to start timeline animations

Image
This is where I'm at now... As you can see my character starts in the incorrect position (inside the ground plane after the T-pose). However this in itself is considerable progress because I now have my outfit chooser script starting after a few seconds instead of when the scene first initializes. This was accomplished using a collider object as per this YouTube video . When the animated (and invisible) collider object touches my character, the script is triggered.

Adding objects to characters in Unity

So I've finally figured out a proper way to add objects (in this case, VR goggles) to my unity 3d characters. It's much simpler than any of the tutorials I've found on the subject which didn't even work. Now I can control via bool script whether or not my character is wearing any object in the scene: if (animator.GetBool("OutfitSwitch") == true) GameObject.Find("vr_headset").transform.localScale = new Vector3(0.01f, 0.01f, 0.01f); I can control the scale of the clothing item and make it appear to disappear by using transform.localScale to change its size vector to (0,0,0) My next step is to add clothing items to an array and cycle through them