From bcc58cb3048faa146ed0f90b330ebbe791d53b5c Mon Sep 17 00:00:00 2001 From: anon5 Date: Sun, 19 Sep 2021 12:45:50 +0000 Subject: Switch to Minetest 5.4.1 protocol and other changes --- nodedef.go | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) (limited to 'nodedef.go') diff --git a/nodedef.go b/nodedef.go index 91b8235..8664caf 100644 --- a/nodedef.go +++ b/nodedef.go @@ -158,3 +158,27 @@ type NodeDef struct { //mt:end } + +func BuiltinNodeDefs(n int) map[Content]NodeDef { + defs := make(map[Content]NodeDef, 3+n) + defs[Unknown] = NodeDef{ + Name: "unknown", + } + defs[Air] = NodeDef{ + Name: "air", + DrawType: DrawNothing, + P1Type: P1Light, + Translucent: true, + Transparent: true, + Replaceable: true, + Floodable: true, + GndContent: true, + } + defs[Ignore] = NodeDef{ + Name: "ignore", + DrawType: DrawNothing, + Replaceable: true, + GndContent: true, + } + return defs +} -- cgit v1.2.3