d2jsp
Log InRegister
d2jsp Forums > Diablo II > Diablo 2 Discussion > Strategy & Guides > D2r Multiclient Guide - One Pc / No Virtualization > D2:R
12323Next
Add Reply New Topic New Poll
Banned
Posts: 6,156
Joined: Sep 27 2021
Gold: Locked
Trader: Scammer
Nov 28 2021 09:51am
Hello, here is how to practically run multiple D2R clients on a single PC, let say 8 accounts, without virtualization / without sandboxing solutions. This does not include how to control clients at once (broadcasting to multiple windows).

This is guide for 'medium' skilled people. The powershell script explained below does not have proper error/exception handling, use at your own risk.



Use case:
1 PC
No virtualization / no sandbox
8 accounts (MF in your own pace, rushing yourself, XP boost) - everyone knows advantages of having more people in the game, mainly the no-drop chance reduction

Requirements for 8 clients - to actually be able to play and enjoy the game, not just to run it with 10 fps:
modern CPU - 8 cores+
RAM 64GB
VRAM 24GB / modern GPU - Nvidia RTX etc - some folks mentioned a certain success with GPU shared memory, where you can have 8GB physical memory chips on GPU and get some more from DRAM - https://superuser.com/questions/1546634/shared-gpu-memory-can-i-turn-off-this-feature
8x D2R license (currently 8x 30€)
220 GB hard drive space
Admin rights
8x email account / 8x battle.net account - be sure you number them properly so you orient yourself when operating them (name1-8, some reasonable passwords etc)
I recommend 2x wide screen monitor. So you have 4 windows on one monitor, 4 windows on the second.

Overall workflow:
a] start first battle net Launcher with account1, start D2R client 1, click intro and let it finish Battle.net login -> you get into character screen
b] Close handle (run powershell script)
c] start second battle net Launcher with account2, start D2R client 2, click intro and let it finish Battle.net login -> you get into character screen
d] Close handle (run powershell script)
... repeat


Implementation:

1) Create 8x copy of game folder - 220gb, just copy and rename (do not install it again)



2) Create shortcuts on your desktop leading to each game copy Diablo II Resurrected Launcher.exe, number it (if one client crashes, you need to be able to orient yourself), process explorer helps to show you which crashed

- Make sure in your battle.net client - Setttings - Advanced Features - you have "Allow multiple instances of Battle.Net" enabled ( this is where you can find it - https://i.imgur.com/ab6PV9X.png )
- Uncheck Battle.net auto login

Go into first game copy folder, right click on Diablo II Resurrected Launcher.exe - Create shortcut -> D2R1
1 -> "F:\Diablo II Resurrected 1\Diablo II Resurrected Launcher.exe"
Go into second game copy folder, right click on Diablo II Resurrected Launcher.exe - Create shortcut -> D2R2
2 -> "F:\Diablo II Resurrected 2\Diablo II Resurrected Launcher.exe"
etc



3) After you start D2R (D2R window opens with intro), a handle which prevents other instances from running is created, it is described here, so you need to kill it:
More details, credits to those guys:
https://us.forums.blizzard.com/en/d2r/t/running-multiple-instances-of-d2r-on-the-same-computer/9899/103

It is very impractical to do this manually via Process Explorer every single time so I solved that by using SysInternals handle utility + powershell script as follows:

- Create a folder on your desktop or somewhere, something like D2Rhandle_del
- Download and put handle64.exe in that folder - get it from the official site: https://docs.microsoft.com/en-us/sysinternals/downloads/handle
- Create a powershell script called D2Rhandle_del.ps1 with the code below (what it does? it will invoke the script as admin to be able to kill process handles, it will dump all D2R process handles into d2r_handles.txt file, it will enumerate through that file to find the process id and handle id, if there is one, it will start handle64 utility and kill it which allows you to spawn next instance on the same PC, otherwise when you click in battlenet to start D2R it will just switch to your already existing window)
- Create a shortcut to this script, so you can execute the overall workflow

C:\Users\<user>\Desktop\D2Rhandle_del\ folder structure:
- handle64.exe is coming from the official site, explained above
- handles txt file is created as a temp file with all D2R processes / handles, every time you run the script
- D2Rhandle_del.ps1
https://i.imgur.com/QpHi3lo.png

D2Rhandle_del.ps1:
Code
if (!([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole] "Administrator")) { Start-Process powershell.exe "-NoProfile -ExecutionPolicy Bypass -File `"$PSCommandPath`"" -Verb RunAs; exit }

& "$PSScriptRoot\handle64.exe" -accepteula -a -p D2R.exe > $PSScriptRoot\d2r_handles.txt

$proc_id_populated = ""
$handle_id_populated = ""

foreach($line in Get-Content $PSScriptRoot\d2r_handles.txt) {


$proc_id = $line | Select-String -Pattern '^D2R.exe pid\: (?<g1>.+) ' | %{$_.Matches.Groups[1].value}
if ($proc_id)
{
$proc_id_populated = $proc_id
}
$handle_id = $line | Select-String -Pattern '^(?<g2>.+): Event.*DiabloII Check For Other Instances' | %{$_.Matches.Groups[1].value}
if ($handle_id)
{
$handle_id_populated = $handle_id
}

if($handle_id){

Write-Host "Closing" $proc_id_populated $handle_id_populated
& "$PSScriptRoot\handle64.exe" -p $proc_id_populated -c $handle_id_populated -y

}

}

read-host "Press ENTER to continue..."


This is how it looks when it closes the D2R "Instance" handle as intended:
https://i.imgur.com/BnQL6vN.png

I am sure handles can be killed via API programmatically, I just did this fast hack way to make it work, not worth my time to do this in C# or so.

4) I recommend that in Graphics settings (outside of your main client) you lock fps to max ~40, it will make your main game running smoothly and also to disable sound so you don't hear things multiple times
I experimented with legacy graphics but it does not reduce VRAM usage, so I do not believe it will help

4 windows per monitor, sort it nicely so you can switch windows and find if something crashed:
https://i.imgur.com/zcGIAlM.png


If you have a particular issue or question PM me. But as I said, if you do not understand what is process explorer or how to run a powershell script this might not be for you.

If you found it helpful for what you wanted to achieve, a tip is appreciated.

This post was edited by Chobot on Dec 6 2021 03:13am
Banned
Posts: 6,156
Joined: Sep 27 2021
Gold: Locked
Trader: Scammer
Nov 28 2021 10:31am
Some folks mentioned it can run on less vram, I do not work at a PC shop to test that, so I put here only on what setup I know for sure it works.

And you still play fullscreen main client - ultra gfx, with no stuttering, high fps 3840 * 1600.

Key performance figures:





This post was edited by Chobot on Nov 28 2021 10:32am
Member
Posts: 3,001
Joined: May 1 2020
Gold: 0.00
Nov 30 2021 02:31pm
Maybe stupid question but want to be sure. I need to buy 2x D2R to run 2 instances?
Banned
Posts: 6,156
Joined: Sep 27 2021
Gold: Locked
Trader: Scammer
Nov 30 2021 02:33pm
Correct sir, every game client needs a purchased game copy license. Online multiplayer.
Member
Posts: 2,651
Joined: Sep 21 2021
Gold: 255,744.19
Nov 30 2021 05:25pm
but can you alt f4 + remake on all 8 though?
Member
Posts: 78,072
Joined: Jun 24 2007
Gold: 37,510.56
Nov 30 2021 05:47pm
So is this legal?
Banned
Posts: 6,156
Joined: Sep 27 2021
Gold: Locked
Trader: Scammer
Nov 30 2021 06:09pm
Only when you have 3 brothers and 4 sisters and you share PC. We can also request a mediator.
Member
Posts: 78,072
Joined: Jun 24 2007
Gold: 37,510.56
Dec 1 2021 01:45am
Quote (Chobot @ 1 Dec 2021 01:09)
Only when you have 3 brothers and 4 sisters and you share PC. We can also request a mediator.



Well I have 19 roommates :D
Banned
Posts: 6,156
Joined: Sep 27 2021
Gold: Locked
Trader: Scammer
Dec 1 2021 01:53am
Then totally legit.

No seriously, in the EULA they do not prohibit usage of multiple accounts, they have profit from it - the only thing which feeds this game, no subs, no cosmetics outside of ultimate edition etc.

In Wow multi accounts no problem, they just prohibit multi windows control broadcasting - official site, this is not wow though :) there are general Bnet terms of use as well, it goes among those lines too
https://eu.battle.net/support/en/article/24258
Member
Posts: 78,072
Joined: Jun 24 2007
Gold: 37,510.56
Dec 1 2021 03:05am
Quote (Chobot @ 1 Dec 2021 08:53)
Then totally legit.

No seriously, in the EULA they do not prohibit usage of multiple accounts, they have profit from it - the only thing which feeds this game, no subs, no cosmetics outside of ultimate edition etc.

In Wow multi accounts no problem, they just prohibit multi windows control broadcasting - official site, this is not wow though :) there are general Bnet terms of use as well, it goes among those lines too
https://eu.battle.net/support/en/article/24258



Cool I’ll look into it then, just looking to play 2 copies only anyway :)
Go Back To Strategy & Guides Topic List
12323Next
Add Reply New Topic New Poll