On Tue, 26 Dec 1995, ShadowLord wrote: > I've implemented an auto-auctioning system for the MUD I work at, now, > but I have ran into a crash bug; I can probably write the neccessary code > to fix the problem, however, the big problem is that I can't think of a > good way to prevent the problem without removing the auctioned items. > > The problem is if the current bidder logs off and the auction system > tries selling the item to them, it obviously won't work; my first > sollution was to keep the idnum of the last bidder and what they bid, but > then I thought it was possible that _they_ would have logged off, and the > last bidder would _be_ them, therefore, I'd be forced just to remove the > item from the list. You could keep track of the highest bidder's idnum, then when the object is declared sold, check to make sure they're online. If they aren't, you could check out do_stat (to see how to find out how much gold the player has) and do_set (to see how to set a player's gold in their file). Deduct the gold from their account, and if you don't want to mess with rent files, you can log the item sold, so the player can get the object from an immortal when they come back. Sam
This archive was generated by hypermail 2b30 : 12/07/00 PST