Asm Craft

Asm Craft

This mod enables you to write programs in assembly language within Minecraft and run them.

by
28 Downloads
fabriccursed
Rent Server with this Mod

About this Mod

Asm Craft

The mod is made by sally4953.

This mod is licensed under the MIT open-source agreement. You can view its source code through the GitHub repository: https://github.com/sally4953/asmcraft

This mod enables you to write programs in assembly language within Minecraft and run them.
At present, the mod just support Minecraft Assembly Language. C++ compiler is still in the process of implementing.
But I will try my best to complete the C++ compiler.

For making the assembled application executable, I implemented a virtual machine(VM) in Minecraft. It uses a completely different framework. So, let me show you the specific information:

Virtual Machine Information

Registers

There are 7 registers. The first four are used as variables when calling a function. Another register stores the pointer for program execution (pointing to the address in memory, indicating the current executing statement), and there is one for storing the function return value. The last register is the result of the condition judgment, with only two states.

Memories

There are two memories in the VM. One is to store the application's commands. Its size is 1024 bytes. So every application shouldn't be more than 1024 bytes ( but I think no one can write such application ). The other memory is to store runtime data. Its size is also 1024 bytes. I think 1024-byte memory is enough for the most players (or programmers).

Commands

The VM supports only 22 commands at present. The following table will show you the information.

Name Comment Length(byte)
nop Do-nothing command. 1
ret Function return command. 1
mov A, B Assign B to A. 5
sub A, B Subtract B from A. 5
mul A, B Multiply A by B. 5
div A, B Divide A by B. 5
jmp A Direct jump to A. 3
cjp A Jump to A if the last register is true. 3
grt A, B If A is greater than B, the last register is true (otherwise not true). 5
lst A, B If A is less than B, the last register is true (otherwise not true). 5
equ A, B If A is equal to B, the last register is true (otherwise not true). 5
cal A Call function A (A is the address in memory or a label). 3
ccl A Call A if the last register is true (A is the address in memory or a label). 3
and Set the last register to true if and only if the values in the first and second registers are both true (otherwise false). 1
or Set the last register to true if and only if one of the values in the first and second registers is true (otherwise false). 1
xor Set the last register to true if and only if the values in the first and second registers are not the same (true or false). 1
not Reverse the last register's value. 1
inc A Add one to A. 3
dec A Subtract one from A. 3
neg A Store the opposite number of A in A. 3
int A Interrupt, request the virtual machine to call the function with the number A in memory, wait for completion, and the virtual machine will set the value to the register 5. For the information of the supported interruptions, view the following table. 2

Interruptions

The VM supports only 12 interrupt commands. The following table will show you the interruptions.

Code Comment
0 Exit.
1 Print a integer above the hotbar.
2 Print a character above the hotbar.
3 Set the world time to the register 0's value.
4 Set the register 5's value to the world time.
5 Take the register 0 as the seed and generate a random number to the register 5.
6 Set the player's score to the register 0's value.
7 Set the register 5's value to the player's score.
8 Set the player's health to the register 0's value.
9 Set the register 5's value to ten times the player's health.
10 Set the X, Y, and Z axis positions of the player to 1/10 of the register 0, register 1, and register 2's values respectively.
11 If the register 0's value is 0, set the register 5 to ten times the player's X-axis position; if it is 1, set the register 5 to ten times the player's Y-axis position; if it is 2, set the register 5 to ten times the player's Z-axis position; otherwise, R5 remains 0.

This mod has better support for Chinese. Therefore, if you are not familiar with Chinese, you may need to use a translator.

The above is all the content of this mod. Anyway, enjoy it!

Available Versions

Asm Craft 1.0-SNAPSHOT-2alpha
MC 1.21.4fabric
March 1, 2026
Asm Craft 1.0-SNAPSHOTalpha
MC 1.21.4fabric
February 23, 2026

How to Install Asm Craft on Your Server

1

Order Server

Order a Minecraft Java server with at least 3 GB RAM (4 GB recommended).

2

Set fabric Loader

In the panel under "Egg", select the fabric loader and matching Minecraft version (1.21.4).

3

Install Mod

Open the mod browser in the dashboard and search for "Asm Craft". Click "Install" – done! Alternatively, upload the .jar via SFTP to the /mods folder.

Compatibility

Mod Loaders

fabric

Minecraft Versions

1.21.4

Server-side

Required

Recommended RAM

4 GB(min. 3 GB)

Frequently Asked Questions

Asm Craft server crashes on startup – what to do?

Most common cause: wrong fabric version or insufficient RAM. Check the server log (latest.log) for "OutOfMemoryError" or "Mixin" errors. With Mado Hosting: ensure at least 3 GB RAM is allocated and the loader matches the mod version (1.21.4). You can switch loaders with one click in the panel.

Is Asm Craft compatible with fabric?

Asm Craft officially supports fabric for Minecraft 1.21.4. The Mado dashboard automatically detects incompatible loader combinations.

Server lagging with Asm Craft – how to optimize performance?

Recommended RAM: 4 GB (per 8 players). Use /spark profiler to check if Asm Craft consumes the most tick time. Common fixes: reduce server view-distance to 8-10, install "performant" or "starlight" as supplementary mods on Forge. With Mado Hosting, your server runs on NVMe SSDs with dedicated CPU cores for minimal latency.

Rent Modded Server

Install Asm Craft with just one click on your server.

Recommended RAM
4 GBab €8/mo
Min. 3 GB | +1 GB pro 8 Spieler
Create Server Now
1-Click Mod Install
NVMe SSD Storage
DDoS Protection included

Details

License
MIT License
Server-side
Required

Supported Versions

1.21.4