summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--aligntype_string.go25
-rw-r--r--alphause_string.go26
-rw-r--r--animtype_string.go26
-rw-r--r--ao.go6
-rw-r--r--aocmds_cmdno.go2
-rw-r--r--auth.go2
-rw-r--r--authmethods_string.go35
-rw-r--r--chatmsgtype_string.go27
-rw-r--r--cmd.go2
-rwxr-xr-xcmd.sh2
-rwxr-xr-xcmdno.sh2
-rw-r--r--dir.go2
-rw-r--r--dir_string.go29
-rw-r--r--drawtype_string.go40
-rw-r--r--hotbarparam_string.go26
-rw-r--r--hudfield_string.go36
-rw-r--r--hudtype_string.go28
-rw-r--r--interaction_string.go28
-rw-r--r--itemdef.go2
-rw-r--r--itemtype_string.go26
-rw-r--r--light.go2
-rw-r--r--lightbank_string.go24
-rw-r--r--liquidtype_string.go25
-rw-r--r--minimap.go10
-rw-r--r--minimaptype_string.go26
-rwxr-xr-xmkpktinfos.sh2
-rwxr-xr-xmkserialize.sh2
-rw-r--r--modchansig_string.go28
-rw-r--r--nodebox.go12
-rw-r--r--nodeboxtype_string.go28
-rw-r--r--nodedef.go12
-rw-r--r--param1type_string.go24
-rw-r--r--param2type_string.go34
-rw-r--r--pktinfos.go2
-rw-r--r--playerlistupdatetype_string.go25
-rw-r--r--serialize.fmt4
-rw-r--r--serialize.go246
-rw-r--r--sound.go8
-rw-r--r--soundsrctype_string.go25
-rw-r--r--tileanim.go10
-rw-r--r--tiledef.go4
-rw-r--r--tileflags_string.go47
-rw-r--r--tocltcmds.go41
-rw-r--r--tocltcmds_cmdno.go2
-rw-r--r--tosrvcmds.go6
-rw-r--r--tosrvcmds_cmdno.go2
-rw-r--r--wavetype_string.go26
47 files changed, 873 insertions, 176 deletions
diff --git a/aligntype_string.go b/aligntype_string.go
new file mode 100644
index 0000000..6771a9b
--- /dev/null
+++ b/aligntype_string.go
@@ -0,0 +1,25 @@
+// Code generated by "stringer -type AlignType"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[NoAlign-0]
+ _ = x[WorldAlign-1]
+ _ = x[UserAlign-2]
+}
+
+const _AlignType_name = "NoAlignWorldAlignUserAlign"
+
+var _AlignType_index = [...]uint8{0, 7, 17, 26}
+
+func (i AlignType) String() string {
+ if i >= AlignType(len(_AlignType_index)-1) {
+ return "AlignType(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _AlignType_name[_AlignType_index[i]:_AlignType_index[i+1]]
+}
diff --git a/alphause_string.go b/alphause_string.go
new file mode 100644
index 0000000..6e5959b
--- /dev/null
+++ b/alphause_string.go
@@ -0,0 +1,26 @@
+// Code generated by "stringer -type AlphaUse"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[Blend-0]
+ _ = x[Mask-1]
+ _ = x[Opaque-2]
+ _ = x[Legacy-3]
+}
+
+const _AlphaUse_name = "BlendMaskOpaqueLegacy"
+
+var _AlphaUse_index = [...]uint8{0, 5, 9, 15, 21}
+
+func (i AlphaUse) String() string {
+ if i >= AlphaUse(len(_AlphaUse_index)-1) {
+ return "AlphaUse(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _AlphaUse_name[_AlphaUse_index[i]:_AlphaUse_index[i+1]]
+}
diff --git a/animtype_string.go b/animtype_string.go
new file mode 100644
index 0000000..3c78525
--- /dev/null
+++ b/animtype_string.go
@@ -0,0 +1,26 @@
+// Code generated by "stringer -linecomment -type AnimType"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[NoAnim-0]
+ _ = x[VerticalFrameAnim-1]
+ _ = x[SpriteSheetAnim-2]
+ _ = x[maxAnim-3]
+}
+
+const _AnimType_name = "nonevertical framesprite sheetmaxAnim"
+
+var _AnimType_index = [...]uint8{0, 4, 18, 30, 37}
+
+func (i AnimType) String() string {
+ if i >= AnimType(len(_AnimType_index)-1) {
+ return "AnimType(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _AnimType_name[_AnimType_index[i]:_AnimType_index[i+1]]
+}
diff --git a/ao.go b/ao.go
index 40b9983..436cb62 100644
--- a/ao.go
+++ b/ao.go
@@ -43,7 +43,7 @@ type AOProps struct {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -167,12 +167,12 @@ type AOCmdAnimSpeed struct {
Speed float32
}
-//go:generate ./cmdno.sh aocmds AOCmd ao uint8 AOMsg newAOMsg
-
type AOMsg interface {
aoCmdNo() uint8
}
+//go:generate ./cmdno.sh aocmds AOCmd ao uint8 AOMsg newAOMsg
+
func writeAOMsg(w io.Writer, msg AOMsg) error {
if _, err := w.Write([]byte{msg.aoCmdNo()}); err != nil {
return err
diff --git a/aocmds_cmdno.go b/aocmds_cmdno.go
index 6d051b5..e41d533 100644
--- a/aocmds_cmdno.go
+++ b/aocmds_cmdno.go
@@ -1,4 +1,4 @@
-// Code generated by cmdno.sh. DO NOT EDIT.
+// Code generated by cmdno.sh; DO NOT EDIT.
package mt
diff --git a/auth.go b/auth.go
index 5c2df14..cb7df1f 100644
--- a/auth.go
+++ b/auth.go
@@ -7,3 +7,5 @@ const (
SRP
FirstSRP
)
+
+//go:generate stringer -type AuthMethods
diff --git a/authmethods_string.go b/authmethods_string.go
new file mode 100644
index 0000000..a235e62
--- /dev/null
+++ b/authmethods_string.go
@@ -0,0 +1,35 @@
+// Code generated by "stringer -type AuthMethods"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[LegacyPasswd-1]
+ _ = x[SRP-2]
+ _ = x[FirstSRP-4]
+}
+
+const (
+ _AuthMethods_name_0 = "LegacyPasswdSRP"
+ _AuthMethods_name_1 = "FirstSRP"
+)
+
+var (
+ _AuthMethods_index_0 = [...]uint8{0, 12, 15}
+)
+
+func (i AuthMethods) String() string {
+ switch {
+ case 1 <= i && i <= 2:
+ i -= 1
+ return _AuthMethods_name_0[_AuthMethods_index_0[i]:_AuthMethods_index_0[i+1]]
+ case i == 4:
+ return _AuthMethods_name_1
+ default:
+ return "AuthMethods(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+}
diff --git a/chatmsgtype_string.go b/chatmsgtype_string.go
new file mode 100644
index 0000000..cc21329
--- /dev/null
+++ b/chatmsgtype_string.go
@@ -0,0 +1,27 @@
+// Code generated by "stringer -linecomment -type ChatMsgType"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[RawMsg-0]
+ _ = x[NormalMsg-1]
+ _ = x[AnnounceMsg-2]
+ _ = x[SysMsg-3]
+ _ = x[maxMsg-4]
+}
+
+const _ChatMsgType_name = "rawnormalannouncesysmaxMsg"
+
+var _ChatMsgType_index = [...]uint8{0, 3, 9, 17, 20, 26}
+
+func (i ChatMsgType) String() string {
+ if i >= ChatMsgType(len(_ChatMsgType_index)-1) {
+ return "ChatMsgType(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _ChatMsgType_name[_ChatMsgType_index[i]:_ChatMsgType_index[i+1]]
+}
diff --git a/cmd.go b/cmd.go
index db6b912..19c250e 100644
--- a/cmd.go
+++ b/cmd.go
@@ -1,4 +1,4 @@
-// Code generated by cmd.sh. DO NOT EDIT.
+// Code generated by cmd.sh; DO NOT EDIT.
package mt
diff --git a/cmd.sh b/cmd.sh
index ed887f3..71a541f 100755
--- a/cmd.sh
+++ b/cmd.sh
@@ -1,7 +1,7 @@
#!/bin/sh
(
- echo // Code generated by cmd.sh. DO NOT EDIT.
+ echo '// Code generated by cmd.sh; DO NOT EDIT.'
echo
echo package mt
echo
diff --git a/cmdno.sh b/cmdno.sh
index 186df7b..e9e16d0 100755
--- a/cmdno.sh
+++ b/cmdno.sh
@@ -1,7 +1,7 @@
#!/bin/sh
(
- echo // Code generated by cmdno.sh. DO NOT EDIT.
+ echo '// Code generated by cmdno.sh; DO NOT EDIT.'
echo
echo package mt
echo
diff --git a/dir.go b/dir.go
index 693db98..e7bb47a 100644
--- a/dir.go
+++ b/dir.go
@@ -13,6 +13,8 @@ const (
NoDir
)
+//go:generate stringer -type Dir
+
// Opposite returns the Dir's opposite.
// NoDir is its own opposite.
func (d Dir) Opposite() Dir {
diff --git a/dir_string.go b/dir_string.go
new file mode 100644
index 0000000..cd48e1b
--- /dev/null
+++ b/dir_string.go
@@ -0,0 +1,29 @@
+// Code generated by "stringer -type Dir"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[East-0]
+ _ = x[Above-1]
+ _ = x[North-2]
+ _ = x[South-3]
+ _ = x[Below-4]
+ _ = x[West-5]
+ _ = x[NoDir-6]
+}
+
+const _Dir_name = "EastAboveNorthSouthBelowWestNoDir"
+
+var _Dir_index = [...]uint8{0, 4, 9, 14, 19, 24, 28, 33}
+
+func (i Dir) String() string {
+ if i >= Dir(len(_Dir_index)-1) {
+ return "Dir(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _Dir_name[_Dir_index[i]:_Dir_index[i+1]]
+}
diff --git a/drawtype_string.go b/drawtype_string.go
new file mode 100644
index 0000000..4bc1593
--- /dev/null
+++ b/drawtype_string.go
@@ -0,0 +1,40 @@
+// Code generated by "stringer -trimprefix Draw -type DrawType"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[DrawCube-0]
+ _ = x[DrawNothing-1]
+ _ = x[DrawLiquid-2]
+ _ = x[DrawFlowing-3]
+ _ = x[DrawLikeGlass-4]
+ _ = x[DrawAllFaces-5]
+ _ = x[DrawAllFacesOpt-6]
+ _ = x[DrawTorch-7]
+ _ = x[DrawSign-8]
+ _ = x[DrawPlant-9]
+ _ = x[DrawFence-10]
+ _ = x[DrawRail-11]
+ _ = x[DrawNodeBox-12]
+ _ = x[DrawGlassFrame-13]
+ _ = x[DrawFire-14]
+ _ = x[DrawGlassFrameOpt-15]
+ _ = x[DrawMesh-16]
+ _ = x[DrawRootedPlant-17]
+}
+
+const _DrawType_name = "CubeNothingLiquidFlowingLikeGlassAllFacesAllFacesOptTorchSignPlantFenceRailNodeBoxGlassFrameFireGlassFrameOptMeshRootedPlant"
+
+var _DrawType_index = [...]uint8{0, 4, 11, 17, 24, 33, 41, 52, 57, 61, 66, 71, 75, 82, 92, 96, 109, 113, 124}
+
+func (i DrawType) String() string {
+ if i >= DrawType(len(_DrawType_index)-1) {
+ return "DrawType(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _DrawType_name[_DrawType_index[i]:_DrawType_index[i+1]]
+}
diff --git a/hotbarparam_string.go b/hotbarparam_string.go
new file mode 100644
index 0000000..e8552b6
--- /dev/null
+++ b/hotbarparam_string.go
@@ -0,0 +1,26 @@
+// Code generated by "stringer -trimprefix Hotbar -type HotbarParam"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[HotbarSize-1]
+ _ = x[HotbarImg-2]
+ _ = x[HotbarSelImg-3]
+}
+
+const _HotbarParam_name = "SizeImgSelImg"
+
+var _HotbarParam_index = [...]uint8{0, 4, 7, 13}
+
+func (i HotbarParam) String() string {
+ i -= 1
+ if i >= HotbarParam(len(_HotbarParam_index)-1) {
+ return "HotbarParam(" + strconv.FormatInt(int64(i+1), 10) + ")"
+ }
+ return _HotbarParam_name[_HotbarParam_index[i]:_HotbarParam_index[i+1]]
+}
diff --git a/hudfield_string.go b/hudfield_string.go
new file mode 100644
index 0000000..4190d19
--- /dev/null
+++ b/hudfield_string.go
@@ -0,0 +1,36 @@
+// Code generated by "stringer -trimprefix HUD -type HUDField"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[HUDPos-0]
+ _ = x[HUDName-1]
+ _ = x[HUDScale-2]
+ _ = x[HUDText-3]
+ _ = x[HUDNumber-4]
+ _ = x[HUDItem-5]
+ _ = x[HUDDir-6]
+ _ = x[HUDAlign-7]
+ _ = x[HUDOffset-8]
+ _ = x[HUDWorldPos-9]
+ _ = x[HUDSize-10]
+ _ = x[HUDZIndex-11]
+ _ = x[HUDText2-12]
+ _ = x[hudMax-13]
+}
+
+const _HUDField_name = "PosNameScaleTextNumberItemDirAlignOffsetWorldPosSizeZIndexText2hudMax"
+
+var _HUDField_index = [...]uint8{0, 3, 7, 12, 16, 22, 26, 29, 34, 40, 48, 52, 58, 63, 69}
+
+func (i HUDField) String() string {
+ if i >= HUDField(len(_HUDField_index)-1) {
+ return "HUDField(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _HUDField_name[_HUDField_index[i]:_HUDField_index[i+1]]
+}
diff --git a/hudtype_string.go b/hudtype_string.go
new file mode 100644
index 0000000..e0c1b2b
--- /dev/null
+++ b/hudtype_string.go
@@ -0,0 +1,28 @@
+// Code generated by "stringer -type HUDType"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[ImgHUD-0]
+ _ = x[TextHUD-1]
+ _ = x[StatbarHUD-2]
+ _ = x[InvHUD-3]
+ _ = x[WaypointHUD-4]
+ _ = x[ImgWaypointHUD-5]
+}
+
+const _HUDType_name = "ImgHUDTextHUDStatbarHUDInvHUDWaypointHUDImgWaypointHUD"
+
+var _HUDType_index = [...]uint8{0, 6, 13, 23, 29, 40, 54}
+
+func (i HUDType) String() string {
+ if i >= HUDType(len(_HUDType_index)-1) {
+ return "HUDType(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _HUDType_name[_HUDType_index[i]:_HUDType_index[i+1]]
+}
diff --git a/interaction_string.go b/interaction_string.go
new file mode 100644
index 0000000..5bd4103
--- /dev/null
+++ b/interaction_string.go
@@ -0,0 +1,28 @@
+// Code generated by "stringer -type Interaction"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[Dig-0]
+ _ = x[StopDigging-1]
+ _ = x[Dug-2]
+ _ = x[Place-3]
+ _ = x[Use-4]
+ _ = x[Activate-5]
+}
+
+const _Interaction_name = "DigStopDiggingDugPlaceUseActivate"
+
+var _Interaction_index = [...]uint8{0, 3, 14, 17, 22, 25, 33}
+
+func (i Interaction) String() string {
+ if i >= Interaction(len(_Interaction_index)-1) {
+ return "Interaction(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _Interaction_name[_Interaction_index[i]:_Interaction_index[i+1]]
+}
diff --git a/itemdef.go b/itemdef.go
index a761b65..12651fa 100644
--- a/itemdef.go
+++ b/itemdef.go
@@ -11,6 +11,8 @@ const (
ToolItem
)
+//go:generate stringer -type ItemType
+
// An ItemDef defines the properties of an item.
type ItemDef struct {
//mt:lenhdr 16
diff --git a/itemtype_string.go b/itemtype_string.go
new file mode 100644
index 0000000..ccae2f6
--- /dev/null
+++ b/itemtype_string.go
@@ -0,0 +1,26 @@
+// Code generated by "stringer -type ItemType"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[NodeItem-1]
+ _ = x[CraftItem-2]
+ _ = x[ToolItem-3]
+}
+
+const _ItemType_name = "NodeItemCraftItemToolItem"
+
+var _ItemType_index = [...]uint8{0, 8, 17, 25}
+
+func (i ItemType) String() string {
+ i -= 1
+ if i >= ItemType(len(_ItemType_index)-1) {
+ return "ItemType(" + strconv.FormatInt(int64(i+1), 10) + ")"
+ }
+ return _ItemType_name[_ItemType_index[i]:_ItemType_index[i+1]]
+}
diff --git a/light.go b/light.go
index b086591..30d2a58 100644
--- a/light.go
+++ b/light.go
@@ -11,3 +11,5 @@ const (
Day LightBank = iota
Night
)
+
+//go:generate stringer -type LightBank
diff --git a/lightbank_string.go b/lightbank_string.go
new file mode 100644
index 0000000..ef37758
--- /dev/null
+++ b/lightbank_string.go
@@ -0,0 +1,24 @@
+// Code generated by "stringer -type LightBank"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[Day-0]
+ _ = x[Night-1]
+}
+
+const _LightBank_name = "DayNight"
+
+var _LightBank_index = [...]uint8{0, 3, 8}
+
+func (i LightBank) String() string {
+ if i >= LightBank(len(_LightBank_index)-1) {
+ return "LightBank(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _LightBank_name[_LightBank_index[i]:_LightBank_index[i+1]]
+}
diff --git a/liquidtype_string.go b/liquidtype_string.go
new file mode 100644
index 0000000..3fb9eee
--- /dev/null
+++ b/liquidtype_string.go
@@ -0,0 +1,25 @@
+// Code generated by "stringer -type LiquidType"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[NotALiquid-0]
+ _ = x[FlowingLiquid-1]
+ _ = x[LiquidSrc-2]
+}
+
+const _LiquidType_name = "NotALiquidFlowingLiquidLiquidSrc"
+
+var _LiquidType_index = [...]uint8{0, 10, 23, 32}
+
+func (i LiquidType) String() string {
+ if i >= LiquidType(len(_LiquidType_index)-1) {
+ return "LiquidType(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _LiquidType_name[_LiquidType_index[i]:_LiquidType_index[i+1]]
+}
diff --git a/minimap.go b/minimap.go
index f0817f7..221a16b 100644
--- a/minimap.go
+++ b/minimap.go
@@ -3,12 +3,14 @@ package mt
type MinimapType uint16
const (
- NoMinimap MinimapType = iota
- SurfaceMinimap
- RadarMinimap
- TextureMinimap
+ NoMinimap MinimapType = iota // none
+ SurfaceMinimap // surface
+ RadarMinimap // radar
+ TextureMinimap // texture
)
+//go:generate stringer -linecomment -type MinimapType
+
type MinimapMode struct {
Type MinimapType
Label string
diff --git a/minimaptype_string.go b/minimaptype_string.go
new file mode 100644
index 0000000..3dfc0d8
--- /dev/null
+++ b/minimaptype_string.go
@@ -0,0 +1,26 @@
+// Code generated by "stringer -linecomment -type MinimapType"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[NoMinimap-0]
+ _ = x[SurfaceMinimap-1]
+ _ = x[RadarMinimap-2]
+ _ = x[TextureMinimap-3]
+}
+
+const _MinimapType_name = "nonesurfaceradartexture"
+
+var _MinimapType_index = [...]uint8{0, 4, 11, 16, 23}
+
+func (i MinimapType) String() string {
+ if i >= MinimapType(len(_MinimapType_index)-1) {
+ return "MinimapType(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _MinimapType_name[_MinimapType_index[i]:_MinimapType_index[i+1]]
+}
diff --git a/mkpktinfos.sh b/mkpktinfos.sh
index 3d5d5e7..f913495 100755
--- a/mkpktinfos.sh
+++ b/mkpktinfos.sh
@@ -1,7 +1,7 @@
#!/bin/sh
(
- echo // Code generated by mkpktinfos.sh. DO NOT EDIT.
+ echo '// Code generated by mkpktinfos.sh; DO NOT EDIT.'
echo
echo package mt
echo
diff --git a/mkserialize.sh b/mkserialize.sh
index c758a85..f5f0350 100755
--- a/mkserialize.sh
+++ b/mkserialize.sh
@@ -3,7 +3,7 @@
rm -f serialize.go
(
- echo // Code generated by mkserialize.sh. DO NOT EDIT.
+ echo '// Code generated by mkserialize.sh; DO NOT EDIT.'
echo
internal/mkserialize/mkserialize | goimports
) >>serialize.go.tmp &&
diff --git a/modchansig_string.go b/modchansig_string.go
new file mode 100644
index 0000000..b422d6c
--- /dev/null
+++ b/modchansig_string.go
@@ -0,0 +1,28 @@
+// Code generated by "stringer -type ModChanSig"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[JoinOK-0]
+ _ = x[JoinFail-1]
+ _ = x[LeaveOK-2]
+ _ = x[LeaveFail-3]
+ _ = x[NotRegistered-4]
+ _ = x[SetState-5]
+}
+
+const _ModChanSig_name = "JoinOKJoinFailLeaveOKLeaveFailNotRegisteredSetState"
+
+var _ModChanSig_index = [...]uint8{0, 6, 14, 21, 30, 43, 51}
+
+func (i ModChanSig) String() string {
+ if i >= ModChanSig(len(_ModChanSig_index)-1) {
+ return "ModChanSig(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _ModChanSig_name[_ModChanSig_index[i]:_ModChanSig_index[i+1]]
+}
diff --git a/nodebox.go b/nodebox.go
index 46d704c..166961e 100644
--- a/nodebox.go
+++ b/nodebox.go
@@ -5,14 +5,16 @@ type Box [2]Vec
type NodeBoxType uint8
const (
- CubeBox NodeBoxType = iota
- FixedBox
- MountedBox
- LeveledBox
- ConnectedBox
+ CubeBox NodeBoxType = iota // Cube
+ FixedBox // Fixed
+ MountedBox // Mounted
+ LeveledBox // Leveled
+ ConnectedBox // Connected
maxBox
)
+//go:generate stringer -linecomment -type NodeBoxType
+
type DirBoxes struct {
Top, Bot []Box
Front, Left, Back, Right []Box
diff --git a/nodeboxtype_string.go b/nodeboxtype_string.go
new file mode 100644
index 0000000..4f2c337
--- /dev/null
+++ b/nodeboxtype_string.go
@@ -0,0 +1,28 @@
+// Code generated by "stringer -linecomment -type NodeBoxType"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[CubeBox-0]
+ _ = x[FixedBox-1]
+ _ = x[MountedBox-2]
+ _ = x[LeveledBox-3]
+ _ = x[ConnectedBox-4]
+ _ = x[maxBox-5]
+}
+
+const _NodeBoxType_name = "CubeFixedMountedLeveledConnectedmaxBox"
+
+var _NodeBoxType_index = [...]uint8{0, 4, 9, 16, 23, 32, 38}
+
+func (i NodeBoxType) String() string {
+ if i >= NodeBoxType(len(_NodeBoxType_index)-1) {
+ return "NodeBoxType(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _NodeBoxType_name[_NodeBoxType_index[i]:_NodeBoxType_index[i+1]]
+}
diff --git a/nodedef.go b/nodedef.go
index 5606452..91b8235 100644
--- a/nodedef.go
+++ b/nodedef.go
@@ -9,6 +9,8 @@ const (
P1Light
)
+//go:generate stringer -trimprefix P1 -type Param1Type
+
type Param2Type uint8
const (
@@ -26,6 +28,8 @@ const (
P2GlassLikeLevel
)
+//go:generate stringer -trimprefix P2 -type Param2Type
+
// A DrawType specifies how a node is drawn.
type DrawType uint8
@@ -50,6 +54,8 @@ const (
DrawRootedPlant
)
+//go:generate stringer -trimprefix Draw -type DrawType
+
type WaveType uint8
const (
@@ -59,6 +65,8 @@ const (
LiquidWaving // Wave up and down.
)
+//go:generate stringer -type WaveType
+
type LiquidType uint8
const (
@@ -67,6 +75,8 @@ const (
LiquidSrc
)
+//go:generate stringer -type LiquidType
+
// AlphaUse specifies how the alpha channel of a texture is used.
type AlphaUse uint8
@@ -77,6 +87,8 @@ const (
Legacy
)
+//go:generate stringer -type AlphaUse
+
type NodeDef struct {
Param0 Content
diff --git a/param1type_string.go b/param1type_string.go
new file mode 100644
index 0000000..66e79d5
--- /dev/null
+++ b/param1type_string.go
@@ -0,0 +1,24 @@
+// Code generated by "stringer -trimprefix P1 -type Param1Type"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[P1Nothing-0]
+ _ = x[P1Light-1]
+}
+
+const _Param1Type_name = "NothingLight"
+
+var _Param1Type_index = [...]uint8{0, 7, 12}
+
+func (i Param1Type) String() string {
+ if i >= Param1Type(len(_Param1Type_index)-1) {
+ return "Param1Type(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _Param1Type_name[_Param1Type_index[i]:_Param1Type_index[i+1]]
+}
diff --git a/param2type_string.go b/param2type_string.go
new file mode 100644
index 0000000..d3f1428
--- /dev/null
+++ b/param2type_string.go
@@ -0,0 +1,34 @@
+// Code generated by "stringer -trimprefix P2 -type Param2Type"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[P2Nibble-0]
+ _ = x[P2Byte-1]
+ _ = x[P2Flowing-2]
+ _ = x[P2FaceDir-3]
+ _ = x[P2Mounted-4]
+ _ = x[P2Leveled-5]
+ _ = x[P2Rotation-6]
+ _ = x[P2Mesh-7]
+ _ = x[P2Color-8]
+ _ = x[P2ColorFaceDir-9]
+ _ = x[P2ColorMounted-10]
+ _ = x[P2GlassLikeLevel-11]
+}
+
+const _Param2Type_name = "NibbleByteFlowingFaceDirMountedLeveledRotationMeshColorColorFaceDirColorMountedGlassLikeLevel"
+
+var _Param2Type_index = [...]uint8{0, 6, 10, 17, 24, 31, 38, 46, 50, 55, 67, 79, 93}
+
+func (i Param2Type) String() string {
+ if i >= Param2Type(len(_Param2Type_index)-1) {
+ return "Param2Type(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _Param2Type_name[_Param2Type_index[i]:_Param2Type_index[i+1]]
+}
diff --git a/pktinfos.go b/pktinfos.go
index 4b725da..47b7783 100644
--- a/pktinfos.go
+++ b/pktinfos.go
@@ -1,4 +1,4 @@
-// Code generated by mkpktinfos.sh. DO NOT EDIT.
+// Code generated by mkpktinfos.sh; DO NOT EDIT.
package mt
diff --git a/playerlistupdatetype_string.go b/playerlistupdatetype_string.go
new file mode 100644
index 0000000..d8fd486
--- /dev/null
+++ b/playerlistupdatetype_string.go
@@ -0,0 +1,25 @@
+// Code generated by "stringer -linecomment -type PlayerListUpdateType"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[InitPlayers-0]
+ _ = x[AddPlayers-1]
+ _ = x[RemovePlayers-2]
+}
+
+const _PlayerListUpdateType_name = "initaddremove"
+
+var _PlayerListUpdateType_index = [...]uint8{0, 4, 7, 13}
+
+func (i PlayerListUpdateType) String() string {
+ if i >= PlayerListUpdateType(len(_PlayerListUpdateType_index)-1) {
+ return "PlayerListUpdateType(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _PlayerListUpdateType_name[_PlayerListUpdateType_index[i]:_PlayerListUpdateType_index[i+1]]
+}
diff --git a/serialize.fmt b/serialize.fmt
index c157001..991c22b 100644
--- a/serialize.fmt
+++ b/serialize.fmt
@@ -128,7 +128,7 @@ map[[3]int16]*NodeMeta {
PointedThing chk(writePointedThing(w, x))
-[]AOMsg { // For AOInitData.Msgs
+[]AOMsg { // For AOInitData.Msgs.
if len(x) > math.MaxUint8 {
chk(ErrTooLong)
}
@@ -145,7 +145,7 @@ PointedThing chk(writePointedThing(w, x))
}
}
-[]NodeDef { // For ToCltNodeDefs.Defs
+[]NodeDef { // For ToCltNodeDefs.Defs.
if len(x) > math.MaxUint16 {
chk(ErrTooLong)
}
diff --git a/serialize.go b/serialize.go
index 892e9f3..6f27a98 100644
--- a/serialize.go
+++ b/serialize.go
@@ -1,4 +1,4 @@
-// Code generated by mkserialize.sh. DO NOT EDIT.
+// Code generated by mkserialize.sh; DO NOT EDIT.
package mt
@@ -3651,7 +3651,7 @@ func (obj *ToCltNodeDefs) serialize(w io.Writer) {
// See (de)serialize.fmt.
Defs []NodeDef
}))(obj)).Defs
- { // For ToCltNodeDefs.Defs
+ { // For ToCltNodeDefs.Defs.
if len(x) > math.MaxUint16 {
chk(ErrTooLong)
}
@@ -24566,7 +24566,7 @@ func (obj *AOInitData) serialize(w io.Writer) {
// See (de)serialize.fmt.
Msgs []AOMsg
}))(obj)).Msgs
- { // For AOInitData.Msgs
+ { // For AOInitData.Msgs.
if len(x) > math.MaxUint8 {
chk(ErrTooLong)
}
@@ -27223,7 +27223,7 @@ func (obj *TileAnim) serialize(w io.Writer) {
((*(*(struct {
Type AnimType
- //mt:if %s.Type == SpritesheetAnim
+ //mt:if %s.Type == SpriteSheetAnim
AspectRatio [2]uint8
//mt:if %s.Type == VerticalFrameAnim
@@ -27242,7 +27242,7 @@ func (obj *TileAnim) serialize(w io.Writer) {
if !((*(*(struct {
Type AnimType
- //mt:if %s.Type == SpritesheetAnim
+ //mt:if %s.Type == SpriteSheetAnim
AspectRatio [2]uint8
//mt:if %s.Type == VerticalFrameAnim
@@ -27257,7 +27257,7 @@ func (obj *TileAnim) serialize(w io.Writer) {
if (*(*(struct {
Type AnimType
- //mt:if %s.Type == SpritesheetAnim
+ //mt:if %s.Type == SpriteSheetAnim
AspectRatio [2]uint8
//mt:if %s.Type == VerticalFrameAnim
@@ -27266,12 +27266,12 @@ func (obj *TileAnim) serialize(w io.Writer) {
//mt:if %s.Type != NoAnim
Duration float32 // in seconds
- }))(obj)).Type == SpritesheetAnim {
+ }))(obj)).Type == SpriteSheetAnim {
{
_, err := w.Write(((*(*(struct {
Type AnimType
- //mt:if %s.Type == SpritesheetAnim
+ //mt:if %s.Type == SpriteSheetAnim
AspectRatio [2]uint8
//mt:if %s.Type == VerticalFrameAnim
@@ -27287,7 +27287,7 @@ func (obj *TileAnim) serialize(w io.Writer) {
if (*(*(struct {
Type AnimType
- //mt:if %s.Type == SpritesheetAnim
+ //mt:if %s.Type == SpriteSheetAnim
AspectRatio [2]uint8
//mt:if %s.Type == VerticalFrameAnim
@@ -27300,7 +27300,7 @@ func (obj *TileAnim) serialize(w io.Writer) {
for local319 := range (*(*(struct {
Type AnimType
- //mt:if %s.Type == SpritesheetAnim
+ //mt:if %s.Type == SpriteSheetAnim
AspectRatio [2]uint8
//mt:if %s.Type == VerticalFrameAnim
@@ -27314,7 +27314,7 @@ func (obj *TileAnim) serialize(w io.Writer) {
x := ((*(*(struct {
Type AnimType
- //mt:if %s.Type == SpritesheetAnim
+ //mt:if %s.Type == SpriteSheetAnim
AspectRatio [2]uint8
//mt:if %s.Type == VerticalFrameAnim
@@ -27331,7 +27331,7 @@ func (obj *TileAnim) serialize(w io.Writer) {
if (*(*(struct {
Type AnimType
- //mt:if %s.Type == SpritesheetAnim
+ //mt:if %s.Type == SpriteSheetAnim
AspectRatio [2]uint8
//mt:if %s.Type == VerticalFrameAnim
@@ -27345,7 +27345,7 @@ func (obj *TileAnim) serialize(w io.Writer) {
x := (*(*(struct {
Type AnimType
- //mt:if %s.Type == SpritesheetAnim
+ //mt:if %s.Type == SpriteSheetAnim
AspectRatio [2]uint8
//mt:if %s.Type == VerticalFrameAnim
@@ -27365,7 +27365,7 @@ func (obj *TileAnim) deserialize(r io.Reader) {
((*(*(struct {
Type AnimType
- //mt:if %s.Type == SpritesheetAnim
+ //mt:if %s.Type == SpriteSheetAnim
AspectRatio [2]uint8
//mt:if %s.Type == VerticalFrameAnim
@@ -27384,7 +27384,7 @@ func (obj *TileAnim) deserialize(r io.Reader) {
if !((*(*(struct {
Type AnimType
- //mt:if %s.Type == SpritesheetAnim
+ //mt:if %s.Type == SpriteSheetAnim
AspectRatio [2]uint8
//mt:if %s.Type == VerticalFrameAnim
@@ -27399,7 +27399,7 @@ func (obj *TileAnim) deserialize(r io.Reader) {
if (*(*(struct {
Type AnimType
- //mt:if %s.Type == SpritesheetAnim
+ //mt:if %s.Type == SpriteSheetAnim
AspectRatio [2]uint8
//mt:if %s.Type == VerticalFrameAnim
@@ -27408,12 +27408,12 @@ func (obj *TileAnim) deserialize(r io.Reader) {
//mt:if %s.Type != NoAnim
Duration float32 // in seconds
- }))(obj)).Type == SpritesheetAnim {
+ }))(obj)).Type == SpriteSheetAnim {
{
_, err := io.ReadFull(r, ((*(*(struct {
Type AnimType
- //mt:if %s.Type == SpritesheetAnim
+ //mt:if %s.Type == SpriteSheetAnim
AspectRatio [2]uint8
//mt:if %s.Type == VerticalFrameAnim
@@ -27429,7 +27429,7 @@ func (obj *TileAnim) deserialize(r io.Reader) {
if (*(*(struct {
Type AnimType
- //mt:if %s.Type == SpritesheetAnim
+ //mt:if %s.Type == SpriteSheetAnim
AspectRatio [2]uint8
//mt:if %s.Type == VerticalFrameAnim
@@ -27442,7 +27442,7 @@ func (obj *TileAnim) deserialize(r io.Reader) {
for local320 := range (*(*(struct {
Type AnimType
- //mt:if %s.Type == SpritesheetAnim
+ //mt:if %s.Type == SpriteSheetAnim
AspectRatio [2]uint8
//mt:if %s.Type == VerticalFrameAnim
@@ -27456,7 +27456,7 @@ func (obj *TileAnim) deserialize(r io.Reader) {
p := &((*(*(struct {
Type AnimType
- //mt:if %s.Type == SpritesheetAnim
+ //mt:if %s.Type == SpriteSheetAnim
AspectRatio [2]uint8
//mt:if %s.Type == VerticalFrameAnim
@@ -27473,7 +27473,7 @@ func (obj *TileAnim) deserialize(r io.Reader) {
if (*(*(struct {
Type AnimType
- //mt:if %s.Type == SpritesheetAnim
+ //mt:if %s.Type == SpriteSheetAnim
AspectRatio [2]uint8
//mt:if %s.Type == VerticalFrameAnim
@@ -27487,7 +27487,7 @@ func (obj *TileAnim) deserialize(r io.Reader) {
p := &(*(*(struct {
Type AnimType
- //mt:if %s.Type == SpritesheetAnim
+ //mt:if %s.Type == SpriteSheetAnim
AspectRatio [2]uint8
//mt:if %s.Type == VerticalFrameAnim
@@ -27675,7 +27675,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -27714,7 +27714,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -27757,7 +27757,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -27796,7 +27796,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -27839,7 +27839,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -27882,7 +27882,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -27924,7 +27924,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -27963,7 +27963,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28002,7 +28002,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28040,7 +28040,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28077,7 +28077,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28116,7 +28116,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28155,7 +28155,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28193,7 +28193,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28230,7 +28230,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28273,7 +28273,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28299,7 +28299,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Shaded bool
ShowOnMinimap bool
NametagBG color.NRGBA
- }))(obj)).SpritesheetSize {
+ }))(obj)).SpriteSheetSize {
{
x := ((*(*(struct {
MaxHP uint16 // Player only.
@@ -28310,7 +28310,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28336,7 +28336,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Shaded bool
ShowOnMinimap bool
NametagBG color.NRGBA
- }))(obj)).SpritesheetSize)[local326]
+ }))(obj)).SpriteSheetSize)[local326]
write16(w, uint16(x))
}
}
@@ -28349,7 +28349,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28386,7 +28386,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28426,7 +28426,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28469,7 +28469,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28512,7 +28512,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28550,7 +28550,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28589,7 +28589,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28628,7 +28628,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28666,7 +28666,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28705,7 +28705,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28743,7 +28743,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28780,7 +28780,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28820,7 +28820,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28863,7 +28863,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28902,7 +28902,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28945,7 +28945,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -28984,7 +28984,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29026,7 +29026,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29065,7 +29065,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29104,7 +29104,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29143,7 +29143,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29182,7 +29182,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29220,7 +29220,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29259,7 +29259,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29298,7 +29298,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29336,7 +29336,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29375,7 +29375,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29414,7 +29414,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29453,7 +29453,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29492,7 +29492,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29531,7 +29531,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29570,7 +29570,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29609,7 +29609,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29652,7 +29652,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29695,7 +29695,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29738,7 +29738,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29781,7 +29781,7 @@ func (obj *AOProps) serialize(w io.Writer) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29833,7 +29833,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29872,7 +29872,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29918,7 +29918,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -29957,7 +29957,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30000,7 +30000,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30043,7 +30043,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30099,7 +30099,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30135,7 +30135,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30172,7 +30172,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30216,7 +30216,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30252,7 +30252,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30289,7 +30289,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30332,7 +30332,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30358,7 +30358,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Shaded bool
ShowOnMinimap bool
NametagBG color.NRGBA
- }))(obj)).SpritesheetSize {
+ }))(obj)).SpriteSheetSize {
{
p := &((*(*(struct {
MaxHP uint16 // Player only.
@@ -30369,7 +30369,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30395,7 +30395,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Shaded bool
ShowOnMinimap bool
NametagBG color.NRGBA
- }))(obj)).SpritesheetSize)[local335]
+ }))(obj)).SpriteSheetSize)[local335]
*p = int16(read16(r))
}
}
@@ -30408,7 +30408,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30445,7 +30445,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30485,7 +30485,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30531,7 +30531,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30577,7 +30577,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30626,7 +30626,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30667,7 +30667,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30703,7 +30703,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30740,7 +30740,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30780,7 +30780,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30826,7 +30826,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30865,7 +30865,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30911,7 +30911,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -30950,7 +30950,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -31006,7 +31006,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -31043,7 +31043,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -31082,7 +31082,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -31131,7 +31131,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -31178,7 +31178,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -31215,7 +31215,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -31254,7 +31254,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -31293,7 +31293,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -31332,7 +31332,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -31371,7 +31371,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -31417,7 +31417,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -31460,7 +31460,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -31506,7 +31506,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
@@ -31552,7 +31552,7 @@ func (obj *AOProps) deserialize(r io.Reader) {
Visual string
VisualSize [3]float32
Textures []Texture
- SpritesheetSize [2]int16 // in sprites.
+ SpriteSheetSize [2]int16 // in sprites.
SpritePos [2]int16 // in sprite sheet.
Visible bool
MakeFootstepSnds bool
diff --git a/sound.go b/sound.go
index 953677c..c662968 100644
--- a/sound.go
+++ b/sound.go
@@ -5,11 +5,13 @@ type SoundID int32
type SoundSrcType uint8
const (
- NoSrc SoundSrcType = iota
- PosSrc
- AOSrc
+ NoSrc SoundSrcType = iota // nowhere
+ PosSrc // pos
+ AOSrc // ao
)
+//go:generate stringer -linecomment -type SoundSrcType
+
type SoundDef struct {
Name string
Gain, Pitch, Fade float32
diff --git a/soundsrctype_string.go b/soundsrctype_string.go
new file mode 100644
index 0000000..ccf307d
--- /dev/null
+++ b/soundsrctype_string.go
@@ -0,0 +1,25 @@
+// Code generated by "stringer -linecomment -type SoundSrcType"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[NoSrc-0]
+ _ = x[PosSrc-1]
+ _ = x[AOSrc-2]
+}
+
+const _SoundSrcType_name = "nowhereposao"
+
+var _SoundSrcType_index = [...]uint8{0, 7, 10, 12}
+
+func (i SoundSrcType) String() string {
+ if i >= SoundSrcType(len(_SoundSrcType_index)-1) {
+ return "SoundSrcType(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _SoundSrcType_name[_SoundSrcType_index[i]:_SoundSrcType_index[i+1]]
+}
diff --git a/tileanim.go b/tileanim.go
index bc6d6dd..8d664df 100644
--- a/tileanim.go
+++ b/tileanim.go
@@ -3,17 +3,19 @@ package mt
type AnimType uint8
const (
- NoAnim AnimType = iota
- VerticalFrameAnim
- SpritesheetAnim
+ NoAnim AnimType = iota // none
+ VerticalFrameAnim // vertical frame
+ SpriteSheetAnim // sprite sheet
maxAnim
)
+//go:generate stringer -linecomment -type AnimType
+
type TileAnim struct {
Type AnimType
//mt:assert %s.Type < maxAnim
- //mt:if %s.Type == SpritesheetAnim
+ //mt:if %s.Type == SpriteSheetAnim
AspectRatio [2]uint8
//mt:end
diff --git a/tiledef.go b/tiledef.go
index 9a5714d..da6ab39 100644
--- a/tiledef.go
+++ b/tiledef.go
@@ -8,6 +8,8 @@ const (
UserAlign
)
+//go:generate stringer -type AlignType
+
type TileFlags uint16
const (
@@ -19,6 +21,8 @@ const (
TileAlign
)
+//go:generate stringer -type TileFlags
+
type TileDef struct {
//mt:const uint8(6)
diff --git a/tileflags_string.go b/tileflags_string.go
new file mode 100644
index 0000000..f442303
--- /dev/null
+++ b/tileflags_string.go
@@ -0,0 +1,47 @@
+// Code generated by "stringer -type TileFlags"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[TileBackfaceCull-1]
+ _ = x[TileAbleH-2]
+ _ = x[TileAbleV-4]
+ _ = x[TileColor-8]
+ _ = x[TileScale-16]
+ _ = x[TileAlign-32]
+}
+
+const (
+ _TileFlags_name_0 = "TileBackfaceCullTileAbleH"
+ _TileFlags_name_1 = "TileAbleV"
+ _TileFlags_name_2 = "TileColor"
+ _TileFlags_name_3 = "TileScale"
+ _TileFlags_name_4 = "TileAlign"
+)
+
+var (
+ _TileFlags_index_0 = [...]uint8{0, 16, 25}
+)
+
+func (i TileFlags) String() string {
+ switch {
+ case 1 <= i && i <= 2:
+ i -= 1
+ return _TileFlags_name_0[_TileFlags_index_0[i]:_TileFlags_index_0[i+1]]
+ case i == 4:
+ return _TileFlags_name_1
+ case i == 8:
+ return _TileFlags_name_2
+ case i == 16:
+ return _TileFlags_name_3
+ case i == 32:
+ return _TileFlags_name_4
+ default:
+ return "TileFlags(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+}
diff --git a/tocltcmds.go b/tocltcmds.go
index 6af4f09..5fbe18b 100644
--- a/tocltcmds.go
+++ b/tocltcmds.go
@@ -1,5 +1,3 @@
-//go:generate ./cmdno.sh tocltcmds ToClt toClt uint16 Cmd newToCltCmd
-
package mt
import (
@@ -15,6 +13,8 @@ type ToCltCmd interface {
toCltCmdNo() uint16
}
+//go:generate ./cmdno.sh tocltcmds ToClt toClt uint16 Cmd newToCltCmd
+
// ToCltHello is sent as a response to ToSrvInit.
// The client responds to ToCltHello by authenticating.
type ToCltHello struct {
@@ -196,25 +196,14 @@ type ToCltChatMsg struct {
type ChatMsgType uint8
const (
- RawMsg ChatMsgType = iota
- NormalMsg
- AnnounceMsg
- SysMsg
+ RawMsg ChatMsgType = iota // raw
+ NormalMsg // normal
+ AnnounceMsg // announce
+ SysMsg // sys
maxMsg
)
-func (t ChatMsgType) String() string {
- if t >= maxMsg {
- return fmt.Sprintf("ChatMsgType(%d)", t)
- }
-
- return [...]string{
- "raw",
- "normal",
- "announce",
- "sys",
- }[t]
-}
+//go:generate stringer -linecomment -type ChatMsgType
// ToCltAORmAdd tells the client that AOs have been removed from and/or added to
// the AOs that it can see.
@@ -454,6 +443,8 @@ const (
ImgWaypointHUD
)
+//go:generate stringer -type HUDType
+
// ToCltRmHUD tells the client to remove a HUD.
type ToCltRmHUD struct {
ID HUDID
@@ -539,6 +530,8 @@ const (
hudMax
)
+//go:generate stringer -trimprefix HUD -type HUDField
+
// ToCltHUDFlags tells the client to update its HUD flags.
type ToCltHUDFlags struct {
// &^= Mask
@@ -580,6 +573,8 @@ const (
HotbarSelImg
)
+//go:generate stringer -trimprefix Hotbar -type HotbarParam
+
// ToCltBreath tells the client how much breath it has.
type ToCltBreath struct {
Breath uint16
@@ -655,11 +650,13 @@ type ToCltUpdatePlayerList struct {
type PlayerListUpdateType uint8
const (
- InitPlayers PlayerListUpdateType = iota
- AddPlayers
- RemovePlayers
+ InitPlayers PlayerListUpdateType = iota // init
+ AddPlayers // add
+ RemovePlayers // remove
)
+//go:generate stringer -linecomment -type PlayerListUpdateType
+
// ToCltModChanMsg tells the client it has been sent a message on a mod channel.
type ToCltModChanMsg struct {
Channel string
@@ -684,6 +681,8 @@ const (
SetState
)
+//go:generate stringer -type ModChanSig
+
// ToCltModChanMsg is sent when node metadata near the client changes.
type ToCltNodeMetasChanged struct {
//mt:lenhdr 32
diff --git a/tocltcmds_cmdno.go b/tocltcmds_cmdno.go
index 8999717..0dbe4e4 100644
--- a/tocltcmds_cmdno.go
+++ b/tocltcmds_cmdno.go
@@ -1,4 +1,4 @@
-// Code generated by cmdno.sh. DO NOT EDIT.
+// Code generated by cmdno.sh; DO NOT EDIT.
package mt
diff --git a/tosrvcmds.go b/tosrvcmds.go
index 4f60600..4915204 100644
--- a/tosrvcmds.go
+++ b/tosrvcmds.go
@@ -1,5 +1,3 @@
-//go:generate ./cmdno.sh tosrvcmds ToSrv toSrv uint16 Cmd newToSrvCmd
-
package mt
type ToSrvCmd interface {
@@ -7,6 +5,8 @@ type ToSrvCmd interface {
toSrvCmdNo() uint16
}
+//go:generate ./cmdno.sh tosrvcmds ToSrv toSrv uint16 Cmd newToSrvCmd
+
// ToSrvNil is the first packet sent in a connection.
type ToSrvNil struct{}
@@ -109,6 +109,8 @@ const (
Activate // Right click air.
)
+//go:generate stringer -type Interaction
+
// ToSrvRemovedSounds tells the server that the client has finished playing
// the sounds with the given IDs.
type ToSrvRemovedSounds struct {
diff --git a/tosrvcmds_cmdno.go b/tosrvcmds_cmdno.go
index 04e6530..6da3e81 100644
--- a/tosrvcmds_cmdno.go
+++ b/tosrvcmds_cmdno.go
@@ -1,4 +1,4 @@
-// Code generated by cmdno.sh. DO NOT EDIT.
+// Code generated by cmdno.sh; DO NOT EDIT.
package mt
diff --git a/wavetype_string.go b/wavetype_string.go
new file mode 100644
index 0000000..5b4604c
--- /dev/null
+++ b/wavetype_string.go
@@ -0,0 +1,26 @@
+// Code generated by "stringer -type WaveType"; DO NOT EDIT.
+
+package mt
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[NotWaving-0]
+ _ = x[PlantWaving-1]
+ _ = x[LeafWaving-2]
+ _ = x[LiquidWaving-3]
+}
+
+const _WaveType_name = "NotWavingPlantWavingLeafWavingLiquidWaving"
+
+var _WaveType_index = [...]uint8{0, 9, 20, 30, 42}
+
+func (i WaveType) String() string {
+ if i >= WaveType(len(_WaveType_index)-1) {
+ return "WaveType(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _WaveType_name[_WaveType_index[i]:_WaveType_index[i+1]]
+}