예제 #1
0
    public int HitRate(int cellIndex)
    {
        int boxDistance   = tgs.CellGetBoxDistance(currentCellIndex, cellIndex);
        int luckStat      = BASE_STATS["LUCK"].CalculateValue();
        int skillStat     = BASE_STATS["SKILL"].CalculateValue();
        int biorhythmStat = BASE_STATS["BIORHYTHM"].CalculateValue();
        int weaponHitStat = equippedWeapon.STATS["HIT"].CalculateValue();

        int hitRate = (skillStat * 2) + luckStat + biorhythmStat + weaponHitStat;

        if (boxDistance >= 2)
        {
            hitRate -= 15;
        }

        return(hitRate);
    }