示例#1
0
        public override bool InRelation(Pawn me, Pawn other)
        {
            if (me == other)
            {
                return(false);
            }
            if (PawnRelationDefOf.Child.Worker.InRelation(me, other))
            {
                return(false);
            }
            PawnRelationWorker worker  = PawnRelationDefOf.Sibling.Worker;
            PawnRelationWorker worker2 = PawnRelationDefOf.HalfSibling.Worker;

            if (other.GetMother() != null && (worker.InRelation(me, other.GetMother()) || worker2.InRelation(me, other.GetMother())))
            {
                goto IL_0095;
            }
            if (other.GetFather() != null && (worker.InRelation(me, other.GetFather()) || worker2.InRelation(me, other.GetFather())))
            {
                goto IL_0095;
            }
            return(false);

IL_0095:
            return(true);
        }
        public override bool InRelation(Pawn me, Pawn other)
        {
            if (me == other)
            {
                return(false);
            }
            if (PawnRelationDefOf.Grandparent.Worker.InRelation(me, other))
            {
                return(false);
            }
            PawnRelationWorker worker = PawnRelationDefOf.GreatGrandparent.Worker;

            if (other.GetMother() != null && worker.InRelation(me, other.GetMother()))
            {
                goto IL_0066;
            }
            if (other.GetFather() != null && worker.InRelation(me, other.GetFather()))
            {
                goto IL_0066;
            }
            return(false);

IL_0066:
            return(true);
        }
        public override bool InRelation(Pawn me, Pawn other)
        {
            bool result;

            if (me == other)
            {
                result = false;
            }
            else
            {
                PawnRelationWorker worker = PawnRelationDefOf.GranduncleOrGrandaunt.Worker;
                Pawn mother = other.GetMother();
                if (mother != null)
                {
                    if ((mother.GetMother() != null && worker.InRelation(me, mother.GetMother())) || (mother.GetFather() != null && worker.InRelation(me, mother.GetFather())))
                    {
                        return(true);
                    }
                }
                Pawn father = other.GetFather();
                if (father != null)
                {
                    if ((father.GetMother() != null && worker.InRelation(me, father.GetMother())) || (father.GetFather() != null && worker.InRelation(me, father.GetFather())))
                    {
                        return(true);
                    }
                }
                result = false;
            }
            return(result);
        }
        public override bool InRelation(Pawn me, Pawn other)
        {
            if (me == other)
            {
                return(false);
            }
            PawnRelationWorker worker = PawnRelationDefOf.Cousin.Worker;

            if (other.GetMother() != null && worker.InRelation(me, other.GetMother()))
            {
                goto IL_004e;
            }
            if (other.GetFather() != null && worker.InRelation(me, other.GetFather()))
            {
                goto IL_004e;
            }
            PawnRelationWorker worker2 = PawnRelationDefOf.GranduncleOrGrandaunt.Worker;

            if (other.GetMother() != null && worker2.InRelation(me, other.GetMother()))
            {
                goto IL_0095;
            }
            if (other.GetFather() != null && worker2.InRelation(me, other.GetFather()))
            {
                goto IL_0095;
            }
            return(false);

IL_0095:
            return(true);

IL_004e:
            return(true);
        }
        public override bool InRelation(Pawn me, Pawn other)
        {
            if (me == other)
            {
                return(false);
            }
            PawnRelationWorker worker = PawnRelationDefOf.Grandchild.Worker;

            return((other.GetMother() != null && worker.InRelation(me, other.GetMother())) || (other.GetFather() != null && worker.InRelation(me, other.GetFather())));
        }
示例#6
0
        public override bool InRelation(Pawn me, Pawn other)
        {
            if (me == other)
            {
                return(false);
            }
            if (other.GetSpouse() == null)
            {
                return(false);
            }
            PawnRelationWorker worker = PawnRelationDefOf.Child.Worker;

            return(!worker.InRelation(me, other) && worker.InRelation(me, other.GetSpouse()));
        }
        public override bool InRelation(Pawn me, Pawn other)
        {
            if (me == other)
            {
                return(false);
            }
            PawnRelationWorker worker = PawnRelationDefOf.NephewOrNiece.Worker;

            if ((other.GetMother() != null && worker.InRelation(me, other.GetMother())) || (other.GetFather() != null && worker.InRelation(me, other.GetFather())))
            {
                return(true);
            }
            return(false);
        }
        public override bool InRelation(Pawn me, Pawn other)
        {
            if (me == other)
            {
                return(false);
            }
            if (PawnRelationDefOf.Parent.Worker.InRelation(me, other))
            {
                return(false);
            }
            PawnRelationWorker worker = PawnRelationDefOf.Spouse.Worker;

            return((me.GetMother() != null && worker.InRelation(me.GetMother(), other)) || (me.GetFather() != null && worker.InRelation(me.GetFather(), other)));
        }
        public override bool InRelation(Pawn me, Pawn other)
        {
            bool result;

            if (me == other)
            {
                result = false;
            }
            else
            {
                PawnRelationWorker worker = PawnRelationDefOf.Child.Worker;
                result = ((other.GetMother() != null && worker.InRelation(me, other.GetMother())) || (other.GetFather() != null && worker.InRelation(me, other.GetFather())));
            }
            return(result);
        }
示例#10
0
        public override bool InRelation(Pawn me, Pawn other)
        {
            if (me == other)
            {
                return(false);
            }
            PawnRelationWorker worker = PawnRelationDefOf.GranduncleOrGrandaunt.Worker;
            Pawn mother = other.GetMother();

            if (mother != null && ((mother.GetMother() != null && worker.InRelation(me, mother.GetMother())) || (mother.GetFather() != null && worker.InRelation(me, mother.GetFather()))))
            {
                return(true);
            }
            Pawn father = other.GetFather();

            return(father != null && ((father.GetMother() != null && worker.InRelation(me, father.GetMother())) || (father.GetFather() != null && worker.InRelation(me, father.GetFather()))));
        }
        public override bool InRelation(Pawn me, Pawn other)
        {
            if (me == other)
            {
                return(false);
            }
            if (me.GetSpouse() == null)
            {
                return(false);
            }
            PawnRelationWorker worker = PawnRelationDefOf.Parent.Worker;

            if (worker.InRelation(me, other))
            {
                return(false);
            }
            return(worker.InRelation(me.GetSpouse(), other));
        }
        public override bool InRelation(Pawn me, Pawn other)
        {
            bool result;

            if (me == other)
            {
                result = false;
            }
            else if (me.GetSpouse() == null)
            {
                result = false;
            }
            else
            {
                PawnRelationWorker worker = PawnRelationDefOf.Child.Worker;
                result = (!worker.InRelation(me, other) && worker.InRelation(me.GetSpouse(), other));
            }
            return(result);
        }
示例#13
0
        public override bool InRelation(Pawn me, Pawn other)
        {
            bool result;

            if (me == other)
            {
                result = false;
            }
            else if (PawnRelationDefOf.Parent.Worker.InRelation(me, other))
            {
                result = false;
            }
            else
            {
                PawnRelationWorker worker = PawnRelationDefOf.Spouse.Worker;
                result = ((me.GetMother() != null && worker.InRelation(me.GetMother(), other)) || (me.GetFather() != null && worker.InRelation(me.GetFather(), other)));
            }
            return(result);
        }
示例#14
0
        public override bool InRelation(Pawn me, Pawn other)
        {
            if (me == other)
            {
                return(false);
            }
            PawnRelationWorker worker = PawnRelationDefOf.GranduncleOrGrandaunt.Worker;
            Pawn mother = other.GetMother();

            if (mother != null)
            {
                if (mother.GetMother() != null && worker.InRelation(me, mother.GetMother()))
                {
                    goto IL_005b;
                }
                if (mother.GetFather() != null && worker.InRelation(me, mother.GetFather()))
                {
                    goto IL_005b;
                }
            }
            Pawn father = other.GetFather();

            if (father != null)
            {
                if (father.GetMother() != null && worker.InRelation(me, father.GetMother()))
                {
                    goto IL_00a4;
                }
                if (father.GetFather() != null && worker.InRelation(me, father.GetFather()))
                {
                    goto IL_00a4;
                }
            }
            return(false);

IL_005b:
            return(true);

IL_00a4:
            return(true);
        }
        public override bool InRelation(Pawn me, Pawn other)
        {
            if (me == other)
            {
                return(false);
            }
            PawnRelationWorker worker = PawnRelationDefOf.Child.Worker;

            if (other.GetMother() != null && worker.InRelation(me, other.GetMother()))
            {
                goto IL_004e;
            }
            if (other.GetFather() != null && worker.InRelation(me, other.GetFather()))
            {
                goto IL_004e;
            }
            return(false);

IL_004e:
            return(true);
        }
示例#16
0
        public override bool InRelation(Pawn me, Pawn other)
        {
            bool result;

            if (me == other)
            {
                result = false;
            }
            else
            {
                PawnRelationWorker worker = PawnRelationDefOf.Cousin.Worker;
                if ((other.GetMother() != null && worker.InRelation(me, other.GetMother())) || (other.GetFather() != null && worker.InRelation(me, other.GetFather())))
                {
                    result = true;
                }
                else
                {
                    PawnRelationWorker worker2 = PawnRelationDefOf.GranduncleOrGrandaunt.Worker;
                    result = ((other.GetMother() != null && worker2.InRelation(me, other.GetMother())) || (other.GetFather() != null && worker2.InRelation(me, other.GetFather())));
                }
            }
            return(result);
        }