rewrote rand_rules to use weightedChoice, trashed chunk