MasterChef
Contract info
Contract name: pancake::masterchef Contract address:
7968a225eba6c99f5f1070aeec1b405757dee939eabcfda43ba91588bf5fccf3::masterchef
Admin multi sig address: eef8788f3eaa34b936d0bc5897fc40fa3782b1e663bf04edf2cd22fcd18329ff
Resources
MasterChef
Th metadata of the masterchef.
Name | ||
---|---|---|
signer_cap |
| The signer capability of the resource account. |
admin |
| The admin address of the module. |
upkeep_admin |
| The account that execute upkeep call. |
lp_to_pid |
| LP token type info and corresponding pool id. |
lps |
| All added LP token type info array. |
pool_info |
| A list of pool _info struct. |
total_regular_alloc_point |
| Sum of all regular farm allocate points. |
total_special_alloc_point |
| Sum of all special farm allocate points. |
cake_per_second |
| Cake reward per second for all farm pools. |
cake_rate_to_regular |
| The percentage of cake rewards that regular farm can earn |
cake_rate_to_special |
| The percentage of cake rewards that special farm can earn. |
last_upkeep_timestamp |
| The timestamp of the last upkeep execution. |
end_timestamp |
| The last time that farms can get cake reward, each upkeep operation will extend this timestamp. |
PoolUserInfo
All pool informations.
Name | Type | Description |
---|---|---|
pid_to_user_info |
| A table contains |
pids |
| A list of pool id. |
UserInfo
The user information in each pool.
Name | Type | Description |
---|---|---|
amount |
| The total amount of token staked in the pool. |
reward_debt |
| The total amount of reward distributed to the user. |
PoolInfo
The information of each pool
Name | Type | Description |
---|---|---|
total_amount |
| The total amount of stake token. |
acc_cake_per_share |
| The accumulated cake per share in the pool. |
last_reward_timestamp |
| The latest time when reward is distributed. |
alloc_point |
| The pool allocated point. |
is_regular |
| True means this pool is regular farm, otherwise is special farm. |
Entry Functions
Deposit
Deposit the stake token into the pool. It will also transfer reward token to the user if there's any.
Name | Type | Description |
---|---|---|
sender |
| The sender's signer when calling the function. |
amount |
| The amount of token that will be deposited. |
Withdraw
Withdraw the stake token from the pool. It will also transfer reward token to the user if there's any.
Name | Type | Description |
---|---|---|
sender |
| The sender's signer when calling the function. |
amount |
| The amount of token that will be withdrawn. |
Emergency Withdraw
Withdraw the stake token from the pool regardless of any rewards.
Name | Type | Description |
---|---|---|
sender |
| The sender's signer when calling the function. |
Mass Update Pools
Update all the pool information.
Update Pool
Update a specific pool information.
Name | Type | Description |
---|---|---|
pid |
| The id of the pool. |
Public Function
Pending Cake
The pending cake reward of the user.
Input Values
Name | Type | Description |
---|---|---|
pid |
| The id of the pool. |
user |
| The address of the depositor. |
Return Values
Type | Description |
---|---|
| The total amount of cake reward. |
Pool Length
The total number of pools.
Return Values
Type | Description |
---|---|
| The total number of pools. |
Audit
OtterSec's PancakeSwap Aptos MasterChef security audit:
Last updated