You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Invoke admin commands by typing `!` followed by the command name in the chat box.
1
+
# In Game Commands
2
+
Invoke commands by typing `!` followed by the command name in the chat box. Access to commands is granted by using the player's admin_level as a bitmask.
3
3
4
-
Available commands:
4
+
### Available commands:
5
5
6
-
Name | Usage | Example | Description | Admin Required
6
+
Name | Usage | Example | Description | Command Group
7
7
---|---|---|---|---
8
-
`help`|`!help [cmd_name]`|`!help item`| Show list of commands or usage of a given command.|No
9
-
`item`|`!item <item_id>`|`!item 23`| Obtain an item of a given item_id. Item is added to inventory on disconnect.|No
10
-
`level`|`!level <level>`|`!level 10`|Set level to given value. Will reset stats and disconnect player.|No
11
-
`godmode`|`!godmode`|`!godmode`| Toggle god mode.|No
12
-
`setspawn`|`!setspawn <location_num>`|`!setspawn 1`|Set spawn point to given location (1 to 8). Will disconnect player.|No
13
-
`spawn`|`!spawn <mob_id> [amount]`|`!spawn 0 10`| Spawn a mob of a given mob_id. The amount parameter is optional.|Yes
14
-
`spawnall`|`spawnall [amount]`|`!spawnall`| Spawn all mobs in the game.|Yes
15
-
`hurt`|`!hurt`|`!hurt`| Set all nearby mobs to 1 HP.|Yes
16
-
`hurtall`|`!hurtall`|`!hurtall`| Set all mobs in the world to 1 HP.|Yes
17
-
`kill`|`!kill`|`!kill`| Kill all nearby mobs.|Yes
18
-
`killall`|`!killall`|`!killall`| Kill all mobs in the world.|Yes
19
-
`kick`|`!kick <name>`|`!kick user1`| Kick a player.|Yes
20
-
`ban`|`!ban <name>`|`!ban user1`| Ban a player.|Yes
21
-
`unban`|`!unban <name>`|`!unban user1`| Unban a player.|Yes
22
-
`setadmin`|`!setadmin <name> <true false>`|`!setadmin user1 true`| Grant or revoke admin access. This will disconnect the target user.|Yes
8
+
`help`|`!help [cmd_name]`|`!help item`| Show list of commands or usage of a given command.| Unrestricted
9
+
`setspawn`|`!setspawn <location_num>`|`!setspawn 1`|Set spawn point to given location (1 to 8). Will disconnect player.|All
10
+
`statreset`|`!statreset`|`!statreset`|Reset all stats. Will disconnect player.|All
11
+
`item`|`!item <item_id>`|`!item 23`| Obtain an item of a given item_id. Item is added to inventory on disconnect.|Group 1
12
+
`godmode`|`!godmode`|`!godmode`| Toggle god mode.|Group 1
13
+
`level`|`!level <level>`|`!level 10`|Set level to given value. Will reset stats and disconnect player.|Group 2
14
+
`spawn`|`!spawn <mob_id> [amount]`|`!spawn 0 10`| Spawn a mob of a given mob_id. The amount parameter is optional.|Group 3
15
+
`spawnall`|`spawnall [amount]`|`!spawnall`| Spawn all mobs in the game.|Group 3
16
+
`hurt`|`!hurt`|`!hurt`| Set all nearby mobs to 1 HP.|Group 3
17
+
`kill`|`!kill`|`!kill`| Kill all nearby mobs.|Group 3
18
+
`hurtall`|`!hurtall`|`!hurtall`| Set all mobs in the world to 1 HP.|Group 4
19
+
`killall`|`!killall`|`!killall`| Kill all mobs in the world.|Group 4
20
+
`kick`|`!kick <name>`|`!kick user1`| Kick a player.|Group 5
21
+
`ban`|`!ban <name>`|`!ban user1`| Ban a player.|Group 5
22
+
`unban`|`!unban <name>`|`!unban user1`| Unban a player.|Group 5
23
+
`setadmin`|`!setadmin <name> <admin_level>`|`!setadmin user1 190`| Grant or revoke admin access. This will disconnect the target user.|Admin
24
+
25
+
### Groups and Bitmasks
26
+
27
+
Access to commands is granted using the player's admin_level (class) as a bitmask.
28
+
The admin_level is a byte with 2 unused bits, thus allowing for 6 commands groups.
29
+
30
+
```text
31
+
bit 0 = unused
32
+
bit 1 = group 1 commands
33
+
bit 2 = unused
34
+
bit 3 = group 2 commands
35
+
bit 4 = group 3 commands
36
+
bit 5 = group 4 commands
37
+
bit 6 = group 5 commands
38
+
bit 7 = admin commands
39
+
```
40
+
41
+
```python
42
+
BITMASK_ALL=0b00000000
43
+
BITMASK_NONE=0b00000101
44
+
BITMASK_GROUP_1=0b00000010
45
+
BITMASK_GROUP_2=0b00001000
46
+
BITMASK_GROUP_3=0b00010000
47
+
BITMASK_GROUP_4=0b00100000
48
+
BITMASK_GROUP_5=0b01000000
49
+
BITMASK_ADMIN=0b10000000
50
+
```
51
+
52
+
Admin Level | Unrestricted Commands | Group 1 | Group 2 | Group 3 | Group 4 | Group 5 | Admin Commands
0 commit comments