Advertisement
Guest User

Untitled

a guest
Sep 21st, 2016
517
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.56 KB | None | 0 0
  1. function withdrawRewardFor(address _account) noEther internal returns (bool _success) {
  2. if ((balanceOf(_account) * rewardAccount.accumulatedInput()) / totalSupply < paidOut[_account])
  3. throw;
  4.  
  5. uint reward =
  6. (balanceOf(_account) * rewardAccount.accumulatedInput()) / totalSupply - paidOut[_account];
  7.  
  8. reward = rewardAccount.balance < reward ? rewardAccount.balance : reward;
  9.  
  10. paidOut[_account] += reward;
  11. if (!rewardAccount.payOut(_account, reward))
  12. throw;
  13.  
  14. return true;
  15. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement