---
description: >-
  The functions list of a module, created to provide system for disabling
  controls easier and more organized
---

# Client

## cDisable.registerProcess

Function to register a control/controls disable process

```lua
function HRLib.cDisable.registerProcess(key: string|string[], processId: any)
```

Parameters description

* `key` - the control(s) to disable with this process, if more than one, the controls must be in array
* `processId` - the id to recognize the process with (it can be any value, none or nil isn't allowed, just so it can be used again to focus on the specific process)

## cDisable.doesProcessExist

Function to check if a process exists in the list by given processId

```lua
function HRLib.cDisable.doesProcessExist(processId: any): boolean
```

Parameters description

* `processId` - the id of the process you want to check

## cDisable.getProcesses

Function to get all runned processes with their processId and control(s) disabled

```lua
function HRLib.cDisable.getProcesses():
{ key: string|string[], processId: any }[]? processes
```

Return description

* `processes` - a list full of processes. Each process is a hash table with `key` — _the value with all the controls disabled from the specific process_ and `processId` — _the value with the process's id_\
  values in this list

## cDisable.removeProcess

Function to stop and remove process from the list of processes

```lua
function HRLib.cDisable.removeProcess(processId: any): boolean? success
```

Parameters description

* `processId` - the id of the process to stop and remove

Return description

* `success` - contains boolean for whether or not the removal is successful
