Lankhmar_PRC8/_module/nss/ent_spn_fbts.nss
Jaysyn904 ebc0c6a9b2 Initial commit
Initial commit [v9.7]
2025-04-03 12:54:47 -04:00

90 lines
3.6 KiB
Plaintext

#include "nw_i0_generic"
void main()
{
object oSpawn;
effect eVFX;
object oTarget;
// Get the creature who triggered this event.
object oPC = GetEnteringObject();
// Only fire for (real) PCs.
if ( !GetIsPC(oPC) || GetIsDMPossessed(oPC) )
return;
// Abort if the PC does not have the item "fangsofmog".
if ( GetItemPossessedBy(oPC, "fangsofmog") == OBJECT_INVALID )
return;
// Spawn some critters.
eVFX = EffectVisualEffect(467);
oSpawn = CreateObject(OBJECT_TYPE_CREATURE, "firebat", GetLocation(oPC));
AssignCommand(oSpawn, DetermineCombatRound(oPC));
DelayCommand(2.5, ApplyEffectToObject(DURATION_TYPE_INSTANT, eVFX, oSpawn));
oSpawn = CreateObject(OBJECT_TYPE_CREATURE, "firebat", GetLocation(oPC));
AssignCommand(oSpawn, DetermineCombatRound(oPC));
DelayCommand(2.5, ApplyEffectToObject(DURATION_TYPE_INSTANT, eVFX, oSpawn));
oSpawn = CreateObject(OBJECT_TYPE_CREATURE, "firebat", GetLocation(oPC));
AssignCommand(oSpawn, DetermineCombatRound(oPC));
DelayCommand(2.5, ApplyEffectToObject(DURATION_TYPE_INSTANT, eVFX, oSpawn));
oSpawn = CreateObject(OBJECT_TYPE_CREATURE, "firebat", GetLocation(oPC));
AssignCommand(oSpawn, DetermineCombatRound(oPC));
DelayCommand(2.5, ApplyEffectToObject(DURATION_TYPE_INSTANT, eVFX, oSpawn));
oSpawn = CreateObject(OBJECT_TYPE_CREATURE, "firebat", GetLocation(oPC));
AssignCommand(oSpawn, DetermineCombatRound(oPC));
DelayCommand(2.5, ApplyEffectToObject(DURATION_TYPE_INSTANT, eVFX, oSpawn));
oSpawn = CreateObject(OBJECT_TYPE_CREATURE, "firebat", GetLocation(oPC));
AssignCommand(oSpawn, DetermineCombatRound(oPC));
DelayCommand(2.5, ApplyEffectToObject(DURATION_TYPE_INSTANT, eVFX, oSpawn));
oSpawn = CreateObject(OBJECT_TYPE_CREATURE, "firebat", GetLocation(oPC));
AssignCommand(oSpawn, DetermineCombatRound(oPC));
DelayCommand(2.5, ApplyEffectToObject(DURATION_TYPE_INSTANT, eVFX, oSpawn));
oSpawn = CreateObject(OBJECT_TYPE_CREATURE, "firebat", GetLocation(oPC));
AssignCommand(oSpawn, DetermineCombatRound(oPC));
DelayCommand(2.5, ApplyEffectToObject(DURATION_TYPE_INSTANT, eVFX, oSpawn));
oSpawn = CreateObject(OBJECT_TYPE_CREATURE, "firebat", GetLocation(oPC));
AssignCommand(oSpawn, DetermineCombatRound(oPC));
DelayCommand(2.5, ApplyEffectToObject(DURATION_TYPE_INSTANT, eVFX, oSpawn));
oSpawn = CreateObject(OBJECT_TYPE_CREATURE, "firebat", GetLocation(oPC));
AssignCommand(oSpawn, DetermineCombatRound(oPC));
DelayCommand(2.5, ApplyEffectToObject(DURATION_TYPE_INSTANT, eVFX, oSpawn));
oSpawn = CreateObject(OBJECT_TYPE_CREATURE, "firebat", GetLocation(oPC));
AssignCommand(oSpawn, DetermineCombatRound(oPC));
DelayCommand(2.5, ApplyEffectToObject(DURATION_TYPE_INSTANT, eVFX, oSpawn));
oSpawn = CreateObject(OBJECT_TYPE_CREATURE, "firebat", GetLocation(oPC));
AssignCommand(oSpawn, DetermineCombatRound(oPC));
DelayCommand(2.5, ApplyEffectToObject(DURATION_TYPE_INSTANT, eVFX, oSpawn));
oSpawn = CreateObject(OBJECT_TYPE_CREATURE, "firebat", GetLocation(oPC));
AssignCommand(oSpawn, DetermineCombatRound(oPC));
DelayCommand(2.5, ApplyEffectToObject(DURATION_TYPE_INSTANT, eVFX, oSpawn));
//Visual effects can't be applied to waypoints, so if it is a WP
//the VFX will be applied to the WP's location instead
int nInt;
nInt = GetObjectType(oTarget);
if (nInt != OBJECT_TYPE_WAYPOINT) ApplyEffectToObject(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_FNF_FIRESTORM), oTarget);
else ApplyEffectAtLocation(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_FNF_FIRESTORM), GetLocation(oTarget));
DelayCommand(3.5, DestroyObject(OBJECT_SELF));
}