# How to Set Up Admin & Use GM Commands on Your Soulmask Server (/docs/soulmask/admin-setup)



import { Tab, Tabs } from 'fumadocs-ui/components/tabs';
import { Step, Steps } from 'fumadocs-ui/components/steps';

Soulmask's admin system uses a GM (Game Master) password. Once authenticated, you get access to an in-game GM panel and a full set of console commands.

Setting the Admin Password [#setting-the-admin-password]

The admin password is set via **Startup** in the [XGamingServer Panel](https://panel.xgamingserver.com):

| Parameter                       | Description                            |
| ------------------------------- | -------------------------------------- |
| `-adminpsw="YourAdminPassword"` | Password to authenticate as GM in-game |

{/* Screenshot needed: Startup tab showing adminpsw variable */}

Gaining Admin In-Game [#gaining-admin-in-game]

<Steps>
  <Step>
    Open the console [#open-the-console]

    Press **`~`** (tilde) or **Numpad Minus (-)** to open the in-game console.
  </Step>

  <Step>
    Authenticate [#authenticate]

    Type:

    ```
    gm key YourAdminPassword
    ```

    This grants you GM access and opens the **GM Panel** — a visual interface for spawning items, NPCs, and managing the server.
  </Step>
</Steps>

GM Commands [#gm-commands]

All commands start with `gm` after authentication.

<Tabs items={['Player & Teleport', 'NPCs & Creatures', 'World & Weather', 'Building & Raids', 'Server Management']}>
  <Tab value="Player & Teleport">
    | Command                 | Description                           |
    | ----------------------- | ------------------------------------- |
    | `gm Go <x> <y> <z>`     | Teleport to coordinates               |
    | `gm GoF <distance> <z>` | Teleport forward by distance          |
    | `gm GoToJiTan`          | Teleport to nearest altar             |
    | `gm GPS`                | Print your current coordinates        |
    | `gm SetAttr YinShen 1`  | Become invisible to AI (0 to disable) |
    | `gm GhostMode 1`        | Fly + invisible (0 to disable)        |
    | `gm AddExp <value>`     | Add general experience                |
    | `gm AddMJExp <value>`   | Add mask experience                   |
    | `gm DengJi <level>`     | Set character level                   |
    | `gm FuHuo`              | Revive your character                 |
    | `gm XiDian`             | Reset/refund all stat points          |
    | `gm ShowInfo`           | Display detailed player info          |
    | `gm ShowMap`            | Reveal the entire map                 |
  </Tab>

  <Tab value="NPCs & Creatures">
    | Command                                                             | Description                      |
    | ------------------------------------------------------------------- | -------------------------------- |
    | `gm ZhaoMu`                                                         | Recruit the NPC you're aiming at |
    | `gm ZhuaBu`                                                         | Knock out the targeted NPC       |
    | `gm TameDongWu`                                                     | Tame the targeted animal         |
    | `gm ClearAllNpc`                                                    | Remove all NPCs from the server  |
    | `gm CreateSpecifiedMan <num> <sex>`                                 | Spawn tribesman NPCs             |
    | `gm CreateSWByClass <class> <baby> <level> <owned> <qty> <quality>` | Spawn specific NPC by class      |
    | `gm KeJiShu`                                                        | Unlock all technologies/recipes  |
    | `gm JSMJ`                                                           | Unlock all mask nodes            |
    | `gm UnLockAllMaskAndParts`                                          | Unlock all masks and parts       |
  </Tab>

  <Tab value="World & Weather">
    | Command                            | Description                                 |
    | ---------------------------------- | ------------------------------------------- |
    | `gm PrayWeather <type> <duration>` | Change weather (types 0–6)                  |
    | `gm Set24hTime <HH:mm>`            | Set time of day (24h format, e.g., `12:00`) |
    | `gm SetTimePower <multiplier>`     | Change time speed                           |
    | `gm ShuaXinZhiBei <range>`         | Respawn resources within range              |
    | `gm CuiHuiZhiBei <range>`          | Destroy vegetation within range             |
  </Tab>

  <Tab value="Building & Raids">
    | Command                                                 | Description                                |
    | ------------------------------------------------------- | ------------------------------------------ |
    | `gm ShowJianZhuTotalNumber`                             | Display total building piece count         |
    | `gm SaveJianZhuToFile <filename>`                       | Export buildings to file                   |
    | `gm LoadJianZhuFromFile <name> <split> <origin> <file>` | Import buildings from file                 |
    | `gm CuiHuiViewGongHuiJianZhuByRadius <radius>`          | Destroy all buildings within radius        |
    | `gm ShowReDu`                                           | Display invasion heat level                |
    | `gm AddReDu <value>`                                    | Increase raid heat (triggers raids sooner) |
    | `gm ClearAllReDu`                                       | Reset all invasion heat                    |
  </Tab>

  <Tab value="Server Management">
    | Command                                           | Description                      |
    | ------------------------------------------------- | -------------------------------- |
    | `gm BaoCun`                                       | Force save the world immediately |
    | `gm exit`                                         | Save and shut down the server    |
    | `gm KickPlayer <steam_id>`                        | Kick a player by SteamID         |
    | `gm LT <channel> <message>`                       | Send a chat message              |
    | `gm RefreshServerGlobalConfig`                    | Reload server configuration      |
    | `gm AddServerPermissionList <type> <steam_id>`    | Add to whitelist/blacklist       |
    | `gm RemoveServerPermissionList <type> <steam_id>` | Remove from list                 |
    | `gm EnableServerPermissionList <type> <0/1>`      | Enable/disable permission list   |
    | `gm ShowServerPermissionDetails`                  | Show all permission list details |
  </Tab>
</Tabs>

Telnet / RCON Access [#telnet--rcon-access]

For remote administration without being in-game:

Telnet (Default) [#telnet-default]

The Telnet console listens on port **18888** (TCP), localhost only by default.

```
telnet 127.0.0.1 18888
```

Commands: `help`, `quit <seconds>`, `shutdown <seconds>`

RCON (Optional) [#rcon-optional]

Enable RCON by adding to **Startup** parameters:

```
-rconpsw="YourRCONPassword" -rconport=19000
```

Connect with any Source RCON-compatible client using TCP on the configured port.

Related Guides [#related-guides]

* [Server Configuration](/docs/soulmask/server-config)
* [Connect to Your Server](/docs/soulmask/join-server)
