contract HashRush is ERC20, Owned {
    // Applies SafeMath library to uint256 operations
    using SafeMath for uint256;

    // Public variables
    string public name;
    string public symbol;
    uint256 public decimals;

    // Variables
    uint256 totalSupply_;
    uint256 multiplier;

    // Arrays for balances & allowance
    mapping (address => uint256) balance;
    mapping (address => mapping (address => uint256)) allowed;

    // Modifier to prevent short address attack
    modifier onlyPayloadSize(uint size) {
        if(msg.data.length < size.add(4)) revert();
        _;
    }

    constructor(string tokenName, string tokenSymbol, uint8 decimalUnits, uint256 decimalMultiplier) public {
        name = tokenName;
        symbol = tokenSymbol;
        decimals = decimalUnits;
        multiplier = decimalMultiplier;
    }

    /**
    * @dev Total number of tokens in existence
    */
    function totalSupply() public view returns (uint256) {
        return totalSupply_;
    }

    /**
     * @dev Function to check the amount of tokens that an owner allowed to a spender.
     * @param _owner address The address which owns the funds.
     * @param _spender address The address which will spend the funds.
     * @return A uint256 specifying the amount of tokens still available for the spender.
     */
    function allowance(address _owner, address _spender) public view returns (uint256) {
        return allowed[_owner][_spender];
    }

    /**
     * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender.
     * @param _spender The address which will spend the funds.
     * @param _value The amount of tokens to be spent.
     */
    function approve(address _spender, uint256 _value) public returns (bool) {
        allowed[msg.sender][_spender] = _value;
        emit Approval(msg.sender, _spender, _value);
        return true;
    }

    /**
     * @dev Gets the balance of the specified address.
     * @param _owner The address to query the the balance of.
     * @return An uint256 representing the amount owned by the passed address.
     */
    function balanceOf(address _owner) public view returns (uint256) {
        return balance[_owner];
    }

    /**
     * @dev Transfer token to a specified address
     * @param _to The address to transfer to.
     * @param _value The amount to be transferred.
     */
    function transfer(address _to, uint256 _value) onlyPayloadSize(2 * 32) public returns (bool) {
        require(_to != address(0));
        require(_value <= balance[msg.sender]);

        if ((balance[msg.sender] >= _value)
            && (balance[_to].add(_value) > balance[_to])
        ) {
            balance[msg.sender] = balance[msg.sender].sub(_value);
            balance[_to] = balance[_to].add(_value);
            emit Transfer(msg.sender, _to, _value);
            return true;
        } else {
            return false;
        }
    }

    /**
     * @dev Transfer tokens from one address to another
     * @param _from address The address which you want to send tokens from
     * @param _to address The address which you want to transfer to
     * @param _value uint256 the amount of tokens to be transferred
     */
    function transferFrom(address _from, address _to, uint256 _value) onlyPayloadSize(3 * 32) public returns (bool) {
        require(_to != address(0));
        require(_value <= balance[_from]);
        require(_value <= allowed[_from][msg.sender]);

        if ((balance[_from] >= _value) && (allowed[_from][msg.sender] >= _value) && (balance[_to].add(_value) > balance[_to])) {
            balance[_to] = balance[_to].add(_value);
            balance[_from] = balance[_from].sub(_value);
            allowed[_from][msg.sender] = allowed[_from][msg.sender].sub(_value);
            emit Transfer(_from, _to, _value);
            return true;
        } else {
            return false;
        }
    }
}
function transfer(address _to, uint256 _value) onlyPayloadSize(2 * 32) public returns (bool) {
        require(_to != address(0));
        require(_value <= balance[msg.sender]);

        if ((balance[msg.sender] >= _value)
            && (balance[_to].add(_value) > balance[_to])
        ) {
            balance[msg.sender] = balance[msg.sender].sub(_value);
            balance[_to] = balance[_to].add(_value);
            emit Transfer(msg.sender, _to, _value);
            return true;
        } else {
            return false;
        }
    }
/**
 * @dev Transfer token to a specified address
 * @param _to The address to transfer to.
 * @param _value The amount to be transferred.
 */