Skip to content

Edited version of the loader specifically for tracking time spent on Single Player Characters

License

Notifications You must be signed in to change notification settings

shupershuff/D2rSPLoader

Repository files navigation

Overview

A cutdown version of D2rLoader specifically aimed at providing features for single player.
Useful for tracking total time spent across each character on Grail :)
image

Features

Main features

  • Track time spent per character by assessing save game files for changes.
  • Launches in offline mode for those who want to help their mates fill games online but still play single player (uses parameter '-region xxx').
  • Option to skip intro videos and in game videos (works with mods or if using -direct -txt).
  • Ability to start Grail App of your choosing (if not already running at game launch).
  • Ability to start Run timer app of your choosing (if not already running at game launch).
  • Ability to show only characters your interested in on main screen (allows you to hide mules from display).
  • Ability to set launch options for seed, enablerespec, playersX, resetofflinemaps.

Swap Character Sets

Load/Unload Save game sets (eg if switching between Grail characters and edited test characters).
This works by looking in subfolders within your saved game folder (excluding folders called backups or mods) for D2r save game files (.d2s) and allows you to swap these out.
Note that character names should be unique if you want to ensure play time tracking for the character is accurate.

Backup

Local Backups - Ability to manually or automatically backup your save game files into "C:\Users\%USERNAME%\Saved Games\Diablo II Resurrected\Backups". Uses my repurposed Offline Backup script
image

Cloud Backups - Setup wizard in script to allow save games folder to be backed up to the cloud.
This is handy if your computer explodes or if you want to play the same characters across different devices.
Uses my D2rSinglePlayerBackup script.
image

Setup Steps

This has a much easier setup than Diablo2RLoader as this is an offline script and as such doesn't need any accounts added.
Essentially you can just download it and run it but there are some optional config options.

1. Download

  1. Download the latest release here. Click on D2RSPLoader-.zip (eg D2RSPLoader-1.0.0.zip) to download.
  2. One downloaded, extract the zip file to a folder of your choosing.
  3. Right click on D2rSPLoader.ps1 and open properties.
  4. Check the "Unblock" box and click apply.
    image

2. Script Config (Mostly Optional)

Default settings within config.xml should be ok but can be optionally changed. Recommend checking out the features here. Open the .xml file in a text editor such as notepad, Powershell ISE, Notepad++ etc.

  • Most importantly, if you have a game path that's not the default ("C:\Program Files (x86)\Diablo II Resurrected"), then you'll need to edit this to wherever you chose to install the game.

All other config options below this are strictly optional:

  • Optionally set 'CustomLaunchArguments' to any custom launch arguments you previously used in the battlenet client for loading mods or for loading files directly.
  • Optionally set 'GrailAppExecutablePath' if you want Holy Grail software to run when D2r.exe launches.
  • Optionally set 'RunTimerAppExecutablePath' if you have any run timer apps you want to run when the D2r.exe launches.
  • Optionally set 'CreateDesktopShortcut' to False if you don't want a handy dandy shortcut on your desktop. Enabled by default.
  • Optionally set 'ShortcutCustomIconPath' to the location of a custom icon file if you want the desktop icon to be something else (eg the old D2LOD logo). Uses D2r logo by default.
  • Optionally set 'ForceWindowedMode' to True if you want to force windowed mode each time. This causes issues with Diablo remembering resolution settings, so I recommend leaving this as False and manually setting your game to windowed in your game settings. Disabled by default.
  • Optionally set 'AutoBackup' to true if you want the script to automatically locally backup your save game files every half hour.
  • Optionally set 'DisableVideos' to true if you want to skip intro videos or videos between acts.
  • Optionally set 'ManualSettingSwitcherEnabled' to True if you want the ability to be able to choose a settings profile to load from. Once enabled, this is toggleable from the script using 's'. See the Manual Setting Switcher section below for more info. Disabled by default.

Some of the above options can be set within the scripts option menu also. Make sure to save the file when finished editing.

3. Run the script manually for the first time

  1. Browse to the folder, right click on D2rSPLoader.ps1 and choose run (if you see an option for 'Run with PowerShell', use this).
  2. If you get prompted to change the execution policy so you can run the script, type y and press enter. image
    a) If the script opens up and immediately closes or you instead get a message about "D2rSPLoader.ps1 cannot be loaded because running scripts is disabled on this system" then you will need to perform the following steps:
    b) Open the start menu and type in powershell. Right click on PowerShell and click "Run as administrator".
    c) Enter the following command: Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser
    d) Type in "y" and press enter to confirm.
    e) Run the D2rSPLoader.ps1 script again.
  3. If the script prompts to trust it and add it to the unblock list, type in y and press enter to confirm.
  4. This will perform the first time setup to compile settext.exe, populate characters.csv and create a shortcut on your desktop.
  5. All of your characters will be shown by default. You can choose to hide accounts in bulk by editing characters.csv (make sure to close script first) or one by one by using the options menu: image

Tip: If you struggle editing CSV files in text editors like notepad or notepad++, try editing in Excel or ModernCSV (free CSV app).

4. Manual Settings Switcher (Optional)

Do you want to manually choose which settings to use when launching the game? This is for you! This feature is disabled by default, as this needs to be setup first and understood this first.

To enable this feature in the setting 'ManualSettingSwitcherEnabled' must be set to True. You can do this from the options menu or from editing the config file.

Setting up alternate Game settings to switch too

  1. Set 'ManualSettingSwitcherEnabled' to True in your config file or from the options menu in the script.
  2. Launch the Game (via the Loader or via Bnet client, doesn't matter).
  3. Make the required graphics/audio/game changes via the menu.
  4. Close the game.
  5. Browse to "C:\Users\<yourusername>\Saved Games\Diablo II Resurrected"
  6. Copy the Settings.json file and paste into the same folder.
  7. Rename this copied file to Settings.name.json (eg ensure the name is inside two fullstops eg settings.1440pHigh.json or settings.PotatoGraphics.json)
  8. Press 'S' on the main screen of the loader to enable prompting for settings.
  9. Launch the game via the loader, choose settings and proceed find all of the high runes. All of them.

5. Setting up alternate character sets to switch too/from

This is useful if you want to setup alternate character sets (eg have a set of characters for testing builds separate from your legitimate characters).
To setup, create a folder in your D2r saved game folder and cut and paste (don't copy) the users into it.
Folder example could be "C:\Users\%USERNAME%\Saved Games\Diablo II Resurrected\Testing Characters"

If setup, the menu will show an option for it allowing you to switch:
image

Notes

  • You will need to connect online once every 30 days (to update your cookie.bin file) otherwise your game will give you an error that more or less says 'you haven't been online in 30 days, please reconnect'.

Credit for things I stole

Mostly credits from D2rLoader

Proudly made in NZ
nzmade image

Page views as of 2nd Oct 2024:       Hits

About

Edited version of the loader specifically for tracking time spent on Single Player Characters

Resources

License

Stars

Watchers

Forks

Packages

No packages published