Ugly, but working draw card function