Files
TarnaWijaya 26ed99fda6
Build and deploy / Build (push) Has been cancelled
Build and deploy / Update Contributors (push) Has been cancelled
Build and deploy / Deploy (push) Has been cancelled
up3
2026-07-09 08:33:57 +08:00

39 lines
919 B
Go

package block
import "github.com/df-mc/dragonfly/server/world"
// Podzol is a dirt-type block that naturally blankets the surface of the giant tree taiga and bamboo jungles, along
// with their respective variants.
type Podzol struct {
solid
}
// SoilFor ...
func (p Podzol) SoilFor(block world.Block) bool {
switch block.(type) {
case ShortGrass, Fern, DoubleTallGrass, Flower, DoubleFlower, NetherSprouts, DeadBush, SugarCane:
return true
}
return false
}
// Shovel ...
func (Podzol) Shovel() (world.Block, bool) {
return DirtPath{}, true
}
// BreakInfo ...
func (p Podzol) BreakInfo() BreakInfo {
return newBreakInfo(0.5, alwaysHarvestable, shovelEffective, silkTouchOneOf(Dirt{}, p))
}
// EncodeItem ...
func (Podzol) EncodeItem() (name string, meta int16) {
return "minecraft:podzol", 0
}
// EncodeBlock ...
func (Podzol) EncodeBlock() (string, map[string]any) {
return "minecraft:podzol", nil
}