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.
41 lines
601 B
41 lines
601 B
package mightypork.gamecore.util.math.constraints.vect.proxy;
|
|
|
|
|
|
import mightypork.gamecore.util.math.constraints.vect.Vect;
|
|
|
|
|
|
/**
|
|
* Vect proxy with abstract method for plugging in / generating coordinates
|
|
* dynamically.
|
|
*
|
|
* @author Ondřej Hruška (MightyPork)
|
|
*/
|
|
public abstract class VectAdapter extends Vect {
|
|
|
|
/**
|
|
* @return the proxied coord
|
|
*/
|
|
protected abstract Vect getSource();
|
|
|
|
|
|
@Override
|
|
public double x()
|
|
{
|
|
return getSource().x();
|
|
}
|
|
|
|
|
|
@Override
|
|
public double y()
|
|
{
|
|
return getSource().y();
|
|
}
|
|
|
|
|
|
@Override
|
|
public double z()
|
|
{
|
|
return getSource().z();
|
|
}
|
|
|
|
}
|
|
|