333 lines
14 KiB
Plaintext
333 lines
14 KiB
Plaintext
# Wizardry EE Spell Implementation Details
|
|
|
|
## Light-related spells
|
|
|
|
### milwa.nss
|
|
- **Primary Reference**: nw_s0_light.nss
|
|
- **Secondary Reference**: nw_s0_extrathf.nss
|
|
- **Implementation Details**:
|
|
- Creates a light effect using VFX_DUR_LIGHT_WHITE_20
|
|
- Adds a +10 bonus to Search skill
|
|
- Duration: Hours equal to caster level
|
|
- Reveals secret doors in the area
|
|
- Sets a flag "MILWA_ACTIVE" to track the spell's active state
|
|
- Uses CheckMetaMagic() for proper metamagic handling
|
|
|
|
### lomilwa.nss
|
|
- **Primary Reference**: nw_s0_light.nss, nw_s0_daylight.nss
|
|
- **Secondary Reference**: nw_s0_extrathf.nss
|
|
- **Implementation Details**:
|
|
- Creates a stronger light effect
|
|
- Adds a +20 bonus to Search skill (enhanced from MILWA)
|
|
- Duration: Fixed at 24 hours (entire expedition)
|
|
- Removes any existing MILWA effects using RemoveEffectsFromSpell()
|
|
- Reveals secret doors with a stronger visual effect (VFX_FNF_DISPEL_GREATER)
|
|
- Sets a flag "LOMILWA_ACTIVE" to track the spell's active state
|
|
- Uses CheckMetaMagic() for proper metamagic handling
|
|
|
|
## Damage spells
|
|
|
|
### halito.nss
|
|
- **Primary Reference**: nw_s0_burnhand.nss
|
|
- **Implementation Details**:
|
|
- Deals 1d8 fire damage to a single target
|
|
- Includes spell resistance check
|
|
- Supports metamagic (Maximize, Empower)
|
|
- Uses PRCEffectDamage() for proper damage application
|
|
- Uses VFX_IMP_FLAME_S for visual effect
|
|
- Notifies the caster of damage dealt
|
|
|
|
### mahalito.nss
|
|
- **Primary Reference**: nw_s0_fireball.nss
|
|
- **Implementation Details**:
|
|
- Deals 4d6 fire damage to multiple targets in a medium-sized sphere
|
|
- Includes spell resistance check
|
|
- Includes reflex save for half damage
|
|
- Supports metamagic (Maximize, Empower)
|
|
- Uses PRCEffectDamage() for proper damage application
|
|
- Uses VFX_FNF_FIREBALL for area effect and VFX_IMP_FLAME_M for target effect
|
|
- Notifies the caster of total enemies affected
|
|
|
|
### lahalito.nss
|
|
- **Primary Reference**: nw_s0_firestrm.nss
|
|
- **Implementation Details**:
|
|
- Deals 6d6 fire damage to multiple targets in a huge-sized sphere
|
|
- Includes spell resistance check
|
|
- Includes reflex save for half damage
|
|
- Supports metamagic (Maximize, Empower)
|
|
- Uses PRCEffectDamage() for proper damage application
|
|
- Uses VFX_FNF_FIRESTORM for area effect and VFX_IMP_FLAME_M for target effect
|
|
- Notifies the caster of total enemies affected
|
|
|
|
### molito.nss
|
|
- **Primary Reference**: nw_s0_inccloud.nss
|
|
- **Implementation Details**:
|
|
- Deals 3d6 electrical damage to half of the enemies in a medium-sized sphere
|
|
- Includes spell resistance check
|
|
- Includes reflex save for half damage
|
|
- Supports metamagic (Maximize, Empower)
|
|
- Uses PRCEffectDamage() for proper damage application
|
|
- Uses VFX_FNF_INCENDIARY for area effect and VFX_IMP_FLAME_S for target effect
|
|
- Notifies the caster of total enemies affected out of total enemies in area
|
|
|
|
### dalto.nss
|
|
- **Primary Reference**: nw_s0_acidarrow.nss
|
|
- **Implementation Details**:
|
|
- Deals 6d6 acid damage to a single target with a ranged touch attack
|
|
- Includes lingering effect that deals 3d6 additional damage after 6 seconds
|
|
- Includes spell resistance check
|
|
- Supports metamagic (Maximize, Empower)
|
|
- Uses ApplyTouchAttackDamage() for proper damage application
|
|
- Uses VFX_IMP_ACID_L for initial visual effect and VFX_IMP_ACID_S for lingering effect
|
|
- Notifies the caster of damage dealt
|
|
|
|
### madalto.nss
|
|
- **Primary Reference**: nw_s0_acidfog.nss
|
|
- **Implementation Details**:
|
|
- Creates an acid fog area effect that deals 8d8 acid damage per round
|
|
- Duration: Half of caster level in rounds
|
|
- Supports metamagic (Extend)
|
|
- Uses EffectAreaOfEffect(AOE_PER_FOGACID) for the area effect
|
|
- Uses VFX_FNF_GAS_EXPLOSION_ACID for visual effect
|
|
- Sets custom properties on the AOE object for damage calculation
|
|
- Notifies the caster of the duration
|
|
|
|
### dilto.nss
|
|
- **Primary Reference**: nw_s0_conecold.nss
|
|
- **Implementation Details**:
|
|
- Deals 1d6 per caster level (max 10d6) cold damage in a cone
|
|
- Includes spell resistance check
|
|
- Includes reflex save for half damage
|
|
- Supports metamagic (Maximize, Empower)
|
|
- Uses PRCEffectDamage() for proper damage application
|
|
- Uses VFX_IMP_FROST_L for visual effect
|
|
- Uses SHAPE_SPELLCONE for area targeting
|
|
- Notifies the caster of total enemies affected
|
|
|
|
### tiltowait.nss
|
|
- **Primary Reference**: nw_s0_metswarm.nss
|
|
- **Implementation Details**:
|
|
- Deals 10d15 damage (implemented as 30d5 for similar effect) to all enemies in a colossal-sized sphere
|
|
- Includes spell resistance check
|
|
- Includes reflex save for half damage
|
|
- Supports metamagic (Maximize, Empower)
|
|
- Uses PRCEffectDamage() for proper damage application
|
|
- Uses VFX_FNF_METEOR_SWARM for area effect and VFX_IMP_FLAME_M for target effect
|
|
- Notifies the caster of total enemies affected
|
|
|
|
## Control spells
|
|
|
|
### katino.nss
|
|
- **Primary Reference**: nw_s0_sleep.nss
|
|
- **Implementation Details**:
|
|
- Puts enemies to sleep, affecting lowest HD creatures first (up to 4+d4 HD total)
|
|
- Includes spell resistance check
|
|
- Includes Will save to resist
|
|
- Supports metamagic (Maximize, Empower, Extend)
|
|
- Uses EffectSleep() for the sleep effect
|
|
- Uses VFX_FNF_SLEEP for area effect and VFX_IMP_SLEEP for target effect
|
|
- Sets a flag "CONDITION_SLEEPING" to track the sleep state
|
|
- Notifies the caster of total enemies affected
|
|
|
|
### montino.nss
|
|
- **Primary Reference**: nw_s0_silence.nss
|
|
- **Implementation Details**:
|
|
- Creates a silence area effect around the target
|
|
- Includes spell resistance check for hostile targets
|
|
- Includes Will save for hostile targets
|
|
- Supports metamagic (Extend)
|
|
- Uses EffectAreaOfEffect(AOE_MOB_SILENCE) for the silence effect
|
|
- Uses SetAllAoEInts() to set properties on the AOE object
|
|
- Notifies the caster of success or failure
|
|
|
|
## Healing/Restoration spells
|
|
|
|
### dios.nss
|
|
- **Primary Reference**: nw_s0_curinflict.nss
|
|
- **Implementation Details**:
|
|
- Heals 1d8 hit points to a single target
|
|
- Only targets allies
|
|
- Supports metamagic (Maximize, Empower)
|
|
- Adds bonus healing from Augment Healing feat if present
|
|
- Uses PRCEffectHeal() for proper healing application
|
|
- Uses VFX_IMP_HEALING_S for visual effect
|
|
- Notifies the caster of healing done
|
|
|
|
### badios.nss
|
|
- **Primary Reference**: nw_s0_curinflict.nss
|
|
- **Implementation Details**:
|
|
- Deals 1d8 negative energy damage to a single target
|
|
- Only targets enemies
|
|
- Includes spell resistance check
|
|
- Supports metamagic (Maximize, Empower)
|
|
- Uses PRCEffectDamage() for proper damage application
|
|
- Uses VFX_IMP_NEGATIVE_ENERGY for visual effect
|
|
- Notifies the caster of damage dealt
|
|
|
|
### madi.nss
|
|
- **Primary Reference**: nw_s0_healharm.nss
|
|
- **Implementation Details**:
|
|
- Fully heals a target and removes all negative conditions
|
|
- Only targets allies
|
|
- Removes paralysis, poison, sleep, disease, blindness, confusion, and silence effects
|
|
- Uses GetHasEffect() to check for conditions
|
|
- Uses RemoveEffect() to remove conditions
|
|
- Uses VFX_IMP_HEALING_G for visual effect
|
|
- Uses VFX_IMP_REMOVE_CONDITION for condition removal visual
|
|
- Notifies the caster of healing and conditions cured
|
|
|
|
### latumofis.nss
|
|
- **Primary Reference**: nw_s0_poison.nss (for structure)
|
|
- **Implementation Details**:
|
|
- Cures poison from a single target
|
|
- Only targets allies
|
|
- Uses GetHasEffect() to check for poison
|
|
- Uses RemoveEffect() to remove poison effects
|
|
- Uses VFX_IMP_REMOVE_CONDITION for visual effect
|
|
- Removes the "CONDITION_POISONED" flag
|
|
- Notifies the caster of success or if target is not poisoned
|
|
|
|
## Resurrection spells
|
|
|
|
### di.nss
|
|
- **Primary Reference**: nw_s0_protection.nss
|
|
- **Implementation Details**:
|
|
- Attempts to resurrect a dead character with 1 HP
|
|
- Includes a chance of failure (5% chance even with Maximize)
|
|
- On failure, turns the character to ashes
|
|
- On success, decreases Constitution by 1 and applies a protection effect
|
|
- Uses EffectResurrection() for resurrection
|
|
- Uses VFX_IMP_RAISE_DEAD for visual effect
|
|
- Notifies the caster of success or failure
|
|
|
|
### kadorto.nss
|
|
- **Primary Reference**: nw_s0_healharm.nss
|
|
- **Implementation Details**:
|
|
- Attempts to resurrect a dead or ashed character with full HP
|
|
- Includes a chance of failure (reduced with higher caster level)
|
|
- On failure, character is permanently lost
|
|
- On success, removes all negative conditions and fully heals
|
|
- Uses EffectResurrection() for resurrection
|
|
- Uses VFX_IMP_RAISE_DEAD for visual effect
|
|
- Notifies the caster of success or failure
|
|
|
|
## Protection/Buff spells
|
|
|
|
### porfic.nss
|
|
- **Primary Reference**: nw_s0_magearm.nss
|
|
- **Implementation Details**:
|
|
- Improves AC by 4 (armor enchantment bonus)
|
|
- Duration: Hours equal to caster level
|
|
- Supports metamagic (Extend)
|
|
- Uses EffectACIncrease() for AC improvement
|
|
- Uses VFX_IMP_AC_BONUS and VFX_DUR_CESSATE_POSITIVE for visual effects
|
|
- Notifies the caster of AC improvement and duration
|
|
|
|
### kalki.nss
|
|
- **Primary Reference**: nw_s0_bless.nss
|
|
- **Implementation Details**:
|
|
- Improves AC by 1 (deflection bonus)
|
|
- Adds +1 to attack rolls
|
|
- Adds +1 to saves vs fear
|
|
- Affects all allies within 50 feet
|
|
- Duration: Turns equal to caster level
|
|
- Supports metamagic (Extend)
|
|
- Uses VFX_FNF_LOS_HOLY_30 for area effect and VFX_IMP_HEAD_HOLY for target effect
|
|
- Notifies the caster of total allies affected
|
|
|
|
### bamatu.nss
|
|
- **Primary Reference**: nw_s0_haste.nss
|
|
- **Implementation Details**:
|
|
- Applies haste effect to all allies within 50 feet
|
|
- Removes any existing haste or similar effects
|
|
- Duration: Rounds equal to caster level
|
|
- Supports metamagic (Extend)
|
|
- Uses EffectHaste() for the haste effect
|
|
- Uses VFX_FNF_LOS_HOLY_30 for area effect and VFX_IMP_HASTE for target effect
|
|
- Notifies the caster of total allies affected
|
|
|
|
### maporfic.nss
|
|
- **Primary Reference**: x0_s0_shield.nss
|
|
- **Implementation Details**:
|
|
- Improves AC by 2 (shield enchantment bonus) for all party members
|
|
- Duration: Fixed at 24 hours (entire expedition)
|
|
- Removes any existing PORFIC effects
|
|
- Uses EffectACIncrease() for AC improvement
|
|
- Uses VFX_IMP_AC_BONUS and VFX_DUR_CESSATE_POSITIVE for visual effects
|
|
- Sets a flag "MAPORFIC_ACTIVE" to track the spell's active state
|
|
- Notifies the caster of total party members affected
|
|
|
|
### mogref.nss
|
|
- **Primary Reference**: x0_s0_shield.nss
|
|
- **Implementation Details**:
|
|
- Improves AC by 2 (natural armor bonus) for the caster
|
|
- Duration: Rounds equal to caster level
|
|
- Supports metamagic (Extend)
|
|
- Uses EffectACIncrease() for AC improvement
|
|
- Uses VFX_IMP_AC_BONUS and VFX_DUR_CESSATE_POSITIVE for visual effects
|
|
- Notifies the caster of AC improvement and duration
|
|
|
|
## Condition Removal spells
|
|
|
|
### dialko.nss
|
|
- **Primary Reference**: nw_s0_blinddeaf.nss (for structure)
|
|
- **Implementation Details**:
|
|
- Removes sleep and paralysis effects from a single target
|
|
- Uses GetHasEffect() to check for the conditions
|
|
- Uses RemoveEffect() to remove the conditions
|
|
- Uses VFX_IMP_REMOVE_CONDITION for visual effect
|
|
- Notifies the caster of the result
|
|
|
|
## Information/Utility spells
|
|
|
|
### dumapic.nss
|
|
- **Primary Reference**: nw_s0_identify.nss
|
|
- **Implementation Details**:
|
|
- Increases Lore skill by 10 + caster level for 2 rounds
|
|
- Displays current location information (level, coordinates, facing)
|
|
- Identifies special areas (darkness, antimagic, trap zones)
|
|
- Supports metamagic (Extend)
|
|
- Uses VFX_IMP_MAGICAL_VISION for visual effect
|
|
- Uses FloatingTextStringOnCreature() to display location information
|
|
|
|
## Teleportation spells
|
|
|
|
### malor.nss
|
|
- **Primary Reference**: sp_teleport.nss
|
|
- **Implementation Details**:
|
|
- Teleports the entire party to a random or specified location
|
|
- Includes a 5% chance of teleport mishap (party is lost)
|
|
- In combat: Teleports to a random location in the current area
|
|
- Out of combat: Teleports to specified coordinates on a specified dungeon level
|
|
- Uses VFX_FNF_TELEPORT_OUT and VFX_FNF_TELEPORT_IN for visual effects
|
|
- Uses JumpToLocation() for the actual teleportation
|
|
- Notifies the caster of success or failure
|
|
|
|
## Notes on Implementation
|
|
- All spells use the existing PRC spell framework that's already in the project
|
|
- Spells follow the pattern of their reference spells but are adapted to match Wizardry mechanics
|
|
- All spells use SPApplyEffectToObject() for proper effect application with PRC framework
|
|
- All spells use CheckMetaMagic() for proper metamagic handling
|
|
- All spells include notification to the caster about the spell's effects
|
|
- Area effect spells use MyFirstObjectInShape() and MyNextObjectInShape() for proper targeting
|
|
- Condition removal spells use GetHasEffect() and RemoveEffect() to handle conditions
|
|
- Information spells use FloatingTextStringOnCreature() to display information
|
|
- Damage spells include spell resistance checks and appropriate saving throws
|
|
- Control spells check for immunities and apply appropriate effects
|
|
- Resurrection spells include chance of failure and appropriate consequences
|
|
- Teleportation spells include chance of mishap and appropriate consequences
|
|
|
|
## Future Improvements
|
|
- Add proper handling for darkness areas that terminate LOMILWA
|
|
- Implement proper interaction with other light/darkness spells
|
|
- Add proper immunity handling for creatures that should be immune to light effects
|
|
- Consider adding a special effect for when a secret door is revealed
|
|
- Add proper handling for undead targets in healing spells (should damage them)
|
|
- Add proper handling for fire-resistant creatures in damage spells
|
|
- Implement proper faction handling for group-targeting spells like MAHALITO
|
|
- Add proper handling for immunity to sleep and paralysis effects
|
|
- Improve the display of information for utility spells like DUMAPIC
|
|
- Create custom AOE scripts for spells like MADALTO to handle the custom damage calculations
|
|
- Implement proper teleport mishap handling for MALOR with more varied outcomes
|
|
- Add proper handling for resurrection failure consequences in DI and KADORTO
|