2025-11-24 22:52:51 +03:00

44 lines
1.7 KiB
Java

/*
* Decompiled with CFR 0.152.
*
* Could not load the following classes:
* com.mojang.datafixers.kinds.App
* com.mojang.datafixers.kinds.Applicative
* com.mojang.serialization.MapCodec
* com.mojang.serialization.codecs.RecordCodecBuilder
*/
package net.minecraft.world.level.block;
import com.mojang.datafixers.kinds.App;
import com.mojang.datafixers.kinds.Applicative;
import com.mojang.serialization.MapCodec;
import com.mojang.serialization.codecs.RecordCodecBuilder;
import net.minecraft.world.item.DyeColor;
import net.minecraft.world.level.block.BeaconBeamBlock;
import net.minecraft.world.level.block.IronBarsBlock;
import net.minecraft.world.level.block.state.BlockBehaviour;
import net.minecraft.world.level.block.state.BlockState;
public class StainedGlassPaneBlock
extends IronBarsBlock
implements BeaconBeamBlock {
public static final MapCodec<StainedGlassPaneBlock> CODEC = RecordCodecBuilder.mapCodec(i -> i.group((App)DyeColor.CODEC.fieldOf("color").forGetter(StainedGlassPaneBlock::getColor), StainedGlassPaneBlock.propertiesCodec()).apply((Applicative)i, StainedGlassPaneBlock::new));
private final DyeColor color;
public MapCodec<StainedGlassPaneBlock> codec() {
return CODEC;
}
public StainedGlassPaneBlock(DyeColor color, BlockBehaviour.Properties properties) {
super(properties);
this.color = color;
this.registerDefaultState((BlockState)((BlockState)((BlockState)((BlockState)((BlockState)((BlockState)this.stateDefinition.any()).setValue(NORTH, false)).setValue(EAST, false)).setValue(SOUTH, false)).setValue(WEST, false)).setValue(WATERLOGGED, false));
}
@Override
public DyeColor getColor() {
return this.color;
}
}