Many old games (Starcraft, Diablo II, Diablo, Age of Kings…) have huge problems displaying colors correctly on Windows 7. For Starcraft, I have succeeded to fix this using:
- Opening the screen resolution settings dialog (sometimes works)
- Killing
explorer.exe
(always works) - Using DirectDraw color fix (sometimes works)
For Diablo II, only the 2) works for me. So I have written following batch file:
rem Kill explorer.exe
taskkill /IM explorer.exe /F
rem Run the game
"Diablo II.exe"
rem After game is over, resume explorer.exe
rem explorer.exe
The problem is, that the actual process for the game is Game.exe
and the Diablo II.exe
exits immediately – so the explorer immediately restarts.
Do you have any idea, how to automate the resuming of explorer.exe after I close Diablo II?
Best Answer
You can write a loop that checks if a specific process (e.g. "Game.exe") is running and repeats checking until it is closed. The code could look like this.
As I do now have Diablo 2 handy this code is not tested properly. Depending on the flavor of Windows the commands might need to be changed slightly.