Package de.maxhenkel.voicechat.api
Interface VoicechatClientApi
- All Superinterfaces:
VoicechatApi
-
Method Summary
Modifier and TypeMethodDescriptioncreateEntityAudioChannel(UUID uuid) Deprecated.createEntityAudioChannel(UUID uuid, Entity entity) Creates a client side entity audio channel.createLocationalAudioChannel(UUID uuid, Position position) Creates a client side locational audio channel.createStaticAudioChannel(UUID uuid) Creates a client side static audio channel.getGroup()default booleanDoes the same asisDisabled(UUID)withnullas the player UUID.booleanisDisabled(UUID playerId) default booleanDoes the same asisDisconnected(UUID)withnullas the player UUID.booleanisDisconnected(UUID playerId) booleanisMuted()booleanThis method returns if the push to talk key is pressed, even when using voice activation.default booleanDoes the same asisTalking(UUID)withnullas the player UUID.booleandefault booleanDoes the same asisWhispering(UUID)withnullas the player UUID.booleanisWhispering(UUID playerId) booleanvoidregisterClientVolumeCategory(VolumeCategory category) Registers a volume category just for this client.default voidunregisterClientVolumeCategory(VolumeCategory category) Unregisters a category on this client.voidunregisterClientVolumeCategory(String categoryId) Unregisters a category on this client.Methods inherited from interface de.maxhenkel.voicechat.api.VoicechatApi
createDecoder, createEncoder, createEncoder, createMp3Decoder, createMp3Encoder, createPosition, fromEntity, fromServerLevel, fromServerPlayer, getAudioConverter, getVoiceChatDistance, volumeCategoryBuilder
-
Method Details
-
isMuted
boolean isMuted()- Returns:
- if the local voice chat is muted
-
isDisabled
default boolean isDisabled()Does the same asisDisabled(UUID)withnullas the player UUID.- Returns:
- if the local voice chat is disabled
-
isDisabled
- Parameters:
playerId- the UUID of the player ornullfor the local player- Returns:
- if the player with the provided UUID has the voice chat disabled
-
isDisconnected
default boolean isDisconnected()Does the same asisDisconnected(UUID)withnullas the player UUID.- Returns:
- if the voice chat is disconnected from the server
-
isDisconnected
- Parameters:
playerId- the UUID of the player ornullfor the local player- Returns:
- if the player with the provided UUID is disconnected from voice chat
-
isTalking
default boolean isTalking()Does the same asisTalking(UUID)withnullas the player UUID.- Returns:
- if the local player is talking
-
isTalking
- Parameters:
playerId- the UUID of the player ornullfor the local player- Returns:
- if the player with the provided UUID is currently talking
-
isWhispering
default boolean isWhispering()Does the same asisWhispering(UUID)withnullas the player UUID.- Returns:
- if the local player is whispering
-
isWhispering
- Parameters:
playerId- the UUID of the player ornullfor the local player- Returns:
- if the player with the provided UUID is currently whispering
-
isPushToTalkKeyPressed
boolean isPushToTalkKeyPressed()This method returns if the push to talk key is pressed, even when using voice activation.- Returns:
- if the push to talk key is pressed
-
isWhisperKeyPressed
boolean isWhisperKeyPressed()- Returns:
- if the whisper key is pressed
-
getGroup
-
createEntityAudioChannel
Deprecated.Creates a client side entity audio channel.- Parameters:
uuid- the UUID of the entity- Returns:
- the audio channel
-
createEntityAudioChannel
Creates a client side entity audio channel.- Parameters:
uuid- the UUID of the entityentity- the entity- Returns:
- the audio channel
-
createLocationalAudioChannel
Creates a client side locational audio channel.- Parameters:
uuid- the ID of the channel- Returns:
- the audio channel
-
createStaticAudioChannel
Creates a client side static audio channel.- Parameters:
uuid- the ID of the channel- Returns:
- the audio channel
-
registerClientVolumeCategory
Registers a volume category just for this client. A category can be created withVoicechatApi.volumeCategoryBuilder(). The category can be unregistered withunregisterClientVolumeCategory(de.maxhenkel.voicechat.api.VolumeCategory).- Parameters:
category- the category to register
-
unregisterClientVolumeCategory
Unregisters a category on this client. This will release the texture ID for the icon if one exists.- Parameters:
category- the category to remove
-
unregisterClientVolumeCategory
Unregisters a category on this client. This will release the texture ID for the icon if one exists.- Parameters:
categoryId- the category ID to remove
-
getClientConfig
ConfigAccessor getClientConfig()- Returns:
- a read-only config accessor for the mods client config
-
createEntityAudioChannel(UUID, Entity)