JonoUWE Posted Thursday at 10:21 PM Share Posted Thursday at 10:21 PM See the Pen JYpOOK by osublake (@osublake) on CodePen I've forked Blake Bowen's amazing procedural grass pen to add a mouse movement effect, which I've got working but it's got a bug where the effect the mouse has increases over time, so it starts too subtle, goes through a sweet spot of looking natural but quickly goes past that to being too strong an effect which looks way too jittery to be natural. I've been trying lots of different stuff but no joy. I logged a few values for things like the currentSpeedMultiplier and the targetSpeedMultiplier but they seem to remain stable over time. If anyone else can spot the cause of this I would love to know! See the Pen yLdBodK by mrjonoces (@mrjonoces) on CodePen Link to comment Share on other sites More sharing options...
Rodrigo Posted Friday at 12:24 AM Share Posted Friday at 12:24 AM Hi, Blake's demos are not the simplest ones to follow and modify/enhance. There is a lot of code there and honestly I don't have time to dig into it and check where to look for. Maybe you can point us where to look exactly in order to check what could be the problem and how to solve it. Happy Tweening! Link to comment Share on other sites More sharing options...
JonoUWE Posted Saturday at 07:38 PM Author Share Posted Saturday at 07:38 PM Hey Rodrigo. Yes I appreciate it's a lot of code, I should have narrowed it down a little more. I'm pretty sure it's due to time in the 'Grass update function' section. Resetting time stops the issue but has the effect of visually resetting the scene which doesn't work. I also tried reducing other factors as time progresses which had a big improvement, but I got called away from that computer in a rush before I got a chance to push the changes and update the pen. I'll do that on Monday when I'm next at work Link to comment Share on other sites More sharing options...
JonoUWE Posted 2 hours ago Author Share Posted 2 hours ago Here's the updated pen, which definitely works better now, but does eventually suffer the same issues. See the Pen WNqNOLq by mrjonoces (@mrjonoces) on CodePen Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now