Adds documentation to appearance file

This commit is contained in:
Vicilu 2016-10-14 11:00:11 -03:00 committed by GitHub
parent 38f21e1b05
commit 466619d296

View File

@ -16,26 +16,48 @@ public class Appearance {
private final double shine;
private final Decal texture;
/**
* Main constructor
*
* @param paint the color to be used
* @param shine shine of the appearance, will be clamped between 0 and 1
* @param texture The appearance texture
*/
public Appearance(final Color paint, final double shine, final Decal texture) {
this.paint = paint;
this.shine = MathUtil.clamp(shine, 0, 1);
this.texture = texture;
}
/**
* Main constructor
*
* @param paint the color to be used
* @param shine shine of the appearance, will be clamped between 0 and 1
*/
public Appearance(final Color paint, final double shine) {
this.paint = paint;
this.shine = MathUtil.clamp(shine, 0, 1);
this.texture = null;
}
/**
* @return colr of the appearance
*/
public Color getPaint() {
return paint;
}
/**
* @return Shine of appearance
*/
public double getShine() {
return shine;
}
/**
* @return Texture used in appearance
*/
public Decal getTexture() {
return texture;
}