---
title: "add(_:)"
framework: gameplaykit
role: symbol
role_heading: Instance Method
path: "gameplaykit/gkrulesystem/add(_:)-7u5zw"
---

# add(_:)

Adds the specified list of rules to the system.

## Declaration

```swift
func add(_ rules: [GKRule])
```

## Parameters

- `rules`: An array of rule objects.

## Discussion

Discussion Adding rules to the system also adds them to the agenda list, in decreasing order of the rules’ salience values. Rules with the same salience are added to the agenda in the order of the specified array.

## See Also

### Related Documentation

- [agenda](gameplaykit/gkrulesystem/agenda.md)

### Managing a System’s List of Rules

- [rules](gameplaykit/gkrulesystem/rules.md)
- [add(_:)](gameplaykit/gkrulesystem/add(_:)-76jb5.md)
- [removeAllRules()](gameplaykit/gkrulesystem/removeallrules().md)
