moire

Kotlin DSL for polymer-virtual-entity

2 011 downloads 1 followers

moire

moire is a Kotlin library providing extension functions and a DSL for polymer-virtual-entity. With moire, you can easily create and manage ElementHolder instance.

Note: The API is subject to change without backward compatibility until version 1.0.0. Please be aware of potential changes.

Gradle Setup

Groovy

repositories {
    maven { url 'https://maven.nucleoid.xyz/' }
    maven { url 'https://api.modrinth.com/maven' }
}

dependencies {
    modImplementation 'eu.pb4:polymer-virtual-entity:POLYMER_VERSION'
    modImplementation 'maven.modrinth:moire:MOIRE_VERSION'
}

Kotlin DSL

repositories {
    maven("https://maven.nucleoid.xyz/")
    maven("https://api.modrinth.com/maven")
}

dependencies {
    modImplementation("eu.pb4:polymer-virtual-entity:POLYMER_VERSION")
    modImplementation("maven.modrinth:moire:MOIRE_VERSION")
}

Usage

Here is a simple example.

import jp.fishmans.moire.elements.*
import jp.fishmans.moire.matrices.rotateLocalYDegrees
import net.minecraft.item.Items

fun create() = elementHolder {
    itemDisplayElement {
        transformation {
            scaleLocal(0.5f)
        }

        onTick {
            transform {
                rotateLocalYDegrees(11.25f)
            }

            startInterpolationIfDirty(1)
        }

        item = Items.TNT.defaultStack
        teleportDuration = 1
    }
}

No gallery available for this project.

Version Minecraft Loader Download

0.4.6

1.21.4
fabric
Download

0.4.5

1.21.4
fabric
Download

0.4.4

1.21.4
fabric
Download

0.4.3

1.21.4
fabric
Download

0.4.2

1.21.4
fabric
Download

0.4.1

1.21.4
fabric
Download

0.4.0

1.21.4
fabric
Download

0.3.10

1.21.4
fabric
Download

0.3.9

1.21.4
fabric
Download

0.3.8

1.21.4
fabric
Download

0.3.7

1.21.4
fabric
Download

0.3.6

1.21.4
fabric
Download

0.3.5

1.21.4
fabric
Download

0.3.4

1.21.4
fabric
Download

0.3.3

1.21.4
fabric
Download

0.3.2

1.21.4
fabric
Download

0.3.1

1.21.4
fabric
Download

0.3.0

1.21.4
fabric
Download

0.2.5

1.21.4
fabric
Download

0.2.4

1.21.4
fabric
Download

0.2.3

1.21.4
fabric
Download

0.2.2

1.21.4
fabric
Download

0.2.1

1.21.4
fabric
Download

0.2.0

1.21.4
fabric
Download

0.1.7

1.21.4
fabric
Download

0.1.6

1.21.4
fabric
Download

0.1.5

1.21.4
fabric
Download

0.1.4

1.21.4
fabric
Download

0.1.3

1.21.4
fabric
Download

0.1.2

1.21.4
fabric
Download

0.1.1

1.21.4
fabric
Download

0.1.0

1.21.4
fabric
Download