Search in sources :

Example 6 with MovingSound

use of net.minecraft.client.audio.MovingSound in project RFTools by McJty.

the class ElevatorSounds method isLoopPlaying.

public static boolean isLoopPlaying(World worldObj, BlockPos pos) {
    GlobalCoordinate g = new GlobalCoordinate(pos, worldObj.provider.getDimension());
    MovingSound movingSound = sounds.get(g);
    return movingSound instanceof ElevatorLoopSound;
}
Also used : GlobalCoordinate(mcjty.lib.varia.GlobalCoordinate) MovingSound(net.minecraft.client.audio.MovingSound)

Example 7 with MovingSound

use of net.minecraft.client.audio.MovingSound in project RFTools by McJty.

the class ElevatorSounds method playLoop.

public static void playLoop(World worldObj, BlockPos pos) {
    MovingSound sound = new ElevatorLoopSound(worldObj, pos.getX(), pos.getY(), pos.getZ());
    playSound(worldObj, pos, sound);
}
Also used : MovingSound(net.minecraft.client.audio.MovingSound)

Example 8 with MovingSound

use of net.minecraft.client.audio.MovingSound in project RFTools by McJty.

the class ProjectorSounds method stopSound.

public static void stopSound(BlockPos pos) {
    if (sounds.containsKey(pos)) {
        MovingSound movingSound = sounds.get(pos);
        ((ProjectorSound) movingSound).stop();
        Minecraft.getMinecraft().getSoundHandler().stopSound(movingSound);
        sounds.remove(pos);
    }
}
Also used : MovingSound(net.minecraft.client.audio.MovingSound)

Example 9 with MovingSound

use of net.minecraft.client.audio.MovingSound in project RFTools by McJty.

the class ProjectorSounds method playScan.

public static void playScan(World worldObj, BlockPos pos) {
    MovingSound sound = new ProjectorSound(worldObj, pos.getX(), pos.getY(), pos.getZ());
    playSound(pos, sound);
}
Also used : MovingSound(net.minecraft.client.audio.MovingSound)

Aggregations

MovingSound (net.minecraft.client.audio.MovingSound)9 GlobalCoordinate (mcjty.lib.varia.GlobalCoordinate)4