From f1f3d40f7785cdd481796dfaa01a8230cf7e1b29 Mon Sep 17 00:00:00 2001 From: Crypto137 Date: Sun, 15 Jan 2023 11:17:08 +0300 Subject: [PATCH] Move corpse res charge reset to checkpoint --- .../GSSystem/ActorSystem/Implementations/Checkpoint.cs | 1 + src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Player.cs | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/DiIiS-NA/D3-GameServer/GSSystem/ActorSystem/Implementations/Checkpoint.cs b/src/DiIiS-NA/D3-GameServer/GSSystem/ActorSystem/Implementations/Checkpoint.cs index 349a0ea..184a5f5 100644 --- a/src/DiIiS-NA/D3-GameServer/GSSystem/ActorSystem/Implementations/Checkpoint.cs +++ b/src/DiIiS-NA/D3-GameServer/GSSystem/ActorSystem/Implementations/Checkpoint.cs @@ -33,6 +33,7 @@ namespace DiIiS_NA.GameServer.GSSystem.ActorSystem.Implementations }); player.CheckPointPosition = this.Position; + player.Attributes[GameAttribute.Corpse_Resurrection_Charges] = 3; // Reset corpse resurrection charges } } diff --git a/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Player.cs b/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Player.cs index 9a3fa30..7ad5235 100644 --- a/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Player.cs +++ b/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Player.cs @@ -1336,6 +1336,8 @@ namespace DiIiS_NA.GameServer.GSSystem.PlayerSystem this.Attributes[GameAttribute.Hitpoints_Cur] = this.Attributes[GameAttribute.Hitpoints_Max_Total]; + this.Attributes[GameAttribute.Corpse_Resurrection_Charges] = 3; + //TestOutPutItemAttributes(); //Activate this only for finding item stats. this.Attributes.BroadcastChangedIfRevealed(); @@ -2462,8 +2464,6 @@ namespace DiIiS_NA.GameServer.GSSystem.PlayerSystem } } - this.Attributes[GameAttribute.Corpse_Resurrection_Charges] = 3; // Reset resurrection charges on zone change (TODO: do not reset charges on reentering the same zone) - #if DEBUG Logger.Warn("Местоположение игрока {0}, Scene: {1} SNO: {2} LevelArea: {3}", this.Toon.Name, this.CurrentScene.SceneSNO.Name, this.CurrentScene.SceneSNO.Id, this.CurrentScene.Specification.SNOLevelAreas[0]); #else