Begin building vote-tallying and round-ending logic

This patch also has database stub fixes