Wednesday, May 20, 2020

FMP: Week 20 Wednesday

On Wednesday, I went back to the foot IK to try and get it working. In the end, I had to reduce it significantly, and remove the hip offset as it was glitching the player up and down every now and again, especially when jumping. Another reason I had to dampen the effect was that the horse link really didn't like being pushed up too much, which is understandable considering the anatomy.
Leg IK hooked up to the animation
Once again, hooking up to the custom function
Hooking the socket locations into the custom functions, then picking only the leg with the highest difference so that one leg will always be touching the ground. I implemented this after watching both legs go up at the same time once and thinking: 'why would you crouch like that when you can just stand...'
I used sphere trace this time, so that the trace wouldn't accidentally find a gap between collision boxes, and would instead be thick enough to ignore it and hit the surface edges instead.
I compiled once again, (also a few times after that while I was trying to figure out what would give the best results) and tested in scene:
Time to test all of the surfaces!
Smooth alpha lerp between the current leg position and the new one
I found that the IK system liked some collisions, but didn't work for others, and especially didn't like being directly on the edge of a tall collision box:
please make your mind up about being up or down... please...

No comments:

Post a Comment