News for hackers. Stuff that matters.
Re:The Magic Behind Cubacadabra by Heliodex on Saturday September 12, 2026 @09:42PM (#49679081)
https://github.com/cubacadabra/first-game/blob/main/src/main...

I'm puzzled by the -- @import comment syntax used in these main files. Did they have to build custom Luau tooling for type-checking across files for this, and why not use require()?

Other than this, the example games had easily readable and clear code.

Re:The Magic Behind Cubacadabra by cs1996 on Sunday September 13, 2026 @04:33AM (#49681480)
This luau gets packaged via:

https://github.com/cubacadabra/tools

but I think you are right, it should not use this custom syntax.

Re:The Magic Behind Cubacadabra by andrewfromx on Sunday September 13, 2026 @05:21AM (#49681825)
new commit here: https://github.com/cubacadabra/tools/commit/662c18a43deafb5b...

Thanks this was indeed the wrong design. Now it has:

Game code can now do normal Luau imports like local Round = require("./round")

Cubacadabra SDK modules use aliases like require("@cubacadabra/shared-state")

.luaurc files maps the @cubacadabra alias for editor navigation/type checking