---
name: "getMissionConfigValue"
type: command
status: ok
groups: ["Config", "Mission Information"]
arma3_since: "1.56"
locality: {"argument": null, "effect": null, "server_exec": false}
source: https://community.bistudio.com/wiki/getMissionConfigValue
revid: 352827
updated: 2024-02-22T21:48:04Z
---

# getMissionConfigValue

*Command · Config, Mission Information · Arma 3 v1.56*

## Description

Returns value of the given scenario attribute from the 1st tier. Since only config properties have values, the attribute should be config property.
If it is not found or config class is given, the return is [nil](../commands/nil.md). If the attribute defined in multiple places, the command checks them in the following order:
1. [Description.ext](../topics/Description.ext.md) entry
1. Eden Editor scenario attribute

So if an attribute exists in both places, the [Description.ext](../topics/Description.ext.md) value is used.
Previously, scenario attributes were extracted from Description.ext using [missionConfigFile](../commands/missionConfigFile.md).
That still works, but it ignores attributes set directly in the editor and should not be used anymore.

> [!IMPORTANT]
> This command cannot force return type, it will return the value of the type given in config. Use [isEqualType](../commands/isEqualType.md) to additionally reaffirm the correct type if necessary to account for human error.

## Syntax

### Syntax 1

```sqf
getMissionConfigValue attribute
```

**Parameters:**

- `attribute`: [String](../topics/String.md) - attribute name

**Returns:** [Number](../topics/Number.md), [String](../topics/String.md), [Boolean](../topics/Boolean.md) or [Array](../topics/Array.md), depending on the attribute value type. [Nil](../commands/nil.md) when the attribute is undefined.

### Syntax 2

```sqf
getMissionConfigValue [attribute, defaultValue]
```

**Parameters:**

- `attribute`: [String](../topics/String.md) - attribute name
- `defaultValue`: [Anything](../topics/Anything.md) - value used when the attribute is undefined

**Returns:** [Number](../topics/Number.md), [String](../topics/String.md), [Boolean](../topics/Boolean.md) or [Array](../topics/Array.md), depending on the attribute value type. Default value when the attribute is undefined.

## Examples

### Example 1

```sqf
private _respawnDelay = getMissionConfigValue ["respawnDelay", 0];            // returns the real, defined respawn delay value
private _respawnDelay = getNumber (missionConfigFile >> "respawnDelay");    // old approach, ignoring the Eden Editor-set value
```

## See also

[getMissionConfig](../commands/getMissionConfig.md) · [missionConfigFile](../commands/missionConfigFile.md) · [BIS_fnc_getParamValue](../functions/BIS_fnc_getParamValue.md) · Mission Parameters

<sub>Source: [BI Community Wiki — getMissionConfigValue](https://community.bistudio.com/wiki/getMissionConfigValue) (revision 352827).</sub>
