I'm doing a little bit of D2 modification to try and enhance the single player experience in a few ways I've not necessarily seen before in my relatively limited modded D2 playing(hoping to do some things like auto potion pickup and management, maybe converting junk items to gold, automatic re-hire of your merc on death, and a dedicated TP button). I think I know how I'll go about most of these things, what to hook to, and I have a lot of the basics working(examining packets to monitor item drops, deaths, etc).
The problem I'm running into is that certain changes appear to be surface-only. Modifying player stats, for instance, through the AddPlayerStat(D2COMMON:10551) functions DO update the value of gold in your inventory or the number of unused skill points, but don't actually update the values where it counts. With gold, for instance, I see five places where my gold value is stored in memory, two of which update immediately when dropping gold, three of which update a few ticks later. But when I add gold via AddPlayerStat, it updates two of those but the change never propogates to the other three, and the gold doesn't exist or get saved to the character in reality.
I've come to figure out this is because D2 runs a server and client in the same process even in Single-player, which makes sense why I'm seeing packets via an intercept GamePacketRecv_Interception on D2Client:0xACE61. I have even watched the Get Gold packets that get sent on picking up gold.
My questions:
Do changes to the player via AddPlayerStat and similar functions only update the Client's copy of the player, and if so, would I need to send those updated stats in some manner to the Server via a packet, or is there some other mechanism for updating the Server's player state?
I see that PlugY, for example, is using these functions to set player gold and skill amounts on the player when using the shared stash and respecting, but it also seems to be doing something after that to update the player state, but I'm having trouble figuring out what exactly it's doing at that point.
Is there any documentation or reference somewhere that goes into more detail on the internal client and server system and how information is communicated between the two?
Sorry if I've missed this information somewhere on the forum(I have done hours of reading posts and searching) or if this is against the rules to ask about. Looked like, from stickies, that client-server questions not related to BNet functionality were acceptable.
[1.13c] Stat modification and single-player CE questions
This forum is for discussions on how to edit what can not be edited through the txt files, needless to say this isn't about battle net hacking.
Moderators: Nefarius, Havvoric
1 post
• Page 1 of 1
[1.13c] Stat modification and single-player CE questions
Post by dicene » Wed Apr 21, 2021 9:11 pm
dicene
1 post
• Page 1 of 1
Jump to
- The Phrozen Keep Forums
- ↳ Staff Announcements
- ↳ Keep Updates
- ↳ File Center Announcements
- ↳ Keep Polls
- ↳ Members area
- ↳ Member news
- ↳ Job Offerings
- ↳ Multi-Player Matchups
- ↳ Member Аnnouncements
- ↳ Feedback
- ↳ Site support
- ↳ Mod Spotlight & Quick links
- ↳ Keep Discord
- Diablo Universe
- ↳ Diablo II Legacy Modding and Discussion
- ↳ General Mod Making
- ↳ Tools
- ↳ Multimedia
- ↳ Map Editing
- ↳ Code Editing
- ↳ PlugY|NefEx|D2Mod
- ↳ Skill Clinic
- ↳ Mod Concepts & Research
- ↳ Mac Modding
- ↳ Diablo II Chatter
- ↳ Diablo II Resurrected Discussion
- ↳ Other Diablo Games
- Diablo II Legacy Mods
- ↳ Apokaliptic
- ↳ Plugins by Nizari
- ↳ Back to Hellfire
- ↳ Battle for Elements
- ↳ Black Omen Productions
- ↳ Mods by Nefarius
- ↳ Shadow Empires
- ↳ Blackened
- ↳ Diabolic Studios
- ↳ Diabolic Studios Site
- ↳ The Hordes of Chaos
- ↳ Dark Alliance
- ↳ Planar Rifts
- ↳ Dreamland betatesting
- ↳ Eastern Sun
- ↳ Eastern Sun Rises
- ↳ Escape From The Afterlife
- ↳ Le Royaume des Ombres
- ↳ Mods by Lady Isabelle
- ↳ Talonrage's Requiem of Sorrow
- ↳ Zy-El: Trial by Fire
- ↳ The Sandbox
- ↳ Unsupported Mods
- ↳ Nezeramontias
- ↳ Ancestral Recall
- ↳ Kingdom of Tenai
- ↳ Mods by GuyAskingQuestion
- ↳ The Fury Within: Ancients & Awakening
- ↳ Darkness Weaves
- ↳ V&K Mods
- ↳ New Dawn & North Star
- ↳ Baldur's Gate Mod
- ↳ Sir_Generals Rune Mod
- ↳ Dragons' Uprising
- ↳ Seasons After
- ↳ CryptForge
- ↳ d2:elements
- ↳ Underkill
- ↳ Pagan Heart
- ↳ Hades Mods
- ↳ Apocalypse
- ↳ Cubaholics
- ↳ Hades Underworld
- ↳ Sanctum Arcanum
- ↳ Arcanum Archives
- ↳ Rise of the Old Gods
- ↳ Elder Scrolls Mod
- ↳ Legacy of the Horadrim
- Diablo I Discussion
- ↳ Diablo I Chatter
- ↳ Diablo I Modding
- ↳ Devilution
- ↳ Infernity
- ↳ Belzebub
- ↳ Tchernobog
- ↳ EQUINE
- ↳ Crucible
- ↳ D1Legit
- Other Games
- ↳ It Lurks Below
- Miscellaneous
- ↳ Off-Topic
- ↳ Testing
- Currently Unavailable
- ↳ Upcoming Forums
- ↳ Limbo
- ↳ Seven Lances
- ↳ Wheel of Time
- ↳ Tactics Central
- ↳ Mod Reviews
- ↳ DoomsDay
- ↳ Time of Heroes
- ↳ Bloodwars, Inc.
- ↳ Darque Onyx Mods
- ↳ Cabal Wars - Aeons Tide
- ↳ Deathfile's Sanctuary
- ↳ A Pledge To Evil
- ↳ When Worlds Collide II
- ↳ Prophecy of Shadows
- ↳ Valhalla
- ↳ Darque Onyx Site
- ↳ Visions of Valor
- ↳ Cheater's Choice Series
- ↳ Dark Sabbath
- ↳ Corrupted Death
- ↳ Belize's Revenge
- ↳ Brother Laz
- ↳ Chaos Empire
- ↳ Odin's Runeword Mod
- ↳ Stormbringer
- ↳ The Dark Omen
- ↳ Mods By Laz
- ↳ The Stairway to Oblivion
-
- Login
-
- Who is online
- In total there are 11 users online :: 1 registered, 0 hidden and 10 guests
Most users ever online was 1797 on Tue Nov 25, 2008 1:27 pm
Users browsing this forum: AppleWebKi and 10 guests
Recent Forum Topics
-
- Menu
-
- Community
-
- Modding Resources