docker-palworld-dedicated-server icon indicating copy to clipboard operation
docker-palworld-dedicated-server copied to clipboard

[Bug Report] PAL_AUTO_HP_REGENE_RATE_IN_SLEEP replaced by other var

Open TsunaLamperouge opened this issue 1 year ago • 2 comments

Have you read the Important information text above

  • [X] Yes i did

Current behavior

In the script theres an extra SED command to replace PAL_AUTO_HP_REGENE_RATE_IN_SLEEP with the BUILD_OBJECT_DETERIORATION_DAMAGE_RATE value.

Desired behavior

PAL_AUTO_HP_REGENE_RATE_IN_SLEEP only being replaced by its own environment var.

Links to screenshots

No response

To Reproduce

Line 152 of servermanager.sh

if [[ ! -z ${BUILD_OBJECT_DETERIORATION_DAMAGE_RATE+x} ]]; then echo "> Setting PalAutoHpRegeneRateInSleep to $BUILD_OBJECT_DETERIORATION_DAMAGE_RATE" sed -E -i "s/PalAutoHpRegeneRateInSleep=[+-]?([0-9]*[.])?[0-9]+/PalAutoHpRegeneRateInSleep=$BUILD_OBJECT_DETERIORATION_DAMAGE_RATE/" ${GAME_PATH}/Pal/Saved/Config/LinuxServer/PalWorldSettings.ini fi

Software setup

  • OS: Linux
  • Docker:

Hardware setup

  • vCPU: 4
  • RAM: 16Gb
  • Disk:400gb

Additional context

No response

TsunaLamperouge avatar Jan 28 '24 21:01 TsunaLamperouge

Thank your for pointing this out, thought something was off but couldn't figure it out. I just checked my PalWorldSettings.ini BUILD_OBJECT_DETERIORATION_DAMAGE_RATE is set "0" but PAL_AUTO_HP_REGENE_RATE_IN_SLEEP also.

tipanic avatar Jan 29 '24 08:01 tipanic

I changed the values to the following in the servermanager.sh on my environment, started the container, and its now working as it should.

if [[ ! -z ${PAL_AUTO_HP_REGENE_RATE_IN_SLEEP+x} ]]; then
    echo "Setting PalAutoHpRegeneRateInSleep to $PAL_AUTO_HP_REGENE_RATE_IN_SLEEP"
    sed -E -i "s/PalAutoHpRegeneRateInSleep=[+-]?([0-9]*[.])?[0-9]+/PalAutoHpRegeneRateInSleep=$PAL_AUTO_HP_REGENE_RATE_IN_SLEEP/" ${GAME_PATH}/Pal/Saved/Config/LinuxServer/PalWorldSettings.ini 
fi

tipanic avatar Jan 29 '24 14:01 tipanic

Hey @TsunaLamperouge you are right, thanks for reporting it, sorry about that, we had some massive merges and updates of the code. Im to blame for that. #137 fixed that.

jammsen avatar Jan 30 '24 09:01 jammsen