diff options
author | Andrei Karas <akaras@inbox.ru> | 2013-01-26 21:49:55 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2013-01-26 21:49:55 +0300 |
commit | ef32d3fbf4df050a25cf2a82903403ab34b97ce1 (patch) | |
tree | 2c06772f13668369bb6f5326a5df23c8bad813b0 /testxml/testxml.py | |
parent | 8e6b630e10422987afc58ffd3de5155cd81d44e3 (diff) | |
download | evol-tools-ef32d3fbf4df050a25cf2a82903403ab34b97ce1.tar.gz evol-tools-ef32d3fbf4df050a25cf2a82903403ab34b97ce1.tar.bz2 evol-tools-ef32d3fbf4df050a25cf2a82903403ab34b97ce1.tar.xz evol-tools-ef32d3fbf4df050a25cf2a82903403ab34b97ce1.zip |
testxml: add miss sound support.
Diffstat (limited to 'testxml/testxml.py')
-rwxr-xr-x | testxml/testxml.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/testxml/testxml.py b/testxml/testxml.py index e5aacc6..499f49a 100755 --- a/testxml/testxml.py +++ b/testxml/testxml.py @@ -1258,6 +1258,7 @@ def testParticles(id, node, nodeName, src): def testSounds(id, node, type): global errors + havemiss = False for sound in node.getElementsByTagName("sound"): try: event = sound.attributes["event"].value @@ -1271,9 +1272,14 @@ def testSounds(id, node, type): print "error: incorrect sound event name " + event + " in id=" + id errors = errors + 1 elif type == "item": - if event != "hit" and event != "strike": + if event != "hit" and event != "strike" and event != "miss": print "error: incorrect sound event name " + event + " in id=" + id errors = errors + 1 + if event == "strike" or event == "miss": + if havemiss: + print "error: miss and strike attributes at same time in id=" + id + errors = errors + 1 + havemiss = True testSound(sound.childNodes[0].data, sfxDir, "") |