ConstructionWand/src/main/java/thetadev/constructionwand/basics/option/IOption.java
Theta-Dev bb3d36fa56 BIG Refactoring.
Modular WandActions and WandSuppliers.
Wand Cores and Wand Reservoirs can be added to your wand, they determine which action and supplier gets used.
2021-02-14 02:20:53 +01:00

36 lines
764 B
Java

package thetadev.constructionwand.basics.option;
import thetadev.constructionwand.ConstructionWand;
public interface IOption<T>
{
String getKey();
String getValueString();
void setValueString(String val);
default String getKeyTranslation() {
return ConstructionWand.MODID + ".option." + getKey();
}
default String getValueTranslation() {
return ConstructionWand.MODID + ".option." + getKey() + "." + getValueString();
}
default String getDescTranslation() {
return ConstructionWand.MODID + ".option." + getKey() + "." + getValueString() + ".desc";
}
boolean isEnabled();
void set(T val);
T get();
T next(boolean dir);
default T next() {
return next(true);
}
}