# Parameters ( Clientside )

## Save Value - aphone.Clientside.SaveSetting(string name, any var)

| Parameters | Purpose     |
| ---------- | ----------- |
| Name       | Unique name |
| Var        | Value       |

{% hint style="info" %}
Internally, this use JSON format. So please read the warnings there : <https://wiki.facepunch.com/gmod/util.TableToJSON>
{% endhint %}

```
aphone.Clientside.SaveSetting("hello", true)
```

## Get Value - aphone.Clientside.GetSetting(string name, any fallback)

| Parameters | Purpose                                                    |
| ---------- | ---------------------------------------------------------- |
| Name       | Unique name                                                |
| Fallback   | If the value doesn't hold any values, will return fallback |

```
aphone.Clientside.GetSetting("GetMyName", "I don't got any name" )
```

## Create a in-game setting - aphone:RegisterParameters(string catName, string paramName, string short\_name, string var\_type, any defaultValue, function onChange)

| Parameters   | Purpose                          |
| ------------ | -------------------------------- |
| catName      | Category name                    |
| paramName    | Pretty name of the setting       |
| short\_name  | Unique name ( For SaveSetting )  |
| var\_type    | string, num or bool              |
| defaultValue | Default value                    |
| onChange     | ( Optional ) Function to execute |

```
Creating a parameter named "Hello", bool

aphone:RegisterParameters("Tutorials", "Hello It's me", "hello", "bool", false,
    function()
        print("Hello, me !")
    end)
```

## Get in-game setting value - aphone:GetParameters(string catName, string shortName, any fallback)

> The values required are the same as RegisterParameters

```
aphone:GetParameters("Tutorials", "hello", false)
```

## Change in-game parameters - aphone:ChangeParameters(string catName, string short\_name, any newvalue)

```
aphone:GetParameters("Tutorials", "hello", "Set the value to a string")
```

> The values required are the same as RegisterParameters

##


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://akulla-pro.gitbook.io/aphone/api/parameters-clientside.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
