forked from df-mc/dragonfly
-
Notifications
You must be signed in to change notification settings - Fork 0
/
iron_bars.go
33 lines (27 loc) · 821 Bytes
/
iron_bars.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
package block
import (
"github.com/Adrian8115/dragonfly-Amethyst-Protocol/server/block/cube"
"github.com/Adrian8115/dragonfly-Amethyst-Protocol/server/world"
)
// IronBars are blocks that serve a similar purpose to glass panes, but made of iron instead of glass.
type IronBars struct {
transparent
thin
sourceWaterDisplacer
}
// BreakInfo ...
func (i IronBars) BreakInfo() BreakInfo {
return newBreakInfo(5, pickaxeHarvestable, pickaxeEffective, oneOf(i)).withBlastResistance(30)
}
// SideClosed ...
func (i IronBars) SideClosed(cube.Pos, cube.Pos, *world.World) bool {
return false
}
// EncodeItem ...
func (IronBars) EncodeItem() (name string, meta int16) {
return "minecraft:iron_bars", 0
}
// EncodeBlock ...
func (IronBars) EncodeBlock() (string, map[string]any) {
return "minecraft:iron_bars", nil
}