private static bool Prefix(BlueprintAbilityResource __instance, UnitDescriptor unit, ref int __result)
            {
                if (__instance.GetType() == typeof(WarriorSpiritPoolLogic))
                {
                    __result = 0;
                    if (unit.Progression.GetClassLevel(Helpers.fighterClass) >= 5)
                    {
                        int basePool = 1;

                        int weaponTrainingValue = AdvancedWeaponTraining.GetWeaponTrainingRank(unit, ((WarriorSpiritPoolLogic)__instance).WeaponTraining);

                        __result = basePool + weaponTrainingValue;
                    }

                    return(false);
                }

                return(true);
            }