架設幻獸帕魯(Palworld)

-架設幻獸帕魯(Palworld)-


架設幻獸帕魯(Palworld)


1.基本套件apt update -y

add-apt-repository multiverse; sudo dpkg --add-architecture i386; sudo apt update
apt install steamcmd -y  #安裝會跳出提醒,直接下一步與同意即可。
timedatectl set-timezone Asia/Taipei

 

2.建立使用者

adduser steam #建立使用者
- 依照資訊隨便輸入
usermod -aG sudo steam #讓用戶加入sudo,擁有近乎root權限
vi /etc/ssh/sshd_config
#------------ #禁止自己使用者被SSH連線,(空白隔開可以輸入多個用戶)
DenyUsers steam
#---------------
su steam #登入使用者
 

3.安裝帕魯

export PATH=$PATH:/usr/games #設定環境變數

mkdir -p /home/steam/data #建立安裝路徑的文件夾
cd /home/steam/data #前往路徑
steamcmd #啟動steam
force_install_dir /home/steam/data/ #設定預設路徑
login anonymous #登入任何人
app_update 2394010 validate #安裝
exit #離開
/home/steam/data/./PalServer.sh #啟動
#log 中出現 Setting breakpad minidump AppID = 2394010 那就是啟動成功了
#複製預設參數到實際使用文件
cp /home/steam/data/DefaultPalWorldSettings.ini /home/steam/data/Pal/Saved/Config/LinuxServer/PalWorldSettings.ini

4.運行時出現以下錯誤找不到 steamclient.so

mkdir -p /home/steam/.steam/sdk64
ln -s /home/steam/data/linux64/steamclient.so /home/steam/.steam/sdk64/steamclient.so
/home/steam/data/./PalServer.sh #啟動


 

5.設定systemd服務

sudo vi /etc/systemd/system/palserver.service
#----加入以下-----------
[Unit]
Description=Palworld Server

Wants=network-online.target

[Service]
Type=simple
User=steam
WorkingDirectory=/home/steam/data/
ExecStart=/bin/bash -c "./PalServer.sh"
# 如果要啟用非同步,多線程可以用下面的指令,把上面的 ExecStart 給 # 註解
#ExecStart=/bin/bash -c "./PalServer.sh -useperfthreads -NoAsyncLoadingThread -UseMultithreadForDS"
Restart=always

[Install]
WantedBy=multi-user.target
#--------------
sudo systemctl daemon-reload
sudo systemctl enable palserver
sudo systemctl start palserver
sudo systemctl status palserver
 

6.防火牆設定

ufw allow 8211
ufw allow 27015
ufw allow 1985

##幻獸帕魯配置文件設定值

vi /home/steam/data/Pal/Saved/Config/LinuxServer/PalWorldSettings.ini
#預設就有不用輸入

 

[/Script/Pal.PalGameWorldSettings]

OptionSettings=(Difficulty=None,DayTimeSpeedRate=1.500000,NightTimeSpeedRate=1.500000,ExpRate=4.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=3.000000,CollectionObjectHpRate=1.000000,CollectionObjectRespawnSpeedRate=1.000000,EnemyDropItemRate=1.000000,DeathPenalty=None,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="伺服器名字",ServerDescription="伺服器介紹",AdminPassword="",ServerPassword="",PublicPort=8211,PublicIP="",RCONEnabled=False,RCONPort=25575,Region="",bUseAuth=True,BanListURL="https://api.palworldgame.com/api/banlist.txt")

 

 

##如何更新伺服器版本

##Linux server版本更新:steamcmd #啟動steam
su steam
steamcmd #啟動steam
force_install_dir /home/steam/data/ #設定預設路徑
login anonymous #登入任何人
app_update 2394010 validate #安裝
exit #離開
sudo systemctl restart palserver

返回上一頁