What are you searching for?

DGLib

DGLib

Common code for MsDogGirl's mods. Includes dynamic skin swapping and emissive skin layer APIs.

download 7 Downloads · favorite 0 Followers · Updated 5 days ago
Forge Library 1.20.1

Versions

inventory_2
DGLib Alpha 1.0

1.0_alpha · 5 days ago · 43.76 KB

Forge 1.20.1

About

My character in a library. Appropriate.

DGLib - Overview

If you're not a dev, this is another boring library mod. Just install it with the mod that requires it- that's all there is to it.

If you are a dev, then this is a another not-so-boring library mod. It has two APIs included, SkinSwapper and SkinGlowLayer, which I use in my mod Cyberware: Visible Modifications. The names pretty much say what they do.

Feature - SkinSwapper API (For Developers)

You can find all the methods included on the GitHub page. Their function is simple: they swap out parts of the player skin with a skin file you've provided. You can swap out any part of the player's skin like their arms and legs, but leave the rest of their skin untouched.

There are also methods to add transparent overlays to a skin in the same way. For example, this is useful if you're making something like armor and want it to have a bit of a tighter fit without fussing with render layers yourself.

But how does it do this, you ask? Well, it actually fetches the player's skin and makes a compound image to load instead. No render layers involved here, keeping compatibility with other mods at a max.

Feature - SkinGlowLayer API (For Developers)

This works the same as the SkinSwapper, but instead adds emissive pixels to the player skin via a render layer. You just need a transparent image with the pixels you want to glow and use that when you call the methods.

Compatibility (For Developers)

This depends on the you and your use case as a dev. SkinGlowLayer, however, has some compat built in with Epic Fight. It will turn itself off in fight mode, preventing visual glitches... for the most part.

Modpacks?

If you're publishing the pack, it needs to be on either Modrinth or Curseforge.

open_in_new View on Modrinth
Categories
Compatibility
Client: Required Server: Optional
gavel CC-BY-NC-SA-4.0

Conversation

What are your thoughts?

Related projects

Library
Fabric API
Fabric API

by modmuss50

Lightweight and modular API providing common hooks and intercompatibility measures utilized by mods using the Fabric toolchain.

download 128.4M
favorite 27,401
Library
Cloth Config API
Cloth Config API

by shedaniel

Configuration Library for Minecraft Mods

download 94.4M
favorite 13,670
Library Management Utility
YetAnotherConfigLib (YACL)
YetAnotherConfigLib (YACL)

by isxander

A builder-based configuration library for Minecraft!

download 66.1M
favorite 7,607
Library
Architectury API
Architectury API

by shedaniel

An intermediary api aimed to ease developing multiplatform mods.

download 61.0M
favorite 6,652
lock Cookie consent

SkinMC uses cookies to provide functionality and features.