KenshiLib
Reconstruction of game structures and methods for Kenshi
Install / Use
/learn @KenshiReclaimer/KenshiLibREADME
MOVED
This repo has been moved to: https://github.com/BFrizzleFoShizzle/KenshiLib
KenshiLib
KenshiLib is a library that reconstructs Kenshi's structures, exporting a version-independent API for accessing variables and calling and hooking methods.
KenshiLib is released under the GPLv3, please be aware that this generally means KenshiLib plugins must also be released under the GPLv3. KenshiLib also contains 3rd-party components with additional licenses.
Developing RE_Kenshi/KenshiLib plugins
Example KenshiLib plugins can be found here.
The easiest way to set up standard plugin dependencies is to use the KenshiLib_Examples dependencies repo, which comes with all required KenshiLib includes + precompiled libs for KenshiLib/Ogre/Boost/Etc.
The steps for setting up a new KenshiLib plugin:
Set the compiler toolchain to Visual Studio 2010.
Add KenshiLib's Include dir to your includes.
Add Boost 1.60.0 includes.
Add KenshiLib + OgreMain .lib files to the linker input (OgreMain .lib is in the KenshiLib repo, KenshiLib .lib is included in KenshiLib releases).
Plugin Best-practices
DO use KenshiLib's built-in function hooking system, it is designed to handle multiple plugins hooking the same function.
DON'T use 3rd-party function hooking/detouring libraries as these can cause issues when multiple plugins hook the same function using different libraries.
DON'T access the UI from non-UI threads. Most MyGUI functions are NOT thread-safe, this will cause race conditions that will intermittently crash the game.
If you are exporting functions for other plugins to use, it is wise to make your plugin a Preload Plugin (doccumentation coming) so that it is loaded before other plugins.
Compiling
Requires Visual Studio 2019 or newer and the Visual C++ 2010 x64 compilers. KenshiLib MUST be compiled using the Visual Studio 2010 compiler. Copies of Visual Studio 2010 can be found on the Wayback Machine.
Also requires boost 1.60.0 and the multihook version of MinHook.
Open the project and compile in RELEASE mode. DEBUG is currently broken.
Related Skills
node-connect
354.2kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
112.2kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
354.2kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
qqbot-media
354.2kQQBot 富媒体收发能力。使用 <qqmedia> 标签,系统根据文件扩展名自动识别类型(图片/语音/视频/文件)。
