Skip to content

Repository files navigation

Dead Cells Core Modding

GitHub License Build And Test Discord

A Dead Cells Modding API/loader.

See Documentation

Download the latest build here

Join the Discord server for more help.

Requirement

  • .NET 10 runtime
  • Microsoft Visual C++ Redistributable package (2015-2022)

Installation

  1. Get the core file from nightly link or releases
  2. Unzip it to the game root directory

The folder structure should be similar to the following

<DeadCellsGameRoot>
|
+- coremod
|  |
|  +- core
|  |  |
|  |  +- native
|  |  |  |
|  |  |  +- ...
|  |  |
|  |  +- mdk
|  |  |	 |
|  |  |  +- install.ps1
|  |  |  |
|  |  |  +- uninstall.ps1
|  |  |  |
|  |  |  +- ...
|  |  |
|  |  +- host
|  |  |  |
|  |  |  +- startup
|  |  |  |  |
|  |  |  |  +- DeadCellsModding.exe
|  |  |  |  |
|  |  |  |  +- ...
|  |  |  +- ...
|  |  +- ...
|  +- ...
|
+- deadcells.exe
|
+- deadcells_gl.exe
|
+- ...

Mods Development

Here are some examples.

Preparation

  1. Install .NET SDK 10
  2. Install Dead Cells Core Modding as above
  3. Run <DeadCellsGameRoot>/coremod/core/mdk/install.ps1 to configure the environment

Create a mod project

  1. Create a library project based on .NET 10
  2. Add package reference DeadCellsCoreModding.MDK
  3. Add the following to your csproj file
<PropertyGroup>
	<!--Enter the mod name here-->
	<ModName>$(AssemblyName)</ModName>

	<!--
	Enter mod type here

	Available values:
		mod: Normal mod
		library: Library
	-->
	<ModType>mod</ModType>

	<!--Enter the full name of the mod's main type here-->
	<ModMain>ModNamespace.MainModClass</ModMain>
</PropertyGroup>

Build

Build the mod using dotnet build. The default output directory is $(OutputPath)/output/

Usage

Startup

Start the game from <DeadCellsGameRoot>/coremod/core/host/startup/DeadCellsModding.exe

Mods Installation

  1. Create <DeadCellsGameRoot>/coremod/mods folder if it does not exist.
  2. Move the mods files into the mods folder. The folder structure should look like this:
mods
|
+- <ModName>
|  |
|  +- modinfo.json
|  |
|  +- ...
|
+- ...

Warning

<ModName> must be exactly the same as the name property in modinfo.json, otherwise the mods loader will refuse to load the mods

Development

Requirement

  • .NET SDK 10
  • CMake
  • MSVC

Download Additional Dependencies

The native build requires OpenAL and SDL3 headers and libraries:

cd sources\native\3rd\hashlink\include

# OpenAL
Invoke-WebRequest -Uri "https://github.com/kcat/openal-soft/releases/download/1.23.1/openal-soft-1.23.1-bin.zip" -OutFile "OpenAL.zip"
Expand-Archive -LiteralPath "OpenAL.zip" -DestinationPath . -Force
Move-Item -Path "openal-soft-1.23.1-bin" -Destination "openal" -Force

# SDL3
Invoke-WebRequest -Uri https://github.com/libsdl-org/SDL/releases/download/release-3.4.10/SDL3-devel-3.4.10-VC.zip -OutFile ./SDL.zip
Expand-Archive -LiteralPath ./SDL.zip -DestinationPath . -Force
Move-Item -Path ./SDL3-3.4.10 -Destination ./sdl -Force

Build

# Full build (Debug)
.\build.ps1

# Full build (Release)
.\build.ps1 --configuration Release

# Individual targets
.\build.ps1 BuildNative                  # Native runtime only
.\build.ps1 BuildCore                    # Managed core only
.\build.ps1 BuildMDK                     # MDK toolchain only
.\build.ps1 BuildAssets                  # Assets project only

# Combine multiple targets
.\build.ps1 BuildCore BuildMDK BuildAssets --configuration Release

⚠️ Before running BuildAssets, the MDK must be installed. See the step below.

Install MDK

After building the MDK, install it by running the setup script:

.\build.ps1 BuildMDK
.\bin\core\mdk\install.ps1

Output

Build artifacts are placed in the bin/ directory:

bin/
├── core/
│   ├── host/startup/          
│   │   └── DeadCellsModding.exe # Game launcher
│   ├── mdk/                   # MDK toolchain
│   └── native/
│       └── win-x64/           # Native runtime
│           └── goldberg/      # Goldberg Steam emulator
└── ...

Credit

Third-Party Open Source Libraries

This project uses the following open source libraries directly (bundled or linked):

Library License Path
HashLink MIT sources/native/3rd/hashlink/
TinyCC LGPL 2.1 sources/native/3rd/tinycc/
mbedTLS Apache 2.0 / GPL 2.0+ sources/native/3rd/hashlink/include/mbedtls/
zlib zlib sources/native/3rd/hashlink/include/zlib/
libpng libpng sources/native/3rd/hashlink/include/png/
libjpeg-turbo IJG / Modified BSD sources/native/3rd/hashlink/include/turbojpeg/
minimp3 CC0 1.0 sources/native/3rd/hashlink/include/minimp3/
libogg + libvorbis BSD-style (Xiph.org) sources/native/3rd/hashlink/include/vorbis/
SDL zlib sources/native/3rd/hashlink/include/sdl/
OpenAL Soft LGPL 2.0 sources/native/3rd/hashlink/include/openal/
libuv MIT sources/native/3rd/hashlink/include/libuv/
PCRE2 BSD sources/native/3rd/hashlink/include/pcre/
meshoptimizer MIT sources/native/3rd/hashlink/include/meshoptimizer/
MikkTSpace zlib-like sources/native/3rd/hashlink/include/mikktspace/
V-HACD BSD 3-Clause sources/native/3rd/hashlink/include/vhacd/
SQLite Public Domain sources/native/3rd/hashlink/include/sqlite/
hlsteam MIT sources/native/hdlls/libs/hlsteam/
hlgog MIT sources/native/hdlls/libs/hlgog/
Goldberg Emulator LGPL 3.0 3rd/Goldberg/
Steamworks.NET MIT 3rd/Steamworks.NET/
RectpackSharp MIT 3rd/RectpackSharp/
crashlink MIT 3rd/crashlink/

NuGet Packages

Package License
Newtonsoft.Json MIT
Mono.Cecil MIT
MonoMod MIT
Iced MIT
Fody MIT
Serilog Apache 2.0
StbImageSharp MIT
StbImageWriteSharp MIT
K4os.Hash.xxHash MIT
SharpPdb MIT
System.IO.Hashing MIT
CsWin32 MIT

Code Signing Policy

Free code signing provided by SignPath.io, certificate by SignPath Foundation.

Team Roles

  • Authors (committers): Members team
  • Reviewers: Members team — each change proposed by non-members must be reviewed by a team member
  • Approvers: Owners — each signing request must be approved by a team member trusted to decide if a release can be code signed

Privacy Policy

This program will not transfer any information to other networked systems unless specifically requested by the user or the person installing or operating it.

Artifact Configuration

All signed binaries have product name set to 'Dead Cells Core Modding' and product version set to the release version.

License

Distributed under the MIT license.

Disclaimer

Dead Cells Core Modding is in no way associated with Motion Twin.

Releases

Packages

Used by

Contributors

Languages