You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
35 lines
525 B
35 lines
525 B
package net.tortuga.util;
|
|
|
|
|
|
import com.porcupine.math.Calc;
|
|
|
|
|
|
/**
|
|
* Double which supports delta timing
|
|
*
|
|
* @author Ondřej Hruška (MightyPork)
|
|
*/
|
|
public class AnimDoubleDeg extends AnimDouble {
|
|
|
|
/**
|
|
* new AnimDoubleDeg
|
|
*
|
|
* @param d value
|
|
*/
|
|
public AnimDoubleDeg(double d) {
|
|
super(d);
|
|
}
|
|
|
|
|
|
/**
|
|
* Get value at delta time<br>
|
|
* <b>render(delta) MUST BE CALLED FIRST!</b>
|
|
*
|
|
* @return the value
|
|
*/
|
|
@Override
|
|
public double delta()
|
|
{
|
|
return Calc.interpolateDeg(start, end, animTime / time);
|
|
}
|
|
}
|
|
|