Package org.geysermc.geyser.api.pack
Interface ResourcePack
public interface ResourcePack
Represents a resource pack sent to Bedrock clients
This representation of a resource pack only contains what Geyser requires to send it to the client.
- Since:
- 2.1.1
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic interfaceA builder for a resource pack. -
Method Summary
Modifier and TypeMethodDescriptionstatic ResourcePack.BuilderReturns aResourcePack.Builderfor a resource pack.codec()Thecodecfor this pack.Gets the content key of the resource pack.static ResourcePackCreates a resource pack with the givenPackCodec.manifest()Gets the resource pack manifest.default UUIDuuid()Shortcut for getting the UUID from theResourcePackManifest.
-
Method Details
-
codec
PackCodec codec()Thecodecfor this pack.- Returns:
- the codec for this pack
- Since:
- 2.1.1
-
manifest
ResourcePackManifest manifest()Gets the resource pack manifest.- Returns:
- the resource pack manifest
- Since:
- 2.1.1
-
contentKey
String contentKey()Gets the content key of the resource pack. Lack of a content key is represented by an empty String.- Returns:
- the content key of the resource pack
- Since:
- 2.1.1
-
uuid
Shortcut for getting the UUID from theResourcePackManifest.- Returns:
- the resource pack uuid
- Since:
- 2.6.2
-
create
Creates a resource pack with the givenPackCodec.- Parameters:
codec- the pack codec- Returns:
- the resource pack
- Since:
- 2.1.1
-
builder
Returns aResourcePack.Builderfor a resource pack. It can be used to set a content key.- Parameters:
codec- thePackCodecto base the builder on- Returns:
- a
ResourcePack.Builderto build a resource pack - Since:
- 2.6.2
-