//:://///////////////////////////////////////////// //:: Mummy Dust //:: X2_S2_MumDust //:: Copyright (c) 2001 Bioware Corp. //::////////////////////////////////////////////// /* Summons a strong warrior mummy for you to command. */ //::////////////////////////////////////////////// //:: Created By: Andrew Nobbs //:: Created On: Feb 07, 2003 //::////////////////////////////////////////////// #include "70_inc_spells" #include "x2_inc_spellhook" const float cDist = 5.0; const int cNumbersumm = 2; void main() { /* Spellcast Hook Code Added 2003-06-20 by Georg If you want to make changes to all spells, check x2_inc_spellhook.nss to find out more */ if (!X2PreSpellCastCode()) { // If code within the PreSpellCastHook (i.e. UMD) reports FALSE, do not run this spell return; } //Declare major variables spellsDeclareMajorVariables(); int nDuration = 24; //effect eVis = EffectVisualEffect(VFX_FNF_SUMMON_UNDEAD); //Summon the appropriate creature based on the summoner level //Warrior Mummy //If PC is a powerful pale master, ignore the fact that he has low caster level and summon the strongest mummy if ( GetLevelByClass(CLASS_TYPE_PALE_MASTER, OBJECT_SELF) > 19 ) { effect eSummon = EffectSummonCreature("NA_S_MUMMYDUST3",496,1.0); eSummon = ExtraordinaryEffect(eSummon); ApplyEffectAtLocation(DURATION_TYPE_TEMPORARY, eSummon, spell.Loc, HoursToSeconds(nDuration)); } else if (GetCasterLevel(OBJECT_SELF) >= 40) { effect eSummon = EffectSummonCreature("NA_S_MUMMYDUST3",496,1.0); if (GetLevelByClass(CLASS_TYPE_DRUID, OBJECT_SELF) > 20) eSummon = EffectSummonCreature("NA_S_TREANTDUST3",496,1.0); eSummon = ExtraordinaryEffect(eSummon); ApplyEffectAtLocation(DURATION_TYPE_TEMPORARY, eSummon, spell.Loc, HoursToSeconds(nDuration)); } else if (GetCasterLevel(OBJECT_SELF) >= 31) { effect eSummon = EffectSummonCreature("NA_S_MUMMYDUST2",496,1.0); if (GetLevelByClass(CLASS_TYPE_DRUID, OBJECT_SELF) > 20) eSummon = EffectSummonCreature("NA_S_TREANTDUST2",496,1.0); eSummon = ExtraordinaryEffect(eSummon); ApplyEffectAtLocation(DURATION_TYPE_TEMPORARY, eSummon, spell.Loc, HoursToSeconds(nDuration)); } else { effect eSummon = EffectSummonCreature("NA_S_MUMMYDUST1",496,1.0); if (GetLevelByClass(CLASS_TYPE_DRUID, OBJECT_SELF) > 20) eSummon = EffectSummonCreature("NA_S_TREANTDUST1",496,1.0); eSummon = ExtraordinaryEffect(eSummon); ApplyEffectAtLocation(DURATION_TYPE_TEMPORARY, eSummon, spell.Loc, HoursToSeconds(nDuration)); } }