Author Topic: some question about worker  (Read 1206 times)

0 Members and 1 Guest are viewing this topic.

Offline xeroc

  • Board Moderator
  • Hero Member
  • *****
  • Posts: 12922
  • ChainSquad GmbH
    • View Profile
    • ChainSquad GmbH
  • BitShares: xeroc
  • GitHub: xeroc

Offline xeroc

  • Board Moderator
  • Hero Member
  • *****
  • Posts: 12922
  • ChainSquad GmbH
    • View Profile
    • ChainSquad GmbH
  • BitShares: xeroc
  • GitHub: xeroc
Burn reduces the max supply while refund gives the pay back to the reserves ..

Bts pay per day is a blockchain paramater that is controlled by committee .

Offline BTSdac

  • Hero Member
  • *****
  • Posts: 1219
    • View Profile
  • BitShares: K1
I try explain worker function to public , but I have two questions ,who can help me ,thanks  thanks

1. what different between "burn_worker" and "refund_worker"?
2.how many bts chain's budget per day?
Code: [Select]
void refund_worker_type::pay_worker(share_type pay, database& db)
{
   total_burned += pay;
   db.modify(db.get(asset_id_type()).dynamic_data(db), [pay](asset_dynamic_data_object& d) {
      d.current_supply -= pay;
   });
}
void burn_worker_type::pay_worker(share_type pay, database& db)
{
   total_burned += pay;
   db.adjust_balance( GRAPHENE_NULL_ACCOUNT, pay );
}
they are both burn the pay ,
but refund_worker_type does not increase totally supply of core asset
github.com :pureland
BTS2.0 API :ws://139.196.37.179:8091
BTS2.0 API 数据源ws://139.196.37.179:8091

Offline BTSdac

  • Hero Member
  • *****
  • Posts: 1219
    • View Profile
  • BitShares: K1
I try explain worker function to public , but I have two questions ,who can help me ,thanks  thanks

1. what different between "burn_worker" and "refund_worker"?
2.how many bts chain's budget per day?
« Last Edit: January 24, 2016, 09:09:08 am by BTSdac »
github.com :pureland
BTS2.0 API :ws://139.196.37.179:8091
BTS2.0 API 数据源ws://139.196.37.179:8091