forked from alRex-U/ParCool
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathRenderPipelines.java
More file actions
25 lines (22 loc) · 1.15 KB
/
RenderPipelines.java
File metadata and controls
25 lines (22 loc) · 1.15 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
package com.alrex.parcool.client.renderer;
import com.alrex.parcool.ParCool;
import com.mojang.blaze3d.pipeline.RenderPipeline;
import com.mojang.blaze3d.vertex.DefaultVertexFormat;
import com.mojang.blaze3d.vertex.VertexFormat;
import net.minecraft.resources.ResourceLocation;
public class RenderPipelines {
private static final RenderPipeline.Snippet ZIPLINE_SNIPPET = RenderPipeline.builder(net.minecraft.client.renderer.RenderPipelines.MATRICES_FOG_SNIPPET)
.withVertexShader("core/rendertype_leash")
.withFragmentShader("core/rendertype_leash")
.withSampler("Sampler2")
.withVertexFormat(DefaultVertexFormat.POSITION_COLOR_LIGHTMAP, VertexFormat.Mode.QUADS)
.buildSnippet();
public static final RenderPipeline ZIPLINE_3D = RenderPipeline.builder(ZIPLINE_SNIPPET)
.withLocation(ResourceLocation.fromNamespaceAndPath(ParCool.MOD_ID, "zipline3d"))
.withCull(true)
.build();
public static final RenderPipeline ZIPLINE_2D = RenderPipeline.builder(ZIPLINE_SNIPPET)
.withLocation(ResourceLocation.fromNamespaceAndPath(ParCool.MOD_ID, "zipline2d"))
.withCull(false)
.build();
}