public void Bid(int deviceID, int item1Bid, int item2Bid, int item3Bid) { //add to the bid list, if it's not the length of # players wait if (!bids.ContainsKey(deviceID)) { //new bid, add it to the list and check if it's the last bid or not bids[deviceID] = new BidInformation(deviceID, item1Bid, item2Bid, item3Bid); } if (bids.Count == players.Count) { doneBidding = true; } }
public int BidCar(int useID, int carID, int BidValue) { var BidInfo = new BidInformation { UserId = useID, CarId = carID, Bid = BidValue }; if (BidInfo.Insert()) { return(1); } else { return(0); } }