Page MenuHomeFeedback Tracker

[Not Working] CleanupLifetimeDeadPlayer
Assigned, NormalPublic

Description

I've had CleanupLifetimeDeadPlayer set to 3600 (1 hour) and currently 7200 (2 hours) due to players saying when they run directly back to their body that it's not there. I personally tested this myself via in-game suicide. My tme was around 1:53pm est and the body was gone by 2:33pm est.

Not sure if there is another setting I need to adjust, but this setting is not working as intended.

Details

Severity
Major
Resolution
Open
Reproducibility
Always
Operating System
Windows 10 x64
Category
Gameplay
Steps To Reproduce

Kill yourself then freecam with COT from a distance.

Additional Information

I'll do another test to get an accurate time that the body stays.

Event Timeline

Weyland created this task.Oct 9 2019, 8:44 PM
Weyland updated the task description. (Show Details)Oct 9 2019, 8:49 PM
Weyland edited Steps To Reproduce. (Show Details)Oct 9 2019, 9:20 PM
Geez changed the task status from New to Need More Info.Oct 11 2019, 2:18 PM
Geez added a subscriber: Geez.

Hello Weyland and thank you for the report.
We have tested adjusting the lifetime but the bodies have lasted for 2 hours when using the 7200 value.
Is it possible that there is something else affecting this on your side?
Regards,
Geez

confirm CleanupLifetimeDeadPlayer broken...

Had players despawn within 30 minutes on our server, today. Our setting:

<var name="CleanupLifetimeDeadPlayer" type="0" value="3600"/>

We are lightly modded, but I can guarantee you 100% that we have nothing that would override CleanupLifetimeDeadPlayer. Is there any other cleanup process that could supersede this setting?

Hello Weyland and thank you for the report.
We have tested adjusting the lifetime but the bodies have lasted for 2 hours when using the 7200 value.
Is it possible that there is something else affecting this on your side?
Regards,
Geez

I have no clue what could be effecting this. Many of our files have modfications to them, including our Globals.xml. Would you like a copy of all modified files? I can zip them up and get them to you privately.

If you're suggesting a mod conflict, here are the collections for both of our servers...

Let me know how I can further assist.

Best,
-Weyland

Please look into this as soon as possible. I've lost too many extremely rare items that I cannot replace due to this bug. Thank you.

Lex added a subscriber: Lex.Oct 29 2019, 9:08 AM

Had players despawn within 30 minutes on our server, today. Our setting:

<var name="CleanupLifetimeDeadPlayer" type="0" value="3600"/>

We are lightly modded, but I can guarantee you 100% that we have nothing that would override CleanupLifetimeDeadPlayer. Is there any other cleanup process that could supersede this setting?

Just my guess. A player wearing a thing, each of which have their cleaning time. At the same time, the state of things (new \ worn \ damaged \ destroyed) - affects the cleaning time. Cleaning one of all the things in the body starts cleaning of all things wearing on the body with the cleaning of the character's body.

Geez added a comment.Oct 29 2019, 12:26 PM

Hello Weyland and thank you for the report.
We have tested adjusting the lifetime but the bodies have lasted for 2 hours when using the 7200 value.
Is it possible that there is something else affecting this on your side?
Regards,
Geez

I have no clue what could be effecting this. Many of our files have modfications to them, including our Globals.xml. Would you like a copy of all modified files? I can zip them up and get them to you privately.

If you're suggesting a mod conflict, here are the collections for both of our servers...

Hello Weyland.
If it is not an issue, please create a private ticket containing the xml files that are modified and also adjust the lifetime cleanup for the corpses.
Regards,
Geez

Hello Weyland and thank you for the report.
We have tested adjusting the lifetime but the bodies have lasted for 2 hours when using the 7200 value.
Is it possible that there is something else affecting this on your side?
Regards,
Geez

I have no clue what could be effecting this. Many of our files have modfications to them, including our Globals.xml. Would you like a copy of all modified files? I can zip them up and get them to you privately.

If you're suggesting a mod conflict, here are the collections for both of our servers...

Hello Weyland.
If it is not an issue, please create a private ticket containing the xml files that are modified and also adjust the lifetime cleanup for the corpses.
Regards,
Geez

Here ya go, thanks!
https://feedback.bistudio.com/T146144

Geez added a comment.Jan 17 2020, 12:40 PM

Hello again.
Are you still experiencing this problem on the latest version?
Regards,
Geez

Hello,

I tried to change this setting to 24 hours (value="86400") since the server restarts once a day and it's a low pop server, and still, bodies disappear in less than an hour.

We tested 2 cases, in each the character were not holding anything in their hands.
In one case the character got hit by a car
In the other case, the character died from sickness while driving a car.

Is this a recognized bug or something wrong in the server's settings?
Is there any other setting that might affect this setting ?

Version: 1.07.152951

Hello again.
Are you still experiencing this problem on the latest version?
Regards,
Geez

Yes, this is still an issue.

Beavis added a subscriber: Beavis.Nov 17 2020, 1:31 PM

It seems to me that bodies will be cleaned away pretty much instantly if there are no other players within the network bubble. Either that or the body sometimes simply falls through the ground and gets deleted because of that?

As a temporary fix the GraveCross mod can be used but it is a major immersion breaker for me, I really don't want to use it.

Confirmed this is still an issue

Can we please get this issue fixed for 1.11?

I have tried what was suggested of using the 7200 value, and no change in the results. The player corpse still gets cleaned up long before the timer should be completed.

My guess what could be causing this is maybe a ruined item on the corpse gets cleaned up and takes the corpse with it?

I agree, this can be a very frustrating bug. Today a player on my server died and begged me to put his stuff in a stash since body lifetimes can't be trusted. I was there within ten minutes and it had been cleared already. Sometimes the bodies stay for the intended lifetime, sometimes not - and I have not been able to find a pattern to it. It is an issue that needs to be addressed.

Geez added a comment.Jan 21 2021, 1:00 PM

Hello again.
We have been thoroughly testing this on the current version but we still are unable to produce any issues in the vanilla non modded environment. Corpses always disappear for us accordingly in the time we set them up (10 mins,1 hour and even 2 hours).

Just to make sure, are these servers you are having these problems on rented through provider, or launched from your machine through Steam?

Regards,
Geez

Very odd. I have tested on both modded and vanilla environments and bodies regularly disappear as soon as there is nobody in the net bubble close to the corpse. Sometimes within a few minutes despite the cleanup time being set to two hours or more.

Is there any limitation to what lifetimes are valid for the parameter? I'd like corpses to remain until server restart so I wanted to set the lifetime in sync with restart schedule. This obviously didn't work so I have tried with 1 hour and two hours instead, still without luck.

I have checked all my xmls and they are in order. By the way, is there any other setting in the server config that can override the Cleanup setting?

Also - did you test around vehicles? It seems it is more likely to happen if the dead player is in or near a vehicle.

I have seen this on my prod server, hosted by Gaming Deluxe, and also on my test server (both modded and vanilla) hosted on my local machine, accessed via Steam/DayZ Launcher still.

In all instances there was a real inconsistency with dead body life times.
Once or twice it would honour the value in Globals.xml but most times it appeared to pick a random value and clean up after that, sometimes within a few mins and sometimes after a couple of hours.

I ran somewhere in the region of 30-40 tests on both machines, and various configurations, and cannot find a pattern to narrow this down.

I've resorted to using the Grave Cross mod but I'd really rather just do without it if possible as it takes away from the server immersion that I'm looking for.

This is still happening. I think Expansion fixed it, but we've removed Expansion and gone back to normal. Can this be properly fixed please? Just had a player die at 17:54:44 and by the time they got back at 18:24:39, the bodies were gone. They weren't cut up as they died inside of a locked base.

Can confirm this is still happening. I have a vanilla server on a dedicated PC running through Steam. There are no mods being used, version is current. I died and my body was gone before 1 hour. I made it back to where I died within 45 minutes and all I found was the weapon that dropped from my hands when the zombies killed me.

I have been having this same issue on 2 servers, 1 vanilla and the other modded.
Dead bodies are despawning if no one is around in about 10-15 minutes it seems.

Here is my setting:
<var name="CleanupLifetimeDeadPlayer" type="0" value="3600"/>

Hello, I saw this ticket about a body disappearing and then reappearing in a moving vehicle. https://feedback.bistudio.com/T157684

Is it possible that these issues are related? Maybe the bodies aren't actually cleaned away by the server (=despawned) but somehow hidden or not loading properly for players? In other words, is it possible that the body state can cause a desync error hiding the body for nearby players?

Beavis added a comment.EditedFeb 10 2022, 2:04 PM

This is still not working properly. CleanupLifetime is not consistent with any value put into globals.xml, bodies very often disappear as soon as they are no longer within range of any player network bubbles. Sometimes they are gone in less than five minutes, sometimes they remain for the full lifetime. Something is provoking a premature cleanup.

Would it be possible to add a function to let server owners assign an actual lifetime to dead bodies like any item, making them persist for whatever the lifetime is, regardless of restarts and other factors? This would get around the problems since it seems it is hard to reproduce in "office" environment.

Hello everyone & @Geez,

I have this value set to 28800 (8 hours) on my server, but it doesn't affect anything at all.
In fact, none of the values I used ever worked.
So I've tested this again and it is clear that there is a problem with "CleanupLifetimeDeadPlayer".

Please note that:

  1. This ticket was opened almost 2.5 years ago.
  2. The following tests were performed on 3 different servers, two 1.15 stable servers and one 1.16 experimental server.
  3. We found a very simple workaround and tested it extensively.

The problem:
On CorpsesData.c, line 54: m_iMaxLifetime = m_Player.GetLifetime()
Returns the value of almost 1800 (~30 min) when a player dies.

Corpses will despawn after 30 minutes, it is a fact. I printed out the value when the process starts:
SCRIPT : [DEBUG] UpdateCorpseState :: GetLifetime: 1746

Workaround:
Since the current code relies on GetLifetime() for the dead player (which I must admit, is odd), we can set the lifetimes ourselves in types.xml, for example:

<type name="SurvivorF_Baty">
<lifetime>86400</lifetime>
</type>

As long as we use any value higher than 60 (enough time for the 30 seconds ticker to catch it), it will take the lowest value between "lifetime" from types.xml and "CleanupLifetimeDeadPlayer" from globals.xml.

So in this configuration, for example:

  • "CleanupLifetimeDeadPlayer" = 28800
  • Characters in types.xml are set to 86400

Once a player dies, the despawn time will be 28800.

In short:
All the characters classnames should to be added to types.xml with lifetime value set at least as the value of "CleanupLifetimeDeadPlayer" in globals.xml.

This workaround was tested with different times settings, varying from 60 to 86400 (60 sec - 24hrs), and worked in every test.
The only thing that does not work is persistence, the body will despawn on server restart.

I can confirm the above, I have done the same testing on a 1.15 test server and had the same results.

@tarkules nice, neat work around. can anyone share a complete list of player classnames?

@speedweasel
A complete list of characters is attached here (types_characters.xml):

Geez changed the task status from Need More Info to Assigned.Feb 18 2022, 2:52 PM

@Geez

Hello,

Is the solution to this still to do the workaround posted by tarkules?

This ticket was submitted a little over 3 years ago and I can confirm this issue still exists on vanilla - fresh install of DayZ directly from Steam with zero modifications. If someone is not in the network bubble range, the body despawns sometimes within less than 15 minutes.

Would also like to see this addressed still.

Yes, I am not sure why this hasn't been listed for patching yet. We have tested many times and determined it despawns incorrectly. tarkules fix is still the solution.

rxyyy added a subscriber: rxyyy.Sep 6 2023, 7:39 PM
This comment was removed by rxyyy.

I've been seeing this often since 1.25
is there a work around for this?
I've resorted to installing expansion and replacing bodies with graves.

I've been seeing this often since 1.25
is there a work around for this?
I've resorted to installing expansion and replacing bodies with graves.

Work-around is:

Hello everyone & @Geez,

I have this value set to 28800 (8 hours) on my server, but it doesn't affect anything at all.
In fact, none of the values I used ever worked.
So I've tested this again and it is clear that there is a problem with "CleanupLifetimeDeadPlayer".

Please note that:

  1. This ticket was opened almost 2.5 years ago.
  2. The following tests were performed on 3 different servers, two 1.15 stable servers and one 1.16 experimental server.
  3. We found a very simple workaround and tested it extensively.

    The problem: On CorpsesData.c, line 54: m_iMaxLifetime = m_Player.GetLifetime() Returns the value of almost 1800 (~30 min) when a player dies.

    Corpses will despawn after 30 minutes, it is a fact. I printed out the value when the process starts: SCRIPT : [DEBUG] UpdateCorpseState :: GetLifetime: 1746

    Workaround: Since the current code relies on GetLifetime() for the dead player (which I must admit, is odd), we can set the lifetimes ourselves in types.xml, for example:

    <type name="SurvivorF_Baty"> <lifetime>86400</lifetime> </type>

    As long as we use any value higher than 60 (enough time for the 30 seconds ticker to catch it), it will take the lowest value between "lifetime" from types.xml and "CleanupLifetimeDeadPlayer" from globals.xml.

    So in this configuration, for example:
  4. "CleanupLifetimeDeadPlayer" = 28800
  5. Characters in types.xml are set to 86400 Once a player dies, the despawn time will be 28800.

    In short: All the characters classnames should to be added to types.xml with lifetime value set at least as the value of "CleanupLifetimeDeadPlayer" in globals.xml.

    This workaround was tested with different times settings, varying from 60 to 86400 (60 sec - 24hrs), and worked in every test. The only thing that does not work is persistence, the body will despawn on server restart.
csatx added a subscriber: csatx.Oct 22 2024, 5:06 PM