max_entities=5000;

Set it before loading the level.