Exemplo n.º 1
0
    IEnumerator Creation()
    {
        yield return(new WaitForSeconds(0.1f));

        _currentVisitor    = Instantiate(_standardVisitor);
        _contractCurrent   = Instantiate(_standardContract);
        _dataInfo          = _dbContract.getBestContract();
        _contractBehaviour = _contractCurrent.GetComponent <ContractBehaviour>();
        _contractInfo      = _contractCurrent.GetComponent <ContractInfo>();
        _contractInfo.updateInfoContract(_dataInfo);
        _contractCurrent.transform.parent        = _currentVisitor.transform.GetChild(0).transform;
        _contractCurrent.transform.localRotation = new Quaternion(0, 0, 0, 0);
    }
Exemplo n.º 2
0
    public override bool Equals(object obj)
    {
        if (obj == null)
        {
            return(false);
        }
        if (ReferenceEquals(this, obj))
        {
            return(true);
        }
        if (obj.GetType() != typeof(ContractBehaviour))
        {
            return(false);
        }
        ContractBehaviour other = (ContractBehaviour)obj;

        return(_contract == other._contract);
    }
Exemplo n.º 3
0
 private void Start()
 {
     _contractBehaviour = GetComponent <ContractBehaviour>();
 }