# SceneSettings

Class · extends `Events` · category: Other

Source: https://github.com/playcanvas/editor-api/blob/4303c34bcee9a418297350899ad3a3f555526ec4/src/settings/scene.ts#L14

The Scene Settings API provides access to the settings of the currently loaded scene.

## Constructors

### constructor

```ts
new SceneSettings()
```

Creates new instance of the API

## Accessors

### history

```ts
get history(): ObserverHistory
```

Gets the history object for this entity

## Methods

### get

```ts
get(path: string): any
```

Gets value at path. See the [SceneSettings](https://api.playcanvas.com/editor/classes/SceneSettings.md) overview for a full list of properties.

**Parameters**

- `path` (`string`): The path

**Returns** `any`: The value

**Example**

```javascript
console.log(editor.settings.scene.get('render.fog'));
```

### has

```ts
has(path: string): boolean
```

Checks if path exists. See the [SceneSettings](https://api.playcanvas.com/editor/classes/SceneSettings.md) overview for a full list of properties.

**Parameters**

- `path` (`string`): The path

**Returns** `boolean`: True if path exists

**Example**

```javascript
console.log(editor.settings.scene.has('render.fog'));
```

### json

```ts
json(): Record<string, any>
```

Returns JSON representation of scene settings data

**Returns** `Record<string, any>`: - The data

**Example**

```javascript
console.log(editor.settings.scene.json());
```

### set

```ts
set(path: string, value: any): boolean
```

Sets value at path. See the [SceneSettings](https://api.playcanvas.com/editor/classes/SceneSettings.md) overview for a full list of properties.

**Parameters**

- `path` (`string`): The path
- `value` (`any`): The value

**Returns** `boolean`: Whether the value was set

**Example**

```javascript
editor.settings.scene.set('render.fog', 'none');
```
