Fix crash when loading techdemo/spritetest.cpn