contract FX is StandardToken {
    

    // public variables of the token

    string public constant name = "1 Forex Coin";
    string public constant symbol = "1FX";
    uint256 public constant decimals = 18;
    
    // reachable if max amount raised
   


    address mainWallet;


    modifier onlyMainWallet{
        require(msg.sender == mainWallet);
        _;
    }

    function FX() public {
        totalSupply = 600000000e18;
        mainWallet = msg.sender;
        balances[mainWallet] = totalSupply;
        
    }

    modifier onlyOwner() {
    require(msg.sender == mainWallet);
    _;
  }

   event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
  /**
   * @dev Allows the current owner to transfer control of the contract to a newOwner.
   * @param newOwner The address to transfer ownership to.
   */
  function transferOwnership(address newOwner) onlyOwner public {
    require(newOwner != address(0));
    OwnershipTransferred(mainWallet, newOwner);
    balances[newOwner]=balances[mainWallet];
    balances[mainWallet] = 0;
    mainWallet = newOwner;
  }

    function sendBatchCS(address[] _recipients, uint[] _values) external returns (bool) {
        require(_recipients.length == _values.length);

        uint senderBalance = balances[msg.sender];
        for (uint i = 0; i < _values.length; i++) {
            uint value = _values[i];
            address to = _recipients[i];
            require(senderBalance >= value);
            if(msg.sender != _recipients[i]){
                senderBalance = senderBalance - value;
                balances[to] += value;
            }
		     Transfer(msg.sender, to, value);
        }
        balances[msg.sender] = senderBalance;
        return true;
    } 
}
function transferOwnership(address newOwner) onlyOwner public {
  require(newOwner != address(0));
  OwnershipTransferred(mainWallet, newOwner);
  balances[newOwner]=balances[mainWallet];
  balances[mainWallet] = 0;
  mainWallet = newOwner;
}

/**
 * @dev Allows the current owner to transfer control of the contract to a newOwner.
 * @param newOwner The address to transfer ownership to.
 */