2025/06/07 Evening Update
Fixed Opportunistic Piety & Turning. Fixed Midnight Augmentation.
This commit is contained in:
parent
01f4c1b408
commit
a668be703a
@ -1335,7 +1335,7 @@ void DelayAddItemProperty(float fDelay, object oGenerationHolder, string sGenera
|
|||||||
* @see DecrementRemainingFeatUses()
|
* @see DecrementRemainingFeatUses()
|
||||||
* @see IncrementRemainingFeatUses()
|
* @see IncrementRemainingFeatUses()
|
||||||
*/
|
*/
|
||||||
void FeatUsePerDay(object oPC, int iFeat, int iAbiMod = ABILITY_CHARISMA, int iMod = 0, int iMin = 1)
|
void FeatUsePerDay(object oPC, int iFeat, int iAbiMod = ABILITY_CHARISMA, int iMod = 0, int iMin = 1)
|
||||||
{
|
{
|
||||||
if(!GetHasFeat(iFeat,oPC))
|
if(!GetHasFeat(iFeat,oPC))
|
||||||
return;
|
return;
|
||||||
@ -2042,6 +2042,34 @@ void WildMage(object oPC)
|
|||||||
} */
|
} */
|
||||||
|
|
||||||
void Factotum(object oPC)
|
void Factotum(object oPC)
|
||||||
|
{
|
||||||
|
int nClass = GetLevelByClass(CLASS_TYPE_FACTOTUM, oPC);
|
||||||
|
if(nClass > 0)
|
||||||
|
{
|
||||||
|
if (nClass >= 20)
|
||||||
|
{
|
||||||
|
FeatUsePerDay(oPC, FEAT_OPPORTUNISTIC_PIETY_TURN, ABILITY_WISDOM, 6);
|
||||||
|
FeatUsePerDay(oPC, FEAT_OPPORTUNISTIC_PIETY_HEAL, ABILITY_WISDOM, 6);
|
||||||
|
}
|
||||||
|
else if (nClass >= 15)
|
||||||
|
{
|
||||||
|
FeatUsePerDay(oPC, FEAT_OPPORTUNISTIC_PIETY_TURN, ABILITY_WISDOM, 5);
|
||||||
|
FeatUsePerDay(oPC, FEAT_OPPORTUNISTIC_PIETY_HEAL, ABILITY_WISDOM, 5);
|
||||||
|
}
|
||||||
|
else if (nClass >= 10)
|
||||||
|
{
|
||||||
|
FeatUsePerDay(oPC, FEAT_OPPORTUNISTIC_PIETY_TURN, ABILITY_WISDOM, 4);
|
||||||
|
FeatUsePerDay(oPC, FEAT_OPPORTUNISTIC_PIETY_HEAL, ABILITY_WISDOM, 4);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
FeatUsePerDay(oPC, FEAT_OPPORTUNISTIC_PIETY_TURN, ABILITY_WISDOM, 3);
|
||||||
|
FeatUsePerDay(oPC, FEAT_OPPORTUNISTIC_PIETY_HEAL, ABILITY_WISDOM, 3);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* void Factotum(object oPC)
|
||||||
{
|
{
|
||||||
int nClass = GetLevelByClass(CLASS_TYPE_FACTOTUM, oPC);
|
int nClass = GetLevelByClass(CLASS_TYPE_FACTOTUM, oPC);
|
||||||
if(nClass > 0)
|
if(nClass > 0)
|
||||||
@ -2067,7 +2095,7 @@ void Factotum(object oPC)
|
|||||||
FeatUsePerDay(oPC, FEAT_OPPORTUNISTIC_PIETY_HEAL, ABILITY_WISDOM, 0, 3);
|
FeatUsePerDay(oPC, FEAT_OPPORTUNISTIC_PIETY_HEAL, ABILITY_WISDOM, 0, 3);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
} */
|
||||||
|
|
||||||
void Sharess(object oPC)
|
void Sharess(object oPC)
|
||||||
{
|
{
|
||||||
|
@ -456,7 +456,7 @@ struct manifestation EvaluateAugmentation(struct manifestation manif, struct pow
|
|||||||
int nAugPPCostReductions = 0;
|
int nAugPPCostReductions = 0;
|
||||||
int bMaxAugment = GetLocalInt(manif.oManifester, PRC_AUGMENT_MAXAUGMENT) &&
|
int bMaxAugment = GetLocalInt(manif.oManifester, PRC_AUGMENT_MAXAUGMENT) &&
|
||||||
!GetLocalInt(manif.oManifester, PRC_AUGMENT_OVERRIDE); // Override profile also overrides max augment
|
!GetLocalInt(manif.oManifester, PRC_AUGMENT_OVERRIDE); // Override profile also overrides max augment
|
||||||
|
|
||||||
// Initialise the augmentation data in the manifestation structure to zero
|
// Initialise the augmentation data in the manifestation structure to zero
|
||||||
/* Probably unnecessary due to auto-init
|
/* Probably unnecessary due to auto-init
|
||||||
manif.nTimesAugOptUsed_1 = 0;
|
manif.nTimesAugOptUsed_1 = 0;
|
||||||
@ -545,27 +545,25 @@ struct manifestation EvaluateAugmentation(struct manifestation manif, struct pow
|
|||||||
nAugPPCostReductions += nSurge;
|
nAugPPCostReductions += nSurge;
|
||||||
|
|
||||||
// Midnight Augmentation feat from incarnum
|
// Midnight Augmentation feat from incarnum
|
||||||
if (GetHasFeat(FEAT_MIDNIGHT_AUGMENTATION, manif.oManifester))
|
int bMidAug = GetLocalInt(manif.oManifester, "MidnightAugPower");
|
||||||
{
|
int nMidnightAugReduction = 0;
|
||||||
int nPower = GetLocalInt(manif.oManifester, "MidnightAugPower");
|
//if (GetHasFeat(FEAT_MIDNIGHT_AUGMENTATION, manif.oManifester))
|
||||||
if (manif.nSpellID == nPower)
|
if(bMidAug > 0)
|
||||||
{
|
|
||||||
int bUsedFocus = UsePsionicFocus(manif.oManifester);
|
|
||||||
if (bUsedFocus)
|
|
||||||
{
|
|
||||||
nAugPPCostReductions += GetEssentiaInvestedFeat(manif.oManifester, FEAT_MIDNIGHT_AUGMENTATION);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/* // Midnight Augmentation feat from incarnum
|
|
||||||
if (GetHasFeat(FEAT_MIDNIGHT_AUGMENTATION, manif.oManifester))
|
|
||||||
{
|
{
|
||||||
// Make sure the power is the correct one, and that you can expend your psionic focus
|
if(DEBUG) DoDebug("Checking Midnight Augumentation");
|
||||||
|
int bMidAugInvestment = GetLocalInt(manif.oManifester, "MidnightAugPowerInvestment");
|
||||||
|
|
||||||
|
// Make sure the power is the correct one, and that you can expend your psionic focus
|
||||||
if (manif.nSpellID == GetLocalInt(manif.oManifester, "MidnightAugPower") && UsePsionicFocus(manif.oManifester))
|
if (manif.nSpellID == GetLocalInt(manif.oManifester, "MidnightAugPower") && UsePsionicFocus(manif.oManifester))
|
||||||
nAugPPCostReductions += GetEssentiaInvestedFeat(manif.oManifester, FEAT_MIDNIGHT_AUGMENTATION);
|
{
|
||||||
} */
|
if(DEBUG) DoDebug("Midnight Augumentation power invested Essentia is: "+IntToString(bMidAugInvestment)+".");
|
||||||
|
//nAugPPCostReductions = nAugPPCostReductions + bMidAugInvestment;
|
||||||
|
nMidnightAugReduction = bMidAugInvestment;
|
||||||
|
|
||||||
|
if(DEBUG) DoDebug("Final Midnight Augumentation power adjustment "+IntToString(nMidnightAugReduction)+".");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/*/ Various effects modifying the augmentation go above /*/
|
/*/ Various effects modifying the augmentation go above /*/
|
||||||
|
|
||||||
// Auto-distribution, if modifying effects provided more PP than has been used so far or
|
// Auto-distribution, if modifying effects provided more PP than has been used so far or
|
||||||
@ -701,10 +699,11 @@ struct manifestation EvaluateAugmentation(struct manifestation manif, struct pow
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Add in cost reduction
|
// Add in cost reduction
|
||||||
nAugPPCost = PRCMax(0, nAugPPCost - nAugPPCostReductions);
|
//nAugPPCost = PRCMax(0, nAugPPCost - nAugPPCostReductions);
|
||||||
|
nAugPPCost = nAugPPCost - nAugPPCostReductions;
|
||||||
// Store the PP cost increase
|
// Store the PP cost increase
|
||||||
manif.nPPCost += nAugPPCost;
|
manif.nPPCost += nAugPPCost;
|
||||||
|
manif.nPPCost -= nMidnightAugReduction; //:: Had to apply this directly, wouldn't work otherwise. -Jaysyn
|
||||||
|
|
||||||
return manif;
|
return manif;
|
||||||
}
|
}
|
||||||
|
@ -176,8 +176,6 @@ void main()
|
|||||||
|
|
||||||
if(sName != "")
|
if(sName != "")
|
||||||
{
|
{
|
||||||
// Replace this with the correct check for whether oMeldshaper actually knows the power.
|
|
||||||
// Example using GetHasSpell:
|
|
||||||
if (GetHasPower(i, oMeldshaper))
|
if (GetHasPower(i, oMeldshaper))
|
||||||
{
|
{
|
||||||
if(SORT) AddToTempList(oMeldshaper, sName, i);
|
if(SORT) AddToTempList(oMeldshaper, sName, i);
|
||||||
@ -296,6 +294,7 @@ void main()
|
|||||||
if (nChoice)
|
if (nChoice)
|
||||||
{
|
{
|
||||||
SetLocalInt(oMeldshaper, "MidnightAugPower", GetLocalInt(oMeldshaper, "nPower"));
|
SetLocalInt(oMeldshaper, "MidnightAugPower", GetLocalInt(oMeldshaper, "nPower"));
|
||||||
|
SetLocalInt(oMeldshaper, "MidnightAugPowerInvestment", GetLocalInt(oMeldshaper, "nEssentia"));
|
||||||
InvestEssentiaFeat(oMeldshaper, FEAT_MIDNIGHT_AUGMENTATION, GetLocalInt(oMeldshaper, "nEssentia"));
|
InvestEssentiaFeat(oMeldshaper, FEAT_MIDNIGHT_AUGMENTATION, GetLocalInt(oMeldshaper, "nEssentia"));
|
||||||
DeleteLocalInt(oMeldshaper, "nPower");
|
DeleteLocalInt(oMeldshaper, "nPower");
|
||||||
DeleteLocalInt(oMeldshaper, "nEssentia");
|
DeleteLocalInt(oMeldshaper, "nEssentia");
|
||||||
|
@ -61,13 +61,13 @@ void main()
|
|||||||
|
|
||||||
int nItemType = GetBaseItemType(oItem);
|
int nItemType = GetBaseItemType(oItem);
|
||||||
|
|
||||||
if(nItemType == BASE_ITEM_CBLUDGWEAPON
|
if(nItemType == BASE_ITEM_CBLUDGWEAPON
|
||||||
|| BASE_ITEM_CPIERCWEAPON
|
|| nItemType == BASE_ITEM_CPIERCWEAPON
|
||||||
|| BASE_ITEM_CSLASHWEAPON
|
|| nItemType == BASE_ITEM_CSLASHWEAPON
|
||||||
|| BASE_ITEM_CSLSHPRCWEAP)
|
|| nItemType == BASE_ITEM_CSLSHPRCWEAP)
|
||||||
{
|
{
|
||||||
DestroyObject(oItem);
|
DestroyObject(oItem);
|
||||||
}
|
}
|
||||||
|
|
||||||
int nClaw = GetStringLeft(GetResRef(oItem), 12) == "prc_diaclaw_" ? TRUE : FALSE;
|
int nClaw = GetStringLeft(GetResRef(oItem), 12) == "prc_diaclaw_" ? TRUE : FALSE;
|
||||||
if(nClaw)DestroyObject(oItem);
|
if(nClaw)DestroyObject(oItem);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user