WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content

Conversation

@LocalIdentity
Copy link
Contributor

The new GetProcessCount helper (sys_main.cpp:438) walks the system process list via Windows’ Toolhelp API—no external commands. It creates a snapshot with CreateToolhelp32Snapshot, iterates PROCESSENTRY32W, lowercases each executable name, and increments a counter whenever the name matches one of the PoB executable variants passed in from Lua. That count flows back through the Lua binding (ui_api.cpp:2024) up to getMatchingProcessCount in src/Launch.lua:20, so the updater knows exactly how many sibling PoB processes are running.

The new `GetProcessCount` helper (sys_main.cpp:438) walks the system process list via Windows’ Toolhelp API—no external commands. It creates a snapshot with `CreateToolhelp32Snapshot`, iterates `PROCESSENTRY32W`, lowercases each executable name, and increments a counter whenever the name matches one of the PoB executable variants passed in from Lua. That count flows back through the Lua binding (ui_api.cpp:2024) up to `getMatchingProcessCount` in src/Launch.lua:20, so the updater knows exactly how many sibling PoB processes are running.
@LocalIdentity LocalIdentity added the enhancement New feature or request label Dec 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants