added total monster number check before and after spawning