From d2bfdd0bbeb3ffd5093436ae0637b3761337f4d8 Mon Sep 17 00:00:00 2001 From: Gitea Date: Fri, 2 Sep 2022 18:27:53 +1000 Subject: [PATCH 01/14] Network code update to 2.7.4.84161 --- .../BGS-Server/GamesSystem/GameDescriptor.cs | 2 +- .../Services/GameUtilitiesService.cs | 23 +-------- .../GSSystem/ActorSystem/Actor.cs | 1 - .../GSSystem/ItemsSystem/ItemGenerator.cs | 2 +- .../MessageSystem/GameAttirbute.List.cs | 8 +-- .../Definitions/ACD/ACDEnterKnownMessage.cs | 6 +-- .../Dungeon/UberBossClosingMessage.cs | 42 ++++++++++++++++ .../Definitions/Game/VersionsMessage.cs | 2 +- .../Inventory/UnlockableRandomAffixMessage.cs | 49 +++++++++++++++++++ .../Fields/UnlockableRandomAffixProperties.cs | 47 ++++++++++++++++++ .../D3-GameServer/MessageSystem/Opcodes.cs | 14 ++++-- src/DiIiS-NA/Program.cs | 4 +- 12 files changed, 161 insertions(+), 39 deletions(-) create mode 100644 src/DiIiS-NA/D3-GameServer/MessageSystem/Message/Definitions/Dungeon/UberBossClosingMessage.cs create mode 100644 src/DiIiS-NA/D3-GameServer/MessageSystem/Message/Definitions/Inventory/UnlockableRandomAffixMessage.cs create mode 100644 src/DiIiS-NA/D3-GameServer/MessageSystem/Message/Fields/UnlockableRandomAffixProperties.cs diff --git a/src/DiIiS-NA/BGS-Server/GamesSystem/GameDescriptor.cs b/src/DiIiS-NA/BGS-Server/GamesSystem/GameDescriptor.cs index 1bf3477..61f3347 100644 --- a/src/DiIiS-NA/BGS-Server/GamesSystem/GameDescriptor.cs +++ b/src/DiIiS-NA/BGS-Server/GamesSystem/GameDescriptor.cs @@ -31,7 +31,7 @@ namespace DiIiS_NA.LoginServer.GamesSystem public D3.OnlineService.GameCreateParams GameCreateParams { get; private set; } - public string Version = "2.7.3"; + public string Version = "2.7.4"; public ulong FactoryID { get; private set; } public KeyValuePair GServer { get; private set; } public ulong RequestId { get; private set; } diff --git a/src/DiIiS-NA/BGS-Server/ServicesSystem/Services/GameUtilitiesService.cs b/src/DiIiS-NA/BGS-Server/ServicesSystem/Services/GameUtilitiesService.cs index 86dc78b..ce1e38a 100644 --- a/src/DiIiS-NA/BGS-Server/ServicesSystem/Services/GameUtilitiesService.cs +++ b/src/DiIiS-NA/BGS-Server/ServicesSystem/Services/GameUtilitiesService.cs @@ -87,18 +87,6 @@ namespace DiIiS_NA.LoginServer.ServicesSystem.Services Init.SetGameAccountSettings(GAS); Init.SetHeroDigests(d); Init.SetAccountDigest(Client.Account.GameAccount.Digest); - /*Init.SetSyncedVars("OnlineService.Season.EarliestSeasonNum=4" + - " OnlineService.Season.Num=1" + - " OnlineService.Season.State=1" + - " OnlineService.FreeToPlay=true" + - " OnlineService.Leaderboard.Era=10" + - " OnlineService.AnniversaryEvent.Status=2" + - " ChallengeRift.ChallengeNumber=140" + - " OnlineService.Store.Status=0" + - " OnlineService.Store.ProductCatalogDigest=C42DC6117A7008EDA2006542D6C07EAD096DAD90" + - " OnlineService.Store.ProductCatalogVersion=633565800390338000" + - " OnlineService.Store.NewestProductTime=516240000000000000" + - " OnlineService.Region.Id=5");*/ Init.SetSyncedVars( " OnlineService.Season.Num=1" + //Номер сезона " OnlineService.Season.State=1" + //Статус сезона, 1 - Активирован, 0 - Деактивирован @@ -3791,7 +3779,7 @@ challenge_end_time_unix_seconds: 1583200800 var gameAccount = client.Account.GameAccount; return gameAccount.Settings.ToByteString(); } - private ByteString SetGameAccountSettings(D3.GameMessage.SetGameAccountSettings settings, BattleClient client) + private ByteString SetGameAccountSettings(SetGameAccountSettings settings, BattleClient client) { Logger.Trace("SetGameAccountSettings()"); @@ -3832,14 +3820,5 @@ challenge_end_time_unix_seconds: 1583200800 } #endregion - #region Heroes of The Storm - private ByteString FirstRequest(BattleClient Client, ClientRequest request) - { - - - return null;// res.Build().ToByteString(); - } - - #endregion } } diff --git a/src/DiIiS-NA/D3-GameServer/GSSystem/ActorSystem/Actor.cs b/src/DiIiS-NA/D3-GameServer/GSSystem/ActorSystem/Actor.cs index 7c2c343..59aa096 100644 --- a/src/DiIiS-NA/D3-GameServer/GSSystem/ActorSystem/Actor.cs +++ b/src/DiIiS-NA/D3-GameServer/GSSystem/ActorSystem/Actor.cs @@ -835,7 +835,6 @@ namespace DiIiS_NA.GameServer.GSSystem.ActorSystem snoAmbientOcclusionOverrideTex = null, MarkerSetSNO = null, MarkerSetIndex = null, - TimeActorCreated = null, EnterKnownLookOverrides = null }; } diff --git a/src/DiIiS-NA/D3-GameServer/GSSystem/ItemsSystem/ItemGenerator.cs b/src/DiIiS-NA/D3-GameServer/GSSystem/ItemsSystem/ItemGenerator.cs index 3c78137..17f0774 100644 --- a/src/DiIiS-NA/D3-GameServer/GSSystem/ItemsSystem/ItemGenerator.cs +++ b/src/DiIiS-NA/D3-GameServer/GSSystem/ItemsSystem/ItemGenerator.cs @@ -1013,7 +1013,7 @@ namespace DiIiS_NA.GameServer.GSSystem.ItemsSystem var legaDefinition = GetRandom(AllowedItems.Values .Where(def => def.ItemLevel <= Math.Min(level + 2, 73) - && !ObsoleteItems.Contains(def.Hash) //obsolete 1.0.3 items + && !ObsoleteItems.Contains(def.Hash) && UniqueItems.UniqueItemStats.ContainsKey(def.Hash) && def.Quality != ItemTable.ItemQuality.Special && (type == null ? true : ItemGroup.HierarchyToHashList(ItemGroup.FromHash(def.ItemTypesGBID)).Contains(type.Hash)) diff --git a/src/DiIiS-NA/D3-GameServer/MessageSystem/GameAttirbute.List.cs b/src/DiIiS-NA/D3-GameServer/MessageSystem/GameAttirbute.List.cs index d8a8137..bc10782 100644 --- a/src/DiIiS-NA/D3-GameServer/MessageSystem/GameAttirbute.List.cs +++ b/src/DiIiS-NA/D3-GameServer/MessageSystem/GameAttirbute.List.cs @@ -29,7 +29,7 @@ namespace DiIiS_NA.GameServer.MessageSystem ScriptedAttributeInitializer.ProcessAttributes(Attributes); } - #region 2.7.1 + #region 2.7.4 //* public static readonly GameAttributeF Axe_Bad_Data = new GameAttributeF(0, 0, -1, 0, 0, "", "", "Axe_Bad_Data", GameAttributeEncoding.Float32, 0, 0, 0, 32); public static readonly GameAttributeF Attribute_Timer = new GameAttributeF(1, 0, -1, 0, 0, "", "", "Attribute_Timer", GameAttributeEncoding.Float32, 0, 0, 0, 32); @@ -1511,9 +1511,11 @@ namespace DiIiS_NA.GameServer.MessageSystem public static readonly GameAttributeB ForcedMove = new GameAttributeB(1401, 0, -1, 0, 0, "", "", "ForcedMove", GameAttributeEncoding.IntMinMax, 0, 0, 1, 1); public static readonly GameAttributeB ReceivedPrimalWhenUnlocking = new GameAttributeB(1474, 0, -1, 0, 0, "", "", "ReceivedPrimalWhenUnlocking", GameAttributeEncoding.IntMinMax, 0, 0, 1, 1); public static readonly GameAttributeB KanaiPowersunlocked = new GameAttributeB(1475, 0, -1, 0, 0, "", "", "KanaiPowersunlocked", GameAttributeEncoding.IntMinMax, 0, 0, 1, 1); - public static readonly GameAttributeB FourthKanaisCubeSlotunlocked = new GameAttributeB(1476, 0, -1, 0, 0, "", "", "Fourth Kanai's Cube Slot unlocked", GameAttributeEncoding.IntMinMax, 0, 0, 1, 1); + public static readonly GameAttributeB FourthKanaisCubeSlotunlocked = new GameAttributeB(1476, 0, -1, 0, 0, "", "", "FourthKanai'sCubeSlotunlocked", GameAttributeEncoding.IntMinMax, 0, 0, 1, 1); public static readonly GameAttributeB Seasononlyitemsunlocked = new GameAttributeB(1477, 0, -1, 0, 0, "", "", "Season-onlyitemsunlocked", GameAttributeEncoding.IntMinMax, 0, 0, 1, 1); - public static readonly GameAttributeB Soul_shards_unlocked = new GameAttributeB(1478, 0, -1, 0, 0, "", "", "Soul shards unlocked", GameAttributeEncoding.IntMinMax, 0, 0, 1, 1); + public static readonly GameAttributeB Soul_shards_unlocked = new GameAttributeB(1478, 0, -1, 0, 0, "", "", "Soulshardsunlocked", GameAttributeEncoding.IntMinMax, 0, 0, 1, 1); + public static readonly GameAttributeB Item_was_sanctified = new GameAttributeB(1479, 0, -1, 0, 0, "", "", "Itemwassanctified", GameAttributeEncoding.IntMinMax, 0, 0, 1, 1); + public static readonly GameAttributeB Sanctified_items_unlocked = new GameAttributeB(1480, 0, -1, 0, 0, "", "", "Sanctifieditemsunlocked", GameAttributeEncoding.IntMinMax, 0, 0, 1, 1); public static readonly GameAttributeF Fiil1 = new GameAttributeF(1223, -1, -1, 0, 0, "", "", "Fiil1", GameAttributeEncoding.Float32, 0, 0, 0, 32); public static readonly GameAttributeF Fiil2 = new GameAttributeF(1224, -1, -1, 0, 0, "", "", "Fiil2", GameAttributeEncoding.Float32, 0, 0, 0, 32); diff --git a/src/DiIiS-NA/D3-GameServer/MessageSystem/Message/Definitions/ACD/ACDEnterKnownMessage.cs b/src/DiIiS-NA/D3-GameServer/MessageSystem/Message/Definitions/ACD/ACDEnterKnownMessage.cs index 006a024..8589c22 100644 --- a/src/DiIiS-NA/D3-GameServer/MessageSystem/Message/Definitions/ACD/ACDEnterKnownMessage.cs +++ b/src/DiIiS-NA/D3-GameServer/MessageSystem/Message/Definitions/ACD/ACDEnterKnownMessage.cs @@ -30,7 +30,7 @@ namespace DiIiS_NA.GameServer.MessageSystem.Message.Definitions.ACD public int? /* sno */ snoAmbientOcclusionOverrideTex; public int? MarkerSetSNO; public int? MarkerSetIndex; - public uint? TimeActorCreated; + public uint? TimeActorCreated = null; public EnterKnownLookOverrides EnterKnownLookOverrides; public ACDEnterKnownMessage() : base(Opcodes.ACDEnterKnownMessage) { } @@ -39,7 +39,7 @@ namespace DiIiS_NA.GameServer.MessageSystem.Message.Definitions.ACD { ActorID = buffer.ReadUInt(32); ActorSNOId = buffer.ReadInt(32); - Flags = buffer.ReadInt(8); + Flags = buffer.ReadInt(9); LocationType = buffer.ReadInt(2) + (-1); if (buffer.ReadBool()) { @@ -83,7 +83,7 @@ namespace DiIiS_NA.GameServer.MessageSystem.Message.Definitions.ACD { buffer.WriteUInt(32, ActorID); buffer.WriteInt(32, ActorSNOId); - buffer.WriteInt(8, Flags); + buffer.WriteInt(9, Flags); buffer.WriteInt(2, LocationType - (-1)); buffer.WriteBool(WorldLocation != null); if (WorldLocation != null) diff --git a/src/DiIiS-NA/D3-GameServer/MessageSystem/Message/Definitions/Dungeon/UberBossClosingMessage.cs b/src/DiIiS-NA/D3-GameServer/MessageSystem/Message/Definitions/Dungeon/UberBossClosingMessage.cs new file mode 100644 index 0000000..b464a93 --- /dev/null +++ b/src/DiIiS-NA/D3-GameServer/MessageSystem/Message/Definitions/Dungeon/UberBossClosingMessage.cs @@ -0,0 +1,42 @@ +using DiIiS_NA.GameServer.MessageSystem; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace DiIiS_NA.D3_GameServer.MessageSystem.Message.Definitions.Dungeon +{ + [Message(Opcodes.UberBossClosingMessage)] + public class UberBossClosingMessage : GameMessage + { + public int field0; + public int field1; + + public UberBossClosingMessage() : base(Opcodes.UberBossClosingMessage) { } + + public override void Parse(GameBitBuffer buffer) + { + field0 = buffer.ReadInt(32); + field1 = buffer.ReadInt(32); + } + + public override void Encode(GameBitBuffer buffer) + { + buffer.WriteInt(32, field0); + buffer.WriteInt(32, field1); + } + + public override void AsText(StringBuilder b, int pad) + { + b.Append(' ', pad); + b.AppendLine("SetDungeonJoinMessage:"); + b.Append(' ', pad++); + b.AppendLine("{"); + b.Append(' ', pad); b.AppendLine("field0: 0x" + field0.ToString("X8")); + b.Append(' ', pad); b.AppendLine("field1: 0x" + field1.ToString("X8")); + b.Append(' ', --pad); + b.AppendLine("}"); + } + } +} diff --git a/src/DiIiS-NA/D3-GameServer/MessageSystem/Message/Definitions/Game/VersionsMessage.cs b/src/DiIiS-NA/D3-GameServer/MessageSystem/Message/Definitions/Game/VersionsMessage.cs index d52de2d..3ea177b 100644 --- a/src/DiIiS-NA/D3-GameServer/MessageSystem/Message/Definitions/Game/VersionsMessage.cs +++ b/src/DiIiS-NA/D3-GameServer/MessageSystem/Message/Definitions/Game/VersionsMessage.cs @@ -22,7 +22,7 @@ namespace DiIiS_NA.GameServer.MessageSystem.Message.Definitions.Game { this.SNOPackHash = snoPacketHash; this.ProtocolHash = protocol; - this.Version = "DiIiS Server - 2.7.3.82753"; + this.Version = "DiIiS Server - 2.7.4.84161"; } public VersionsMessage() : base(Opcodes.VersionsMessage) { } diff --git a/src/DiIiS-NA/D3-GameServer/MessageSystem/Message/Definitions/Inventory/UnlockableRandomAffixMessage.cs b/src/DiIiS-NA/D3-GameServer/MessageSystem/Message/Definitions/Inventory/UnlockableRandomAffixMessage.cs new file mode 100644 index 0000000..f338491 --- /dev/null +++ b/src/DiIiS-NA/D3-GameServer/MessageSystem/Message/Definitions/Inventory/UnlockableRandomAffixMessage.cs @@ -0,0 +1,49 @@ +//Blizzless Project 2022 +using System; +//Blizzless Project 2022 +using System.Collections.Generic; +//Blizzless Project 2022 +using System.Linq; +//Blizzless Project 2022 +using System.Text; +//Blizzless Project 2022 +using System.Threading.Tasks; + +namespace DiIiS_NA.GameServer.MessageSystem.Message.Definitions.Inventory +{ + [Message(Opcodes.UnlockableRandomAffixMessage, Consumers.Inventory)] + public class UnlockableRandomAffixMessage : GameMessage + { + public uint ItemID; // Item's DynamicID + public int Field1; + public UnlockableRandomAffixMessage Affix; + + public override void Parse(GameBitBuffer buffer) + { + ItemID = buffer.ReadUInt(32); + Field1 = buffer.ReadInt(32); + Affix.Parse(buffer); + } + + public override void Encode(GameBitBuffer buffer) + { + buffer.WriteUInt(32, ItemID); + buffer.WriteInt(32, Field1); + Affix.Encode(buffer); + } + + public override void AsText(StringBuilder b, int pad) + { + b.Append(' ', pad); + b.AppendLine("ChangeUsableItemMessage:"); + b.Append(' ', pad++); + b.AppendLine("{"); + b.Append(' ', pad); b.AppendLine("ItemID: 0x" + ItemID.ToString("X8") + " (" + ItemID + ")"); + b.Append(' ', pad); b.AppendLine("Field1: 0x" + Field1.ToString("X8") + " (" + Field1 + ")"); + b.Append(' ', --pad); + b.AppendLine("}"); + } + + + } +} diff --git a/src/DiIiS-NA/D3-GameServer/MessageSystem/Message/Fields/UnlockableRandomAffixProperties.cs b/src/DiIiS-NA/D3-GameServer/MessageSystem/Message/Fields/UnlockableRandomAffixProperties.cs new file mode 100644 index 0000000..94df1fa --- /dev/null +++ b/src/DiIiS-NA/D3-GameServer/MessageSystem/Message/Fields/UnlockableRandomAffixProperties.cs @@ -0,0 +1,47 @@ +//Blizzless Project 2022 +using System; +//Blizzless Project 2022 +using System.Collections.Generic; +//Blizzless Project 2022 +using System.Linq; +//Blizzless Project 2022 +using System.Text; +//Blizzless Project 2022 +using System.Threading.Tasks; + +namespace DiIiS_NA.GameServer.MessageSystem.Message.Fields +{ + public class UnlockableRandomAffixProperties + { + public int field0; + public bool field1; + + public void Parse(GameBitBuffer buffer) + { + field0 = buffer.ReadInt(32); + field1 = buffer.ReadBool(); + } + + public void Encode(GameBitBuffer buffer) + { + buffer.WriteInt(32, field0); + buffer.WriteBool(field1); + } + + public void AsText(StringBuilder b, int pad) + { + b.Append(' ', pad); + b.AppendLine("UnlockableRandomAffixProperties:"); + b.Append(' ', pad++); + b.AppendLine("{"); + b.Append(' ', pad); + b.AppendLine("field0: 0x" + field0.ToString("X8")); + b.Append(' ', pad); + b.AppendLine("field1: 0x" + field1); + b.Append(' ', --pad); + b.AppendLine("}"); + } + + + } +} diff --git a/src/DiIiS-NA/D3-GameServer/MessageSystem/Opcodes.cs b/src/DiIiS-NA/D3-GameServer/MessageSystem/Opcodes.cs index 4708c27..6980607 100644 --- a/src/DiIiS-NA/D3-GameServer/MessageSystem/Opcodes.cs +++ b/src/DiIiS-NA/D3-GameServer/MessageSystem/Opcodes.cs @@ -572,7 +572,7 @@ namespace DiIiS_NA.GameServer.MessageSystem PlayerIndexMessage16 = 550,//SIZE 12 //*/ #endregion - #region 2.7.3 + #region 2.7.4 ClientTryConsoleCommand = 1,//SIZE 1060 - Client ServerTryConsoleCommand = 2,//SIZE 1060 - Server QuitGameMessage = 3,//SIZE 12 @@ -1111,10 +1111,10 @@ namespace DiIiS_NA.GameServer.MessageSystem PlayerLoadoutTabIconMessage = 534, // //SIZE16 PlayerLoadoutSaveMessage1 = 535, // //SIZE68 ANNDataMessage45 = 536, // //SIZE12 - PlayerLoadoutDataMessage = 537, // //SIZE592 - PlayerLoadoutDataMessage1 = 538, // //SIZE592 + PlayerLoadoutDataMessage = 537, // //SIZE 808 - 2.7.4 + PlayerLoadoutDataMessage1 = 538, // //SIZE 808 - 2.7.4 PlayerLoadoutTabIconMessage1 = 539, // //SIZE16 - PlayerLoadoutEquipmentUpdateMessage = 540, // //SIZE48 + PlayerLoadoutEquipmentUpdateMessage = 540, // //SIZE 64 - - 2.7.4 PlayerLoadoutEquipResultsMessage = 541, // //SIZE156 SwapSkillsMessage = 542, // //SIZE16 GBIDDataMessage5 = 543, // //SIZE12 @@ -1124,7 +1124,11 @@ namespace DiIiS_NA.GameServer.MessageSystem DWordDataMessage18 = 547, // //SIZE12 ANNDataMessage46 = 548, // //SIZE12 DungeonFinderCompletionTimeMessage = 549, // //SIZE16 - IntDataMessage26 = 550, // //SIZE12 + IntDataMessage26 = 550, // //SIZE 12 + IntDataMessage27 = 551, // //SIZE 12 - 2.7.4 + UberBossClosingMessage = 552, // //SIZE 16 - 2.7.4 + PlayerIndexMessage16 = 551, // //SIZE 12 - 2.7.4 + UnlockableRandomAffixMessage = 553, // //SIZE124 - 2.7.4 #endregion } } diff --git a/src/DiIiS-NA/Program.cs b/src/DiIiS-NA/Program.cs index 2dea975..e9ffc44 100644 --- a/src/DiIiS-NA/Program.cs +++ b/src/DiIiS-NA/Program.cs @@ -83,7 +83,7 @@ namespace DiIiS_NA public static string RESTSERVERIP = DiIiS_NA.REST.Config.Instance.IP; public static string PUBLICGAMESERVERIP = DiIiS_NA.GameServer.NATConfig.Instance.PublicIP; - public static int Build = 11; + public static int Build = 29; public static int Stage = 4; public static string TypeBuild = "Beta"; public static bool D3CoreEnabled = DiIiS_NA.GameServer.Config.Instance.CoreActive; @@ -99,7 +99,7 @@ namespace DiIiS_NA string Name = $"Blizzless: Build {Build}, Stage: {Stage} - {TypeBuild}"; Console.WriteLine(" " + Name); - Console.WriteLine("Connected Module: 0x00 - Diablo 3 RoS 2.7.3.82785"); + Console.WriteLine("Connected Module: 0x00 - Diablo 3 RoS 2.7.4.84161"); Console.WriteLine("------------------------------------------------------------------------"); Console.ResetColor(); Console.Title = Name; From d9add6cccbeca915b965545090d59389ce1633f7 Mon Sep 17 00:00:00 2001 From: pr701 Date: Fri, 2 Sep 2022 19:31:43 +0300 Subject: [PATCH 02/14] update version --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 5924c06..362f366 100644 --- a/README.md +++ b/README.md @@ -35,7 +35,7 @@ DiIiS is a fully-functional open-source local server for [Diablo III: Reaper of Each version of the client includes changes to structures, opcodes and attributes. -The currently supported version of the client: **2.7.3.82785** +The currently supported version of the client: **2.7.4.84161** ## Server Deploying From aa20980d1112926c6e461b66fbea46b999008850 Mon Sep 17 00:00:00 2001 From: Crypto137 Date: Tue, 10 Jan 2023 03:48:34 +0300 Subject: [PATCH 03/14] Fix Skill_Override GameAttribute encoding Wizard's Archon skill works again --- src/DiIiS-NA/D3-GameServer/MessageSystem/GameAttirbute.List.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/DiIiS-NA/D3-GameServer/MessageSystem/GameAttirbute.List.cs b/src/DiIiS-NA/D3-GameServer/MessageSystem/GameAttirbute.List.cs index bc10782..fbd7aff 100644 --- a/src/DiIiS-NA/D3-GameServer/MessageSystem/GameAttirbute.List.cs +++ b/src/DiIiS-NA/D3-GameServer/MessageSystem/GameAttirbute.List.cs @@ -380,7 +380,7 @@ namespace DiIiS_NA.GameServer.MessageSystem public static readonly GameAttributeF Corpse_Resurrection_Allowed_Game_Time = new GameAttributeF(807, 0, -1, 0, 0, "", "", "Corpse_Resurrection_Allowed_Game_Time", GameAttributeEncoding.Float32, 0, 0, 0, 32); public static readonly GameAttributeF Controlling_TimedEvent_SNO = new GameAttributeF(810, -1, -1, 0, 0, "", "", "Controlling_TimedEvent_SNO", GameAttributeEncoding.Float32, 0, 0, 0, 32); public static readonly GameAttributeF Spawner_Concurrent_Count_ID = new GameAttributeF(855, -1, -1, 0, 0, "", "", "Spawner_Concurrent_Count_ID", GameAttributeEncoding.Float32, 0, 0, 0, 32); - public static readonly GameAttributeF Skill_Override = new GameAttributeF(857, -1, -1, 0, 0, "", "", "Skill_Override", GameAttributeEncoding.Float32, 136, 0, 0, 32); + public static readonly GameAttributeI Skill_Override = new GameAttributeI(857, -1, -1, 0, 0, "", "", "Skill_Override", GameAttributeEncoding.Int, 136, 0, 0, 32); public static readonly GameAttributeF Walk_Passability_Power_SNO = new GameAttributeF(1057, -1, -1, 0, 0, "", "", "Walk_Passability_Power_SNO", GameAttributeEncoding.Float32, 0, 0, 0, 32); public static readonly GameAttributeF Passability_Power_SNO = new GameAttributeF(1058, -1, -1, 0, 0, "", "", "Passability_Power_SNO", GameAttributeEncoding.Float32, 0, 0, 0, 32); public static readonly GameAttributeF Flippy_ID = new GameAttributeF(1059, -1, -1, 0, 0, "", "", "Flippy_ID", GameAttributeEncoding.Float32, 0, 0, 0, 32); From f100f499d2d5b66b87323529c422b34998c89957 Mon Sep 17 00:00:00 2001 From: Crypto137 Date: Tue, 10 Jan 2023 04:47:06 +0300 Subject: [PATCH 04/14] Fix Wizard's Ray of Frost rune VFX --- .../GSSystem/PowerSystem/Implementations/HeroSkills/Wizard.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/DiIiS-NA/D3-GameServer/GSSystem/PowerSystem/Implementations/HeroSkills/Wizard.cs b/src/DiIiS-NA/D3-GameServer/GSSystem/PowerSystem/Implementations/HeroSkills/Wizard.cs index 57e4a93..69ca3f6 100644 --- a/src/DiIiS-NA/D3-GameServer/GSSystem/PowerSystem/Implementations/HeroSkills/Wizard.cs +++ b/src/DiIiS-NA/D3-GameServer/GSSystem/PowerSystem/Implementations/HeroSkills/Wizard.cs @@ -2102,8 +2102,8 @@ namespace DiIiS_NA.GameServer.GSSystem.PowerSystem.Implementations else { _beamEnd = SpawnEffect(6535, User.Position, 0, WaitInfinite()); - User.AddComplexEffect(RuneSelect(19327, 149835, -1, 149836, 149869, 149879), _beamEnd); - if (Rune_A > 0) User.AddComplexEffect(19327, _beamEnd); + User.AddComplexEffect((Rune_E > 0) ? 149879 : 19327, _beamEnd); // Rune E uses a special beam + User.AddComplexEffect(RuneSelect(-1, 149835, -1, 149836, 149869, -1), _beamEnd); // Runes A, C and D add effects on top of the standard beam } } From 4b6e81e398d27727c3753397d262dcaa3c3ad4fa Mon Sep 17 00:00:00 2001 From: Crypto137 Date: Tue, 10 Jan 2023 05:05:23 +0300 Subject: [PATCH 05/14] Change auth error message to be more clear --- src/DiIiS-NA/REST/RestSession.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/DiIiS-NA/REST/RestSession.cs b/src/DiIiS-NA/REST/RestSession.cs index 8008e8a..648565e 100644 --- a/src/DiIiS-NA/REST/RestSession.cs +++ b/src/DiIiS-NA/REST/RestSession.cs @@ -175,7 +175,7 @@ namespace DiIiS_NA.REST { loginResult.AuthenticationState = "LOGIN"; loginResult.ErrorCode = "UNABLE_TO_DECODE"; - loginResult.ErrorMessage = "HEBEPHO! WRONG! English do you speak IT?!"; + loginResult.ErrorMessage = "The information you have entered is not valid."; SendResponse(HttpCode.BadRequest, loginResult); Logger.Error("Аутентификация неудалась: Логин - {0}. Cоединение с REST разорвано.", login); } From ea1b0eda7cfb526309571b07590fe83544f924aa Mon Sep 17 00:00:00 2001 From: Crypto137 Date: Tue, 10 Jan 2023 08:01:50 +0300 Subject: [PATCH 06/14] Implement a temp workaround to unlock stash tabs Tab purchasing with gold needs to be fixed properly. --- src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Inventory.cs | 3 ++- src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Player.cs | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Inventory.cs b/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Inventory.cs index c6a67f1..7ac3128 100644 --- a/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Inventory.cs +++ b/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Inventory.cs @@ -2418,7 +2418,8 @@ namespace DiIiS_NA.GameServer.GSSystem.PlayerSystem _owner.World.Game.GameDBSession.SessionGet(_owner.Toon.GameAccount.PersistentID).StashSize; if (slots > 0) { - _owner.Attributes[GameAttribute.Shared_Stash_Slots] = slots; + //_owner.Attributes[GameAttribute.Shared_Stash_Slots] = slots; + _owner.Attributes[GameAttribute.Shared_Stash_Slots] = 700; // HACK: Give player 10 stash tabs. Remove this when tab purchasing gets fixed. _owner.Attributes.BroadcastChangedIfRevealed(); // To be applied before loading items, to have all the space needed _stashGrid.ResizeGrid(_owner.Attributes[GameAttribute.Shared_Stash_Slots] / 7, 7); diff --git a/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Player.cs b/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Player.cs index 5b0777b..da6ef2c 100644 --- a/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Player.cs +++ b/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Player.cs @@ -468,7 +468,6 @@ namespace DiIiS_NA.GameServer.GSSystem.PlayerSystem Attributes[GameAttribute.Buff_Icon_Count0, 0x00033C40] = 1; Attributes[GameAttribute.Currencies_Discovered] = 0x0011FFF8; - Attributes[GameAttribute.Stash_Tabs_Purchased_With_Gold] = 5; this.Attributes[GameAttribute.Skill, 30592] = 1; this.Attributes[GameAttribute.Resource_Degeneration_Prevented] = false; @@ -622,7 +621,8 @@ namespace DiIiS_NA.GameServer.GSSystem.PlayerSystem this.Attributes[GameAttribute.Cannot_Dodge] = false; this.Attributes[GameAttribute.Trait, 0x0000CE11] = 1; this.Attributes[GameAttribute.TeamID] = 2; - this.Attributes[GameAttribute.Stash_Tabs_Purchased_With_Gold] = 1; + this.Attributes[GameAttribute.Stash_Tabs_Purchased_With_Gold] = 5; // what do these do? + this.Attributes[GameAttribute.Stash_Tabs_Rewarded_By_Achievements] = 5; this.Attributes[GameAttribute.Backpack_Slots] = 60; this.Attributes[GameAttribute.General_Cooldown] = 0; } From 2e70fa6538c08bc3a23847552c4693f94daec96b Mon Sep 17 00:00:00 2001 From: Crypto137 Date: Tue, 10 Jan 2023 08:41:07 +0300 Subject: [PATCH 07/14] Increase default stash size --- .../BGS-Server/AccountsSystem/GameAccountManager.cs | 6 +++--- .../D3-GameServer/GSSystem/PlayerSystem/Inventory.cs | 3 +-- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/src/DiIiS-NA/BGS-Server/AccountsSystem/GameAccountManager.cs b/src/DiIiS-NA/BGS-Server/AccountsSystem/GameAccountManager.cs index 8afc7b9..7a4a30d 100644 --- a/src/DiIiS-NA/BGS-Server/AccountsSystem/GameAccountManager.cs +++ b/src/DiIiS-NA/BGS-Server/AccountsSystem/GameAccountManager.cs @@ -76,9 +76,9 @@ namespace DiIiS_NA.LoginServer.AccountsSystem ParagonLevelHardcore = 0, Experience = 7200000, ExperienceHardcore = 7200000, - StashSize = 70, - HardcoreStashSize = 70, - SeasonStashSize = 70, + StashSize = 700, // Default stash sizes should be 70 with purchasable upgrades + HardcoreStashSize = 700, + SeasonStashSize = 700, BloodShards = 0, HardcoreBloodShards = 0, BossProgress = new byte[] { 0xff, 0xff, 0xff, 0xff, 0xff }, diff --git a/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Inventory.cs b/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Inventory.cs index 7ac3128..c6a67f1 100644 --- a/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Inventory.cs +++ b/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Inventory.cs @@ -2418,8 +2418,7 @@ namespace DiIiS_NA.GameServer.GSSystem.PlayerSystem _owner.World.Game.GameDBSession.SessionGet(_owner.Toon.GameAccount.PersistentID).StashSize; if (slots > 0) { - //_owner.Attributes[GameAttribute.Shared_Stash_Slots] = slots; - _owner.Attributes[GameAttribute.Shared_Stash_Slots] = 700; // HACK: Give player 10 stash tabs. Remove this when tab purchasing gets fixed. + _owner.Attributes[GameAttribute.Shared_Stash_Slots] = slots; _owner.Attributes.BroadcastChangedIfRevealed(); // To be applied before loading items, to have all the space needed _stashGrid.ResizeGrid(_owner.Attributes[GameAttribute.Shared_Stash_Slots] / 7, 7); From c7da2775b2b53997990efc2ad79ac690147be773 Mon Sep 17 00:00:00 2001 From: Crypto137 Date: Fri, 13 Jan 2023 09:38:52 +0300 Subject: [PATCH 08/14] Fix resurrection time attribute encoding --- .../D3-GameServer/MessageSystem/GameAttirbute.List.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/DiIiS-NA/D3-GameServer/MessageSystem/GameAttirbute.List.cs b/src/DiIiS-NA/D3-GameServer/MessageSystem/GameAttirbute.List.cs index fbd7aff..99c9605 100644 --- a/src/DiIiS-NA/D3-GameServer/MessageSystem/GameAttirbute.List.cs +++ b/src/DiIiS-NA/D3-GameServer/MessageSystem/GameAttirbute.List.cs @@ -375,9 +375,9 @@ namespace DiIiS_NA.GameServer.MessageSystem public static readonly GameAttributeF World_Seed = new GameAttributeF(758, 0, -1, 0, 0, "", "", "World_Seed", GameAttributeEncoding.Float32, 0, 0, 0, 32); public static readonly GameAttributeF Combo_Time_Last_Move = new GameAttributeF(802, 0, -1, 0, 0, "", "", "Combo_Time_Last_Move", GameAttributeEncoding.Float32, 0, 0, 0, 32); public static readonly GameAttributeF Death_Replacement_Effect_Group_SNO = new GameAttributeF(804, -1, -1, 0, 0, "", "", "Death_Replacement_Effect_Group_SNO", GameAttributeEncoding.Float32, 0, 0, 0, 32); - public static readonly GameAttributeF Checkpoint_Resurrection_Allowed_Game_Time = new GameAttributeF(805, 0, -1, 0, 0, "", "", "Checkpoint_Resurrection_Allowed_Game_Time", GameAttributeEncoding.Float32, 0, 0, 0, 32); - public static readonly GameAttributeF Checkpoint_Resurrection_Forced_Game_Time = new GameAttributeF(806, 0, -1, 0, 0, "", "", "Checkpoint_Resurrection_Forced_Game_Time", GameAttributeEncoding.Float32, 0, 0, 0, 32); - public static readonly GameAttributeF Corpse_Resurrection_Allowed_Game_Time = new GameAttributeF(807, 0, -1, 0, 0, "", "", "Corpse_Resurrection_Allowed_Game_Time", GameAttributeEncoding.Float32, 0, 0, 0, 32); + public static readonly GameAttributeI Checkpoint_Resurrection_Allowed_Game_Time = new GameAttributeI(805, 0, -1, 0, 0, "", "", "Checkpoint_Resurrection_Allowed_Game_Time", GameAttributeEncoding.Int, 0, 0, 0, 32); + public static readonly GameAttributeI Checkpoint_Resurrection_Forced_Game_Time = new GameAttributeI(806, 0, -1, 0, 0, "", "", "Checkpoint_Resurrection_Forced_Game_Time", GameAttributeEncoding.Int, 0, 0, 0, 32); + public static readonly GameAttributeI Corpse_Resurrection_Allowed_Game_Time = new GameAttributeI(807, 0, -1, 0, 0, "", "", "Corpse_Resurrection_Allowed_Game_Time", GameAttributeEncoding.Int, 0, 0, 0, 32); public static readonly GameAttributeF Controlling_TimedEvent_SNO = new GameAttributeF(810, -1, -1, 0, 0, "", "", "Controlling_TimedEvent_SNO", GameAttributeEncoding.Float32, 0, 0, 0, 32); public static readonly GameAttributeF Spawner_Concurrent_Count_ID = new GameAttributeF(855, -1, -1, 0, 0, "", "", "Spawner_Concurrent_Count_ID", GameAttributeEncoding.Float32, 0, 0, 0, 32); public static readonly GameAttributeI Skill_Override = new GameAttributeI(857, -1, -1, 0, 0, "", "", "Skill_Override", GameAttributeEncoding.Int, 136, 0, 0, 32); From 1babc5cfd4e18c756f0a6e67463b8e8f4c86a176 Mon Sep 17 00:00:00 2001 From: Crypto137 Date: Fri, 13 Jan 2023 09:48:21 +0300 Subject: [PATCH 09/14] Fix resurrection at corpse --- .../D3-GameServer/GSSystem/PlayerSystem/Player.cs | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Player.cs b/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Player.cs index da6ef2c..9a3fa30 100644 --- a/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Player.cs +++ b/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Player.cs @@ -2461,8 +2461,11 @@ 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]); + 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 #endif @@ -2653,7 +2656,11 @@ namespace DiIiS_NA.GameServer.GSSystem.PlayerSystem this.Revive(this.CheckPointPosition); break; case 2: - //this.Revive(this.Position); + if (this.Attributes[GameAttribute.Corpse_Resurrection_Charges] > 0) + { + this.Revive(this.Position); + this.Attributes[GameAttribute.Corpse_Resurrection_Charges]--; + } break; } } @@ -3811,8 +3818,8 @@ namespace DiIiS_NA.GameServer.GSSystem.PlayerSystem this.Attributes[GameAttribute.Resurrect_As_Observer] = state; //this.Attributes[GameAttribute.Observer] = !state; } - //this.Attributes[GameAttribute.Corpse_Resurrection_Charges] = 1; //enable that to allow resurrecting at corpse - //this.Attributes[GameAttribute.Corpse_Resurrection_Allowed_Game_Time] = this.World.Game.TickCounter + 300; //timer for auto-revive + //this.Attributes[GameAttribute.Corpse_Resurrection_Charges] = 1; // Enable this to allow unlimited resurrection at corpse + //this.Attributes[GameAttribute.Corpse_Resurrection_Allowed_Game_Time] = this.World.Game.TickCounter + 300; // Timer for auto-revive (seems to be broken?) this.Attributes.BroadcastChangedIfRevealed(); } From e65446a73466c8be93260de34d1b36d1c95e0b25 Mon Sep 17 00:00:00 2001 From: Crypto137 Date: Fri, 13 Jan 2023 10:14:03 +0300 Subject: [PATCH 10/14] Move health potion implementation to a power --- .../GSSystem/ItemsSystem/Item.cs | 3 +-- .../General/DrinkHealthPotion.cs | 24 +++++++++++++++++++ 2 files changed, 25 insertions(+), 2 deletions(-) create mode 100644 src/DiIiS-NA/D3-GameServer/GSSystem/PowerSystem/Implementations/General/DrinkHealthPotion.cs diff --git a/src/DiIiS-NA/D3-GameServer/GSSystem/ItemsSystem/Item.cs b/src/DiIiS-NA/D3-GameServer/GSSystem/ItemsSystem/Item.cs index 84d2885..85c3faa 100644 --- a/src/DiIiS-NA/D3-GameServer/GSSystem/ItemsSystem/Item.cs +++ b/src/DiIiS-NA/D3-GameServer/GSSystem/ItemsSystem/Item.cs @@ -927,8 +927,7 @@ namespace DiIiS_NA.GameServer.GSSystem.ItemsSystem if (player.Attributes[GameAttribute.Hitpoints_Cur] == player.Attributes[GameAttribute.Hitpoints_Max]) return; - player.AddPercentageHP(60); - player.World.BuffManager.AddBuff(this, player, new PowerSystem.Implementations.CooldownBuff(30211, TickTimer.WaitSeconds(player.World.Game, 30f))); + player.World.PowerManager.RunPower(player, 30211); if (this.Attributes[GameAttribute.ItemStackQuantityLo] <= 1) player.Inventory.DestroyInventoryItem(this); // No more potions! diff --git a/src/DiIiS-NA/D3-GameServer/GSSystem/PowerSystem/Implementations/General/DrinkHealthPotion.cs b/src/DiIiS-NA/D3-GameServer/GSSystem/PowerSystem/Implementations/General/DrinkHealthPotion.cs new file mode 100644 index 0000000..b517f22 --- /dev/null +++ b/src/DiIiS-NA/D3-GameServer/GSSystem/PowerSystem/Implementations/General/DrinkHealthPotion.cs @@ -0,0 +1,24 @@ +//Blizzless Project 2022 +using System.Collections.Generic; +using DiIiS_NA.GameServer.GSSystem.PlayerSystem; +using DiIiS_NA.GameServer.GSSystem.TickerSystem; + +namespace DiIiS_NA.GameServer.GSSystem.PowerSystem.Implementations.General +{ + //30211 class DrinkHealthPotion + [ImplementsPowerSNO(30211)] + public class DrinkHealthPotion : PowerScript + { + public override IEnumerable Run() + { + if (User is Player) + { + Player player = (Player)User; + player.AddPercentageHP(60); + AddBuff(player, player, new CooldownBuff(30211, TickTimer.WaitSeconds(player.World.Game, 30f))); + } + + yield break; + } + } +} From a489b22d686f1e29fee09ecc26807d5715e6af4a Mon Sep 17 00:00:00 2001 From: Crypto137 Date: Fri, 13 Jan 2023 10:15:00 +0300 Subject: [PATCH 11/14] Disable potion consumption on use --- src/DiIiS-NA/D3-GameServer/GSSystem/ItemsSystem/Item.cs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/DiIiS-NA/D3-GameServer/GSSystem/ItemsSystem/Item.cs b/src/DiIiS-NA/D3-GameServer/GSSystem/ItemsSystem/Item.cs index 85c3faa..366072f 100644 --- a/src/DiIiS-NA/D3-GameServer/GSSystem/ItemsSystem/Item.cs +++ b/src/DiIiS-NA/D3-GameServer/GSSystem/ItemsSystem/Item.cs @@ -929,6 +929,7 @@ namespace DiIiS_NA.GameServer.GSSystem.ItemsSystem player.World.PowerManager.RunPower(player, 30211); + /* Potions are no longer consumable if (this.Attributes[GameAttribute.ItemStackQuantityLo] <= 1) player.Inventory.DestroyInventoryItem(this); // No more potions! else @@ -936,6 +937,8 @@ namespace DiIiS_NA.GameServer.GSSystem.ItemsSystem this.UpdateStackCount(--this.Attributes[GameAttribute.ItemStackQuantityLo]); // Just remove one this.Attributes.SendChangedMessage(player.InGameClient); } + */ + return; } From ba3cd35ae617483954f84ad7e26f9d2ccdf0b596 Mon Sep 17 00:00:00 2001 From: Crypto137 Date: Fri, 13 Jan 2023 10:22:13 +0300 Subject: [PATCH 12/14] Disable potion drops when player has one in their inventory already --- src/DiIiS-NA/D3-GameServer/GSSystem/MapSystem/World.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/DiIiS-NA/D3-GameServer/GSSystem/MapSystem/World.cs b/src/DiIiS-NA/D3-GameServer/GSSystem/MapSystem/World.cs index 096fbae..ddf6290 100644 --- a/src/DiIiS-NA/D3-GameServer/GSSystem/MapSystem/World.cs +++ b/src/DiIiS-NA/D3-GameServer/GSSystem/MapSystem/World.cs @@ -875,7 +875,7 @@ namespace DiIiS_NA.GameServer.GSSystem.MapSystem } public void SpawnRandomPotion(Actor source, Player player) { - if (player != null && !player.Inventory.HaveEnough(DiIiS_NA.Core.Helpers.Hash.StringHashHelper.HashItemName("HealthPotionBottomless"), 100)) + if (player != null && !player.Inventory.HaveEnough(DiIiS_NA.Core.Helpers.Hash.StringHashHelper.HashItemName("HealthPotionBottomless"), 1)) { var item = ItemGenerator.GenerateRandomPotion(player); if (item == null) return; From f1f3d40f7785cdd481796dfaa01a8230cf7e1b29 Mon Sep 17 00:00:00 2001 From: Crypto137 Date: Sun, 15 Jan 2023 11:17:08 +0300 Subject: [PATCH 13/14] 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 From 926b08d5145071e918f75edf49ea3d125bedadb9 Mon Sep 17 00:00:00 2001 From: Crypto137 Date: Sun, 15 Jan 2023 13:03:54 +0300 Subject: [PATCH 14/14] Implement Shadows in the Desert quest workaround --- src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Player.cs | 2 +- src/DiIiS-NA/D3-GameServer/GSSystem/QuestSystem/ActII.cs | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Player.cs b/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Player.cs index 7ad5235..b5fbc4c 100644 --- a/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Player.cs +++ b/src/DiIiS-NA/D3-GameServer/GSSystem/PlayerSystem/Player.cs @@ -5958,7 +5958,7 @@ namespace DiIiS_NA.GameServer.GSSystem.PlayerSystem minion.SetVisible(true); minion.Hidden = false; - if (minion.ActorSNO.Id == 4580) + if (minion.ActorSNO.Id == 4580) // Act I Leah { (minion.Brain as MinionBrain).PresetPowers.Clear(); (minion.Brain as MinionBrain).AddPresetPower(30599); diff --git a/src/DiIiS-NA/D3-GameServer/GSSystem/QuestSystem/ActII.cs b/src/DiIiS-NA/D3-GameServer/GSSystem/QuestSystem/ActII.cs index b41807a..1c8ee68 100644 --- a/src/DiIiS-NA/D3-GameServer/GSSystem/QuestSystem/ActII.cs +++ b/src/DiIiS-NA/D3-GameServer/GSSystem/QuestSystem/ActII.cs @@ -133,7 +133,8 @@ namespace DiIiS_NA.GameServer.GSSystem.QuestSystem //ListenProximity(85843, new SpawnCultists()); script = new SpawnCultists(); script.Execute(this.Game.GetWorld(70885)); - ListenKill(6027, 7, new Advance()); + //ListenKill(6027, 7, new Advance()); + ListenProximity(85843, new Advance()); // HACK: Skip ambush }) });