Fix bugs in model warmachine, and add serialization of qpixmap
Add idgenerator