mirror of
https://github.com/GTNewHorizons/Angelica.git
synced 2026-11-22 21:29:44 +00:00
* GLStateManagerService & RenderSystemService * Wire up Celeritas * Iris working * Dynamic lights working * Goodbye Sodium 0.2 * Add Multi-Threading for check meshing again
28 lines
878 B
Java
28 lines
878 B
Java
package com.gtnewhorizons.angelica.api;
|
|
|
|
import com.gtnewhorizons.angelica.mixins.interfaces.ITexturesCache;
|
|
import com.gtnewhorizons.angelica.rendering.celeritas.SpriteExtension;
|
|
import net.minecraft.client.renderer.RenderBlocks;
|
|
import net.minecraft.util.IIcon;
|
|
|
|
/**
|
|
* Exposes a method to the API that allow mods to add texture update compat
|
|
*/
|
|
@SuppressWarnings("unused")
|
|
public class TextureServices {
|
|
|
|
@SuppressWarnings("unused")
|
|
public static void updateBlockTextureAnimation(IIcon icon, RenderBlocks renderBlocks) {
|
|
if (renderBlocks instanceof ITexturesCache texturesCache) {
|
|
texturesCache.getRenderedTextures().add(icon);
|
|
}
|
|
}
|
|
|
|
@SuppressWarnings("unused")
|
|
public static void updateTextureAnimation(IIcon icon) {
|
|
if (icon instanceof SpriteExtension ext) {
|
|
ext.celeritas$markActive();
|
|
}
|
|
}
|
|
}
|