Search in sources :

Example 1 with StopSoundPacket

use of cn.nukkit.network.protocol.StopSoundPacket in project Nukkit by Nukkit.

the class BlockEntityJukebox method stop.

public void stop() {
    if (this.recordItem instanceof ItemRecord) {
        StopSoundPacket pk = new StopSoundPacket();
        pk.name = ((ItemRecord) this.recordItem).getSoundId();
        Server.broadcastPacket(this.level.getPlayers().values(), pk);
    }
}
Also used : ItemRecord(cn.nukkit.item.ItemRecord) StopSoundPacket(cn.nukkit.network.protocol.StopSoundPacket)

Aggregations

ItemRecord (cn.nukkit.item.ItemRecord)1 StopSoundPacket (cn.nukkit.network.protocol.StopSoundPacket)1