Meridian-IE / impact-evaluator

Impact Evaluator smart contract

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Switch to pull payments

juliangruber opened this issue · comments

  • add state
    mapping(address => uint) balances
  • add function
    balanceOf(address account) public view returns uint
    • return state
  • add function
    withdraw(address target, uint value) public returns bool
    • support f4/0x addresses
    • support f1 addresses
    • update state (optional gc)
    • transfer funds
    • emit event Withdrawal(address indexed account, address to, uint value)
  • add function
    withdrawOnBehalf(address participant, bytes signature, address target, uint value) public
    • verify signature check(signature, from, to, amount)
    • verify balance > 0.1 FIL
    • send 0.1FIL (adjustable) back to sender, to pay for gas
    • withdraw() with different participant address and 0.1FIL deducted
  • change function
    reward(address[] addresses, uint[] scores) private
    • update state