Made chunk generator generate chunks. (Code needs cleanup.)