Humans are between heaven and earth. So they are the third element in this dynamic: heaven + humans + earth (= a triad).
Humans need to develop sincere and moral lives, so as to keep heaven and earth in balance.
The good ruler has a duty to exert a positive influence for maintaining this balance. Confucius taught that government had both a moral and a political responsibility.
For Confucius and Mencius, heaven had a positive moral role to play in supporting good human behavior.
But to Xunzi, heaven basically just supported natural laws—it was not working to improve human morality. For Xunzi, human improvement requires more human initiative.