2020-04-15 19:06:45 +02:00
|
|
|
package com.minelittlepony.unicopia.container;
|
2020-01-27 17:37:22 +01:00
|
|
|
|
2020-04-25 13:32:33 +02:00
|
|
|
import net.fabricmc.fabric.api.container.ContainerFactory;
|
2020-01-27 17:37:22 +01:00
|
|
|
import net.fabricmc.fabric.api.container.ContainerProviderRegistry;
|
2020-04-25 13:32:33 +02:00
|
|
|
import net.minecraft.container.Container;
|
2020-01-27 17:37:22 +01:00
|
|
|
import net.minecraft.util.Identifier;
|
|
|
|
|
2020-04-15 12:37:14 +02:00
|
|
|
public interface UContainers {
|
2020-01-27 17:37:22 +01:00
|
|
|
|
2020-04-25 13:32:33 +02:00
|
|
|
Identifier BAG_OF_HOLDING = register("bag_of_holding", BagOfHoldingContainer::new);
|
|
|
|
Identifier SPELL_BOOK = register("spell_book", SpellBookContainer::new);
|
2020-01-27 17:37:22 +01:00
|
|
|
|
2020-04-25 13:32:33 +02:00
|
|
|
static Identifier register(String name, ContainerFactory<Container> factory) {
|
|
|
|
Identifier id = new Identifier("unicopia", name);
|
|
|
|
ContainerProviderRegistry.INSTANCE.registerFactory(BAG_OF_HOLDING, factory);
|
|
|
|
return id;
|
2020-01-27 17:37:22 +01:00
|
|
|
}
|
2020-04-25 13:32:33 +02:00
|
|
|
|
|
|
|
static void bootstrap() { }
|
2020-01-27 17:37:22 +01:00
|
|
|
}
|