Fix build issues outside IDE

This commit is contained in:
simibubi 2020-05-25 13:34:25 +02:00
parent 67f88e666c
commit 85a30afc2b
2 changed files with 4 additions and 4 deletions

View file

@ -44,8 +44,7 @@ public class PalettesVariantEntry {
if (pattern.hasFoliage()) if (pattern.hasFoliage())
builder.item() builder.item()
.transform(CreateRegistrate.itemColors(() -> AllColorHandlers::getGrassyItem)::apply) .transform(CreateRegistrate.itemColors(() -> AllColorHandlers::getGrassyItem));
.build();
else else
builder.simpleItem(); builder.simpleItem();

View file

@ -124,9 +124,10 @@ public class CreateRegistrate extends AbstractRegistrate<CreateRegistrate> {
return b -> b.onRegister(entry -> onClient(() -> () -> registerBlockVertexColor(entry, colorFunc))); return b -> b.onRegister(entry -> onClient(() -> () -> registerBlockVertexColor(entry, colorFunc)));
} }
public static NonNullUnaryOperator<ItemBuilder<? extends BlockItem, ?>> itemColors( public static <I extends BlockItem, P> NonNullFunction<ItemBuilder<I, P>, P> itemColors(
Supplier<Supplier<IItemColor>> colorFunc) { Supplier<Supplier<IItemColor>> colorFunc) {
return b -> b.onRegister(entry -> onClient(() -> () -> registerItemColor(entry, colorFunc))); return b -> b.onRegister(entry -> onClient(() -> () -> registerItemColor(entry, colorFunc)))
.build();
} }
protected static void onClient(Supplier<Runnable> toRun) { protected static void onClient(Supplier<Runnable> toRun) {