shupershuff / diablo2rloader Goto Github PK
View Code? Open in Web Editor NEWDiablo 2: Resurrected launcher for multi-boxing
License: MIT License
Diablo 2: Resurrected launcher for multi-boxing
License: MIT License
Include the ability to have a particular account open a custom game path install.
This caters for users who want to have separate installs so that game settings are persistent for each account.
Furthermore, investigate whether this can be done in a way that doesn't require duplication of installs to save disk space (eg via symbolic links)
As suggested by never148
smth's wrong in $arguments, can't debug.
accounts.csv string looks like this:
1,[email protected],Main,,,pwd!,,-enablerespec -txt -mod mod
the game is being launched and renamed but somehow 'connecting to battlenet' screen is being skipped and i'm being thrown on offline characters tab. switching to online tab results in 'cannot connect to server' dialog.
same options given via shortcut work like a charm:
gamepath\D2R.exe -username [email protected] -password pwd! -address eu.actual.battle.net -enablerespec -txt -mod mod
tested with or without password encryption and timetracking - no difference
As requested by Red_Alert_One, prevent the Alt key from being recognised as an input key for the script.
This is to prevent accidentally loading an account when alt tabbing windows.
I saw this new feature so thought I'd give it a go. It throws some errors for me.
Alternatively choose 'r' to refresh, 't' for TZ info or 'x' to quit.: t
Finding TZ Update Posts....
You cannot call a method on a null-valued expression.
At D:\Users\m\Desktop\Diablo2RLoader\D2Loader.ps1:426 char:2
+ $TDs = $geturl.ParsedHtml.body.getElementsByTagName("td") | Selec ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (:) [], RuntimeException
+ FullyQualifiedErrorId : InvokeMethodOnNull
Cannot index into a null array.
At D:\Users\m\Desktop\Diablo2RLoader\D2Loader.ps1:429 char:2
+ $latestpostID = ($AllPostIDs | Sort-Object -Descending)[0]
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (:) [], RuntimeException
+ FullyQualifiedErrorId : NullArray
Cannot index into a null array.
At D:\Users\m\Desktop\Diablo2RLoader\D2Loader.ps1:430 char:2
+ $previouspostID = ($AllPostIDs | Sort-Object -Descending)[1]
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (:) [], RuntimeException
+ FullyQualifiedErrorId : NullArray
Finding Current TZ Name...
Invoke-WebRequest : <script type="text/javascript">location.replace("/derror
/deleted/diablo2resurrected/minor");</script>
At D:\Users\m\Desktop\Diablo2RLoader\D2Loader.ps1:435 char:12
+ $geturl = Invoke-WebRequest $url
+ ~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (System.Net.HttpWebRequest:
HttpWebRequest) [Invoke-WebRequest], WebException
+ FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.Power
Shell.Commands.InvokeWebRequestCommand
You cannot call a method on a null-valued expression.
At D:\Users\m\Desktop\Diablo2RLoader\D2Loader.ps1:436 char:2
+ $divs = $geturl.ParsedHtml.body.getElementsByTagName('div') | Sel ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (:) [], RuntimeException
+ FullyQualifiedErrorId : InvokeMethodOnNull
Finding Next TZ Name...
Invoke-WebRequest : <script type="text/javascript">location.replace("/derror
/deleted/diablo2resurrected/minor");</script>
At D:\Users\m\Desktop\Diablo2RLoader\D2Loader.ps1:445 char:10
+ $geturl=Invoke-WebRequest $url
+ ~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (System.Net.HttpWebRequest:
HttpWebRequest) [Invoke-WebRequest], WebException
+ FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.Power
Shell.Commands.InvokeWebRequestCommand
You cannot call a method on a null-valued expression.
At D:\Users\m\Desktop\Diablo2RLoader\D2Loader.ps1:446 char:2
+ $divs =$geturl.ParsedHtml.body.getElementsByTagName('div') | Sele ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (:) [], RuntimeException
+ FullyQualifiedErrorId : InvokeMethodOnNull
Translating Korean to English...
Current TZ is:
Next TZ is:
Accurate as of: 6:52 AM
Press Enter to continue...:
Hi there,
Thanks for the work. When first setting it up and launching it, I just went in with my #1 acc. It worked. I then tried tabbing to the loader to open #2. That one "timed-out" when connecting to battlenet sending me to the offline screen. The issue isn't the one of "wrong credentials" because now my #1 does the same (the one I already got in-game with on its own).
Tried launching it through the bnet client, it asked for a capcha and ten the regular way worked.
The loader-way, even with 1 or 2 acc's, doesn't. Is this just a matter of temp ban/cool-off period for logging in without the client?
i use mods coz i use mosaic sin so i dont get blinded. and loot filter too. would be a great feature!
I would like to just have a plain function call like 'k'
which kills all open handles
I have one account I have to sign in manually due to 2fa
and afterwards I want to start the other account
when I start manually and then start 1 in the script
, it will not kill all open handles before launching 1
Add optional argument to argument string to start windowed.
Hello,
the if clause in line 199 throws an exception which might have something to do with locales. I am using Windows 11 with german system locale. Script continues just fine, but the auto update column in stats does not get updated in the stats.csv due to the exception.
It says something like "the string is not a valid datetime"
To reproduce I did this:
Cheers!
Hey, @shupershuff
THIS IS NOT AN ISSUE, JUST TO SHOW GRATITUDE!
Thanks for this amazing repo that you've made, amazing quality code, comments for modifying it and overall performance.
Wish you all the best, cheers!
When the script is ran for the first time on my machine I get an error
PS D:\Users\m\Desktop\Diablo2RLoader\Diablo2RLoader-main> .\D2Loader.ps1
.\D2Loader.ps1 : File D:\Users\m\Desktop\Diablo2RLoader\Diablo2RLoader-main\D2Loader.ps1 cannot be loaded because
running scripts is disabled on this system. For more information, see about_Execution_Policies at
https:/go.microsoft.com/fwlink/?LinkID=135170.
At line:1 char:1
+ .\D2Loader.ps1
+ ~~~~~~~~~~~~~~
+ CategoryInfo : SecurityError: (:) [], PSSecurityException
+ FullyQualifiedErrorId : UnauthorizedAccess
I can set the permission like so, but it seems like a potential risk.
PS D:\Users\m\Desktop\Diablo2RLoader\Diablo2RLoader-main> Set-ExecutionPolicy -ExecutionPolicy Unrestricted -Scope CurrentUser
Following this, there is a message
PS D:\Users\m\Desktop\Diablo2RLoader\Diablo2RLoader-main> .\D2Loader.ps1
Security warning
Run only scripts that you trust. While scripts from the internet can be useful, this script can potentially harm your
computer. If you trust this script, use the Unblock-File cmdlet to allow the script to run without this warning
message. Do you want to run D:\Users\m\Desktop\Diablo2RLoader\Diablo2RLoader-main\D2Loader.ps1?
[D] Do not run [R] Run once [S] Suspend [?] Help (default is "D"):
Perhaps the README.md should contain advice on how to configure this? Possibly with a safe config or a warning
I followed setup procedure as follows:
The script continues to run and I can reopen the closed account. The error doesn't usually occur on the first switching of windows, it's usually when I try to bring the characters to the same place or interact. I didn't find any log files or uncaught exceptions.
Basically, I just want to give my HC sorc some BO. :P
Let me know if I can provide you with anymore details.
With the introduction of the revised window naming, this has broken the main menu screen from showing the correct region per account. This means if you're across multiple regions, the menu will just show the same region across all accounts.
Feature request! Possibly simple one. Could you please make refresh the default action in the main prompt? So select 1-N for account id, t for tz, x for exit, enter to refresh.
For extra points perhaps refresh every minute? ๐ฌ๐ค
Thanks!
Hello,
I use the script on my main rig with windows 10 and on a notebook with windows 11.
On the main rig it works just fine. on the notebook with windows 11 it starts the first instance but trying to open the second one results in the script just tabbing into the first one and doing nothing.
I think it used to work under windows 11 before but i tried back to version 1.8.1 with no success.
You got any idea?
BR
I think this is due to the D2R instance running in admin mode? Starting discord in admin mode doesn't seem to fix. I think starting D2r in non-admin would fix but have not tested.
I have tested launching regularly through launcher does fix it.
I believe the actual launched instances of d2r don't need to be admin? Just the script itself. I assume they are inheriting admin mode from the script...
$arguments = (" -username " + $script:acct + " -password " + $script:PW +" -address " + $Script:Region + " -mod ANYMOD -txt -enablerespec ").tostring()
especially with parcing shitty site's pages.
but why don't use API instead?
check it out:
https://d2runewizard.com/integration
{"terrorZone":{"zone":"Blood Moor and Den of Evil","act":"act1","lastReportedBy":{"displayName":"Hazel-rah","uid":"811795758"},"lastUpdate":{"seconds":1685112700,"nanoseconds":58000000},"reportedZones":{"Blood Moor and Den of Evil":9},"highestProbabilityZone":{"zone":"Blood Moor and Den of Evil","act":"act1","amount":9,"probability":1}},"providedBy":"https://d2runewizard.com/terror-zone-tracker"}
So I really like the different settings option! What might be really cool is if I could choose which settings profile to use when opening an account. So, I have 3 accounts, 3 separate settings files, but I only have 2 different types of settings. 1 for full screen detailed graphics and 1 for windowed low graphics. Sometimes I switch which account is the one using the high graphics and the others use the low. It would be cool if I could choose that in the loader. So perhaps another field in the account file with the default settings profile number and a question when loading, similar to the realm one, for selecting the profile at load. I guess you could have an option in the defaults to turn this question off if you don't use the feature.
Thanks!
For instance, I run a dual monitor setup. I play HC. So having my BO barb up in a windowed mode on the 2nd monitor is how I do my sheeez.
Can it be automated to launch there? Maybe by pixel, so you can place it yourself?
I'm sorry if there's a better place for suggestions.
Move config options to a separate config file to allow the script to be overwritten (with new releases) without disrupting end users configs each time.
As suggested by never148.
So I just discovered that PowerShell can talk to you:
$voice = New-Object -ComObject Sapi.spvoice
$voice.rate = 0
$Region = "NA"
$voice.speak("d clone inbound on $region")
Might look into adding this as an optional, configurable feature for S5 Ladder.
It doesn't work on Asia server
Is there any solution?
US and EU servers work well.
Received a request via DM to add capability for custom CMD lines per account for folks who want to use NoHD mod on some accounts but not the primary. Custom CMD lines to be moved to accounts.csv instead of the single entry in config.xml
Hi, first of all - great script. Helps so much with multiple instances.
The problem:
Connecting to the Asia server doesn't work. After the game starts, it tries to connect to battle.net and it says "cannot connect to server". If run from the official Battle.net app it works fine. Some people on various Discord groups mentioned that other similar scripts don't work either so it's likely something on Blizzard's end. Not sure if anything can be done from the script itself but reporting just in case.
Hello I've set up the launcher and it works fine. But when I add a 4th account it always puts me the msg cant verify your account with that information I double checked if I typed everything correct but even after double checking I cant find the issue.
Line 2614 doesn't work properly while using mods in cfg file:
$SettingsProfilePath = ("C:\Users\" + $Env:UserName + "\Saved Games\Diablo II Resurrected\")
This leads to default game path, while given mod directory is stored in accounts.csv
So default settings.json file will always be used and other accounts settings files will always be owerwritten.
Tried to fix it myself but no idea how to parse CustomLaunchArguments from accounts.csv.
Using parameters, every time i try to log on to EU or AS, it will say this account is locked due to suspicious activity. I have to go and get security code for email. I dont have MFA on any of these accounts. Have no issues running them on NA server. Did I miss something?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.