Class ColorSetting
java.lang.Object
org.rusherhack.core.setting.Setting<Color>
org.rusherhack.client.api.setting.ColorSetting
- All Implemented Interfaces:
org.rusherhack.core.feature.IFeature,org.rusherhack.core.interfaces.IHideable,org.rusherhack.core.interfaces.INamed,org.rusherhack.core.serialize.ISerializable<com.google.gson.JsonElement>,org.rusherhack.core.serialize.JsonSerializable
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionColorSetting(String name, Color value) ColorSetting(String name, String description, int value) ColorSetting(String name, String description, Color value) -
Method Summary
Modifier and TypeMethodDescriptionbooleandeserializeValue(com.google.gson.JsonElement json) intgetAlpha()intgetBlue()floatintgetGreen()floatgetHue()intintgetRainbowWithOffset(int offset) intgetRed()floatgetValue()intbooleanbooleanbooleanbooleanbooleanparseValue(String string, boolean set) com.google.gson.JsonElementsetAlphaAllowed(boolean hasAlpha) voidsetAlphaAllowed(int alpha) voidsetBlue(int blue) setChangeAction(Runnable run) voidsetGreen(int green) voidsetHue(float hue) setRainbow(boolean rainbow) setRainbowAllowed(boolean hasRainbowOption) voidsetRainbowMode(ColorSetting.RainbowMode rainbowMode) voidsetRainbowOffset(int rainbowOffset) voidsetRed(int red) setThemeSync(boolean themeSync) setThemeSyncAllowed(boolean themeSyncAllowed) setVisibility(BooleanSupplier tester) Methods inherited from class org.rusherhack.core.setting.Setting
addSubSettings, deserialize, getAllSubSettings, getConsumer, getDefaultValue, getDescription, getDisplayName, getFullName, getName, getParent, getSubSetting, getSubSettings, isHidden, isHiddenByDefault, reset, reset, serialize, setDefaultValue, setDescription, setHidden, setShouldSerialize, setValue, setValueObj, shouldSerializeMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.rusherhack.core.interfaces.INamed
getAliasesMethods inherited from interface org.rusherhack.core.serialize.ISerializable
shouldAutoSave
-
Constructor Details
-
ColorSetting
-
ColorSetting
-
ColorSetting
-
-
Method Details
-
getRealValue
-
getValue
- Overrides:
getValuein classorg.rusherhack.core.setting.Setting<Color>
-
getDisplayValue
- Specified by:
getDisplayValuein classorg.rusherhack.core.setting.Setting<Color>
-
getRainbowWithOffset
public int getRainbowWithOffset(int offset) -
getValueRGB
public int getValueRGB() -
isRainbow
public boolean isRainbow() -
setRainbow
-
isRainbowAllowed
public boolean isRainbowAllowed() -
setRainbowAllowed
-
getRainbowMode
-
setRainbowMode
-
getRainbowOffset
public int getRainbowOffset() -
setRainbowOffset
public void setRainbowOffset(int rainbowOffset) -
isAlphaAllowed
public boolean isAlphaAllowed() -
setAlphaAllowed
-
isThemeSync
public boolean isThemeSync() -
setThemeSync
-
isThemeSyncAllowed
public boolean isThemeSyncAllowed() -
setThemeSyncAllowed
-
parseValue
- Specified by:
parseValuein classorg.rusherhack.core.setting.Setting<Color>
-
deserializeValue
public boolean deserializeValue(com.google.gson.JsonElement json) - Specified by:
deserializeValuein classorg.rusherhack.core.setting.Setting<Color>
-
serializeValue
public com.google.gson.JsonElement serializeValue()- Specified by:
serializeValuein classorg.rusherhack.core.setting.Setting<Color>
-
setVisibility
- Overrides:
setVisibilityin classorg.rusherhack.core.setting.Setting<Color>
-
setChangeAction
- Overrides:
setChangeActionin classorg.rusherhack.core.setting.Setting<Color>
-
onChange
- Overrides:
onChangein classorg.rusherhack.core.setting.Setting<Color>
-
getRed
public int getRed() -
setRed
public void setRed(int red) -
getGreen
public int getGreen() -
setGreen
public void setGreen(int green) -
getBlue
public int getBlue() -
setBlue
public void setBlue(int blue) -
getAlpha
public int getAlpha() -
setAlphaAllowed
public void setAlphaAllowed(int alpha) -
setHue
public void setHue(float hue) - Parameters:
hue- 0-1
-
getHue
public float getHue() -
getSaturation
public float getSaturation() -
getBrightness
public float getBrightness()
-