|
|
@ -51,7 +51,7 @@ func (node *Node) AddPuzzleContract() { |
|
|
|
func (node *Node) CreateTransactionForPlayMethod(priKey string, amount int) error { |
|
|
|
func (node *Node) CreateTransactionForPlayMethod(priKey string, amount int) error { |
|
|
|
var err error |
|
|
|
var err error |
|
|
|
toAddress := node.PuzzleContractAddress |
|
|
|
toAddress := node.PuzzleContractAddress |
|
|
|
GameStake := amount * big.NewInt(params.Wei) |
|
|
|
GameStake := amount * big.NewInt(params.Ether) |
|
|
|
abi, err := abi.JSON(strings.NewReader(contracts.PuzzleABI)) |
|
|
|
abi, err := abi.JSON(strings.NewReader(contracts.PuzzleABI)) |
|
|
|
if err != nil { |
|
|
|
if err != nil { |
|
|
|
utils.GetLogInstance().Error("puzzle-play: Failed to generate staking contract's ABI", "error", err) |
|
|
|
utils.GetLogInstance().Error("puzzle-play: Failed to generate staking contract's ABI", "error", err) |
|
|
|