Rick Posted March 23, 2017 Share Posted March 23, 2017 I have first person arms model, controller, and camera. The first person arms model has a bone where the head would be. I position the camera to this bone. That works great. However, I then set the position of the arms to the controller position (raising the y up some), and this makes the arms jitter. It would seem the controller jitters pretty bad, even when not moving. How can I hide this jittering on my arms if it needs the controller position to set it's position and that position jitters like crazy? We want this setup so the arms animations control the position (in certain situations we have the camera rotation set to this bone rotation too) so we can do some interesting animations to move the camera and make more realistic camera movements in certain situations. Think player crawling through a window, having the camera position/rotation being on a bone allows the animated to get a more realistic feeling and during this activity we'd remove control from the player in moving and rotating the camera). Quote Link to comment Share on other sites More sharing options...
Josh Posted March 23, 2017 Share Posted March 23, 2017 Use the Curve function to smooth the camera Y position and position the arm height relative to the camera. Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Rick Posted March 23, 2017 Author Share Posted March 23, 2017 I need the arms to be the position for the camera though. The arms use the controller for position and the camera uses the arms for position. So positioning the arm height relative to the camera doesn't make sense in this context as the camera needs to be positioned to the arm head bone for our effects. I tried using curve to smooth the arm position from the controller but that still resulted in jitteing. Quote Link to comment Share on other sites More sharing options...
Josh Posted March 23, 2017 Share Posted March 23, 2017 Try this: currentposition.y = Math:Curve(targetposition.y, currentposition.y, 10) Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Rick Posted March 25, 2017 Author Share Posted March 25, 2017 Got that to work. This is a balancing act doing it this way, since using Curve creates a sliding effect as you move. To little value and jitters show up, to big of a value and the arms slide too much from controller and it looks strange. I think being able to get cool and realistic camera movement with certain animations will be worth it though. Quote Link to comment Share on other sites More sharing options...
Roland Posted March 25, 2017 Share Posted March 25, 2017 Lerp is a linear interpolation. Maybe that would work better? Quote Roland Strålberg Website: https://rstralberg.com Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.