Beispiel #1
0
    void AdoptBaby()
    {
        BabyController baby = GameMaster.instance.CreateBaby();

        baby.transform.position = GlobalAdoptionCenter;
        baby.SetAttachment(gameObject, ClingArea);
        babyFruits.Add(baby);
    }
 void Start()
 {
     strollerLocalOffset      = stroller.transform.localPosition;
     strollerSpriteRenderer   = stroller.GetComponent <SpriteRenderer> ();
     pregnipushSpriteRenderer = GetComponent <SpriteRenderer>();
     baby = GameMaster.instance.CreateBaby();
     baby.transform.position = transform.position;
     baby.SetAttachment(stroller, attachment);
     baby.DoNotRemove = true;
 }
Beispiel #3
0
 public void PickupBaby(BabyController baby)
 {
     if (!isAlive)
     {
         return;
     }
     babies.Add(baby);
     baby.SetAttachment(gameObject, attachmentArea);
     baby.gameObject.layer = LayerMask.NameToLayer("Carried");
     baby.DoNotRemove      = true;
 }