Without an explicit rootDir, tstl computed output paths relative to
tsconfig.json's own directory (modules/events-mod/) rather than the
actual TypeScript source root (src/main/typescript/), so control.lua
and settings.lua ended up nested under src/main/typescript/ in the
packaged mod zip instead of at its root - where Factorio requires them
to be. The mod would not have loaded at all as packaged.
This went uncaught because packageFactorioMod never previously
produced real output (blocked by the now-fixed kxs-ts-gen-core/JitPack
issue). Verified by actually running packageFactorioMod and inspecting
the resulting zip: control.lua, settings.lua and info.json are now at
the root, and control.lua's require() calls ("main.global-init" etc.)
correctly resolve against that flat layout.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Bumps the Factorio engine pin and typed-factorio (1.11.0 -> 3.36.0,
targeting 2.0.75) and fixes the resulting breaking API changes:
global -> storage, game.*_prototypes -> prototypes.*, game.table_to_json/
encode_string -> helpers.*, OnBuiltEntityEvent.created_entity -> .entity,
removed TileRead/ColorTable/MapPositionTable-style write-form aliases,
new CollisionMask shape, restructured settings-stage type imports, and
new defines.entity_status values (added to the Status enum, generated
schema, and EntityStatusRecord mapping). Also declares optional mod
dependencies on space-exploration and Krastorio2.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
- create LuaJsonList to handle empty Lua JSON lists being sent as empty objects
- fix exporting of resources and entities
- split up map tiles into different layer directories
- add 'chunk size' to MapChunkPosition
- move tests to correct packages
- bump tstl
- decrease tstl logging
- remove some defined, but unused, kafka topics
- syslog, rest, websocket servers & web-map: decrease logging
- webmap: add additional layers for buildings and resources
- minor version bumps
- new Factorio version
- use both prototype name and type to identify a prototype
- kxs-ts-gen: use BrandTyping, but exclude some identifiers
- kxs-ts-gen: manually create zip dist, so it can run after the project compiles
- mod: use typed-factorio strict types
- mod: refactor event handlers to be a little more consistent and object-oriented