diff options
author | Juan J. Martinez <jjm@usebox.net> | 2022-09-15 08:31:43 +0100 |
---|---|---|
committer | Juan J. Martinez <jjm@usebox.net> | 2022-09-15 08:31:43 +0100 |
commit | 16d6f8e322311eff51b23425218b2d6c383170d6 (patch) | |
tree | e8f4c0d9c4f64a17bba628481befd521671df6ab /tools/png2sprites.py | |
parent | 495b06cc5e3ffb2d5448a98ced49d2637105b119 (diff) | |
download | ubox-msx-lib-16d6f8e322311eff51b23425218b2d6c383170d6.tar.gz ubox-msx-lib-16d6f8e322311eff51b23425218b2d6c383170d6.zip |
The order of elements on a set is undefined
This could lead to change in order, for example, when changing version
of Python. This change ensures the colours are always in the same order.
Diffstat (limited to 'tools/png2sprites.py')
-rwxr-xr-x | tools/png2sprites.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/png2sprites.py b/tools/png2sprites.py index 7528fae..95e6492 100755 --- a/tools/png2sprites.py +++ b/tools/png2sprites.py @@ -109,7 +109,7 @@ def main(): tile = [ data[x + i + ((y + j) * w)] for j in range(DEF_H) for i in range(DEF_W) ] - cols = set([c for c in tile if c != TRANS]) + cols = sorted(set([c for c in tile if c != TRANS])) if not cols: continue |