R15's Library

Quick rating

R15's Library

No reviews yet

A library that I use for my mods

API/Library
Mod Loaders
Forge
NeoForge
Fabric
Minecraft

Community voices

Reviews

Versions
Loading versions…
Match includes

Click once to include, again to exclude, again to clear

Rating Any
Any 0.5 1.0 1.5 2.0 2.5 3.0 3.5 4.0 4.5 5.0
Min
Max
Play Status
Reviews
Time Played
hrs+
Verified developers only
Has developer response
List view
Grid view
Compact view
Sort by
Date
Rating
Helpful
Unhelpful
Edited
Sort ascending
Delete this review?

This removes your review from the project. You can write a new review after.

Review submitted for moderation

Your review has been sent to moderators, who will check that it meets our guidelines before it appears publicly.

No reviews yet. Be the first to review this project!

Get it on

Available Platforms

Compatibility

Supported Environments

Dev Environment
Client Required
Server Required

About

Project Details

Type
Mod
License
MIT License
Latest Version
0.1.0
Authors

For authors

Embed Badge

If you're the author of this project, you can embed a live badge anywhere that supports HTML or Markdown. It updates automatically whenever ratings change.

Custom banner text
ModDex rating badge preview

Use HTML for any page that supports it, or Markdown for README files and Markdown-based descriptions.

Identifiers

Platform IDs

Modrinth ID

Resources

External Links

Source Issues Wiki Discord

About

Description

banner

Docs

This library includes animation player, Create 0.5.1/6.0.0, Create: Copycats and CC:Tweaked compatibility

Animations

Animation player with a lot of uses

Registering clip in code

AnimationClip clip = AnimationClip.builder("myaddon:drill_pose", 20.0F)
    .looping(true)
    .track(new TimelineTrack("right_arm", List.of(
        new Keyframe(0.0F, Transform.IDENTITY, Easing.LINEAR),
        new Keyframe(10.0F, new Transform(Float3.ZERO, new Float3(-0.5F, 0.0F, 0.0F), Float3.ONE), Easing.EASE_IN_OUT),
        new Keyframe(20.0F, Transform.IDENTITY, Easing.EASE_IN_OUT)
    )))
    .build();

LibraryApi.registerAnimation(new ResourceLocation("myaddon", "drill_pose"), clip);

Playing on server

LibraryApi.playAnimation(serverPlayer, new ResourceLocation("myaddon", "drill_pose"), 1.0F, true);

Triggering from client

LibraryApi.requestSelfAnimation(new ResourceLocation("myaddon", "drill_pose"), 1.0F, true);

This sends a client->server packet and is controlled by config (allowClientAnimationTriggerPacket).

Data-driven clips

Drop JSON into data/<namespace>/r15lib_animations/<name>.json.

Example shape:

{
  "length": 12.0,
  "looping": false,
  "tracks": {
    "right_arm": [
      { "tick": 0.0, "rotation": [0.0, 0.0, 0.0], "easing": "LINEAR" },
      { "tick": 4.0, "rotation": [-0.95, 0.1, 0.0], "easing": "EASE_OUT" },
      { "tick": 12.0, "rotation": [0.0, 0.0, 0.0], "easing": "EASE_IN_OUT" }
    ]
  }
}

Commands

  • /r15lib play <targets> <clip> [looping] [speed]
  • /r15lib stop <targets>
  • /r15lib clips

CC:Tweaked

Key pieces

  • @LuaPeripheralMethod annotation for exposed methods.
  • CcTweakedApi.registerPeripheral(...) to bind a BlockEntity class to a peripheral type.
  • Reflection bridge creates an IDynamicPeripheral proxy when CC is installed.
  • Auto capability attach via Forge event hooks.

Quick example

public class CrusherPeripheralOwner {
    private final MyCrusherBlockEntity blockEntity;

    public CrusherPeripheralOwner(MyCrusherBlockEntity blockEntity) {
        this.blockEntity = blockEntity;
    }

    @LuaPeripheralMethod("get_progress")
    public int getProgress() {
        return blockEntity.getProgress();
    }

    @LuaPeripheralMethod("set_enabled")
    public void setEnabled(boolean enabled) {
        blockEntity.setEnabled(enabled);
    }
}

CcTweakedApi.registerPeripheralFromOwnerClass(
    MyCrusherBlockEntity.class,
    "myaddon_crusher",
    CrusherPeripheralOwner::new,
    CrusherPeripheralOwner.class
);

Commands

  • /r15lib cc
  • /r15lib cc bindings
  • /r15lib cc methods <binding-class>

Create: Copycats Plus

What is included

  • Compat detection with multiple candidate mod ids
  • Copycat block/block entity detection helpers
  • Material scanning (getMaterial)
  • Area survey service returning:
    • scanned block count
    • copycat block count
    • copycat block entity count
    • materialized entry count
    • material id (dominant one)

API

  • CopycatsApi.isLoaded()
  • CopycatsApi.isCopycat(state)
  • CopycatsApi.isCopycat(blockEntity)
  • CopycatsApi.material(blockEntity)
  • CopycatsApi.survey(level, center, radius)

Config

  • enableCopycatsReflection
  • maxCopycatsSurveyRadius

Commands

  • /r15lib copycats
  • /r15lib copycats inspect
  • /r15lib copycats survey [radius]

Create

CreateCompatService auto-detects Create and exposes:

  • installed()
  • line() -> V0_5 / V0_6 / UNKNOWN
  • version()
  • isKineticBlockEntity(BlockEntity)
  • reflection reads:
    • readStressImpact(...)
    • readStressCapacity(...)
    • readSpeed(...)
    • isOverStressed(...)

API usage

CreateAddonApi.snapshot(blockEntity) returns a CreateKineticSnapshot with:

  • impact
  • capacity
  • usage ratio
  • speed
  • overstressed
  • stress tier (IDLE, LIGHT, MEDIUM, HEAVY, CRITICAL)

CreateAddonApi.survey(level, center, radius) aggregates a local kinetic network area.

Commands

  • /r15lib create
  • /r15lib create inspect
  • /r15lib create survey [radius]
  • /r15lib create plan <capacity> <machineImpact>
  • /r15lib create profile list
  • /r15lib create profile calc <profile> <capacity>

Screenshots

Gallery

  • banner
    banner

Versions

Files

Relations

Project Relations

More like this

Similar Mods

Suggestions use data such as tags, dependencies, dependents, descriptions, titles, and more to rank how much they overlap with this mod.

On ModDex

Community snapshot

0
Ratings
0
Followers
0
In stacks

By the numbers

Statistics

<1,000
Downloads
Last Updated
CurseForge
Created
Last synced
When ModDex last fetched this project from CurseForge or Modrinth. Every project is re-checked on a schedule, and any project that ships a new file is synced automatically within hours of the release.
New file updates sync automatically
How syncing works