Lankhmar_PRC8/_module/nss/cnv_spn_gldmg.nss

28 lines
687 B
Plaintext
Raw Permalink Normal View History

2025-04-03 12:54:47 -04:00
void main()
{
object oTarget;
object oSpawn;
location lTarget;
int nInt;
object oPC = GetPCSpeaker();
oTarget = oPC;
lTarget = GetLocation(oTarget);
oSpawn = CreateObject(OBJECT_TYPE_CREATURE, "guildmage", lTarget);
oTarget = 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
nInt = GetObjectType(oTarget);
if (nInt != OBJECT_TYPE_WAYPOINT) DelayCommand(0.5, ApplyEffectToObject(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_FNF_SUMMON_MONSTER_1), oTarget));
else DelayCommand(0.5, ApplyEffectAtLocation(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_FNF_SUMMON_MONSTER_1), GetLocation(oTarget)));
}