Class CottonHud
java.lang.Object
io.github.cottonmc.cotton.gui.client.CottonHud
Deprecated, for removal: This API element is subject to removal in a future version.
Manages widgets that are painted on the in-game HUD.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interface
Deprecated, for removal: This API element is subject to removal in a future version.Positioners can be used to change the position of a widget based on the window dimensions. -
Constructor Summary
ConstructorsConstructorDescriptionDeprecated, for removal: This API element is subject to removal in a future version. -
Method Summary
Modifier and TypeMethodDescriptionstatic void
Deprecated, for removal: This API element is subject to removal in a future version.Adds a new widget to the HUD.static void
Deprecated, for removal: This API element is subject to removal in a future version.Adds a new widget to the HUD at the specified offsets.static void
Deprecated, for removal: This API element is subject to removal in a future version.Adds a new widget to the HUD at the specified offsets and resizes it.static void
add
(WWidget widget, CottonHud.Positioner positioner) Deprecated, for removal: This API element is subject to removal in a future version.Adds a new widget to the HUD with a custom positioner.static void
add
(WWidget widget, CottonHud.Positioner positioner, int width, int height) Deprecated, for removal: This API element is subject to removal in a future version.Adds a new widget to the HUD with a custom positioner and resizes it.static void
Deprecated, for removal: This API element is subject to removal in a future version.Removes the widget from the HUD.static void
setPositioner
(WWidget widget, CottonHud.Positioner positioner) Deprecated, for removal: This API element is subject to removal in a future version.Sets the positioner of the widget.
-
Constructor Details
-
CottonHud
public CottonHud()Deprecated, for removal: This API element is subject to removal in a future version.
-
-
Method Details
-
add
Deprecated, for removal: This API element is subject to removal in a future version.Adds a new widget to the HUD.- Parameters:
widget
- the widget
-
add
Deprecated, for removal: This API element is subject to removal in a future version.Adds a new widget to the HUD at the specified offsets.- Parameters:
widget
- the widgetx
- the x offsety
- the y offset- See Also:
-
add
Deprecated, for removal: This API element is subject to removal in a future version.Adds a new widget to the HUD at the specified offsets and resizes it.- Parameters:
widget
- the widgetx
- the x offsety
- the y offsetwidth
- the width of the widgetheight
- the height of the widget- See Also:
-
add
Deprecated, for removal: This API element is subject to removal in a future version.Adds a new widget to the HUD with a custom positioner.- Parameters:
widget
- the widgetpositioner
- the positioner
-
add
Deprecated, for removal: This API element is subject to removal in a future version.Adds a new widget to the HUD with a custom positioner and resizes it.- Parameters:
widget
- the widgetpositioner
- the positionerwidth
- the width of the widgetheight
- the height of the widget
-
setPositioner
Deprecated, for removal: This API element is subject to removal in a future version.Sets the positioner of the widget.- Parameters:
widget
- the widgetpositioner
- the positioner
-
remove
Deprecated, for removal: This API element is subject to removal in a future version.Removes the widget from the HUD.- Parameters:
widget
- the widget
-
HudElementRegistry
withWidgetHudElement
.