ChosenLib

ChosenLib

Mod

ChosenLib: a lightweight utility library for Fabric

Client or server Library

31 downloads
0 followers
Follow Save

ChosenLib 1.1.0

Changelog

ChosenLib v1.1.0 – Changelog

New in this release

General-purpose utility functions added to ChosenLib

  • randomInt(int min, int max): Get a random integer in a range.
  • clamp(int value, int min, int max): Clamp a value between min and max.
  • lerp(double a, double b, double t): Linear interpolation between two values.
  • isBetween(int value, int min, int max): Check if a value is within a range.
  • safeEquals(Object a, Object b): Null-safe equality check.
  • debugLog(String message): Log debug messages with the mod logger.

Expanded TextUtils with new helpers

  • capitalize(String input): Capitalize the first letter of a string.
  • repeat(String str, int times): Repeat a string multiple times.
  • isNullOrEmpty(String str): Check if a string is null or empty.
  • join(String separator, String... elements): Join strings with a separator.

Documentation

  • README updated with usage examples for all new functions.

No breaking changes. Code is fully documented and ready for use in your Fabric mods!

Dependencies

Files

chosenlib-1.1.0.jar(16.7 KiB) Primary Download

Project members

urmoit

Owner

Details

Licensed MIT
Published 5 days ago
Updated 4 days ago