
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
Try it with the Online Editor!
Check out the changelog for a list of new features!
Latest Compatible Minecraft Version: 1.12
Note: I called it Script because it has a syntax similar to JavaScript.
Learn how to write in Minecraft Script in the Wiki.
mcs has been tested with node and as a standalone (web) script. Though it should also support CommonJS (node, browserify) and AMD (RequireJS).
Installation via npm:
$ npm install mcs
> var mcs = require('mcs');
> mcs('function hello { say hello world; }');
Alternatively you can install mcs globally so that it may be run from the command line.
$ npm install mcs -g
$ mcs ./input.mcs ./output/
Add to your html
<script src="https://unpkg.com/mcs"></script>
Download mcs.min.js
Add to your html
<script src="path/to/mcs.min.js"></script>
var input = 'function hello { say hello world; }'
var result = mcs(input)
// result = { "_namespace": { "_type": "namespace", "hello": { "_type": "function", "value": "say hello world\n" } } }
mcs() takes one required argument, the input (string to convert), and returns a JSON object with namespaces, groups, and functions (you can differentiate them using _type).
$ mcs [input] [output (optional)]
Using mcs in the CLI takes one require argument, the input file (.mcs file), and outputs to the (optional) output directory. If no output directory is given, ./ is used.
Check out the current todo list here.
npm install or yarn/src# Use your own input/output
$ npm run build
$ node index.js [input] [output]
# Alternatively:
# Use test/new_syntax.mcs as input, and test/output/ as output
$ npm run test
# Build the source files AND use test/new_syntax.mcs as input, and test/output/ as output
$ npm run bnt
# Autocompile/build whenever you change the src files (instead of npm run build)
$ gulp
dist/mcs.min.js file after buildingMade by Pandawan.
Thanks to @coolsa for contributing.
Thanks to Andrew Mast and Chris Smith for helping out and providing feedback!
Please see the LICENSE file
mcs is not affiliated with Minecraft or Mojang AB.
FAQs
A pre-processor to write Minecraft Functions more efficiently
We found that mcs demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.