Enum Class Img
- All Implemented Interfaces:
Serializable
,Comparable<Img>
,Constable
This stores an enum with the names of all the images to be used in the game.
It creates a new instance of the image by loading the object and returning
a BufferedImage object from a png file with its name.
- Author:
- Diana
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantDescriptionThe blue key image.The blue key image without background for inventory display.The blue locked door image.The image for a BouncyPad that launches a player downwards.The image for a BouncyPad that launches a player to the left.The image for a BouncyPad that launches a player to the right.The image for a BouncyPad that launches a player upwards.The exit tile image.The free tile image.The green key image.The green key image without background for inventory display.The green locked door image.The infoField tile image.The image displaying the information for level 1.The image displaying the information for level 2.The locked exit tile image.The image for the MilkPuddle tile.The image of the player moving downwards.The image of the player moving to the left.The image of the player moving to the right.The image of the player moving upwards.The red key image.The red key image without background for inventory display.The red locked door image.The title card for the side panel.The image for a treasure.The image for a wall tile.The yellow key image.The yellow key image without background for inventory display.The yellow locked door image. -
Field Summary
Modifier and TypeFieldDescriptionfinal BufferedImage
The image to be loaded and displayed on screen. -
Method Summary
-
Enum Constant Details
-
Title
The title card for the side panel. -
BlueKey
The blue key image. -
BlueLockedDoor
The blue locked door image. -
GreenKey
The green key image. -
GreenLockedDoor
The green locked door image. -
RedKey
The red key image. -
RedLockedDoor
The red locked door image. -
YellowKey
The yellow key image. -
YellowLockedDoor
The yellow locked door image. -
FreeTile
The free tile image. -
Exit
The exit tile image. -
LockedExit
The locked exit tile image. -
InfoField
The infoField tile image. -
Level1Info
The image displaying the information for level 1. -
PlayerDown
The image of the player moving downwards. -
PlayerLeft
The image of the player moving to the left. -
PlayerRight
The image of the player moving to the right. -
PlayerUp
The image of the player moving upwards. -
Treasure
The image for a treasure. -
Wall
The image for a wall tile. -
BlueKeyNB
The blue key image without background for inventory display. -
GreenKeyNB
The green key image without background for inventory display. -
RedKeyNB
The red key image without background for inventory display. -
YellowKeyNB
The yellow key image without background for inventory display. -
BouncyPadDown
The image for a BouncyPad that launches a player downwards. -
BouncyPadLeft
The image for a BouncyPad that launches a player to the left. -
BouncyPadRight
The image for a BouncyPad that launches a player to the right. -
BouncyPadUp
The image for a BouncyPad that launches a player upwards. -
Level2Info
The image displaying the information for level 2. -
MilkPuddle
The image for the MilkPuddle tile.
-
-
Field Details
-
image
The image to be loaded and displayed on screen.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-