Init for entity