> For the complete documentation index, see [llms.txt](https://scripting.breeze.rip/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://scripting.breeze.rip/api/breeze/settings/colorsetting.md).

# ColorSetting

A color setting.

### Remarks

Can only be created while initializing the script.

### Example

```ts
const color = new ColorSetting(script, "Color", "The color to use.", new Color(255, 255, 255, 255));
```

### Extends

* [`Setting`](/api/breeze/settings/setting.md)

### Constructors

#### Constructor

> **new ColorSetting**(`holder`, `name`, `description`, `defaultValue`): `ColorSetting`

**Parameters**

**holder**

`object`

Can either be 'script' or a subgroup.

**name**

`string`

The name of the setting.

**description**

`string`

The description of the setting.

**defaultValue**

[`Color`](/api/breeze/util/color.md)

The default color.

**Returns**

`ColorSetting`

**Overrides**

`Setting.constructor`

#### Constructor

> **new ColorSetting**(`holder`, `name`, `description`, `defaultValue`, `allowAlpha`): `ColorSetting`

**Parameters**

**holder**

`object`

Can either be 'script' or a subgroup.

**name**

`string`

The name of the setting.

**description**

`string`

The description of the setting.

**defaultValue**

[`Color`](/api/breeze/util/color.md)

The default color.

**allowAlpha**

`boolean`

Whether the alpha channel can be changed.

**Returns**

`ColorSetting`

**Overrides**

`Setting.constructor`

### Methods

#### description()

> **description**(): `string`

**Returns**

`string`

The description of the setting.

**Inherited from**

[`Setting`](/api/breeze/settings/setting.md).[`description`](/api/breeze/settings/setting.md#description)

***

#### getValue()

> **getValue**(): [`Color`](/api/breeze/util/color.md)

**Returns**

[`Color`](/api/breeze/util/color.md)

The current color value.

***

#### name()

> **name**(): `string`

**Returns**

`string`

The name of the setting.

**Inherited from**

[`Setting`](/api/breeze/settings/setting.md).[`name`](/api/breeze/settings/setting.md#name)

***

#### setValue()

> **setValue**(`color`): `void`

**Parameters**

**color**

[`Color`](/api/breeze/util/color.md)

The color to set.

**Returns**

`void`

***

#### visible()

> **visible**(`visible`): `void`

You can use this to hide settings temporarily depending on the user config. The callback should return a boolean.

**Parameters**

**visible**

`Function`

The function to determine if the setting should be visible or not.

**Returns**

`void`

**Example**

```ts
const delay = new IntSetting("Delay", "The amount of ticks to wait in between attacks.", false);

delay.visible(() => {
	return someOtherSetting.getValue()
});
```

**Inherited from**

[`Setting`](/api/breeze/settings/setting.md).[`visible`](/api/breeze/settings/setting.md#visible)
