智能合约循环互助游戏开发详细逻辑
2023-02-28 23:22 作者:V_kaifa873 | 我要投稿
struct block_header{
uint32_t timestamp;
name producer;kaifa873
uint16_t confirmed=0;
capi_checksum256 previous;
capi_checksum256 transaction_mroot;
capi_checksum256 action_mroot;
uint32_t schedule_version=0;
std::optional<eosio::producer_schedule>new_producers;
EOSLIB_SERIALIZE(block_header,(timestamp)(producer)(confirmed)(previous)(transaction_mroot)(action_mroot)
(schedule_version)(new_producers))
};
struct wait_weight{
uint32_t wait_sec;
uint16_t weight;
EOSLIB_SERIALIZE(wait_weight,(wait_sec)(weight))
};需求及模式详细:kaifa873
该结构体没有什么特别的,陌生的部分仍旧只有第一个参数wait_sec,但通过字面含义即可理解,就是等待的秒数。
struct authority{
uint32_t threshold=0;
std::vector<key_weight>keys;
std::vector<permission_level_weight>accounts;