changed total weight based on percentage