Solidity智能合约开发技术与实战-编写安全的智能合约.pptVIP

  • 1
  • 0
  • 约2.67万字
  • 约 165页
  • 2023-10-22 发布于山东
  • 举报

Solidity智能合约开发技术与实战-编写安全的智能合约.ppt

116: // Checks that the sender of this callback was in fact oraclize 117: assert(msg.sender == oraclize_cbAddress()); 118: 119: numberWinner = (uint(sha3(_result))%10+1); 120: distributePrizes(); 121: } 122: 123: /// @notice Sends the corresponding Ether to each winner then deletes all the 124: /// players for the next game and resets the `totalBet` and `numberOfBets` 125: function distributePrizes() onEndGame { 126: uint winnerEtherAmount = totalBet / numberBetPlayers[numberWinner].length; // How much each winner gets 127: 128: // Loop through all the wi

文档评论(0)

1亿VIP精品文档

相关文档