2026/01/26 Update

Added Improved Critical (touch attack).
Added Improved Critical (ray).
Added Weapon Focus (touch attack).
Added Epic Weapon Focus (touch attack).
Fell Shot was resolving as a melee touch attack instead of a ranged weapon touch attack.
Cleaned up ungated debug in prc_inc_nat_hb.
This commit is contained in:
Jaysyn904
2026-01-26 12:36:54 -05:00
parent 43cf043470
commit 8772b32d43
10 changed files with 107 additions and 33 deletions

View File

@@ -26010,10 +26010,10 @@
26006 FEAT_VOWABSTINENCE 16990541 16990542 ife_sacredvow **** **** **** **** **** **** **** **** 3388 **** 0 0 1 **** **** **** **** 0.5 **** 97 **** **** **** **** **** **** **** **** **** **** FEAT_VOWABSTINENCE 6 **** **** **** **** **** 0 0
26007 FEAT_VOWCHASTITY 16990543 16990544 ife_sacredvow **** **** **** **** **** **** **** **** 3388 **** 0 0 1 **** **** **** **** 0.5 **** 97 **** **** **** **** **** **** **** **** **** **** FEAT_VOWCHASTITY 6 **** **** **** **** **** 0 0
26008 FEAT_GIFTOFFAITH 16990545 16990546 ife_sacredvow **** **** **** **** 13 **** **** **** **** **** 0 0 1 **** **** **** **** 0.5 **** 97 **** **** **** **** **** **** **** **** **** **** FEAT_GIFTOFFAITH 6 **** **** **** **** **** 0 0
26009 **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** ****
26010 **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** ****
26011 **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** ****
26012 **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** ****
26009 FEAT_IMPROVED_CRITICAL_TOUCH 16990322 228 ife_kistrike 8 **** **** **** **** **** **** **** **** **** 0 0 1 **** **** **** **** 1 **** 0 **** **** **** **** **** **** **** **** **** **** FEAT_IMPROVED_CRITICAL_TOUCH 1 **** **** **** **** **** 0 1
26010 FEAT_IMPROVED_CRITICAL_RAY 16990324 228 ife_X1SilPal 8 **** **** **** **** **** **** **** **** **** 0 0 1 **** **** **** **** 1 **** 0 **** **** **** **** **** **** **** **** **** **** FEAT_IMPROVED_CRITICAL_RAY 1 **** **** **** **** **** 0 1
26011 FEAT_WEAPON_FOCUS_TOUCH 16990326 16990327 ife_X1SilPal 1 **** **** **** **** **** **** **** **** **** 0 0 1 **** **** **** **** 0.5 **** 1 **** **** **** **** **** **** **** **** **** **** FEAT_WEAPON_FOCUS_TOUCH 2 **** **** **** **** **** 0 1
26012 FEAT_EPIC_WEAPON_FOCUS_TOUCH 16990328 16990329 ife_X1SilPal **** **** **** **** **** **** **** **** 26011 **** 0 0 1 **** **** **** **** 0.5 **** 10 **** **** **** **** **** **** **** **** **** **** FEAT_EPIC_WEAPON_FOCUS_TOUCH 2 **** **** **** **** **** 1 1
26013 **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** ****
26014 **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** ****
26015 **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** ****

View File

@@ -2480,7 +2480,7 @@
2476 ForestMaster_DeepRoots 16793751 is_x2vinemine T P 0 0x00 0x01 prc_fm_deeproots **** **** **** **** **** **** 4 500 head **** **** **** **** **** **** self 500 **** **** vca_uphexnatr01 sca_outnatr01 0 **** **** **** **** **** **** 1 **** **** **** **** **** 10 **** 3 16793759 0 0 16778866 0 5446 **** **** 0 **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** ****
2477 **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** ****
2478 **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** ****
2479 SPELL_CHASING_PERFECTION 16990493 fot_strengthone T T vs 0x02 0x0b sp_chasperfect **** 6 6 **** **** 6 6 1500 hand **** vco_mehannatr03 **** sco_mehannatr01 vs_chant_ench_lm vs_chant_ench_hf out 1000 **** **** **** **** 0 **** **** **** **** **** **** 0 **** **** **** **** **** 7 **** 1 16990494 1 0 **** 0 **** **** **** 0 **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** ****
2479 SPELL_CHASING_PERFECTION 16990493 fot_strengthone T T vs 0x3a 0x0b sp_chasperfect **** 6 6 **** **** 6 6 1500 hand **** vco_mehannatr03 **** sco_mehannatr01 vs_chant_ench_lm vs_chant_ench_hf out 1000 **** **** **** **** 0 **** **** **** **** **** **** 0 **** **** **** **** **** 7 **** 1 16990494 1 0 **** 0 **** **** **** 0 **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** ****
2480 SPELL_FORCE_MISSILES 16990488 is_X1LesMis V L vs 0x3d 0x1E sp_forcemissiles **** **** **** **** **** 4 4 1500 hand **** vco_mehancold03 **** sco_mehancold03 vs_chant_evoc_lm vs_chant_evoc_lf out 1900 **** vca_outsonic **** sca_outsonic 0 **** **** **** **** path **** 1 **** **** **** **** **** 2 **** 1 16990489 1 0 **** 1 **** **** **** 1 sphere 8.33 **** 2 **** **** **** **** **** **** **** **** **** **** **** **** **** ****
2481 SYMBOL_OF_DEATH 16790080 is_symb_death N S vs 0x3f 0x3E sp_symbol **** 8 **** **** **** 8 8 1500 head **** **** vco_megrdevil01 sco_megrdevil01 vs_chant_necr_hm vs_chant_necr_hf area 1000 **** **** **** **** 1 vpr_ectoevil01 homing hand spr_ectoevil01 path Death 1 **** **** **** **** **** 11 **** 1 16790082 1 0 **** 1 **** **** **** 1 **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** ****
2482 SYMBOL_OF_FEAR 16790083 is_symb_fear N S vs 0x3f 0x3E sp_symbol **** 6 **** **** **** 6 6 1500 head **** **** vco_lgsprevil01 sco_lgsprevil01 vs_chant_necr_hm vs_chant_necr_hf area 1000 **** **** **** **** 1 vpr_ectoevil01 homing hand spr_ectoevil01 path Fear 1 **** **** **** **** **** 11 **** 1 16790085 1 0 **** 1 **** **** **** 1 **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** ****

View File

@@ -1494,9 +1494,13 @@ const int FEAT_VILE_MARTIAL_MINDBLADE = 3624;
const int FEAT_VILE_MARTIAL_WHIP = 3598;
const int FEAT_VILE_MARTIAL_TRIDENT = 3599;
// Weapon Focus (Ray)
const int FEAT_WEAPON_FOCUS_RAY = 4819;
const int FEAT_EPIC_WEAPON_FOCUS_RAY = 4820;
//:: Spell-like Weapons
const int FEAT_WEAPON_FOCUS_RAY = 4819;
const int FEAT_EPIC_WEAPON_FOCUS_RAY = 4820;
const int FEAT_IMPROVED_CRITICAL_TOUCH = 26009;
const int FEAT_IMPROVED_CRITICAL_RAY = 26010;
const int FEAT_WEAPON_FOCUS_TOUCH = 26011;
const int FEAT_EPIC_WEAPON_FOCUS_TOUCH = 26012;
// Battleguard Tempus
const int TEMPUS_ABILITY_ENHANC1 = 1;

View File

@@ -265,7 +265,8 @@ struct WeaponFeat GetAllFeatsOfWeaponType(int iWeaponType);
// Returns the low end of oWeap's critical threat range
// Accounts for Keen and Improved Critical bonuses
int GetWeaponCriticalRange(object oPC, object oWeap);
//int GetWeaponCriticalRange(object oPC, object oWeap);
int GetWeaponCriticalRange(object oPC, object oWeap, int iTouchAttackType = FALSE);
// returns the critical multiplier of the weapons base type
int GetCriticalMultiplierOfWeaponType(int iWeaponType);
@@ -1999,11 +2000,37 @@ object GetAmmunitionFromWeapon(object oWeapon, object oAttacker)
return GetAmmunitionFromWeaponType(GetBaseItemType(oWeapon), oAttacker);
}
int GetWeaponCriticalRange(object oPC, object oWeap)
//int GetWeaponCriticalRange(object oPC, object oWeap)
// for a ranged weapon we should call this *after* we have ammo equipped, because it checks the ammo for keen
// if we (re)equip the ammo later, we don't get the right keen property
int GetWeaponCriticalRange(object oPC, object oWeap, int iTouchAttackType = FALSE)
{
//no weapon, touch attacks mainly
// Check for spell-based touch attacks
if(iTouchAttackType == TOUCH_ATTACK_MELEE_SPELL)
{
if (DEBUG) DoDebug("prc_inc_combat >> GetWeaponCriticalRange() | TOUCH_ATTACK_MELEE_SPELL detected.");
// Spell-based melee touch attacks
if(GetHasFeat(FEAT_IMPROVED_CRITICAL_TOUCH, oPC))
{
if (DEBUG) DoDebug("prc_inc_combat >> GetWeaponCriticalRange() | Improved Critical: Touch detected.");
return 19; // Doubles threat range from 20 to 19-20
}
else
return 20;
}
else if(iTouchAttackType == TOUCH_ATTACK_RANGED_SPELL)
{
if (DEBUG) DoDebug("prc_inc_combat >> GetWeaponCriticalRange() | TOUCH_ATTACK_RANGED_SPELL detected.");
// Ray attacks
if(GetHasFeat(FEAT_IMPROVED_CRITICAL_RAY, oPC))
{
if (DEBUG) DoDebug("prc_inc_combat >> GetWeaponCriticalRange() | Improved Critical: Ray detected.");
return 19; // Doubles threat range from 20 to 19-20
}
else
return 20;
}
//no weapon, touch attacks mainly
if(!GetIsObjectValid(oWeap))
return 20;
@@ -3306,7 +3333,33 @@ int GetAttackBonus(object oDefender, object oAttacker, object oWeap, int iOffhan
// weapon specific feats
sWeaponFeat = GetAllFeatsOfWeaponType(iWeaponType);
int bFocus = 0;
int bFocus = 0;
int bEpicFocus = 0;
int bIsRangedTouchAttack = iTouchAttackType == TOUCH_ATTACK_RANGED || iTouchAttackType == TOUCH_ATTACK_RANGED_SPELL;
int bIsMeleeTouchAttack = iTouchAttackType == TOUCH_ATTACK_MELEE_SPELL;
if(bIsRangedTouchAttack)
{
// Weapon Focus(Ray) applies to ranged touch attacks
bFocus = GetHasFeat(FEAT_WEAPON_FOCUS_RAY, oAttacker);
if (bFocus) // no need to look for epic focus, if we don't have focus
bEpicFocus = GetHasFeat(FEAT_EPIC_WEAPON_FOCUS_RAY, oAttacker);
}
else if(bIsMeleeTouchAttack)
{
// Weapon Focus(Touch Attack) applies to melee touch attacks
bFocus = GetHasFeat(FEAT_WEAPON_FOCUS_TOUCH, oAttacker);
if (bFocus) // no need to look for epic focus, if we don't have focus
bEpicFocus = GetHasFeat(FEAT_EPIC_WEAPON_FOCUS_TOUCH, oAttacker);
}
else
{ // no touch attack, normal weapon focus feats
bFocus = GetHasFeat(sWeaponFeat.Focus, oAttacker);
if (bFocus) // no need to look for epic focus, if we don't have focus
bEpicFocus = GetHasFeat(sWeaponFeat.EpicFocus, oAttacker);
}
/* int bFocus = 0;
int bEpicFocus = 0;
int bIsRangedTouchAttack = iTouchAttackType == TOUCH_ATTACK_RANGED || iTouchAttackType == TOUCH_ATTACK_RANGED_SPELL;
@@ -3322,7 +3375,7 @@ int GetAttackBonus(object oDefender, object oAttacker, object oWeap, int iOffhan
bFocus = GetHasFeat(sWeaponFeat.Focus, oAttacker);
if (bFocus) // no need to look for epic focus, if we don't have focus
bEpicFocus = GetHasFeat(sWeaponFeat.EpicFocus, oAttacker);
}
} */
int bEpicProwess = GetHasFeat(FEAT_EPIC_PROWESS, oAttacker);
@@ -3937,7 +3990,7 @@ int GetAttackRoll(object oDefender, object oAttacker, object oWeapon, int iOffha
//if (bDebug) sDebugFeedback = COLOR_WHITE + "Attack Roll = " + IntToString(iAttackBonus + iDiceRoll) + ": " + sDebugFeedback;
//if (DEBUG) DoDebug("GetAttackRoll: End Section #1");
int iWeaponType = GetBaseItemType(oWeapon);
int iCritThreat = GetWeaponCriticalRange(oAttacker, oWeapon);
int iCritThreat = GetWeaponCriticalRange(oAttacker, oWeapon, iTouchAttackType);
//If using Killing Shot, ciritical range improves by 2;
if(GetLocalInt(oAttacker, "KillingShotCritical") )

View File

@@ -507,7 +507,7 @@ void DoNaturalWeaponHB(object oPC = OBJECT_SELF)
if(!GetIsObjectValid(oLimbo))
lLimbo = GetStartingLocation();
oWeapon = CreateObject(OBJECT_TYPE_ITEM, sResRef, lLimbo);
DoDebug(PRC_TEXT_WHITE + "prc_inc_nat_hb >> DoNaturalWeaponHB: creature weapon object found!!!");
if(DEBUG) DoDebug(PRC_TEXT_WHITE + "prc_inc_nat_hb >> DoNaturalWeaponHB: creature weapon object found!!!");
}
// Check for enhancements after creating the weapon object

View File

@@ -47,7 +47,7 @@ int PRCDoRangedTouchAttack(object oTarget, int nDisplayFeedback = TRUE, object o
{
SetLocalInt(oCaster, "RangedRecall", nRecall+1);
// Reroll with a -5 penalty
nResult = GetAttackRoll(oTarget,oCaster,OBJECT_INVALID,0,nAttackBonus-5,0,nDisplayFeedback,0.0,TOUCH_ATTACK_MELEE_SPELL);
nResult = GetAttackRoll(oTarget,oCaster,OBJECT_INVALID,0,nAttackBonus-5,0,nDisplayFeedback,0.0,TOUCH_ATTACK_RANGED_SPELL);
}
}
}

View File

@@ -34,5 +34,6 @@ void main()
return;
}
PerformAttackRound(oTarget, oPC, eDummy, 0.0, 0, 0, 0, FALSE, "Fell Shot Hit", "Fell Shot Miss", FALSE, TRUE);
//PerformAttackRound(oTarget, oPC, eDummy, 0.0, 0, 0, 0, FALSE, "Fell Shot Hit", "Fell Shot Miss", FALSE, TRUE);
PerformAttackRound(oTarget, oPC, eDummy, 0.0, 0, 0, 0, FALSE, "Fell Shot Hit", "Fell Shot Miss", FALSE, TOUCH_ATTACK_RANGED);
}

View File

@@ -10023,6 +10023,7 @@ Combining the dynamic powers of martial prowess and arcane might, the Hexblade p
- Alignment Restrictions: non-good only
- Hit Die: d10
- Proficiencies: Hexblades are proficient with all simple and martial weapons, and with light armor but not with shields.
- Skill Points: 2+ Int Modifier.
CLASS FEATURES:
@@ -51957,7 +51958,7 @@ Benefit: When using the Rapid Shot feat, you may ignore the -2 penalty on all yo
Use: Automatic</entry>
<entry id="59236" lang="en" sex="m">Ranged Recall</entry>
<entry id="59237" lang="en" sex="m">Type of Feat: General
Prerequisite: Point Blank Shot, Weapon Focus (Ray), Spellcraft 4
Prerequisite: Point Blank Shot, Weapon Focus (ray), Spellcraft 4
Benefit: When you miss with a spell or spell-like ability ranged attack against a target within 30 feet, you can spend a swift action to reroll the attack with a -5 penalty. You can use this ability three times per day.
Use: Automatic</entry>
<entry id="59238" lang="en" sex="m">Somatic Weaponry</entry>
@@ -76492,6 +76493,21 @@ Benefit: You turn (but not destroy) plants as a good cleric turns undead. Treat
Prerequisites: Plant Defiance, ability to cast speak with plants.
Benefit: You rebuke or command plants as an evil cleric rebukes undead. To command a plant, you must be able to speak with it via a speak with plants effect, though you may issue your commands mentally if desired. The number of times per day that you can use this ability is equal to 3 + your Charisma modifier. Your highest divine caster level is the level at which you rebuke plants.</entry>
<entry id="213106" lang="en" sex="m">Improved Critical (touch attack)</entry>
<entry id="213107" lang="en" sex="m">****</entry>
<entry id="213108" lang="en" sex="m">Improved Critical (ray)</entry>
<entry id="213109" lang="en" sex="m">****</entry>
<entry id="213110" lang="en" sex="m">Weapon Focus (touch attack)</entry>
<entry id="213111" lang="en" sex="m">Type of Feat: General
Prerequisite: Base attack bonus +1 or higher
Specifics: The character gains a +1 bonus to all attack rolls with touch attack spells.
Use: Automatic</entry>
<entry id="213112" lang="en" sex="m">Epic Weapon Focus (touch attack)</entry>
<entry id="213113" lang="en" sex="m">Type of Feat: Epic, Combat
Prerequisite: 21st level, Weapon Focus: Touch Attack.
Specifics: The character gains a +2 bonus to all attack rolls with touch attack spells.
Use: Automatic
</entry>
<entry id="213198" lang="en" sex="m">Investigator</entry>
<entry id="213199" lang="en" sex="m">Type of Feat: General
Benefit: You get a +2 bonus on all Sense Motive and Search checks.