Package com.cryptomorin.xseries
Class NMSExtras
java.lang.Object
com.cryptomorin.xseries.NMSExtras
A class that provides various different essential features that the API
didn't/doesn't support.
All the parameters are non-null.
- Version:
- 5.3.1
- Author:
- Crypto Morin
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enum
Order of this enum should not be changed.static enum
static class
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final MethodHandle
static final MethodHandle
static final MethodHandle
static final Class<?>
static final MethodHandle
static final MethodHandle
static final MethodHandle
static final MethodHandle
static final MethodHandle
static final MethodHandle
static final MethodHandle
static final Class<?>
static final MethodHandle
static final MethodHandle
static final MethodHandle
static final MethodHandle
static final MethodHandle
static final MethodHandle
static final MethodHandle
static final MethodHandle
static final Class<?>
static final MethodHandle
static final MethodHandle
static final MethodHandle
static final MethodHandle
static final MethodHandle
static final MethodHandle
static final MethodHandle
static final MethodHandle
static final MethodHandle
static final MethodHandle
static final MethodHandle
static final MethodHandle
static final MethodHandle
-
Method Summary
Modifier and TypeMethodDescriptionstatic void
animation
(Collection<? extends org.bukkit.entity.Player> players, org.bukkit.entity.LivingEntity entity, NMSExtras.Animation animation) For the trident riptide animation usespinEntity(LivingEntity, float)
instead.static void
chest
(org.bukkit.block.Block chest, boolean open) static void
getData
(org.bukkit.entity.LivingEntity entity, NMSExtras.DataWatcherItemType id) static Object
getStaticField
(Class<?> clazz, String name) static void
lightning
(Collection<org.bukkit.entity.Player> players, org.bukkit.Location location, boolean sound) https://minecraft.wiki/w/Damage#Lightning_damage Lightnings deal 5 damage.static void
lightning
(org.bukkit.entity.Player player, org.bukkit.Location location, boolean sound) static void
openSign
(org.bukkit.entity.Player player, org.bukkit.DyeColor textColor, String[] lines, boolean frontSide) Currently only supports 1.17protected static void
sendBlockChange
(org.bukkit.entity.Player player, org.bukkit.Chunk chunk, Map<NMSExtras.WorldlessBlockWrapper, Object> blocks) Deprecated.static Object
setData
(org.bukkit.entity.LivingEntity entity, NMSExtras.DataWatcherItemType id, Object value) static void
setExp
(org.bukkit.entity.Player player, float bar, int lvl, int exp) static void
spinEntity
(org.bukkit.entity.LivingEntity entity, float ticks)
-
Field Details
-
EntityLivingClass
-
EXP_PACKET
-
ENTITY_PACKET
-
WORLD_HANDLE
-
ENTITY_HANDLE
-
LIGHTNING_ENTITY
-
VEC3D
-
GET_DATA_WATCHER
-
DATA_WATCHER_GET_ITEM
-
DATA_WATCHER_SET_ITEM
-
PACKET_PLAY_OUT_OPEN_SIGN_EDITOR
-
PACKET_PLAY_OUT_BLOCK_CHANGE
-
ANIMATION_PACKET
-
ANIMATION_TYPE
-
ANIMATION_ENTITY_ID
-
PLAY_OUT_MULTI_BLOCK_CHANGE_PACKET
-
MULTI_BLOCK_CHANGE_INFO
-
CHUNK_WRAPPER_SET
-
CHUNK_WRAPPER
-
SHORTS_OR_INFO
-
SET_BLOCK_DATA
-
BLOCK_POSITION
-
PLAY_BLOCK_ACTION
-
GET_BUKKIT_ENTITY
-
GET_BLOCK_TYPE
-
GET_BLOCK
-
GET_IBLOCK_DATA
-
SANITIZE_LINES
-
TILE_ENTITY_SIGN
-
TILE_ENTITY_SIGN__GET_UPDATE_PACKET
-
TILE_ENTITY_SIGN__SET_LINE
-
SIGN_TEXT
-
MULTI_BLOCK_CHANGE_INFO_CLASS
-
BLOCK_DATA
-
-
Method Details
-
setExp
public static void setExp(org.bukkit.entity.Player player, float bar, int lvl, int exp) -
lightning
public static void lightning(org.bukkit.entity.Player player, org.bukkit.Location location, boolean sound) -
lightning
public static void lightning(Collection<org.bukkit.entity.Player> players, org.bukkit.Location location, boolean sound) https://minecraft.wiki/w/Damage#Lightning_damage Lightnings deal 5 damage.- Parameters:
players
- the players to send the packet to.location
- the location to spawn the lightning.sound
- if the lightning should have a sound or be silent.
-
getData
-
setData
public static Object setData(org.bukkit.entity.LivingEntity entity, NMSExtras.DataWatcherItemType id, Object value) -
getStaticField
-
spinEntity
public static void spinEntity(org.bukkit.entity.LivingEntity entity, float ticks) -
animation
public static void animation(Collection<? extends org.bukkit.entity.Player> players, org.bukkit.entity.LivingEntity entity, NMSExtras.Animation animation) For the trident riptide animation usespinEntity(LivingEntity, float)
instead. -
chest
public static void chest(org.bukkit.block.Block chest, boolean open) -
sendBlockChange
@Deprecated protected static void sendBlockChange(org.bukkit.entity.Player player, org.bukkit.Chunk chunk, Map<NMSExtras.WorldlessBlockWrapper, Object> blocks) Deprecated.Not completed yet. I have no idea. -
openSign
public static void openSign(org.bukkit.entity.Player player, org.bukkit.DyeColor textColor, String[] lines, boolean frontSide) Currently only supports 1.17
-