{"library":"mlogx","title":"MLOGX","description":"MLOGX is a transpiler and toolchain for Mindustry Logic (MLOG), the scripting language of the game Mindustry. Version 2.7.2 provides validation, readability improvements (e.g., infix operators, printf), compiler constants, loops, and multi-file support. It is actively maintained with frequent releases. Unlike raw MLOG, MLOGX catches invalid commands and type mismatches at compile time. It ships TypeScript types and supports both CLI and API usage.","language":"javascript","status":"active","last_verified":"Fri May 01","install":{"commands":["npm install mlogx"],"cli":{"name":"mlogx","version":null}},"imports":["import { compile } from 'mlogx'","import transpile from 'mlogx'","import type { CompileOptions } from 'mlogx'"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"import { compile, writeOutput } from 'mlogx';\nimport { readFileSync } from 'fs';\n\nconst source = readFileSync('example.mlogx', 'utf8');\nconst result = compile(source, {\n  filename: 'example.mlogx',\n  targetVersion: 7,\n  format: 'mlog'\n});\nconsole.log(result.code);\nwriteOutput(result, './out/output.txt');\n// Output: compiled MLOG with error checks","lang":"typescript","description":"Compiles an MLOGX file to MLOG, showing the basic API usage.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}