Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

it is wrong that Calculating the distance. #78

Open
xiayu98020214 opened this issue May 18, 2017 · 1 comment
Open

it is wrong that Calculating the distance. #78

xiayu98020214 opened this issue May 18, 2017 · 1 comment

Comments

@xiayu98020214
Copy link

xiayu98020214 commented May 18, 2017

public boolean update (long miliseconds) {
    ............
	mCurrentX = mInitialX+mSpeedX*realMiliseconds+mAccelerationX*realMiliseconds*realMiliseconds;

............. return true;
}

x=v0t+1/2at^2 , it should be mAccelerationXrealMiliseconds*realMiliseconds/2

@plattysoft
Copy link
Owner

Good find! Thanks for reporting

I'm reluctant to change it because that will make all the animations that are currently using the acceleration parameter work wrong.

Probably for the next release with a note on changing behaviour.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants