COWMODSКаталог модов

Moxlib

A library of many helpful functions, tags and predicates, to improve the datapack developer's day.

1,8 тыс.9обновлён 19 июн. 2024 г.
Библиотеки

Описание

Moxlib

Moxvallix's Datapack Creation Library

Moxlib aims to make Datapack creation fun and enjoyable.

With a predictable API, and a focus on data driven functionality, Moxlib serves as an excellent foundation to any Datapack project.

Moxlib aims to run as little as possible on the tick function. Most functions in the pack only run when they are called.

Another focus of the pack is instantaneous functions. Most of the functions in the pack have been designed to run in a single tick, and do not use schedules, or other timer based methods.

Moxlib is licensed under the GNU LGPL, meaning you are free to use it in your own Datapacks, themselves under any license, but any changes you make to Moxlib must be released under the terms of the LGPL. See LICENSE.md for full license.

Suggestions and contributions welcomed!

The API

Conventions

Any function outside of the moxlib:api folder is considered private, and is not supported.

Functions that take in data storage as an input, will read and write data at the same path you would use to call the function.

Eg. /function moxlib:api/helpers/block/get writes to /data get storage moxlib:api/helpers/block/get

However, the test and tui modules are an exception, using more semantic language for their respective tasks. See their individual documentations.

Functions will usually take in a target. Think of this as the main input. It is the piece of data that the function will manipulate. Functions will occasionally ask for other data as well.

Functions, if they output anything, will write to output. Optionally, they might also record their success to a success tag, although not all functions implement this.

Some functions and modules are marked as "experimental". These require Moxlib Exp to function.

Modules

Helpers

See documentation...

The helpers module contains small, miscellaneous, but helpful functions.

These functions are too small and specific to warrant a module of their own.

Data

See documentation...

The data module contains functions specifically for working with arrays of NBT data.

Test

See documentation...

The test module contains functions for testing other functions.

Currently, it can only test to see that a function returned the correct value.

TUI

See documentation...

The TUI module allows for easy creation of data driven TUIs.

Math

See documentation...

The Math module provides some helpful math functions.

Player

See documentation...

The Player module exposes some helpful information about the player.

String

See documentation...

The String module provides functions to manipulate strings.

Dimension

See documentation...

Moxlib provides a dimension for storing and accessing blocks. (Requires Moxlib Exp)

Галерея

Moxlib

Последние версии

Все версии →
release

Moxlib v0.5.13

0.5.13
19 июн. 2024 г.495Minecraft: 1.21datapack
Скачать
Что нового
## [0.5.13] - 2024-06-19 ### Changed - Pack now requires 1.21
release

Moxlib v0.5.12

0.5.12
27 апр. 2024 г.80Minecraft: 1.20.5, 1.20.6datapack
Скачать
Что нового
## [0.5.12] - 2024-04-28 ### Changed - Pack now requires 1.20.5 - String / ASCII now only has one function, lookup. - Helpers / Block / Get now uses a binary search tree. - Helpers / Data / Type no longer has `json` type. ### Removed - String / ASCII decode and encode.
release

Moxlib v0.5.11

0.5.11
23 дек. 2023 г.144Minecraft: 1.20.2, 1.20.3, 1.20.4datapack
Скачать
Что нового
## [0.5.11] - 2023-12-24 ### Added - String / Concatenate, to combine two strings. Requires 1.20.2+. ### Fixed - String / From Array now actually functions.
release

Moxlib v0.5.10

0.5.10
23 дек. 2023 г.35Minecraft: 1.20.2, 1.20.3, 1.20.4datapack
Скачать
Что нового
## [0.5.10] - 2023-12-24 ### Added - New Exec function, which executes the command in `target`. Requires 1.20.2+. ### Changed - String / From Array has been moved out of Moxlib Experimental. Requires 1.20.2+.
release

Moxlib v0.5.9

0.5.9
26 нояб. 2023 г.190Minecraft: 1.20, 1.20.1, 1.20.2datapack
Скачать
Что нового
## [0.5.9] - 2023-11-23 ### Fixed - Helpers / Inventory / Insert no longer overflows incorrectly.
release

Moxlib v0.5.8

0.5.8
24 авг. 2023 г.135Minecraft: 1.20, 1.20.1datapack
Скачать
Что нового
## [0.5.8] - 2023-08-24 ### Added - Data / Array / Reverse, to reverse the order of an array. - Helpers / Inventory / Insert, to handle adding items to inventory NBT. ### Changed - Predicates have been updated to the 1.20 format.
release

Moxlib v0.5.7

0.5.7
31 мар. 2023 г.118Minecraft: 1.19.4datapack
Скачать
Что нового
## [0.5.7] - 2023-04-01 ### Added - Verify function, to check that Moxlib is installed. - Data / Array / Slice, to select data from an array between the `start` and `end` indexes. - String / ASCII - Table, a two dimensional array, of all the ASCII characters at their correct co-ordinates. - Reference, an object containing all ASCII characters that can't be directly written in NBT. - Encode, given a character, return it's ASCII index as a byte. - Decode, given an index, return it's corresponding ASCII character.
release

Moxlib v0.5.6

0.5.6
19 февр. 2023 г.132Minecraft: 1.19, 1.19.1, 1.19.2, 1.19.3, 1.19.4datapack
Скачать
Что нового
## [0.5.6] - 2023-02-20 ### Changed - Math / Constants now have 2000, 4000, 8000, and 10000 - Helpers / Block / Get can now get block states. - Running all tests from Test / Start will display a percentage of successful tests.
release

Moxlib v0.5.5

0.5.5
6 февр. 2023 г.61Minecraft: 1.19, 1.19.1, 1.19.2, 1.19.3datapack
Скачать
Что нового
## [0.5.5] - 2023-02-03 ### Fixed - Version number set correctly again. - String / Filter, being inconsistent because entities randomly re-order tags, is now fixed.
release

Moxlib v0.5.4

0.5.4
1 февр. 2023 г.52Minecraft: 1.19, 1.19.1, 1.19.2, 1.19.3datapack
Скачать
Что нового
## [0.5.4] - 2023-02-02 ### Added - Helpers / Block / Place, places the given block at ~ ~ ~. Runs a callback when it has finished.