Package graphics.common

Examples of graphics.common.Velocity.modify()


            double modifier = mTime / delta;
            double deltaDecay = mShouldApplyDecay ? mDeltaDecayRate : 1.0;
            mVelDelta.modify( mVelDelta.getXPart() * modifier * deltaDecay,
                    mVelDelta.getYPart() * modifier * deltaDecay,
                    mVelDelta.getZPart() * modifier * deltaDecay );
            vel.modify( mVelDelta.getXPart(), mVelDelta.getYPart(), mVelDelta.getZPart() );

            // Make sure the modified velocity does not go below/above a certain amount
            // so that something doesn't either reverse velocity, or slow down
            // so much that it does not actually get to where it needs to go.

View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.