aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--formspec.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/formspec.go b/formspec.go
index a465143..bfe2e98 100644
--- a/formspec.go
+++ b/formspec.go
@@ -6,7 +6,7 @@ import (
var itemName = regexp.MustCompile("(item_image\\[[0-9.-]+,[0-9.-]+;[0-9.-]+,[0-9.-]+;)([a-zA-Z0-9-_.: ]+)(\\])")
var itemButtonName = regexp.MustCompile("(item_image_button\\[[0-9.-]+,[0-9.-]+;[0-9.-]+,[0-9.-]+;)([a-zA-Z0-9-_.: ]+)(;[a-zA-Z0-9-_.: ]+;[^\\[\\]]*\\])")
-var textureName = regexp.MustCompile("([a-zA-Z0-9-_.]+\\.[a-zA-Z-_.]+)")
+var textureName = regexp.MustCompile("([a-zA-Z0-9-_.]+\\.(?i:png|jpg|bmp|tga))")
func (sc *ServerConn) prependFormspec(fs *string) {
*fs = ReplaceAllStringSubmatchFunc(textureName, *fs, func(groups []string) string {