Advertisement
Guest User

Buying/Selling EtherTanks with MEW

a guest
Dec 31st, 2017
2,575
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.91 KB | None | 0 0
  1. How to buy and sell tanks manually using MyEtherWallet (MEW):
  2.  
  3. Setup:
  4. 1) Go to MEW's contracts section: https://www.myetherwallet.com/#contracts
  5. 2) Copy EtherTank's contract address and ABI info from EtherScan at https://etherscan.io/address/0x336db6c1ead9cc4d5b0a33ac03c057e20640126a#code
  6. 3) You can now directly call the buy and sell functions through MEW
  7.  
  8. Buy someone's tank:
  9. 1) Select "bid" and enter the Tank ID number the seller listed
  10. 2) Click "WRITE"
  11. 2) Enter the amount of ETH you are buying the tank for (i.e. 0.65 ETH)
  12. *if you enter more ETH than needed, the extra will be credited to you on EtherTanks, which you can cash out
  13. 3) Enter 500000 for the gas limit
  14. 4) Click generate transaction
  15.  
  16. To verify the price of someone's tank before you buy (no transaction fee):
  17. 1) Select "getCurrentPriceAuction" and enter the Tank ID number the seller listed
  18. 2) Click "READ"
  19. 3) The number displayed is the current price of the tank in WEI (shift 18 decimal places to get ETH)
  20.  
  21. To sell your tank:
  22. 1) Select "sellTank"
  23. 2) Find the Tank ID number of the tank you want to sell:
  24. a) Find the transaction you bought your tank with on EtherScan
  25. b) Click on "Event Logs"
  26. c) Your tank ID will be the SECOND "HEX" line
  27. d) Convert the HEX value to decimal (https://www.binaryhexconverter.com/hex-to-decimal-converter)
  28. 3) Enter the starting sale price in WEI (IMPORTANT - shift 18 decimal places to get ETH)
  29. 4) Enter the ending sale price in WEI
  30. 5) Enter the amount of time in SECONDS you want your tank to be on sale
  31. 5) Enter 300000 for the gas limit
  32. 6) Click generate transaction
  33. 7) Give your Tank ID number to the buyer
  34.  
  35. Notes:
  36. These transactions all use EtherTank's official smart contract, and should be the exact same functions that their official marketplace will use once it is launched. There is a 3% "auction fee" built into the smart contract, where the seller will receive 3% less than the actual selling price.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement