[ol]
[/ol]
docker-compose
在 palworld-arm-docker 文件夹下面创建 docker-compose.yml 文件。
mem_limit视自己的刚才的Memory Limit调整,比如Memory Limit是 14G ,那么mem_limit就设定为 13G ,这样可以在内存泄露严重时自动重启容器。
version: '3'
services:
pal:
image: czy0612/palworld-server
restart: always
mem_limit: 13g
container_name: pal
ports:
- 8211:8211/udp
- 25575:25575/tcp
volumes:
- ./PalWorldSettings.ini:/home/steam/Steam/steamapps/common/PalServer/Pal/Saved/Config/LinuxServer/PalWorldSettings.ini
- ./palworld:/home/steam/Steam/steamapps/common/PalServer/
PalGameWorldSettings(游戏配置)
在 palworld-arm-docker 文件夹下面创建 PalWorldSettings.ini 文件。
官方文档: https://tech.palworldgame.com/optimize-game-balance
配置生成器: https://dysoncheng.github.io/PalWorldSettingGenerator/setting.html
默认配置如下,如何修改可以参考上面两个网页:
[/Script/Pal.PalGameWorldSettings]
OptionSettings=(Difficulty=None,DayTimeSpeedRate=1.000000,NightTimeSpeedRate=1.000000,ExpRate=1.000000,PalCaptureRate=1.000000,PalSpawnNumRate=1.000000,PalDamageRateAttack=1.000000,PalDamageRateDefense=1.000000,PlayerDamageRateAttack=1.000000,PlayerDamageRateDefense=1.000000,PlayerStomachDecreaceRate=1.000000,PlayerStaminaDecreaceRate=1.000000,PlayerAutoHPRegeneRate=1.000000,PlayerAutoHpRegeneRateInSleep=1.000000,PalStomachDecreaceRate=1.000000,PalStaminaDecreaceRate=1.000000,PalAutoHPRegeneRate=1.000000,PalAutoHpRegeneRateInSleep=1.000000,BuildObjectDamageRate=1.000000,BuildObjectDeteriorationDamageRate=1.000000,CollectionDropRate=1.000000,CollectionObjectHpRate=1.000000,CollectionObjectRespawnSpeedRate=1.000000,EnemyDropItemRate=1.000000,DeathPenalty=All,bEnablePlayerToPlayerDamage=False,bEnableFriendlyFire=False,bEnableInvaderEnemy=True,bActiveUNKO=False,bEnableAimAssistPad=True,bEnableAimAssistKeyboard=False,DropItemMaxNum=3000,DropItemMaxNum_UNKO=100,BaseCampMaxNum=128,BaseCampWorkerMaxNum=15,DropItemAliveMaxHours=1.000000,bAutoResetGuildNoOnlinePlayers=False,AutoResetGuildTimeNoOnlinePlayers=72.000000,GuildPlayerMaxNum=20,PalEggDefaultHatchingTime=72.000000,WorkSpeedRate=1.000000,bIsMultiplay=False,bIsPvP=False,bCanPickupOtherGuildDeathPenaltyDrop=False,bEnableNonLoginPenalty=True,bEnableFastTravel=True,bIsStartLocationSelectByMap=True,bExistPlayerAfterLogout=False,bEnableDefenseOtherGuildPlayer=False,CoopPlayerMaxNum=4,ServerPlayerMaxNum=32,ServerName="Default Palworld Server",ServerDescription="",AdminPassword="123456",ServerPassword="",PublicPort=8211,PublicIP="",RCONEnabled=True,RCONPort=25575,Region="",bUseAuth=True,BanListURL="https://api.palworldgame.com/api/banlist.txt")
运行
[ol]
看到如下信息说明服务器配置好了,马上可以冲了!
[/ol]
dlopen failed trying to load:
steamclient.so
with error:
steamclient.so: cannot open shared object file: No such file or directory
[S_API] SteamAPI_Init(): Loaded '/home/steam/.steam/sdk64/steamclient.so' OK. (First tried local 'steamclient.so')
CAppInfoCacheReadFromDiskThread took 29 milliseconds to initialize
Setting breakpad minidump AppID = 2394010
[S_API FAIL] Tried to access Steam interface SteamUser021 before SteamAPI_Init succeeded.
[S_API FAIL] Tried to access Steam interface SteamFriends017 before SteamAPI_Init succeeded.
[S_API FAIL] Tried to access Steam interface STEAMAPPS_INTERFACE_VERSION008 before SteamAPI_Init succeeded.
[S_API FAIL] Tried to access Steam interface SteamNetworkingUtils004 before SteamAPI_Init succeeded.
网络配置
如果你能拿到公网 ip ,看端口映射章节,拿不到公网 ip 看内网穿透章节。
端口映射
[ol]
[/ol]
FRP 内网穿透
FRP 教程我这里就不在赘述了,这里使用的是 0.52.3 版本。下面有一份配置可供参考。
frps 配置参考:
bindPort = 7001 #{必选} 客户端与该端口建立连接
transport.tls.enable = true
#身份验证
auth.method = "token" #{可选}身份验证方式
auth.token = "123456" #token 设置密码,用于通过身份验证创建连接
#frp 服务仪表板配置
webServer.port = 17300 #{也可自行修改端口}
webServer.addr = "0.0.0.0" #公网 ip 或者域名
webServer.user = "shellhk" #登录用户名{可自行修改}
webServer.password = "gongting521" #登录密码{可自行修改}
frpc 配置参考:
serverAddr = "114.114.115.115" #填写你的 frps 服务器
serverPort = 7001 #填写你的 frps 服务的端口
auth.token = "123456"
transport.tls.enable = true
[[proxies]]
name = "palworld-ucp"
type = "udp"
localIP = "127.0.0.1"
localPort = 8211
remotePort = 8211
[[proxies]]
name = "palworld-rcon"
type = "tcp"
localIP = "127.0.0.1"
localPort = 25575
remotePort = 25575
RCON 服务器指令
工具:
https://github.com/gorcon/rcon-cli
用法示例,12345 为之前设置的游戏参数AdminPassword,根据实际情况修改:
./rcon -a 114.114.115.115:25575 -p 123456
服务器命令表:
https://tech.palworldgame.com/server-commands
PS:
[ol]
[/ol]
看到最后麻烦给我点个赞!