|
|
@ -217,8 +217,14 @@ $('.button-group').each( function( i, buttonGroup ) { |
|
|
|
|
|
|
|
var block_time = 75; |
|
|
|
var blocks_per_day = 60*60*24 / block_time; |
|
|
|
var monthly_inflation = parseFloat( 100 * (blocks_per_day * 30 / json.total)).toPrecision(2); |
|
|
|
var yearly_inflation = parseFloat( 100 * (blocks_per_day * 365 / json.total)).toPrecision(2); |
|
|
|
var block_reward = 3.125; |
|
|
|
// TODO: add future halvings |
|
|
|
if ( json.height >= 2020000) { |
|
|
|
block_reward /= 2; |
|
|
|
} |
|
|
|
var monthly_inflation = parseFloat( 100 * (block_reward * blocks_per_day * 30 / json.total)).toPrecision(2); |
|
|
|
var yearly_inflation = parseFloat( 100 * (block_reward * blocks_per_day * 365 / json.total)).toPrecision(2); |
|
|
|
|
|
|
|
|
|
|
|
$('#inflation').html( monthly_inflation + "% monthly, " + yearly_inflation + "% yearly" ); |
|
|
|
|
|
|
|