This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{ | |
"constant": false, | |
"inputs": [ | |
{ | |
"name": "_agent", | |
"type": "address" | |
}, | |
{ | |
"name": "_status", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{ | |
"constant": true, | |
"inputs": [], | |
"name": "transToken", | |
"outputs": [ | |
{ | |
"name": "", | |
"type": "address" | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[{"name": "CONTINUE_MINTING", "type": "function", "inputs": [], "outputs": [{"name": "", "type": "bool"}], "payable": false, "constant": true, "stateMutability": "view"}, {"name": "getFreezing", "type": | |
"function", "inputs": [{"name": "_addr", "type": "address"}, {"name": "_index", "type": "uint256"}], "outputs": [{"name": "_release", "type": "uint64"}, {"name": "_balance", "type": "uint256"}], "payable" | |
: false, "constant": true, "stateMutability": "view"}, {"name": "mintingFinished", "type": "function", "inputs": [], "outputs": [{"name": "", "type": "bool"}], "payable": false, "constant": true, "stateMu | |
tability": "view"}, {"name": "approve", "type": "function", "inputs": [{"name": "_spender", "type": "address"}, {"name": "_value", "type": "uint256"}], "outputs": [{"name": "", "type": "bool"}], "payable" | |
: false, "constant": false, "stateMutability": "nonpayable"}, {"name": "mintAndFreeze", "type": "function", "inputs": [{"name": "_to", "type": "address"}, {"name": "_amount", "type": "uint256"}, {"name": |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const fs = require('fs'); | |
const Web3 = require('web3'); | |
const web3 = new Web3('https://mainnet.infura.io/v3/1198c5abaa8c4d3e8e170694ca1e3d59'); | |
const abi = [{ | |
"constant": true, | |
"inputs": [{"name": "", "type": "address"}], | |
"name": "registers", | |
"outputs": [{"name": "", "type": "string"}], | |
"payable": false, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function getPrice(heirsCount, tokensCount, checkInterval, activeTo) { | |
const gasPrice = 40000000000; | |
const constructGas = 1660000; | |
const constructGasPerHeir = 40000; | |
const checkGas = 25000; | |
const triggerGas = 32000; | |
const triggerGasPerHeir = 42000; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function getPrice(heirsCount, tokensCount, checkInterval, activeTo) { | |
const energyPrice = 10; | |
const netPrice = 10; | |
const constructEnergy = 1171716; | |
const constructNet = 7819; | |
const heirConstructAdditionEnergy = 25722; | |
const heirConstructAdditionNet = 78; | |
const checkEnergy = 2003; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const TronWeb = require("tronweb"); | |
const axios = require("axios"); | |
const privateKey = "da146374a75310b9666e834ee4ad0866d6f4035967bfc76217c5a495fff9f0d0"; | |
const tronWeb = new TronWeb( | |
"https://trontestnet.mywish.io/", | |
"https://trontestnet.mywish.io/", | |
"https://trontestnet.mywish.io/", | |
privateKey | |
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{ | |
"constant": true, | |
"inputs": [], | |
"name": "noActivityPeriod", | |
"outputs": [ | |
{ | |
"name": "", | |
"type": "uint32" | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pragma solidity >=0.5.3 <0.6.0; | |
contract TronRegister { | |
event RegisterAdd(address indexed ethAddress, address indexed tronAddress); | |
mapping(address => address) private ethToTronMapping; | |
function put(address _tronAddress) external { | |
address ethAddress = msg.sender; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{ | |
"constant": true, | |
"inputs": [ | |
{ | |
"name": "_addr", | |
"type": "address" | |
}, | |
{ | |
"name": "_index", |
NewerOlder