Erlang: working algorithm for attackers with zero min_dmg