程序包 org.bukkit.block
接口 Skull
- 所有超级接口:
BlockState
,Metadatable
代表一个头颅(快照).
-
方法概要
修饰符和类型方法说明getOwner()
已过时。Get the player which owns the skull.获取这个头颅在世界的角度.获取头颅的类型.boolean
hasOwner()
检测此头颅是否有主人.boolean
void
setOwningPlayer
(OfflinePlayer player) Set the player which owns the skull.void
setRotation
(BlockFace rotation) 设置这个头颅在世界的角度.void
setSkullType
(SkullType skullType) 设置头颅的类型.从接口继承的方法 org.bukkit.block.BlockState
getBlock, getChunk, getData, getLightLevel, getLocation, getLocation, getRawData, getType, getTypeId, getWorld, getX, getY, getZ, isPlaced, setData, setRawData, setType, setTypeId, update, update, update
从接口继承的方法 org.bukkit.metadata.Metadatable
getMetadata, hasMetadata, removeMetadata, setMetadata
-
方法详细资料
-
hasOwner
boolean hasOwner()检测此头颅是否有主人.原文: Checks to see if the skull has an owner
- 返回:
- true表示此头颅有主人
-
getOwner
已过时。请查阅getOwningPlayer()
.如果存在,获取这个头颅的主人.原文: Gets the owner of the skull, if one exists
- 返回:
- 头颅主人的名字,如果此透露没有主人将返回null
-
setOwner
设置头颅的主人.提供的名称的配置文件数据涉及一个存在阻塞的Web请求.
原文: Sets the owner of the skull
Involves a potentially blocking web request to acquire the profile data for the provided name.
- 参数:
name
- 新的头颅主人的名字- 返回:
- true表示成功设置这个头颅的主人
-
getOwningPlayer
OfflinePlayer getOwningPlayer()Get the player which owns the skull. This player may appear as the texture depending on skull type.- 返回:
- owning player
-
setOwningPlayer
Set the player which owns the skull. This player may appear as the texture depending on skull type.- 参数:
player
- the owning player
-
getRotation
BlockFace getRotation()获取这个头颅在世界的角度.原文: Gets the rotation of the skull in the world
- 返回:
- 头颅的角度
-
setRotation
设置这个头颅在世界的角度.原文: Sets the rotation of the skull in the world
- 参数:
rotation
- 头颅的角度
-
getSkullType
SkullType getSkullType()获取头颅的类型.原文: Gets the type of skull
- 返回:
- 头颅的类型
-
setSkullType
设置头颅的类型.原文: Sets the type of skull
- 参数:
skullType
- 头颅的类型
-
getOwningPlayer()
.