Spell & Ability Upgrade

Reorganized hak files & removed duplicates.  Added @rafhot's PRC spell & ability level scaling expansion.  Further script integration.  Full compile.
This commit is contained in:
Jaysyn904
2023-08-19 21:08:35 -04:00
parent a911002fe6
commit 7dd83ad168
1466 changed files with 4010 additions and 21168 deletions

View File

@@ -61,6 +61,7 @@ Open up the No Casting Area and edit the area to see how it's set up properly.
//Do not delete any of these includes! (They are vital for this script)
#include "x2_inc_switches"
#include "nw_i0_spells"
#include "prc_inc_spells"
//See this script to learn premade functions to use in this script
//Those functions save you time as this script is rather long!
@@ -76,8 +77,8 @@ void main()
int nCastLevel = GetCasterLevel(OBJECT_SELF);
int zInt;
object oCaster = OBJECT_SELF;
object sTarget = GetSpellTargetObject();
object sItem = GetSpellCastItem();
object sTarget = PRCGetSpellTargetObject();
object sItem = PRCGetSpellCastItem();
location sLocation = GetSpellTargetLocation();
int sClass = GetLastSpellCastClass();
@@ -122,7 +123,7 @@ if(GetLocalInt(GetArea(oCaster), "JAIL")==1)
///////////////Handling Spells Cast From Items/////////////////////////////////
//This is what will happen if the spell was cast from an item..
if(GetSpellCastItem()!=OBJECT_INVALID)
if(PRCGetSpellCastItem()!=OBJECT_INVALID)
{
//If the PC uses an item on a PC, and it's one of the following spells
//Then the spell will not work on the PC, note you can add other effects
@@ -153,7 +154,7 @@ switch (nSpell)
//case SPELL_NAME: (Like So)
case SPELL_EPIC_RUIN:
{
if(GetIsPC(GetSpellTargetObject()))
if(GetIsPC(PRCGetSpellTargetObject()))
{
//Don't Cast the original spell
AssignCommand(oCaster, ClearAllActions());
@@ -169,7 +170,7 @@ switch (nSpell)
case SPELL_HARM:
{
if(GetIsPC(GetSpellTargetObject()))
if(GetIsPC(PRCGetSpellTargetObject()))
{
//Don't cast the original spell at all
AssignCommand(oCaster, ClearAllActions());
@@ -179,7 +180,7 @@ switch (nSpell)
case SPELL_DROWN:
{
if(GetIsPC(GetSpellTargetObject()))
if(GetIsPC(PRCGetSpellTargetObject()))
{
//Stop the original spell from running..
AssignCommand(oCaster, ClearAllActions());
@@ -1505,7 +1506,7 @@ switch (nSpell)
case SPELL_BLAHZAM: //Change the SPELL_NAME to the actual spell being cast.
{
//Note if the spell does target damage use this always!
DoBonusDmg(GetSpellTargetObject());
DoBonusDmg(PRCGetSpellTargetObject());
//Do a generic targeted visual (see the "spellfunc_inc" script)
DoTVisual();