Skip to content

Commit

Permalink
no dead body on freeplay thing idk
Browse files Browse the repository at this point in the history
  • Loading branch information
DillyzThe1 committed Feb 5, 2023
1 parent a5e480b commit d831305
Showing 1 changed file with 11 additions and 8 deletions.
19 changes: 11 additions & 8 deletions DillyzLegacyPack/RecordedObject.cs
Original file line number Diff line number Diff line change
Expand Up @@ -122,14 +122,17 @@ void RewindFrame() {
if (storedTime.isDead)
{
this.pc.Die(DeathReason.Kill, false);
DeadBody deadBody = UnityEngine.Object.Instantiate(this.pc.KillAnimations[0].bodyPrefab);
deadBody.enabled = true;
deadBody.ParentId = this.pc.PlayerId;
this.pc.SetPlayerMaterialColors(deadBody.bodyRenderer);
this.pc.SetPlayerMaterialColors(deadBody.bloodSplatter);
Vector3 vector = this.pc.transform.position + this.pc.KillAnimations[0].BodyOffset;
vector.z = vector.y / 1000f;
deadBody.transform.position = vector;
if (!DillyzUtil.roleIsGhost(this.pc))
{
DeadBody deadBody = UnityEngine.Object.Instantiate(this.pc.KillAnimations[0].bodyPrefab);
deadBody.enabled = true;
deadBody.ParentId = this.pc.PlayerId;
this.pc.SetPlayerMaterialColors(deadBody.bodyRenderer);
this.pc.SetPlayerMaterialColors(deadBody.bloodSplatter);
Vector3 vector = this.pc.transform.position + this.pc.KillAnimations[0].BodyOffset;
vector.z = vector.y / 1000f;
deadBody.transform.position = vector;
}
}
else
{
Expand Down

0 comments on commit d831305

Please sign in to comment.