Enum BlockKind

Source
#[repr(u32)]
pub enum BlockKind {
Show 255 variants Block = 0, Air = 1, Amethyst = 2, AmethystCluster = 3, Anvil = 4, AttachedStem = 5, Azalea = 6, BambooSapling = 7, BambooStalk = 8, Banner = 9, Barrel = 10, Barrier = 11, BaseCoralFan = 12, BaseCoralPlant = 13, BaseCoralWallFan = 14, Beacon = 15, Bed = 16, Beehive = 17, Beetroot = 18, Bell = 19, BigDripleaf = 20, BigDripleafStem = 21, BlastFurnace = 22, BrewingStand = 23, Brushable = 24, BubbleColumn = 25, BuddingAmethyst = 26, Bush = 27, Button = 28, Cactus = 29, CactusFlower = 30, Cake = 31, CalibratedSculkSensor = 32, Campfire = 33, CandleCake = 34, Candle = 35, Carpet = 36, Carrot = 37, CartographyTable = 38, Cauldron = 39, CaveVines = 40, CaveVinesPlant = 41, CeilingHangingSign = 42, Chain = 43, Chest = 44, ChiseledBookShelf = 45, ChorusFlower = 46, ChorusPlant = 47, Cocoa = 48, ColoredFalling = 49, Command = 50, Comparator = 51, Composter = 52, ConcretePowder = 53, Conduit = 54, CopperBulbBlock = 55, Coral = 56, CoralFan = 57, CoralPlant = 58, CoralWallFan = 59, Crafter = 60, CraftingTable = 61, Crop = 62, CryingObsidian = 63, DaylightDetector = 64, DryVegetation = 65, DecoratedPot = 66, DetectorRail = 67, DirtPath = 68, Dispenser = 69, Door = 70, DoublePlant = 71, DragonEgg = 72, DriedGhast = 73, DropExperience = 74, Dropper = 75, EnchantmentTable = 76, EnderChest = 77, EndGateway = 78, EndPortal = 79, EndPortalFrame = 80, EndRod = 81, Eyeblossom = 82, Farm = 83, BonemealableFeaturePlacer = 84, Fence = 85, FenceGate = 86, Fire = 87, FireflyBush = 88, FletchingTable = 89, Flower = 90, FlowerPot = 91, Frogspawn = 92, FrostedIce = 93, Fungus = 94, Furnace = 95, GlazedTerracotta = 96, GlowLichen = 97, Grass = 98, Grindstone = 99, HalfTransparent = 100, HangingMoss = 101, HangingRoots = 102, Hay = 103, HeavyCore = 104, Honey = 105, Hopper = 106, HugeMushroom = 107, Ice = 108, Infested = 109, InfestedRotatedPillar = 110, IronBars = 111, JackOLantern = 112, Jigsaw = 113, Jukebox = 114, Kelp = 115, KelpPlant = 116, Ladder = 117, Lantern = 118, LavaCauldron = 119, LayeredCauldron = 120, LeafLitter = 121, Lectern = 122, Lever = 123, Light = 124, LightningRod = 125, Liquid = 126, Loom = 127, Magma = 128, MangroveLeaves = 129, MangrovePropagule = 130, MangroveRoots = 131, MossyCarpet = 132, MovingPiston = 133, Mud = 134, Multiface = 135, Mushroom = 136, Mycelium = 137, NetherPortal = 138, Netherrack = 139, NetherSprouts = 140, NetherWart = 141, Note = 142, Nylium = 143, Observer = 144, Piglinwallskull = 145, FlowerBed = 146, PistonBase = 147, PistonHead = 148, PitcherCrop = 149, PlayerHead = 150, PlayerWallHead = 151, PointedDripstone = 152, Potato = 153, PowderSnow = 154, Powered = 155, PoweredRail = 156, PressurePlate = 157, Pumpkin = 158, Rail = 159, RedstoneLamp = 160, RedstoneOre = 161, RedstoneTorch = 162, RedstoneWallTorch = 163, RedstoneWire = 164, Repeater = 165, RespawnAnchor = 166, RootedDirt = 167, Roots = 168, RotatedPillar = 169, Sapling = 170, Sand = 171, Scaffolding = 172, SculkCatalyst = 173, Sculk = 174, SculkSensor = 175, SculkShrieker = 176, SculkVein = 177, Seagrass = 178, SeaPickle = 179, ShortDryGrass = 180, ShulkerBox = 181, Skull = 182, Slab = 183, Slime = 184, SmallDripleaf = 185, SmithingTable = 186, Smoker = 187, SnifferEgg = 188, SnowLayer = 189, SnowyDirt = 190, SoulFire = 191, SoulSand = 192, Spawner = 193, CreakingHeart = 194, Sponge = 195, SporeBlossom = 196, StainedGlassPane = 197, StainedGlass = 198, Stair = 199, StandingSign = 200, Stem = 201, Stonecutter = 202, Structure = 203, StructureVoid = 204, SugarCane = 205, SweetBerryBush = 206, TallDryGrass = 207, TallFlower = 208, TallGrass = 209, TallSeagrass = 210, Target = 211, Test = 212, TestInstance = 213, TintedGlass = 214, TintedParticleLeaves = 215, Tnt = 216, TorchflowerCrop = 217, Torch = 218, Transparent = 219, Trapdoor = 220, TrappedChest = 221, TrialSpawner = 222, TripWireHook = 223, Tripwire = 224, TurtleEgg = 225, TwistingVinesPlant = 226, TwistingVines = 227, UntintedParticleLeaves = 228, Vault = 229, Vine = 230, WallBanner = 231, WallHangingSign = 232, WallSign = 233, WallSkull = 234, WallTorch = 235, Wall = 236, Waterlily = 237, WaterloggedTransparent = 238, WeatheringCopperBulb = 239, WeatheringCopperDoor = 240, WeatheringCopperFull = 241, WeatheringCopperGrate = 242, WeatheringCopperSlab = 243, WeatheringCopperStair = 244, WeatheringCopperTrapDoor = 245, Web = 246, WeepingVinesPlant = 247, WeepingVines = 248, WeightedPressurePlate = 249, WetSponge = 250, WitherRose = 251, WitherSkull = 252, WitherWallSkull = 253, WoolCarpet = 254,
}

Variants§

§

Block = 0

§

Air = 1

§

Amethyst = 2

§

AmethystCluster = 3

§

Anvil = 4

§

AttachedStem = 5

§

Azalea = 6

§

BambooSapling = 7

§

BambooStalk = 8

§

Banner = 9

§

Barrel = 10

§

Barrier = 11

§

BaseCoralFan = 12

§

BaseCoralPlant = 13

§

BaseCoralWallFan = 14

§

Beacon = 15

§

Bed = 16

§

Beehive = 17

§

Beetroot = 18

§

Bell = 19

§

BigDripleaf = 20

§

BigDripleafStem = 21

§

BlastFurnace = 22

§

BrewingStand = 23

§

Brushable = 24

§

BubbleColumn = 25

§

BuddingAmethyst = 26

§

Bush = 27

§

Button = 28

§

Cactus = 29

§

CactusFlower = 30

§

Cake = 31

§

CalibratedSculkSensor = 32

§

Campfire = 33

§

CandleCake = 34

§

Candle = 35

§

Carpet = 36

§

Carrot = 37

§

CartographyTable = 38

§

Cauldron = 39

§

CaveVines = 40

§

CaveVinesPlant = 41

§

CeilingHangingSign = 42

§

Chain = 43

§

Chest = 44

§

ChiseledBookShelf = 45

§

ChorusFlower = 46

§

ChorusPlant = 47

§

Cocoa = 48

§

ColoredFalling = 49

§

Command = 50

§

Comparator = 51

§

Composter = 52

§

ConcretePowder = 53

§

Conduit = 54

§

CopperBulbBlock = 55

§

Coral = 56

§

CoralFan = 57

§

CoralPlant = 58

§

CoralWallFan = 59

§

Crafter = 60

§

CraftingTable = 61

§

Crop = 62

§

CryingObsidian = 63

§

DaylightDetector = 64

§

DryVegetation = 65

§

DecoratedPot = 66

§

DetectorRail = 67

§

DirtPath = 68

§

Dispenser = 69

§

Door = 70

§

DoublePlant = 71

§

DragonEgg = 72

§

DriedGhast = 73

§

DropExperience = 74

§

Dropper = 75

§

EnchantmentTable = 76

§

EnderChest = 77

§

EndGateway = 78

§

EndPortal = 79

§

EndPortalFrame = 80

§

EndRod = 81

§

Eyeblossom = 82

§

Farm = 83

§

BonemealableFeaturePlacer = 84

§

Fence = 85

§

FenceGate = 86

§

Fire = 87

§

FireflyBush = 88

§

FletchingTable = 89

§

Flower = 90

§

FlowerPot = 91

§

Frogspawn = 92

§

FrostedIce = 93

§

Fungus = 94

§

Furnace = 95

§

GlazedTerracotta = 96

§

GlowLichen = 97

§

Grass = 98

§

Grindstone = 99

§

HalfTransparent = 100

§

HangingMoss = 101

§

HangingRoots = 102

§

Hay = 103

§

HeavyCore = 104

§

Honey = 105

§

Hopper = 106

§

HugeMushroom = 107

§

Ice = 108

§

Infested = 109

§

InfestedRotatedPillar = 110

§

IronBars = 111

§

JackOLantern = 112

§

Jigsaw = 113

§

Jukebox = 114

§

Kelp = 115

§

KelpPlant = 116

§

Ladder = 117

§

Lantern = 118

§

LavaCauldron = 119

§

LayeredCauldron = 120

§

LeafLitter = 121

§

Lectern = 122

§

Lever = 123

§

Light = 124

§

LightningRod = 125

§

Liquid = 126

§

Loom = 127

§

Magma = 128

§

MangroveLeaves = 129

§

MangrovePropagule = 130

§

MangroveRoots = 131

§

MossyCarpet = 132

§

MovingPiston = 133

§

Mud = 134

§

Multiface = 135

§

Mushroom = 136

§

Mycelium = 137

§

NetherPortal = 138

§

Netherrack = 139

§

NetherSprouts = 140

§

NetherWart = 141

§

Note = 142

§

Nylium = 143

§

Observer = 144

§

Piglinwallskull = 145

§

FlowerBed = 146

§

PistonBase = 147

§

PistonHead = 148

§

PitcherCrop = 149

§

PlayerHead = 150

§

PlayerWallHead = 151

§

PointedDripstone = 152

§

Potato = 153

§

PowderSnow = 154

§

Powered = 155

§

PoweredRail = 156

§

PressurePlate = 157

§

Pumpkin = 158

§

Rail = 159

§

RedstoneLamp = 160

§

RedstoneOre = 161

§

RedstoneTorch = 162

§

RedstoneWallTorch = 163

§

RedstoneWire = 164

§

Repeater = 165

§

RespawnAnchor = 166

§

RootedDirt = 167

§

Roots = 168

§

RotatedPillar = 169

§

Sapling = 170

§

Sand = 171

§

Scaffolding = 172

§

SculkCatalyst = 173

§

Sculk = 174

§

SculkSensor = 175

§

SculkShrieker = 176

§

SculkVein = 177

§

Seagrass = 178

§

SeaPickle = 179

§

ShortDryGrass = 180

§

ShulkerBox = 181

§

Skull = 182

§

Slab = 183

§

Slime = 184

§

SmallDripleaf = 185

§

SmithingTable = 186

§

Smoker = 187

§

SnifferEgg = 188

§

SnowLayer = 189

§

SnowyDirt = 190

§

SoulFire = 191

§

SoulSand = 192

§

Spawner = 193

§

CreakingHeart = 194

§

Sponge = 195

§

SporeBlossom = 196

§

StainedGlassPane = 197

§

StainedGlass = 198

§

Stair = 199

§

StandingSign = 200

§

Stem = 201

§

Stonecutter = 202

§

Structure = 203

§

StructureVoid = 204

§

SugarCane = 205

§

SweetBerryBush = 206

§

TallDryGrass = 207

§

TallFlower = 208

§

TallGrass = 209

§

TallSeagrass = 210

§

Target = 211

§

Test = 212

§

TestInstance = 213

§

TintedGlass = 214

§

TintedParticleLeaves = 215

§

Tnt = 216

§

TorchflowerCrop = 217

§

Torch = 218

§

Transparent = 219

§

Trapdoor = 220

§

TrappedChest = 221

§

TrialSpawner = 222

§

TripWireHook = 223

§

Tripwire = 224

§

TurtleEgg = 225

§

TwistingVinesPlant = 226

§

TwistingVines = 227

§

UntintedParticleLeaves = 228

§

Vault = 229

§

Vine = 230

§

WallBanner = 231

§

WallHangingSign = 232

§

WallSign = 233

§

WallSkull = 234

§

WallTorch = 235

§

Wall = 236

§

Waterlily = 237

§

WaterloggedTransparent = 238

§

WeatheringCopperBulb = 239

§

WeatheringCopperDoor = 240

§

WeatheringCopperFull = 241

§

WeatheringCopperGrate = 242

§

WeatheringCopperSlab = 243

§

WeatheringCopperStair = 244

§

WeatheringCopperTrapDoor = 245

§

Web = 246

§

WeepingVinesPlant = 247

§

WeepingVines = 248

§

WeightedPressurePlate = 249

§

WetSponge = 250

§

WitherRose = 251

§

WitherSkull = 252

§

WitherWallSkull = 253

§

WoolCarpet = 254

Implementations§

Source§

impl BlockKind

Source

pub fn azalea_read_id( buf: &mut Cursor<&[u8]>, id: u32, ) -> Result<Self, BufReadError>

Source§

impl BlockKind

Source

pub unsafe fn from_u32_unchecked(id: u32) -> Self

Transmutes a u32 to a BlockKind.

§Safety

The id should be at most 255.

Source

pub fn is_valid_id(id: u32) -> bool

Trait Implementations§

Source§

impl AzaleaRead for BlockKind

Source§

fn azalea_read(buf: &mut Cursor<&[u8]>) -> Result<Self, BufReadError>

Source§

impl AzaleaWrite for BlockKind

Source§

fn azalea_write(&self, buf: &mut impl Write) -> Result<(), Error>

Source§

impl Clone for BlockKind

Source§

fn clone(&self) -> BlockKind

Returns a duplicate of the value. Read more
1.0.0 · Source§

const fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for BlockKind

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'de> Deserialize<'de> for BlockKind

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl Display for BlockKind

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl FromNbtTag for BlockKind

Source§

fn from_nbt_tag(tag: NbtTag<'_, '_>) -> Option<Self>

§

fn from_optional_nbt_tag( tag: Option<NbtTag<'_, '_>>, ) -> Result<Option<Self>, DeserializeError>

Source§

impl FromStr for BlockKind

Source§

type Err = String

The associated error which can be returned from parsing.
Source§

fn from_str(s: &str) -> Result<Self, Self::Err>

Parses a string s to return a value of this type. Read more
Source§

impl Hash for BlockKind

Source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · Source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
Source§

impl PartialEq for BlockKind

Source§

fn eq(&self, other: &BlockKind) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

const fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Registry for BlockKind

Source§

fn from_u32(value: u32) -> Option<Self>

Source§

fn to_u32(&self) -> u32

Source§

impl Serialize for BlockKind

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl ToNbtTag for BlockKind

Source§

fn to_nbt_tag(self) -> NbtTag

§

fn to_optional_nbt_tag(self) -> Option<NbtTag>

Source§

impl TryFrom<u32> for BlockKind

Source§

fn try_from(id: u32) -> Result<Self, Self::Error>

Safely transmutes a u32 to a BlockKind.

Source§

type Error = ()

The type returned in the event of a conversion error.
Source§

impl Copy for BlockKind

Source§

impl Eq for BlockKind

Source§

impl StructuralPartialEq for BlockKind

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T> Instrument for T

§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<T> WithSubscriber for T

§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a [WithDispatch] wrapper. Read more
§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a [WithDispatch] wrapper. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,