/** This function increases the status of the winner's bidding * * @param winner the winner's playerID */ function takeover_process_winner($winner) { global $db; $sql = $db->prepare("UPDATE " . CAVE_TAKEOVER_TABLE . "\n SET status = status + 1\n WHERE playerID = :playerID"); $sql->bindValue('playerID', $winner['playerID'], PDO::PARAM_INT); $sql->execute(); takeover_send_success($winner['playerID'], $winner); }
/** This function increases the status of the winner's bidding * * @param winner the winner's playerID */ function takeover_process_winner($winner) { global $db; $query = "UPDATE `Cave_takeover` SET status = status + 1 WHERE playerID = " . $winner['playerID']; if (!DEBUG) { $db_result = $db->query($query); if (!$db_result) { echo "ERROR (takeover_process_winner) {$query} " . mysql_error(); } } else { echo "DEBUG: {$query} \n"; } takeover_send_success($winner['playerID'], $winner); }