Season Facet
The Season Facet contains the gm
function and handles all logic for Season changes.
Call Functions
Advances Beanstalk to the next Season, sending reward Beans to the caller's Circulating balance.
Return Type | Description |
---|---|
| The number of Beans minted to the caller. |
Advances Beanstalk to the next Season, sending reward Beans to a specified address and balance.
Parameter | Type | Description |
---|---|---|
|
| Indicates to which address reward Beans should be sent. |
|
| The balance to transfer Beans to; see |
Return Type | Description |
---|---|
| The number of Beans minted to the caller. |
View Functions
Returns the current Season number.
Return Type | Description |
---|---|
| The current Season number. |
Returns whether Beanstalk is Paused. When Paused, sunrise
cannot be called.
Return Type | Description |
---|---|
| Whether Beanstalk is Paused. |
Returns the Season struct.
Return Type | Description |
---|---|
| The Season struct in App Storage. |
Returns whether Beanstalk started this Season above or below peg.
Return Type | Description |
---|---|
| Whether Beanstalk started this Season above or below peg. |
Returns the block during which the current Season started.
Return Type | Description |
---|---|
| The block during which the current Season started. |
Returns the expected Season number given the current block timestamp. The sunrise
function can be called when seasonTime() > season()
.
Return Type | Description |
---|---|
| The expected Season number given the current block timestamp. |
Returns the Weather struct.
Return Type | Description |
---|---|
| Returns the Weather struct in App Storage. |
Returns the Rain struct.
Return Type | Description |
---|---|
| Returns the Rain struct in App Storage. |
Returns the Season of Plenty (SOP) rewards per Root for the given Season.
Parameter | Type | Description |
---|---|---|
|
| The Season to fetch SOP rewards per Root for. |
Return Type | Description |
---|---|
| The SOP rewards for the given Season. |
Returns the cumulative deltaB across all pools on the Oracle Whitelist.
Return Value | Type | Description |
---|---|---|
|
| The cumulative deltaB. |
Returns the deltaB for a given pool.
Parameter | Type | Description |
---|---|---|
|
| The address of the pool . |
Return Value | Description |
---|---|
| The deltaB for the given pool. |
Returns the last Well oracle snapshot for a given Well.
Parameter | Type | Description |
---|---|---|
|
| The address of the pool to get the snapshot for. |
Type |
---|
|
Returns the last Curve oracle data snapshot for the BEAN:3CRV pool.
Return Value | Type | Description |
---|---|---|
|
| Last Curve oracle data snapshot. |
Events
Emitted when the Season changes.
Parameter | Type | Description |
---|---|---|
|
| The new Season number. |
Emitted when Beanstalk pays Beans to the sunrise
caller.
Parameter | Type | Description |
---|---|---|
|
| The address to which the reward Beans were sent. |
|
| The amount of Beans paid as a reward. |
Emitted during Sunrise when Beans are distributed to the Field, the Silo, and Fertilizer.
Parameter | Type | Description |
---|---|---|
|
| The Season in which Beans were distributed. |
|
| The number of Beans distributed to the Field. |
|
| The number of Beans distributed to the Silo. |
|
| The number of Beans distributed to Fertilizer holders. |
Emitted during Sunrise when Beanstalk adjusts the amount of available Soil.
Parameter | Type | Description |
---|---|---|
|
| The Season in which Soil was adjusted. |
|
| The new amount of Soil available. |
Emitted when the Weather (now Temperature) changes.
Parameter | Type | Description |
---|---|---|
|
| The current Season. |
|
| The "Weather Case". |
|
| The change in Temperature from the previous value. |
Emitted when Beans are minted during the Season of Plenty.
Parameter | Type | Description |
---|---|---|
|
| The Season in which Beans were minted for distribution. |
|
| The amount of 3CRV which was received for swapping Beans. |
|
| The amount of Beans which were distributed to remaining Pods in the Field. |
Last updated