use of com.simibubi.create.foundation.block.connected.CTSpriteShiftEntry in project Create_Aeronautics by Eriksonnaren.
the class CTSpriteShifter method getCT.
public static CTSpriteShiftEntry getCT(com.simibubi.create.foundation.block.connected.CTSpriteShifter.CTType type, ResourceLocation blockTexture, ResourceLocation connectedTexture) {
String key = type.name() + ":" + blockTexture + "->" + connectedTexture;
if (ENTRY_CACHE.containsKey(key))
return (CTSpriteShiftEntry) ENTRY_CACHE.get(key);
CTSpriteShiftEntry entry = create(type);
entry.set(blockTexture, connectedTexture);
ENTRY_CACHE.put(key, entry);
return entry;
}
use of com.simibubi.create.foundation.block.connected.CTSpriteShiftEntry in project Create by Creators-of-Create.
the class WindowGen method connectedGlassPane.
private static BlockEntry<ConnectedGlassPaneBlock> connectedGlassPane(String name, Supplier<? extends Block> parent, Supplier<CTSpriteShiftEntry> ctshift, ResourceLocation sideTexture, ResourceLocation itemSideTexture, ResourceLocation topTexture, Supplier<Supplier<RenderType>> renderType) {
NonNullConsumer<? super ConnectedGlassPaneBlock> connectedTextures = connectedTextures(() -> new GlassPaneCTBehaviour(ctshift.get()));
String CGPparents = "block/connected_glass_pane/";
String prefix = name + "_pane_";
Function<RegistrateBlockstateProvider, ModelFile> post = getPaneModelProvider(CGPparents, prefix, "post", sideTexture, topTexture), side = getPaneModelProvider(CGPparents, prefix, "side", sideTexture, topTexture), sideAlt = getPaneModelProvider(CGPparents, prefix, "side_alt", sideTexture, topTexture), noSide = getPaneModelProvider(CGPparents, prefix, "noside", sideTexture, topTexture), noSideAlt = getPaneModelProvider(CGPparents, prefix, "noside_alt", sideTexture, topTexture);
NonNullBiConsumer<DataGenContext<Block, ConnectedGlassPaneBlock>, RegistrateBlockstateProvider> stateProvider = (c, p) -> p.paneBlock(c.get(), post.apply(p), side.apply(p), sideAlt.apply(p), noSide.apply(p), noSideAlt.apply(p));
return glassPane(name, parent, itemSideTexture, topTexture, ConnectedGlassPaneBlock::new, renderType, connectedTextures, stateProvider);
}
Aggregations