Added setters to applicable MaterialData classes.
By: sunkid <sunkid@iminurnetz.com>
This commit is contained in:
@@ -37,6 +37,14 @@ public class Lever extends SimpleAttachableMaterialData implements Redstone {
|
||||
return (getData() & 0x8) == 0x8;
|
||||
}
|
||||
|
||||
/**
|
||||
* Set this lever to be powered or not.
|
||||
* @param isPowered whether the lever should be powered or not
|
||||
*/
|
||||
public void setPowered(boolean isPowered) {
|
||||
setData((byte) (isPowered ? (getData() | 0x8) : (getData() & ~0x8)));
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the face that this block is attached on
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user