Package com.xpdustry.distributor.api.gui
Interface DisplayUnit.Pixel
- All Superinterfaces:
DisplayUnit
- Enclosing interface:
- DisplayUnit
Represents a unit in raw pixels.
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.xpdustry.distributor.api.gui.DisplayUnit
DisplayUnit.Axis, DisplayUnit.Pixel -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptiondefault intasPixels(mindustry.gen.Player player, DisplayUnit.Axis axis) Converts this unit to pixels based on the player's screen size.intReturns the pixels.static DisplayUnit.Pixelof(int value) Creates a newDisplayUnit.Pixelinstance with the given value.
-
Field Details
-
ZERO
-
-
Method Details
-
of
Creates a newDisplayUnit.Pixelinstance with the given value.- Parameters:
value- the value- Returns:
- the new instance
-
getPixels
int getPixels()Returns the pixels. -
asPixels
Description copied from interface:DisplayUnitConverts this unit to pixels based on the player's screen size.- Specified by:
asPixelsin interfaceDisplayUnit- Parameters:
player- the playeraxis- the axis to convert- Returns:
- the converted value
-