Interface Receiving
- All Known Implementing Classes:
RadioBlockEntity,RadioItem,TransceiverItem
public interface Receiving
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptiondefault voidappendTooltip(net.minecraft.world.item.ItemStack stack, List<net.minecraft.network.chat.Component> components) default RadioChannellisten(String frequencyName, Frequency.Modulation modulation, UUID owner) Start listening in a certain frequency.default net.minecraft.nbt.CompoundTagsetFrequency(net.minecraft.world.item.ItemStack stack, String frequencyName, Frequency.Modulation modulation) Sets the frequency for an ItemStack.default voidstopListening(String frequencyName, Frequency.Modulation modulation, UUID owner) Stop listening in a certain frequencydefault voidtick(net.minecraft.world.item.ItemStack stack, net.minecraft.world.level.Level level, net.minecraft.world.entity.Entity entity) default booleandefault booleanvalidate(String frequency, Frequency.Modulation modulation, UUID owner) Validates whether a UUID is present in the frequency.
-
Field Details
-
RANDOM
-
-
Method Details
-
setFrequency
default net.minecraft.nbt.CompoundTag setFrequency(net.minecraft.world.item.ItemStack stack, String frequencyName, Frequency.Modulation modulation) Sets the frequency for an ItemStack.- Parameters:
stack- the ItemStack to change the frequency offrequencyName- the frequency to set it tomodulation- the modulation type of the frequency- Returns:
- The updated tag.
-
validate
Validates whether a UUID is present in the frequency.- Parameters:
frequency- the frequency to checkmodulation- the modulation type of the frequencyowner- the UUID to validate- Returns:
- Whether it is present in the frequency.
-
validate
-
listen
Start listening in a certain frequency.- Parameters:
frequencyName- the frequency to listen tomodulation- the modulation type of the frequencyowner- the UUID that will listen- Returns:
- The channel created from the listener.
-
stopListening
Stop listening in a certain frequency- Parameters:
frequencyName- the frequency to stop listening tomodulation- the modulation type of the frequencyowner- the UUID to remove
-
tick
default void tick(net.minecraft.world.item.ItemStack stack, net.minecraft.world.level.Level level, net.minecraft.world.entity.Entity entity) -
appendTooltip
default void appendTooltip(net.minecraft.world.item.ItemStack stack, List<net.minecraft.network.chat.Component> components)
-