Blockwell

Enjin Coin

ERC20

This contract is an ERC20 token.

Name Enjin Coin
Symbol ENJ
Decimals 18
Total Supply 1,000,000,000 ENJ

About link description

Enjin Coin (ENJ) is a cryptocurrency and operates on the Ethereum platform. Enjin Coin has a current supply of 1,000,000,000 with 834,331,121.3990188 in circulation. The last known price of Enjin Coin is 1.24757995 USD and is up 1.93 over the last 24 hours. It is currently trading on 165 active market(s) with $244,091,853.11 traded over the last 24 hours. More information can be found at https://enjin.io/.

Stats

Public Functions 18
Event Types 3
Code Size 18,285 bytes

Events (3) keyboard_arrow_up

Approval Event

Parameters help
_owner
address help
_spender
address help
_value
uint256 help

OwnerUpdate Event

Parameters help
_prevOwner
address help
_newOwner
address help

Transfer Event

Parameters help
_from
address help
_to
address help
_value
uint256 help

ENJ_UNIT Constant

uint256 help
UNKNOWN VALUE

maxPresaleSupply Constant

uint256 help

minCrowdsaleAllocation Constant

uint256 help

incentivisationAllocation Constant

uint256 help

advisorsAllocation Constant

uint256 help

enjinTeamAllocation Constant

uint256 help

endTime Constant

uint256 help
1509494340

totalSupply Variable

uint256 help

crowdFundAddress Variable

address help

advisorAddress Variable

address help

incentivisationFundAddress Variable

address help

enjinTeamAddress Variable

address help

totalAllocatedToAdvisors Variable

uint256 help

totalAllocatedToTeam Variable

uint256 help

totalAllocated Variable

uint256 help

standard Variable

string help

name Variable

string help

symbol Variable

string help

decimals Variable

uint8 help

totalSupply Variable

uint256 help

owner Variable

address help

newOwner Variable

address help

balanceOf Variable

mapping(address => uint256) help

isReleasedToPublic Variable

bool help
Internal Variable

teamTranchesReleased Variable

uint256 help
Internal Variable

maxTeamTranches Variable

uint256 help
Internal Variable

allowance Variable

mapping(address => mapping(address => uint256)) help
Internal Variable

Functions Expand All Collapse All

owner keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help constant
Source Code
function owner() public constant returns (address) {
  owner;
}

transferOwnership keyboard_arrow_up

Parameters help

Name Type
_newOwner
address help

Properties

Visibility help public
Mutability help transaction
Source Code
function transferOwnership(address _newOwner) public ownerOnly {
  require(_newOwner != owner);
  newOwner = _newOwner;
}

acceptOwnership keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help transaction
Source Code
function acceptOwnership() public {
  require(msg.sender == newOwner);
  OwnerUpdate(owner, newOwner);
  owner = newOwner;
  newOwner = 0x0;
}

withdrawTokens keyboard_arrow_up

Parameters help

Name Type
_token
IERC20Token help
_to
address help
_amount
uint256 help

Properties

Visibility help public
Mutability help transaction
Source Code
function withdrawTokens(
  IERC20Token _token,
  address _to,
  uint256 _amount
) public ownerOnly validAddress(_token) validAddress(_to) notThis(_to) {
  assert(_token.transfer(_to, _amount));
}

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help constant
Source Code
function name() public constant returns (string) {
  name;
}

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help constant
Source Code
function symbol() public constant returns (string) {
  symbol;
}

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help constant
Source Code
function decimals() public constant returns (uint8) {
  decimals;
}

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help constant
Source Code
function totalSupply() public constant returns (uint256) {
  totalSupply;
}

Parameters help

Name Type
_owner
address help

Properties

Visibility help public
Mutability help constant
Source Code
function balanceOf(address _owner) public constant returns (uint256 balance) {
  _owner;
  balance;
}

Parameters help

Name Type
_owner
address help
_spender
address help

Properties

Visibility help public
Mutability help constant
Source Code
function allowance(address _owner, address _spender)
  public
  constant
  returns (uint256 remaining)
{
  _owner;
  _spender;
  remaining;
}

Parameters help

Name Type
_to
address help
_value
uint256 help

Properties

Visibility help public
Mutability help transaction
Source Code
function transfer(address _to, uint256 _value) public returns (bool success) {
  if (
    isTransferAllowed() == true ||
    msg.sender == crowdFundAddress ||
    msg.sender == incentivisationFundAddress
  ) {
    assert(super.transfer(_to, _value));
    return true;
  }
  revert();
}

Parameters help

Name Type
_from
address help
_to
address help
_value
uint256 help

Properties

Visibility help public
Mutability help transaction
Source Code
function transferFrom(
  address _from,
  address _to,
  uint256 _value
) public returns (bool success) {
  if (
    isTransferAllowed() == true ||
    msg.sender == crowdFundAddress ||
    msg.sender == incentivisationFundAddress
  ) {
    assert(super.transferFrom(_from, _to, _value));
    return true;
  }
  revert();
}

Parameters help

Name Type
_spender
address help
_value
uint256 help

Properties

Visibility help public
Mutability help transaction

Modifiers help

Source Code
function approve(address _spender, uint256 _value)
  public
  validAddress(_spender)
  returns (bool success)
{
  // if the allowance isn't 0, it can only be updated to 0 to prevent an allowance change immediately after withdrawal
  require(_value == 0 || allowance[msg.sender][_spender] == 0);

  allowance[msg.sender][_spender] = _value;
  Approval(msg.sender, _spender, _value);
  return true;
}

releaseEnjinTeamTokens keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help transaction
Source Code
function releaseEnjinTeamTokens()
  safeTimelock
  ownerOnly
  returns (bool success)
{
  require(totalAllocatedToTeam < enjinTeamAllocation);

  uint256 enjinTeamAlloc = enjinTeamAllocation / 1000;
  uint256 currentTranche = uint256(now - endTime) / 12 weeks; // "months" after crowdsale end time (division floored)

  if (
    teamTranchesReleased < maxTeamTranches &&
    currentTranche > teamTranchesReleased
  ) {
    teamTranchesReleased++;

    uint256 amount = safeMul(enjinTeamAlloc, 125);
    balanceOf[enjinTeamAddress] = safeAdd(balanceOf[enjinTeamAddress], amount);
    Transfer(0x0, enjinTeamAddress, amount);
    totalAllocated = safeAdd(totalAllocated, amount);
    totalAllocatedToTeam = safeAdd(totalAllocatedToTeam, amount);
    return true;
  }
  revert();
}

releaseAdvisorTokens keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help transaction

Requirements help

Source Code
function releaseAdvisorTokens()
  advisorTimelock
  ownerOnly
  returns (bool success)
{
  require(totalAllocatedToAdvisors == 0);
  balanceOf[advisorAddress] = safeAdd(
    balanceOf[advisorAddress],
    advisorsAllocation
  );
  totalAllocated = safeAdd(totalAllocated, advisorsAllocation);
  totalAllocatedToAdvisors = advisorsAllocation;
  Transfer(0x0, advisorAddress, advisorsAllocation);
  return true;
}

retrieveUnsoldTokens keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help transaction
Source Code
function retrieveUnsoldTokens() safeTimelock ownerOnly returns (bool success) {
  uint256 amountOfTokens = balanceOf[crowdFundAddress];
  balanceOf[crowdFundAddress] = 0;
  balanceOf[incentivisationFundAddress] = safeAdd(
    balanceOf[incentivisationFundAddress],
    amountOfTokens
  );
  totalAllocated = safeAdd(totalAllocated, amountOfTokens);
  Transfer(crowdFundAddress, incentivisationFundAddress, amountOfTokens);
  return true;
}

addToAllocation keyboard_arrow_up

Parameters help

Name Type
_amount
uint256 help

Properties

Visibility help public
Mutability help transaction
Source Code
function addToAllocation(uint256 _amount) crowdfundOnly {
  totalAllocated = safeAdd(totalAllocated, _amount);
}

allowTransfers keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help transaction
Source Code
function allowTransfers() ownerOnly {
  isReleasedToPublic = true;
}

Internal Functions Expand All Collapse All

Internal functions are parts of the contract that can't be used directly, but instead are used by the public functions listed above.

internal ENJToken.isTransferAllowed keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help internal
Mutability help constant
Source Code
function isTransferAllowed() internal constant returns (bool) {
  if (now > endTime || isReleasedToPublic == true) {
    return true;
  }
  return false;
}

internal Utils.safeAdd keyboard_arrow_up

Parameters help

Name Type
_x
uint256 help
_y
uint256 help

Properties

Visibility help internal
Mutability help transaction

Requirements help

Source Code
function safeAdd(uint256 _x, uint256 _y) internal returns (uint256) {
  uint256 z = _x + _y;
  assert(z >= _x);
  return z;
}

internal Utils.safeSub keyboard_arrow_up

Parameters help

Name Type
_x
uint256 help
_y
uint256 help

Properties

Visibility help internal
Mutability help transaction

Requirements help

Source Code
function safeSub(uint256 _x, uint256 _y) internal returns (uint256) {
  assert(_x >= _y);
  return _x - _y;
}

internal Utils.safeMul keyboard_arrow_up

Parameters help

Name Type
_x
uint256 help
_y
uint256 help

Properties

Visibility help internal
Mutability help transaction
Source Code
function safeMul(uint256 _x, uint256 _y) internal returns (uint256) {
  uint256 z = _x * _y;
  assert(_x == 0 || z / _x == _y);
  return z;
}

internal Utils.safeAdd keyboard_arrow_up

Parameters help

Name Type
_x
uint256 help
_y
uint256 help

Properties

Visibility help internal
Mutability help transaction

Requirements help

Source Code
function safeAdd(uint256 _x, uint256 _y) internal returns (uint256) {
  uint256 z = _x + _y;
  assert(z >= _x);
  return z;
}

internal Utils.safeSub keyboard_arrow_up

Parameters help

Name Type
_x
uint256 help
_y
uint256 help

Properties

Visibility help internal
Mutability help transaction

Requirements help

Source Code
function safeSub(uint256 _x, uint256 _y) internal returns (uint256) {
  assert(_x >= _y);
  return _x - _y;
}

internal Utils.safeMul keyboard_arrow_up

Parameters help

Name Type
_x
uint256 help
_y
uint256 help

Properties

Visibility help internal
Mutability help transaction
Source Code
function safeMul(uint256 _x, uint256 _y) internal returns (uint256) {
  uint256 z = _x * _y;
  assert(_x == 0 || z / _x == _y);
  return z;
}