Add API for Sound, and playing the sounds for Worlds and Players. Adds BUKKIT-1430, BUKKIT-1226 and BUKKIT-2019

By: feildmaster <admin@feildmaster.com>
This commit is contained in:
Bukkit/Spigot
2012-08-21 17:06:34 -05:00
parent 0ed310838f
commit 6416e06065
3 changed files with 187 additions and 0 deletions

View File

@@ -10,6 +10,7 @@ import org.bukkit.Location;
import org.bukkit.Material;
import org.bukkit.Note;
import org.bukkit.OfflinePlayer;
import org.bukkit.Sound;
import org.bukkit.Statistic;
import org.bukkit.command.CommandSender;
import org.bukkit.conversations.Conversable;
@@ -197,6 +198,19 @@ public interface Player extends HumanEntity, Conversable, CommandSender, Offline
*/
public void playNote(Location loc, Instrument instrument, Note note);
/**
* Play a sound for a player at the location.
* <p />
* This function will fail silently if Location or Sound are null.
*
* @param location The location to play the sound
* @param sound The sound to play
* @param volume The volume of the sound
* @param pitch The pitch of the sound
*/
public void playSound(Location location, Sound sound, float volume, float pitch);
/**
* Plays an effect to just this player.
*