From 3e18596982bda0024ce9ac159ea61f97c45d75d2 Mon Sep 17 00:00:00 2001 From: DaPigGuy Date: Tue, 12 Nov 2024 01:34:21 -0800 Subject: [PATCH] block/skull.go: Remove pointless conversion of cube.Face to cube.Direction --- server/block/skull.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/server/block/skull.go b/server/block/skull.go index 62621dabd..aecb468f0 100644 --- a/server/block/skull.go +++ b/server/block/skull.go @@ -116,10 +116,8 @@ func (s Skull) EncodeBlock() (string, map[string]interface{}) { // allSkulls ... func allSkulls() (skulls []world.Block) { for _, t := range SkullTypes() { - for _, f := range cube.HorizontalFaces() { - // A direction of -2 and -1 isn't actually valid, but when encoding the block these are encoded as 0 and 1. We - // can't otherwise represent this properly in an Attachment type. - skulls = append(skulls, Skull{Type: t, Attach: WallAttachment(f.Direction())}) + for _, d := range cube.Directions() { + skulls = append(skulls, Skull{Type: t, Attach: WallAttachment(d)}) } skulls = append(skulls, Skull{Type: t, Attach: StandingAttachment(0)}) }