▶️ ЗАБЕРИ СВОИ 8 ПОДАРКОВ 🎁 ПРИ СОЗДАНИИ СВОЕГО МАЙНКРАФТ СЕРВЕРА
🔥Тренд дняCaramel Chat⚡Сейчас качаютCaramel Chat🚪Сюда заходят чаще всегоCaramel Chat🚀Взрывает трендыPvp Haimiya Anime Pack🆕Новый хитCaramel Chat📉Люди сбегают отсюдаCaramel Chat🎮Сервер набирает популярностьHypixel🔻Теряет популярностьBlack Pvp Pack🧲Самый липкий ресурсSky V1🔥Тренд дняCaramel Chat⚡Сейчас качаютCaramel Chat🚪Сюда заходят чаще всегоCaramel Chat🚀Взрывает трендыPvp Haimiya Anime Pack🆕Новый хитCaramel Chat📉Люди сбегают отсюдаCaramel Chat🎮Сервер набирает популярностьHypixel🔻Теряет популярностьBlack Pvp Pack🧲Самый липкий ресурсSky V1🔥Тренд дняCaramel Chat⚡Сейчас качаютCaramel Chat🚪Сюда заходят чаще всегоCaramel Chat🚀Взрывает трендыPvp Haimiya Anime Pack🆕Новый хитCaramel Chat📉Люди сбегают отсюдаCaramel Chat🎮Сервер набирает популярностьHypixel🔻Теряет популярностьBlack Pvp Pack🧲Самый липкий ресурсSky V1🔥Тренд дняCaramel Chat⚡Сейчас качаютCaramel Chat🚪Сюда заходят чаще всегоCaramel Chat🚀Взрывает трендыPvp Haimiya Anime Pack🆕Новый хитCaramel Chat📉Люди сбегают отсюдаCaramel Chat🎮Сервер набирает популярностьHypixel🔻Теряет популярностьBlack Pvp Pack🧲Самый липкий ресурсSky V1🔥Тренд дняCaramel Chat⚡Сейчас качаютCaramel Chat🚪Сюда заходят чаще всегоCaramel Chat🚀Взрывает трендыPvp Haimiya Anime Pack🆕Новый хитCaramel Chat📉Люди сбегают отсюдаCaramel Chat🎮Сервер набирает популярностьHypixel🔻Теряет популярностьBlack Pvp Pack🧲Самый липкий ресурсSky V1🔥Тренд дняCaramel Chat⚡Сейчас качаютCaramel Chat🚪Сюда заходят чаще всегоCaramel Chat🚀Взрывает трендыPvp Haimiya Anime Pack🆕Новый хитCaramel Chat📉Люди сбегают отсюдаCaramel Chat🎮Сервер набирает популярностьHypixel🔻Теряет популярностьBlack Pvp Pack🧲Самый липкий ресурсSky V1
Моды/CraftCoreLIB
CraftCoreLIB

CraftCoreLIB

Cross-Platform library providing registgries and utils for mod developers.

Оцените первым
2.3K
1

CraftCoreLIB

CraftCoreLib is a cross-plaftorm library built for developers for simplify registries on multiloader and many more features!

Registries

This lib provides core code for simple registries like blocks, items, creativetabs to recipetypes, recipe serializers menu and more coming!!

Usage Example

public class ModBlocks {

  // Simple Block registration
  public static final ObjectRegistries<Block> MY_BLOCK = ObjectRegistries.registerBlock(
  ResourceLocation.fromNamespaceAndPath("yourmoid", "my_block"),
    ()-> new Block(BlockBehaviour.Properties.of()));

    // It must stay empty, call it on related Init class(for fabric the one implementing ModInitializer for neoforge the class with the @Mod annotation)
    public static void init() {}

}

And initialize all our registris on our setup:

  • Fabric -> ModInitializer class
  • NeoForge -> @Mod annotation class
// Placeholder
public void init() {
  ModBlocks.init();

}

then if Neoforge do this:

private void onRegister(RegisterEvent event) {
  ObjectRegistries.createAll("yourmoid", event.getRegistry());
}

if Fabric inside ModInitializer, after all your init add this:

 ObjectRegistries.createAll("yourmoid");

Configs

CraftCoreLIB also provides a dedicated config system with a custom config screen compatible with other mods!!

Usage Example

public class ModConfigs {


  //Defining all your configs, ConfigValue<> accept all type of configs, Integer, Boolean, Enum, String even your custom one


public static final ConfigValue<Boolean> check;
public static final ConfigValue<Integer> i;

//The config Builder where we build our configs, the constructur needs the modid and the env type: CLIENT, SERVER or COMMON public static final ConfigBuilder BUILDER = new ConfigBuilder("mod_id", ConfigType.CLIENT);

//Inside a static method we register our configs

static {

//Category 1 creantion, we call start to start a category and end to close it, everything behind them is register into the first category BUILDER.strart("category1"); //All the configs you desire to insert onto the 1° category should go there. //The define method accept Integer, Boolean, Enum, String even you custom one! this.check = BUILDER.comment("allows to check something") .defineBoolean("check", false); BUILDER.end();

//Category 2 creation or how many you want BUILDER.strart("category2"); this.i = BUILDER.comment("allows to check something") .defineInt("i",MINVALUE 0, MAXVALUE 10, DEFAULT VALUE 5); BUILDER.end();

//It's also possible to create a main category with each sub category

BUILDER.start("main"); BUILDER.start("category3"); this.check = BUILDER.comment("allows to check something") .defineBoolean("check", false);

this.i = BUILDER.comment("allows to check something") .defineInt("i",MINVALUE 0, MAXVALUE 10, DEFAULT VALUE 5);

BUILDER.end();

BUILDER.end();

}

public static void init() { BUILDER.build(); }

}


### Config Screen
  It features a dedicated Config Screen easy to access.
  It also fetch for all the available mod with config, IT'S NOT A MODLIST MENU, IT ONLY SHOWS  MOD WITH CONFIGS!!
  
!ConfigScreen

# Network Builder
It features:
- Custom Packet creation and handling
- Network Creation
- Network Registration

Chek more on GitHub


Report issues on Discord GitHub Issues

My Other Projects


  
 
  
 
  
Партнёрский материал

Как поиграть с друзьями с модом CraftCoreLIB?

Мод CraftCoreLIB куда интереснее в компании: поднимите сервер Майнкрафт с уже установленным модом, позовите друзей и играйте по своим правилам. Хостинг Майнкрафт для мода CraftCoreLIB будет готов за пару минут - BungeeHost сделает всё за вас.

Часто задаваемые вопросы

Совместимость

Minecraft: Java Edition

26.3.x26.2.x26.1.x1.21.x

Платформы

Поддерживаемые окружения

Клиент и сервер

Ссылки

Детали

Лицензия:
Опубликован:1 месяц назад
Обновлён:2 дня назад
Главная