Class ScreenPainter
java.lang.Object
net.ixdarklord.folios.internal.client.paint.AbstractPainter
net.ixdarklord.folios.internal.client.paint.ScreenPainter
- All Implemented Interfaces:
GuidePainter
-
Nested Class Summary
Nested classes/interfaces inherited from class AbstractPainter
AbstractPainter.Hit, AbstractPainter.NavigatorNested classes/interfaces inherited from interface GuidePainter
GuidePainter.Drag, GuidePainter.Scroll -
Field Summary
Fields inherited from class AbstractPainter
font, navigator, palette, session -
Constructor Summary
ConstructorsConstructorDescriptionScreenPainter(net.minecraft.client.gui.GuiGraphicsExtractor graphics, float x, float y, float scale, GuidePalette palette, GuideSession session, AbstractPainter.Navigator navigator, float time, float pointerX, float pointerY, List<AbstractPainter.Hit> hits) -
Method Summary
Modifier and TypeMethodDescriptionvoidDraws over everything drawn so far, items included (which otherwise lie over flat things drawn after them): for a reveal's effect about an item or over a whole page.protected voiddrawItem(net.minecraft.world.item.ItemStack stack, int x, int y, int argb) Draws an item, tinted byargb(white and opaque: as it is).voidend()Ends the page: undoes the painter's place on the screen.voidfill(int x0, int y0, int x1, int y1, int argb) booleanflat()Whether the page is on a screen (true), or on a book in the world (false).protected voidpopped()protected voidpushed()protected voidscaled(float factor) voidscene(net.ixdarklord.coolcatcanvas.api.client.viewport.SceneViewport viewport, int x, int y, int width, int height) A scene's picture; the painter keeps it in use while it is drawn.voidscene(net.ixdarklord.coolcatcanvas.api.client.viewport.SceneViewport viewport, int x, int y, int width, int height, float u0, float u1) AsGuidePainter.scene(SceneViewport, int, int, int, int), showing only the part of it fromu0tou1across (0 to 1).voidscene(net.ixdarklord.coolcatcanvas.api.client.viewport.SceneViewport viewport, int x, int y, int width, int height, float u0, float v0, float u1, float v1, int argb) AsGuidePainter.scene(SceneViewport, int, int, int, int), showing only the part of it from (u0,v0) to (u1,v1) (0 to 1, from its top left), tinted byargb: its alpha fades the picture.voidtext(net.minecraft.util.FormattedCharSequence text, int x, int y, int argb) voidtexture(net.minecraft.resources.Identifier texture, int x, int y, int width, int height, float u0, float v0, float u1, float v1, int argb) A part of a texture, from its (u0, v0) to its (u1, v1), each 0 to 1, tinted byargb.protected voidtranslated(float x, float y) Methods inherited from class AbstractPainter
action, drag, font, hovered, item, item, link, pageHeight, pageScale, pageWidth, pageX, pageY, palette, pop, push, scale, scroll, time, tooltip, tooltip, tooltip, tooltipLines, translateMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface GuidePainter
centeredText, contentBottom, contentRight, text
-
Constructor Details
-
Method Details
-
end
public void end()Ends the page: undoes the painter's place on the screen. -
flat
public boolean flat()Description copied from interface:GuidePainterWhether the page is on a screen (true), or on a book in the world (false). -
fill
public void fill(int x0, int y0, int x1, int y1, int argb) -
text
public void text(net.minecraft.util.FormattedCharSequence text, int x, int y, int argb) -
texture
public void texture(net.minecraft.resources.Identifier texture, int x, int y, int width, int height, float u0, float v0, float u1, float v1, int argb) Description copied from interface:GuidePainterA part of a texture, from its (u0, v0) to its (u1, v1), each 0 to 1, tinted byargb. -
above
Description copied from class:AbstractPainterDraws over everything drawn so far, items included (which otherwise lie over flat things drawn after them): for a reveal's effect about an item or over a whole page.- Overrides:
abovein classAbstractPainter
-
drawItem
protected void drawItem(net.minecraft.world.item.ItemStack stack, int x, int y, int argb) Description copied from class:AbstractPainterDraws an item, tinted byargb(white and opaque: as it is).- Specified by:
drawItemin classAbstractPainter
-
scene
public void scene(net.ixdarklord.coolcatcanvas.api.client.viewport.SceneViewport viewport, int x, int y, int width, int height) Description copied from interface:GuidePainterA scene's picture; the painter keeps it in use while it is drawn. -
scene
public void scene(net.ixdarklord.coolcatcanvas.api.client.viewport.SceneViewport viewport, int x, int y, int width, int height, float u0, float u1) Description copied from interface:GuidePainterAsGuidePainter.scene(SceneViewport, int, int, int, int), showing only the part of it fromu0tou1across (0 to 1). -
scene
public void scene(net.ixdarklord.coolcatcanvas.api.client.viewport.SceneViewport viewport, int x, int y, int width, int height, float u0, float v0, float u1, float v1, int argb) Description copied from interface:GuidePainterAsGuidePainter.scene(SceneViewport, int, int, int, int), showing only the part of it from (u0,v0) to (u1,v1) (0 to 1, from its top left), tinted byargb: its alpha fades the picture. -
pushed
protected void pushed()- Specified by:
pushedin classAbstractPainter
-
popped
protected void popped()- Specified by:
poppedin classAbstractPainter
-
translated
protected void translated(float x, float y) - Specified by:
translatedin classAbstractPainter
-
scaled
protected void scaled(float factor) - Specified by:
scaledin classAbstractPainter
-