GameServerManagers / GameServerManagers/LinuxGSM
[BUG] Ark Survival Evolved: Unable to display game details
- Dominant language
- Shell
- Stars
- 4.9k
- Forks
- 864
- PR merge metrics
- No merged PRs in 30d
Description
## User Story
As a user, I want 'arkserver details' to output server name, password and admin password.
## Basic info
- **Distro:** Debian 11
- **Game:** Ark Survival Evolved
- **Command:** details
- **LinuxGSM version:** [v22.2.1]
## Further Information
The details command always display "NOT SET" as follows:
```
Server name: NOT SET
App ID: 376030
...
Server password: NOT SET
Admin password: NOT SET
```
## To Reproduce
Steps to reproduce the behaviour:
1. Install Ark as described on website
2. Execute details command
## Expected behaviour
I expect to see server name and admin password to be displayed.
Ark seems to store `GameUserSettings.ini` with UTF-16LE encoding. Even if this file is converted with iconv, ark seems to rewrite it on next start. As `sed` is unable to parse this file we are faced with `NOT SET` strings.
With additional convertion sed works again.
See this for reference:
```
iconv -f utf-16le -t utf-8 ${servercfgfullpath} -o ${servercfgfullpath}.utf8
servername=$(sed -nr 's/^SessionName=(.*)/\1/p' "${servercfgfullpath}.utf8")
adminpassword=$(sed -nr 's/^ServerAdminPassword=(.*)/\1/p' "${servercfgfullpath}.utf8")
serverpassword=$(sed -nr 's/^ServerPassword=(.*)/\1/p' "${servercfgfullpath}.utf8")
```
Contributor guide
Assessment
This issue has not been assessed yet.