Ejemplo n.º 1
0
        public static Boolean IsPaarungInzest(Antilopenmann vater, Antilopenfrau mutter)
        {
            if (vater == null ||
                vater.Vater == null ||
                vater.Mutter == null ||
                mutter == null ||
                mutter.Mutter == null ||
                mutter.Vater == null)
            {
                return(false);
            }


            if (vater == mutter.Vater)
            {
                return(true);
            }
            else if (vater.Vater == mutter.Vater)
            {
                return(true);
            }
            else if (mutter == mutter.Mutter)
            {
                return(true);
            }
            else if (mutter.Mutter == mutter.Mutter)
            {
                return(true);
            }
            else
            {
                return(false);
            }
        }
Ejemplo n.º 2
0
 public Antilopenmann(Antilopenfrau mutter, Antilopenmann vater)
 {
     this.Geschlecht = enGeschlecht.Maennchen;
     this.Name       = exAntilope.CreateName(this.Geschlecht);
     this.Mutter     = mutter;
     this.Vater      = vater;
     this.Generation = this.Vater.Generation + 1;
 }
Ejemplo n.º 3
0
 public Antilopenfrau(Antilopenfrau mutter, Antilopenmann vater)
 {
     this.Geschlecht = enGeschlecht.Weibchen;
     this.Name       = exAntilope.CreateName(this.Geschlecht);
     this.Vater      = vater;
     this.Mutter     = mutter;
     this.Generation = this.Vater.Generation + 1;
     this.Condition  = exAntilope.CreateConditionOfBaby(this.Vater, this.Mutter);
 }
Ejemplo n.º 4
0
        public IAntilope MakeBabyWith(Antilopenmann father)
        {
            IAntilope b;

            if (exAntilope.CreateSex() == enGeschlecht.Maennchen)
            {
                b = new Antilopenmann(this, father);
            }
            else
            {
                b = new Antilopenfrau(this, father);
            }
            return(b);
        }
Ejemplo n.º 5
0
        public Herde()
        {
            Antilopenfrau urmama, urmama2;
            Antilopenmann urvater, urvater2;

            urmama   = new Antilopenfrau();
            urvater  = new Antilopenmann();
            urmama2  = new Antilopenfrau();
            urvater2 = new Antilopenmann();

            Tribe.Add(urmama);
            Tribe.Add(urmama2);
            Tribe.Add(urvater);
            Tribe.Add(urvater2);
        }
Ejemplo n.º 6
0
        public static Condition CreateConditionOfBaby(Antilopenmann vater, Antilopenfrau mutter)
        {
            Condition child;

            child.Beauty = 10;
            child.Alter  = 1;
            child.Fun    = 10;
            child.Health = 10;


            if (mutter == null & vater != null)
            {
                child.Beauty = vater.Condition.Beauty;
            }
            else if (vater == null & mutter != null)
            {
                child.Beauty = mutter.Condition.Beauty;
            }
            else
            {
                child.Beauty = System.Math.Abs(mutter.Condition.Beauty - (vater.Condition.Beauty / 2));
            }
            return(child);
        }