I didn't test it that much, but it seems to work without any side-effects AFAICT, so I added it. I used your fix C, applying to posts only after about now.
Very good, thank you!
Let's test with the table given in the OP example.
Rank | Required activity | Required merit |
Brand new | 0 | 0 |
Newbie | 1 | 0 |
Jr Member | 30 | 1 |
Member | 60 | 10 |
Full Member | 120 | 100 |
Sr. Member | 240 | 250 |
Hero Member | 480 | 500 |
Legendary | Random in the range 775-1030 | 1000 |