Entities: fixed copy-paste error and moved GL states