Package net.frozenblock.lib.sound.api
Class FlyBySoundHub
java.lang.Object
net.frozenblock.lib.sound.api.FlyBySoundHub
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Map<net.minecraft.world.entity.EntityType<?>,FlyBySoundHub.FlyBySound> Plays sounds automatically when a certain entity is near.Cooldowns for playing a sound from the same entity.static final Map<net.minecraft.world.entity.Entity,FlyBySoundHub.FlyBySound> The currently playing flyby sounds. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidaddEntity(net.minecraft.world.entity.Entity entity, FlyBySoundHub.FlyBySound flyBySound) static voidaddEntityType(net.minecraft.world.entity.EntityType<?> type, FlyBySoundHub.FlyBySound flyBySound) static booleanhasPassed(@NotNull net.minecraft.world.phys.Vec3 cameraPos, double cameraWidth, @NotNull net.minecraft.world.phys.Vec3 oldCoord, @NotNull net.minecraft.world.phys.Vec3 newCoord) static booleanhasPassedCoordinate(double cameraCoord, double cameraWidth, double triggerWidth, double oldCoord, double newCoord) static voidupdate(@NotNull net.minecraft.client.Minecraft client, net.minecraft.world.entity.Entity cameraEntity, boolean autoSounds)
-
Field Details
-
AUTO_ENTITIES_AND_SOUNDS
public static final Map<net.minecraft.world.entity.EntityType<?>,FlyBySoundHub.FlyBySound> AUTO_ENTITIES_AND_SOUNDSPlays sounds automatically when a certain entity is near. -
FLYBY_ENTITIES_AND_SOUNDS
public static final Map<net.minecraft.world.entity.Entity,FlyBySoundHub.FlyBySound> FLYBY_ENTITIES_AND_SOUNDSThe currently playing flyby sounds. -
ENTITY_COOLDOWNS
Cooldowns for playing a sound from the same entity.
-
-
Constructor Details
-
FlyBySoundHub
public FlyBySoundHub()
-
-
Method Details
-
update
public static void update(@NotNull @NotNull net.minecraft.client.Minecraft client, net.minecraft.world.entity.Entity cameraEntity, boolean autoSounds) -
hasPassed
public static boolean hasPassed(@NotNull @NotNull net.minecraft.world.phys.Vec3 cameraPos, double cameraWidth, @NotNull @NotNull net.minecraft.world.phys.Vec3 oldCoord, @NotNull @NotNull net.minecraft.world.phys.Vec3 newCoord) -
hasPassedCoordinate
public static boolean hasPassedCoordinate(double cameraCoord, double cameraWidth, double triggerWidth, double oldCoord, double newCoord) -
addEntity
public static void addEntity(net.minecraft.world.entity.Entity entity, FlyBySoundHub.FlyBySound flyBySound) -
addEntityType
public static void addEntityType(net.minecraft.world.entity.EntityType<?> type, FlyBySoundHub.FlyBySound flyBySound)
-