예제 #1
0
    private void Start()
    {
        container = magazine.GetComponent <GunContainer>();
        container.SetFillPercentage(0);

        timeSinceLastEmpty = _emptyingTimeout;

        audioSource = GetComponent <AudioSource>();
    }
예제 #2
0
    private void UpdateContainer()
    {
        container = magazine.GetComponent <GunContainer>();
        container.SetFillPercentage(containerFill);

        if (colorInContainer != null)
        {
            container.SetColor(colorInContainer.Value);
        }
    }