https://github.com/legopitstop/molang-py
Molang to Python Translator & interpreter written in pure Python.
https://github.com/legopitstop/molang-py
bedrock hacktoberfest language minecraft modtoberfest molang
Last synced: 3 months ago
JSON representation
Molang to Python Translator & interpreter written in pure Python.
- Host: GitHub
- URL: https://github.com/legopitstop/molang-py
- Owner: legopitstop
- License: mit
- Created: 2024-01-19T00:20:41.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-11-26T00:12:37.000Z (7 months ago)
- Last Synced: 2025-03-28T19:38:31.980Z (3 months ago)
- Topics: bedrock, hacktoberfest, language, minecraft, modtoberfest, molang
- Language: Python
- Homepage: https://pypi.org/project/molang/
- Size: 2.69 MB
- Stars: 1
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
# molang
[](https://pypi.org/project/molang/)
[](https://www.python.org/downloads//)


[](https://github.com/ambv/black)
[](https://github.com/legopitstop/molang/issues)Molang to Python Translator & interpreter written in pure Python.
## Installation
Install the module with pip:
```bat
pip3 install molang
```Update existing installation: `pip3 install molang --upgrade`
## Requirements
| Name | Description |
| ------------------------------------------------ | --------------------------------------- |
| [`pydantic`](https://pypi.org/project/pydantic/) | Data validation using Python type hints |## Features
- Decorator to convert a Python function to Molang.
- Execute .molang files from the command line or using Python. See [Road map](#road-map)See the docs for more information.
## Example
Convert `my_function` to Molang
```python
from molang import molang@molang
def my_function(a, b):
return a + bprint(my_function)
>> return t.a+t.b
```## Command-line interface
```
usage: molang [-h] [-V]Run molang files
options:
-h, --help show this help message and exit
-V, --version print the molang version number and exit.```
## Road map
- [x] Python function to Molang
- [ ] Interpreter
- [ ] Lexer
- [ ] Parser
- [ ] cli to convert Python code to Molang code (vice versa)