if self.collection:
from .datafile import Statement
with open(os.path.join(path, base+".mdc"), "w") as out_file:
- for r in resources.values():
+ for n in sorted(resources.keys()):
+ r = resources[n]
st = Statement("animation", r.name)
st.sub = r.statements
st.write_to_file(out_file)