update level/block, fix block states

This commit is contained in:
Tnze
2022-12-10 01:09:51 +08:00
parent 2ec7d98e6d
commit bb35ed21c8
4 changed files with 28 additions and 5 deletions

Binary file not shown.

View File

@ -31,10 +31,10 @@ var EnumProperties = []EnumProperty{
{Name: "DripstoneThickness", Values: []string{"tip_merge", "tip", "frustum", "middle", "base"}},
{Name: "Half", TrimPrefix: true, Values: []string{"top", "bottom"}},
{Name: "NoteBlockInstrument", Values: []string{
"harp", "basedrum", "snare", "hat",
"bass", "flute", "bell", "guitar",
"chime", "xylophone", "iron_xylophone", "cow_bell",
"didgeridoo", "bit", "banjo", "pling",
"harp", "basedrum", "snare", "hat", "bass", "flute", "bell",
"guitar", "chime", "xylophone", "iron_xylophone", "cow_bell",
"didgeridoo", "bit", "banjo", "pling", "zombie", "skeleton",
"creeper", "dragon", "wither_skeleton", "piglin", "custom_head",
}},
{Name: "PistonType", Values: []string{"normal", "sticky"}},
{Name: "RailShape", Values: []string{

View File

@ -1,4 +1,5 @@
// Code generated by {{Generator}}; DO NOT EDIT.
package block
import (

View File

@ -1,4 +1,5 @@
// Code generated by generator/properties/main.go; DO NOT EDIT.
package block
import (
@ -484,9 +485,16 @@ const (
NoteBlockInstrumentBit
NoteBlockInstrumentBanjo
NoteBlockInstrumentPling
NoteBlockInstrumentZombie
NoteBlockInstrumentSkeleton
NoteBlockInstrumentCreeper
NoteBlockInstrumentDragon
NoteBlockInstrumentWitherSkeleton
NoteBlockInstrumentPiglin
NoteBlockInstrumentCustomHead
)
var strNoteBlockInstrument = [...]string{"harp", "basedrum", "snare", "hat", "bass", "flute", "bell", "guitar", "chime", "xylophone", "iron_xylophone", "cow_bell", "didgeridoo", "bit", "banjo", "pling"}
var strNoteBlockInstrument = [...]string{"harp", "basedrum", "snare", "hat", "bass", "flute", "bell", "guitar", "chime", "xylophone", "iron_xylophone", "cow_bell", "didgeridoo", "bit", "banjo", "pling", "zombie", "skeleton", "creeper", "dragon", "wither_skeleton", "piglin", "custom_head"}
func (n NoteBlockInstrument) String() string {
if int(n) < len(strNoteBlockInstrument) {
@ -536,6 +544,20 @@ func (n *NoteBlockInstrument) UnmarshalText(text []byte) error {
*n = NoteBlockInstrumentBanjo
case "pling":
*n = NoteBlockInstrumentPling
case "zombie":
*n = NoteBlockInstrumentZombie
case "skeleton":
*n = NoteBlockInstrumentSkeleton
case "creeper":
*n = NoteBlockInstrumentCreeper
case "dragon":
*n = NoteBlockInstrumentDragon
case "wither_skeleton":
*n = NoteBlockInstrumentWitherSkeleton
case "piglin":
*n = NoteBlockInstrumentPiglin
case "custom_head":
*n = NoteBlockInstrumentCustomHead
default:
return errors.New("unknown NoteBlockInstrument: " + str)
}