Mods in WASM, and why that is not a limitation
A native mod has the same permissions as the user who installs it. In a full-loot game with private servers, that is a risk we do not want anyone to take.
The most dangerous mod is the one that works. It does not crash, it does not steal frames, it does not ask for permissions: it reads the tokens saved in your browser, the cookies, the password manager. The game looks normal.
In 2023 that actually happened, at scale, with mods distributed on well-known platforms. The lesson is not “be careful what you download”: it is that a game should not put the player's entire computer in the hands of a file downloaded from a forum.
What a mod in WASM can do
Soulslands mods will run in WebAssembly inside a sandbox, without WASI. Translated: no files, no network, no processes. A mod sees the game world and the APIs we give it, and nothing else.
Inside those limits you can do almost anything: new items, creatures, rules, interfaces, content. You cannot do the one thing that makes native mods a problem.
The price, stated clearly
- A mod cannot write a file of its own: if it needs persistence, it goes through the game APIs.
- It cannot use a native library compiled for the platform: it has to be compiled to WASM.
- It cannot build an external client or a bot that talks to the server on its own: we decide that, and we expose it as an official API.
These are real limits. They are also the reason a parent can install a mod for their child without wondering what it is running, and the reason a private server can accept community content without becoming a malware vector.
The boring part, which is the most important
A sandbox is not safe because it is written in a safe language. It is safe if someone tries to break it. That is why the project has protocol tests, fuzz targets on the data coming from the network, and one simple rule: no native mods, no exceptions.
When the modding system goes public, its attack surface will go public too. That is the right way to build it.