- /* TODO: this shouldn't loop over all players, just the 4 players that are in the game */
- foreach($player as $key=>$pl)
+ /* get players involved in this game */
+ $result = DB_query('SELECT user_id FROM Hand WHERE game_id='.DB_quote_smart($gameid));
+ while($r = DB_fetch_array($result))