Interface IRadarOverlay
- All Known Implementing Classes:
DebugOverlay,ExampleOverlay,IDOverlay
public interface IRadarOverlay
An interface defining a radar overlay
To implement this, you must override
render(boolean, RadarRenderData, Object...) and getModID()- Since:
- 0.14.15.2
-
Method Summary
Modifier and TypeMethodDescriptiondefault voidflipPose(com.mojang.blaze3d.vertex.PoseStack poseStack, com.mojang.math.Axis axis) Flips aPoseStackon the specifiedAxis.default net.minecraft.resources.ResourceLocationgetID()The ID of this overlay, defined bygetModID()andgetIDPath()default StringIf not overriden, this method returns the class name of the implementor converted to snake casegetModID()default RadarModegetRadarMode(RadarRenderData radarRenderData) Get theRadarModeof the radardefault voidorientUpwards(com.mojang.blaze3d.vertex.PoseStack poseStack) Orients aPoseStackto face upwards.default voidplaceOnRadar(net.minecraft.world.phys.Vec3 location, com.mojang.blaze3d.vertex.PoseStack poseStack, RadarRenderData rrd) Goes to the givenVec3relative to the radar's position.default voidposeToRadarSpace(com.mojang.blaze3d.vertex.PoseStack poseStack, RadarRenderData rrd) Transforms and scales a pose so that 1 block in world space == 1 pixel in radar space.default voidposeToWorldSpace(com.mojang.blaze3d.vertex.PoseStack poseStack, RadarRenderData rrd) Untransforms and scales a pose where 1 block in world space == 1 pixel in radar space.default net.minecraft.world.phys.Vec3radarToWorldCoords(double x, double z, net.minecraft.core.BlockPos radarPos, float sizeRenderDiameter, float simSize) Translates aVec3of radar coordinates to aVec3of absolute coordinatesdefault net.minecraft.world.phys.Vec3radarToWorldCoords(double x, double z, RadarRenderData rrd) Translates aVec3of radar coordinates to aVec3of absolute coordinatesdefault net.minecraft.world.phys.Vec3radarToWorldCoords(net.minecraft.world.phys.Vec3 pos, net.minecraft.core.BlockPos radarPos, float sizeRenderDiameter, float simSize) Translates aVec3of radar coordinates to aVec3of absolute coordinatesdefault net.minecraft.world.phys.Vec3radarToWorldCoords(net.minecraft.world.phys.Vec3 pos, RadarRenderData rrd) Translates aVec3of radar coordinates to aVec3of absolute coordinatesvoidrender(boolean canRender, RadarRenderData radarRenderData, Object... args) Renders objects on top of the radardefault voidrenderQuad(RadarRenderData radarRenderData, float qx, float qy, float qz, float scale, com.mojang.blaze3d.vertex.PoseStack poseStack, int color, int cli) default voidrenderQuad(RadarRenderData radarRenderData, net.minecraft.world.phys.Vec3 q, float scale, com.mojang.blaze3d.vertex.PoseStack pose, int color, int cli) default voidrenderText(net.minecraft.network.chat.Component component, RadarRenderData radarRenderData) Render the text given in the givenComponentdefault voidrenderText(net.minecraft.network.chat.Component component, RadarRenderData radarRenderData, com.mojang.blaze3d.vertex.PoseStack poseStack) Render the text given in the givenComponentdefault voidrenderText(net.minecraft.network.chat.Component component, RadarRenderData radarRenderData, com.mojang.blaze3d.vertex.PoseStack poseStack, int backgroundColor) Render the text given in the givenComponentwith a background colordefault voidrenderTexture(net.minecraft.resources.ResourceLocation texture, RadarRenderData radarRenderData) Render a texture at the givenResourceLocationdefault voidrenderTexture(net.minecraft.resources.ResourceLocation texture, RadarRenderData radarRenderData, int color) Render a texture at the givenResourceLocationdefault voidrenderTexture(net.minecraft.resources.ResourceLocation texture, RadarRenderData radarRenderData, com.mojang.blaze3d.vertex.PoseStack poseStack) Render a texture at the givenResourceLocationdefault voidrenderTexture(net.minecraft.resources.ResourceLocation texture, RadarRenderData radarRenderData, com.mojang.blaze3d.vertex.PoseStack poseStack, int color) Render a texture at the givenResourceLocationdefault voidrenderTextureUpwards(net.minecraft.resources.ResourceLocation texture, RadarRenderData radarRenderData) Renders a texture from the givenResourceLocationfacing upwards.default voidrenderTextureUpwards(net.minecraft.resources.ResourceLocation texture, RadarRenderData radarRenderData, int color) Renders a texture from the givenResourceLocationfacing upwards.default voidrenderTextureUpwards(net.minecraft.resources.ResourceLocation texture, RadarRenderData radarRenderData, com.mojang.blaze3d.vertex.PoseStack poseStack) Renders a texture from the givenResourceLocationfacing upwards.default voidrenderTextureUpwards(net.minecraft.resources.ResourceLocation texture, RadarRenderData radarRenderData, com.mojang.blaze3d.vertex.PoseStack poseStack, int color) Renders a texture from the givenResourceLocationfacing upwards.default voidscale(com.mojang.blaze3d.vertex.PoseStack pose, float scaleFactor) Scales a pose by a uniform scale factordefault voidtexVertex(com.mojang.blaze3d.vertex.VertexConsumer buffer, com.mojang.blaze3d.vertex.PoseStack.Pose pose, int color, float x, float y, float z, float u, float v, int overlay) default voidunorientUpwards(com.mojang.blaze3d.vertex.PoseStack poseStack) Unorients aPoseStackthat is facing upwards.default net.minecraft.world.phys.Vec3worldToRadarCoords(double x, double z, net.minecraft.core.BlockPos radarPos, float sizeRenderDiameter, float simSize) Translates aVec3of absolute coordinates to aVec3of radar coordinatesdefault net.minecraft.world.phys.Vec3worldToRadarCoords(double x, double z, RadarRenderData rrd) Translates absolute coordinates to aVec3of radar coordinatesdefault net.minecraft.world.phys.Vec3worldToRadarCoords(net.minecraft.world.phys.Vec3 pos, net.minecraft.core.BlockPos radarPos, float sizeRenderDiameter, float simSize) Translates aVec3of absolute coordinates to aVec3of radar coordinatesdefault net.minecraft.world.phys.Vec3worldToRadarCoords(net.minecraft.world.phys.Vec3 pos, RadarRenderData rrd) Translates aVec3of absolute coordinates to aVec3of radar coordinates
-
Method Details
-
render
Renders objects on top of the radar- Parameters:
canRender-trueif either the server doesn't require WSR-88D or a WSR-88D is complete within 4 chunks of the radarradarRenderData- The data used to callBlockEntityRenderer.render(BlockEntity, float, PoseStack, MultiBufferSource, int, int)args- The arguments to pass to the Radar Overlay- Since:
- 0.14.15.2
-
getRadarMode
Get theRadarModeof the radar- Parameters:
radarRenderData- TheRadarRenderData- Returns:
- The radar's
RadarMode - Since:
- 0.14.16.2
-
renderQuad
default void renderQuad(RadarRenderData radarRenderData, net.minecraft.world.phys.Vec3 q, float scale, com.mojang.blaze3d.vertex.PoseStack pose, int color, int cli) -
renderQuad
default void renderQuad(RadarRenderData radarRenderData, float qx, float qy, float qz, float scale, com.mojang.blaze3d.vertex.PoseStack poseStack, int color, int cli) -
texVertex
default void texVertex(com.mojang.blaze3d.vertex.VertexConsumer buffer, com.mojang.blaze3d.vertex.PoseStack.Pose pose, int color, float x, float y, float z, float u, float v, int overlay) -
renderTexture
default void renderTexture(net.minecraft.resources.ResourceLocation texture, RadarRenderData radarRenderData, com.mojang.blaze3d.vertex.PoseStack poseStack, int color) Render a texture at the givenResourceLocation- Parameters:
texture- TheResourceLocationof the textureradarRenderData- TheRadarRenderDataposeStack- ThePoseStackto render withcolor- The color- Since:
- 0.15.3.3
-
renderTextureUpwards
default void renderTextureUpwards(net.minecraft.resources.ResourceLocation texture, RadarRenderData radarRenderData, com.mojang.blaze3d.vertex.PoseStack poseStack, int color) Renders a texture from the givenResourceLocationfacing upwards. Not guaranteed to work when other rotation transformations are present!- Parameters:
texture- TheResourceLocationof the textureradarRenderData- TheRadarRenderDataposeStack- ThePoseStackto render withcolor- The color- Since:
- 0.16.1.0-rc2
-
renderTexture
default void renderTexture(net.minecraft.resources.ResourceLocation texture, RadarRenderData radarRenderData, com.mojang.blaze3d.vertex.PoseStack poseStack) Render a texture at the givenResourceLocation- Parameters:
texture- TheResourceLocationof the textureradarRenderData- TheRadarRenderDataposeStack- ThePoseStackto render with- Since:
- 0.15.3.3
-
renderTextureUpwards
default void renderTextureUpwards(net.minecraft.resources.ResourceLocation texture, RadarRenderData radarRenderData, com.mojang.blaze3d.vertex.PoseStack poseStack) Renders a texture from the givenResourceLocationfacing upwards. Not guaranteed to work when other rotation transformations are present!- Parameters:
texture- TheResourceLocationof the textureradarRenderData- TheRadarRenderDataposeStack- ThePoseStackto render with- Since:
- 0.16.1.0-rc2
-
renderTexture
default void renderTexture(net.minecraft.resources.ResourceLocation texture, RadarRenderData radarRenderData, int color) Render a texture at the givenResourceLocation- Parameters:
texture- TheResourceLocationof the textureradarRenderData- TheRadarRenderDatacolor- The color- Since:
- 0.15.3.3
-
renderTextureUpwards
default void renderTextureUpwards(net.minecraft.resources.ResourceLocation texture, RadarRenderData radarRenderData, int color) Renders a texture from the givenResourceLocationfacing upwards. Not guaranteed to work when other rotation transformations are present!- Parameters:
texture- TheResourceLocationof the textureradarRenderData- TheRadarRenderDatacolor- The color- Since:
- 0.16.1.0-rc2
-
renderTexture
default void renderTexture(net.minecraft.resources.ResourceLocation texture, RadarRenderData radarRenderData) Render a texture at the givenResourceLocation- Parameters:
texture- TheResourceLocationof the textureradarRenderData- TheRadarRenderData- Since:
- 0.15.3.3
-
renderTextureUpwards
default void renderTextureUpwards(net.minecraft.resources.ResourceLocation texture, RadarRenderData radarRenderData) Renders a texture from the givenResourceLocationfacing upwards. Not guaranteed to work when other rotation transformations are present!- Parameters:
texture- TheResourceLocationof the textureradarRenderData- TheRadarRenderData- Since:
- 0.16.1.0-rc2
-
renderText
default void renderText(net.minecraft.network.chat.Component component, RadarRenderData radarRenderData, com.mojang.blaze3d.vertex.PoseStack poseStack, int backgroundColor) Render the text given in the givenComponentwith a background color- Parameters:
component- TheComponentto renderradarRenderData- TheRadarRenderDataposeStack- ThePoseStackto render withbackgroundColor- The background color to render- Since:
- 0.16.0.0
-
renderText
default void renderText(net.minecraft.network.chat.Component component, RadarRenderData radarRenderData, com.mojang.blaze3d.vertex.PoseStack poseStack) Render the text given in the givenComponent- Parameters:
component- TheComponentto renderradarRenderData- TheRadarRenderDataposeStack- ThePoseStackto render with- Since:
- 0.14.16.2
-
renderText
default void renderText(net.minecraft.network.chat.Component component, RadarRenderData radarRenderData) Render the text given in the givenComponent- Parameters:
component- TheComponentto renderradarRenderData- TheRadarRenderData- Since:
- 0.14.16.2
-
getModID
String getModID()- Returns:
- The Mod ID of the mod that registered this overlay
- Since:
- 0.14.15.2
-
getIDPath
If not overriden, this method returns the class name of the implementor converted to snake case- Returns:
- The path to use for this overlay's ID
- Since:
- 0.14.15.2
-
getID
default net.minecraft.resources.ResourceLocation getID()The ID of this overlay, defined bygetModID()andgetIDPath()- Returns:
- The
ResourceLocationof this overlay - Since:
- 0.14.15.2
-
scale
default void scale(com.mojang.blaze3d.vertex.PoseStack pose, float scaleFactor) Scales a pose by a uniform scale factor- Parameters:
pose- THePoseStackto scalescaleFactor- The scale factor- Since:
- 0.16.1.0-rc2
-
orientUpwards
default void orientUpwards(com.mojang.blaze3d.vertex.PoseStack poseStack) Orients aPoseStackto face upwards. May not work if other rotations are present!- Parameters:
poseStack- ThePoseStackto orient upwards- Since:
- 0.16.1.0-rc2
-
unorientUpwards
default void unorientUpwards(com.mojang.blaze3d.vertex.PoseStack poseStack) Unorients aPoseStackthat is facing upwards. May not work if other rotations are present!- Parameters:
poseStack- ThePoseStackto unorient- Since:
- 0.16.1.0-rc2
-
flipPose
default void flipPose(com.mojang.blaze3d.vertex.PoseStack poseStack, com.mojang.math.Axis axis) Flips aPoseStackon the specifiedAxis.- Parameters:
poseStack- ThePoseStackto flipaxis- TheAxisto flip around- Since:
- 0.16.1.0-rc2
-
placeOnRadar
default void placeOnRadar(net.minecraft.world.phys.Vec3 location, com.mojang.blaze3d.vertex.PoseStack poseStack, RadarRenderData rrd) Goes to the givenVec3relative to the radar's position. UsesposeToRadarSpace(PoseStack, RadarRenderData)andposeToWorldSpace(PoseStack, RadarRenderData)- Parameters:
location- TheVec3of the absolute locationposeStack- ThePoseStackrrd- TheRadarRenderData- Since:
- 0.16.1.0-rc2
-
poseToRadarSpace
Transforms and scales a pose so that 1 block in world space == 1 pixel in radar space.- Parameters:
poseStack- ThePoseStackto transformrrd- TheRadarRenderData- Since:
- 0.16.1.0-rc2
-
worldToRadarCoords
default net.minecraft.world.phys.Vec3 worldToRadarCoords(net.minecraft.world.phys.Vec3 pos, RadarRenderData rrd) Translates aVec3of absolute coordinates to aVec3of radar coordinates- Parameters:
pos- TheVec3of absolute coordinatesrrd- TheRadarRenderData- Returns:
- The
Vec3of radar coordinates - Since:
- 0.16.1.0-rc2
-
worldToRadarCoords
default net.minecraft.world.phys.Vec3 worldToRadarCoords(net.minecraft.world.phys.Vec3 pos, net.minecraft.core.BlockPos radarPos, float sizeRenderDiameter, float simSize) Translates aVec3of absolute coordinates to aVec3of radar coordinates- Parameters:
pos- TheVec3of absolute coordinatesradarPos- TheBlockPosof the radarsizeRenderDiameter- The diameter of the radar size. Is 3 for small radars and 6 for big (unless 3x3 option is on)simSize- The simulation size of the radar. Is 2048 for small radars and 8192 for big radars- Returns:
- The
Vec3of radar coordinates - Since:
- 0.16.1.0-rc2
-
worldToRadarCoords
Translates absolute coordinates to aVec3of radar coordinates- Parameters:
x- The x-coordinate of the absolute positionz- The z-coordinate of the absolute positionrrd- TheRadarRenderData- Returns:
- The
Vec3of radar coordinates - Since:
- 0.16.1.0-rc2
-
worldToRadarCoords
default net.minecraft.world.phys.Vec3 worldToRadarCoords(double x, double z, net.minecraft.core.BlockPos radarPos, float sizeRenderDiameter, float simSize) Translates aVec3of absolute coordinates to aVec3of radar coordinates- Parameters:
x- The x-coordinate of the absolute positionz- The z-coordinate of the absolute positionsizeRenderDiameter- The diameter of the radar size. Is 3 for small radars and 6 for big (unless 3x3 option is on)simSize- The simulation size of the radar. Is 2048 for small radars and 8192 for big radars- Returns:
- The
Vec3of radar coordinates - Since:
- 0.16.1.0-rc2
-
poseToWorldSpace
Untransforms and scales a pose where 1 block in world space == 1 pixel in radar space.- Parameters:
poseStack- ThePoseStackto transformrrd- TheRadarRenderData- Since:
- 0.16.1.0-rc2
-
radarToWorldCoords
default net.minecraft.world.phys.Vec3 radarToWorldCoords(net.minecraft.world.phys.Vec3 pos, RadarRenderData rrd) Translates aVec3of radar coordinates to aVec3of absolute coordinates- Parameters:
pos- TheVec3of radar coordinatesrrd- TheRadarRenderData- Returns:
- The
Vec3of radar coordinates - Since:
- 0.16.1.0-rc2
-
radarToWorldCoords
default net.minecraft.world.phys.Vec3 radarToWorldCoords(net.minecraft.world.phys.Vec3 pos, net.minecraft.core.BlockPos radarPos, float sizeRenderDiameter, float simSize) Translates aVec3of radar coordinates to aVec3of absolute coordinates- Parameters:
pos- TheVec3of radar coordinatessizeRenderDiameter- The diameter of the radar size. Is 3 for small radars and 6 for big (unless 3x3 option is on)simSize- The simulation size of the radar. Is 2048 for small radars and 8192 for big radars- Returns:
- The
Vec3of radar coordinates - Since:
- 0.16.1.0-rc2
-
radarToWorldCoords
Translates aVec3of radar coordinates to aVec3of absolute coordinates- Parameters:
x- The x-coordinate of the radar positionz- The z-coordinate of the radar positionrrd- TheRadarRenderData- Returns:
- The
Vec3of radar coordinates - Since:
- 0.16.1.0-rc2
-
radarToWorldCoords
default net.minecraft.world.phys.Vec3 radarToWorldCoords(double x, double z, net.minecraft.core.BlockPos radarPos, float sizeRenderDiameter, float simSize) Translates aVec3of radar coordinates to aVec3of absolute coordinates- Parameters:
x- The x-coordinate of the radar positionz- The z-coordinate of the radar positionsizeRenderDiameter- The diameter of the radar size. Is 3 for small radars and 6 for big (unless 3x3 option is on)simSize- The simulation size of the radar. Is 2048 for small radars and 8192 for big radars- Returns:
- The
Vec3of radar coordinates - Since:
- 0.16.1.0-rc2
-