Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bidForCancel #37

Open
kolinko opened this issue Sep 25, 2017 · 0 comments
Open

bidForCancel #37

kolinko opened this issue Sep 25, 2017 · 0 comments

Comments

@kolinko
Copy link
Contributor

kolinko commented Sep 25, 2017

Implement a new kind of a bid: "bidForCancel".

  • If the winning bidder is a person who did "bidForCancel", the state of the tokens returns to "trading" (that is, the item doesn't change the owner, and everyone keeps their tokens),
  • the winning bidder gets the second highest bidder's tokens
  • the second highest bidder receives the amount that was sent in bidForCancel
  • you can only call "bidForCancel" when the highest bidder isn't "bidForCancel" already
  • "bidForCancel" needs to be grater on equal than [price_per_token of highest bidder] * [num_of_tokens of highest bidder]
  • regular bids can go after the "bidForCancel" as usual
  • (nice to have) if the auction was started by trivial/artist, disable the bidForCancel mechanic

Example:

  • the item has 1000 tokens, alice has 100 tokens, and starts the auction, bidding 3 ETH
  • bob has 200 tokens, bids 8 ETH - he's the highest bidder now
  • charlie calls bidForCancel, paying 2 ETH - he is the highest bidder now

if there are no other bids, and auction time ends:

  • Charlie gets Bob's 200 tokens, Bob gets 2 ETH, the contract reverts to the previous state, and people can still trade them, the item doesn't change the owner

but Bob can bid back:

  • Bob bids 10 ETH
  • auction ends, Bob gets the item

or Alice can bid back

  • Alice bids 10 ETH
  • auction ends, Alice gets the item
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant