Fixed generation of objects.

#time 2h #plat-832 #plat-528