Back to project page Coloring-book.
The source code is released under:
Apache License
If you think the Android project Coloring-book listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package com.plattysoft.leonids.initializers; // w w w. j a v a2 s . co m import java.util.Random; import com.plattysoft.leonids.Particle; public class RotationInitiazer implements ParticleInitializer { private int mMinAngle; private int mMaxAngle; public RotationInitiazer(int minAngle, int maxAngle) { mMinAngle = minAngle; mMaxAngle = maxAngle; } @Override public void initParticle(Particle p, Random r) { int value = r.nextInt(mMaxAngle-mMinAngle)+mMinAngle; p.mInitialRotation = value; } }