示例#1
0
    public override void UseItem(GameObject target)
    {
        Progresser progress = target.GetComponent <Progresser>();

        if (progress.itemRequest == type)
        {
            progress.sendTranmission();
        }
        else
        {
            progress.setStatus(false, 1, 3f);
        }
    }
示例#2
0
    public override void UseItem(GameObject target)
    {
        Progresser progresserChecker = target.GetComponent <Progresser>();

        if (progresserChecker.itemRequest == type)
        {
            print("use");
            progresserChecker.sendTranmission();
            Destroy(this.gameObject, 0.5f);
        }
        else
        {
            progresserChecker.setStatus(false, 1, EffectDuration);
            Destroy(this.gameObject, 0.5f);
        }
    }