protected override void Start()
    {
        base.Start();

        Container = LiquidContainer.FindLiquidContainer(transform);
        Assert.IsNotNull(Container);
        ObjectType = ObjectType.Bottle;
    }
Exemplo n.º 2
0
    protected override void Start()
    {
        base.Start();

        Container = LiquidContainer.FindLiquidContainer(transform);
        Assert.IsNotNull(Container);
        ObjectType = ObjectType.Syringe;

        Type.On(InteractableType.Attachable, InteractableType.HasLiquid, InteractableType.Interactable, InteractableType.SmallObject);

        Container.OnAmountChange += SetSyringeHandlePosition;
        SetSyringeHandlePosition();

        hasBeenInBottle = false;

        syringeCap = transform.Find("syringe_cap").gameObject;
        NullCheck.Check(syringeCap);

        syringeCap.SetActive(false);

        liquidDisplay = Resources.Load <GameObject>("Prefabs/LiquidDisplay");
        displayState  = false;
    }