Exemplo n.º 1
0
        protected override bool PrivateSatisfies(ManagerCareer manager, SimDescription sim, Lot newLot, bool inspecting)
        {
            if (!inspecting)
            {
                if (!manager.GetValue <ManagerCareer.AssignSelfEmployedOption, bool>())
                {
                    return(false);
                }
            }

            if ((mRequiredObjects == null) || (mRequiredObjects.Count == 0))
            {
                return(true);
            }

            if (newLot != null)
            {
                foreach (GameObject obj in newLot.GetObjects <GameObject>())
                {
                    if (Matches(obj.GetType()))
                    {
                        return(true);
                    }
                }
            }

            return(false);
        }
Exemplo n.º 2
0
        protected override bool PrivateSatisfies(ManagerCareer manager, SimDescription sim, Lot newLot, bool inspecting)
        {
            if (!inspecting)
            {
                if (!manager.GetValue<ManagerCareer.AssignSelfEmployedOption, bool>()) return false;
            }

            if ((mRequiredObjects == null) || (mRequiredObjects.Count == 0)) return true;

            if (newLot != null)
            {
                foreach (GameObject obj in newLot.GetObjects<GameObject>())
                {
                    if (Matches(obj.GetType())) return true;
                }
            }

            return false;
        }