コード例 #1
0
    private IBonus InstantiateBonus(BonusCategory category)
    {
        IBonus projectile = _bonusFactory.Create(category);

        projectile.Dispose();
        return(projectile);
    }
コード例 #2
0
    public void DisposeBonus(IBonus bonus)
    {
        if (bonus == null)
        {
            return;
        }

        bonus.Dispose();

        _bonuses[bonus.Category].Push(bonus);
    }