#include "nw_i0_generic" #include "nw_i0_tool" string sDeny; void main() { object oPC = GetLastUsedBy(); if (!GetIsPC(oPC)) return; if (GetLocalInt(oPC, "MithrasBlood") == 1) return; //checks for bull's blood: if found, destroys if (GetItemPossessedBy(oPC, "it_BullsBlood")== OBJECT_INVALID) return; object oItem; oItem = GetItemPossessedBy(oPC, "it_BullsBlood"); DestroyObject(oItem); SetLocalInt(oPC, "MithrasBlood", 1); //checks if Mithras is his deity already if (GetDeity(oPC)== "Mithras") { sDeny="As the bull's blood washes over you, you feel empowered once more, defender of Mithras..."; SendMessageToPC(oPC, sDeny); GiveXPToCreature(oPC, 200); AdjustAlignment(oPC, ALIGNMENT_NEUTRAL, 5); AdjustAlignment(oPC, ALIGNMENT_EVIL, 5); return; } //checks that he has no previous faith if (GetDeity(oPC)!="") { sDeny="You are already an initiate of another faith. You cannot become a follower of Mithras until you reject your previous faith."; SendMessageToPC(oPC, sDeny); return; } //Makes him Mithras initiate FloatingTextStringOnCreature("You have been bathed in the blood of the bull, and are now an soldier of Mithras! Prepare to meet your first challenge!", oPC); CreateItemOnObject("mithrasshield", oPC); SetDeity (oPC, "Mithras"); AdjustAlignment(oPC, ALIGNMENT_EVIL, 25); AdjustAlignment(oPC, ALIGNMENT_NEUTRAL, 25); //applies whizz bang object oTarget; oTarget = oPC; //Visual effects can't be applied to waypoints, so if it is a WP //apply to the WP's location instead int nInt; nInt = GetObjectType(oTarget); if (nInt != OBJECT_TYPE_WAYPOINT) ApplyEffectToObject(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_FNF_SUNBEAM), oTarget); else ApplyEffectAtLocation(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_FNF_SUNBEAM), GetLocation(oTarget)); object oSpawn; location lTarget; oTarget = GetWaypointByTag("WP_DeathKnight"); lTarget = GetLocation(oTarget); oSpawn = CreateObject(OBJECT_TYPE_CREATURE, "deathknight01", lTarget); oTarget = oSpawn; SetIsTemporaryEnemy(oPC, oTarget); AssignCommand(oTarget, ActionAttack(oPC)); AssignCommand(oTarget, DetermineCombatRound(oPC)); //Visual effects can't be applied to waypoints, so if it is a WP //apply 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_CELESTIAL), oTarget)); else DelayCommand(0.5, ApplyEffectAtLocation(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_FNF_SUMMON_CELESTIAL), GetLocation(oTarget))); }