#include "ah_penta_inc" void main() { object oPC=GetLastUsedBy(); // Inspect local variables if((GetLocalInt(oPC, "ah_GotBlood") == 1)) { ActionDoCommand(ApplyEffectToObject(DURATION_TYPE_INSTANT,EffectVisualEffect(VFX_COM_BLOOD_REG_RED),OBJECT_SELF)); ActionDoCommand(ApplyEffectToObject(DURATION_TYPE_INSTANT,EffectVisualEffect(VFX_COM_BLOOD_LRG_RED),OBJECT_SELF)); } else { int nCurrentHour = (GetCalendarYear()-1)*12*28*24 + (GetCalendarMonth()-1)*28*24 + (GetCalendarDay()-1)*24 + GetTimeHour(); int nLastSpawnHour = GetLocalInt(OBJECT_SELF,"LAST_SPAWN_HOUR"); int nSpawnDelay = 1; if (nCurrentHour > (nLastSpawnHour + nSpawnDelay)) { SetLocalInt(OBJECT_SELF,"NW_DO_ONCE",0); } //return if time has not passed yet if (GetLocalInt(OBJECT_SELF,"NW_DO_ONCE") != 0) { ActionDoCommand(ApplyEffectToObject(DURATION_TYPE_INSTANT,EffectVisualEffect(VFX_COM_BLOOD_REG_RED),OBJECT_SELF)); ActionDoCommand(ApplyEffectToObject(DURATION_TYPE_INSTANT,EffectVisualEffect(VFX_COM_BLOOD_LRG_RED),OBJECT_SELF)); return; } location loc = GetLocation(OBJECT_SELF); pentagram(loc); ActionSpeakString("The time of her coming is nigh; the blood of the innocent spilled, drunk. She will rise once more and such terror will be unleashed in her wake.."); ActionDoCommand(ApplyEffectToObject(DURATION_TYPE_TEMPORARY,EffectVisualEffect(VFX_COM_BLOOD_REG_RED),OBJECT_SELF)); ActionDoCommand(ApplyEffectToObject(DURATION_TYPE_INSTANT,EffectVisualEffect(VFX_FNF_SCREEN_SHAKE),OBJECT_SELF)); ActionDoCommand(ApplyEffectToObject(DURATION_TYPE_INSTANT,EffectVisualEffect(VFX_IMP_HEAD_EVIL),OBJECT_SELF)); // Set the variable to say that the PC has blood in their hands SetLocalInt(oPC, "ah_GotBlood", 1); SetLocalInt(OBJECT_SELF,"NW_DO_ONCE",1); SetLocalInt(OBJECT_SELF,"LAST_SPAWN_HOUR",nCurrentHour); } }