Closed xVinci6 closed 1 month ago
Yes, it regenerates the file on the server with
const ConfigTypes_1 = require("/snapshot/project/obj/models/enums/ConfigTypes");
Yeah, this was my bad. I didn't realize including that would cause issues for people. I have minimal experience with server mods or TS/JS in general, 99.9% of sain is C# client mod. Next published builds will have this omitted.
Fixed in latest release
Hi,
My nodejs development is outdated so I cannot tell you what the proper way to do it is, but I have a fix:
I get the following error on startup:
Stacktrace: Error: Cannot find module 'C:/snapshot/project/obj/models/enums/ConfigTypes' Require stack:
Now the issue seems to be, that post 3.8.0 versions (2.2.1 and 2.2.2) contain the typescript file, plus the js and mapping file.
While this does not cause issues on my windows machine using the SPT server executable, when launching spt-aki with docker on a linux system it seems to pick the .js file instead with the C:/ path in it (line 5: const ConfigTypes_1 = require("C:/snapshot/project/obj/models/enums/ConfigTypes");) , which it obviously fails to find.
Fix for me was to remove the js and map files (which I assume come from development) and leave only the .ts file, now it works on both win and linux.
Thanks for the great work and good luck!