home *** CD-ROM | disk | FTP | other *** search
/ PC Zone 125 / DPPCZ0203B.7z / DPPCZ0203B.ISO / Demos / Neverwinter / data1.cab / override / nw_s1_wingblast.nss < prev    next >
Text File  |  2002-09-10  |  2KB  |  56 lines

  1. //::///////////////////////////////////////////////
  2. //:: Dragon Wing Buffet
  3. //:: NW_S1_WingBlast
  4. //:: Copyright (c) 2001 Bioware Corp.
  5. //:://////////////////////////////////////////////
  6. /*
  7.     The dragon will launch into the air, knockdown
  8.     all opponents who fail a Reflex Save and then
  9.     land on one of those opponents doing damage
  10.     up to a maximum of the Dragons HD + 10.
  11. */
  12. //:://////////////////////////////////////////////
  13. //:: Created By: Preston Watamaniuk
  14. //:: Created On: Feb 4, 2002
  15. //:://////////////////////////////////////////////
  16.  
  17. void main()
  18. {
  19.     //Declare major variables
  20.     effect eAppear;
  21.     effect eKnockDown = EffectKnockdown();
  22.     int nHP;
  23.     int nCurrent = 0;
  24.     object oVict;
  25.     int nDamage = GetHitDice(OBJECT_SELF);
  26.     int nDC = nDamage;
  27.     nDamage = Random(nDamage) + 11;
  28.     effect eDam = EffectDamage(nDamage, DAMAGE_TYPE_BLUDGEONING);
  29.     effect eVis = EffectVisualEffect(VFX_IMP_PULSE_WIND);
  30.     ApplyEffectToObject(DURATION_TYPE_INSTANT, eVis, OBJECT_SELF);
  31.     //Get first target in spell area
  32.     object oTarget = GetFirstObjectInShape(SHAPE_SPHERE, RADIUS_SIZE_GARGANTUAN, GetLocation(OBJECT_SELF));
  33.     while(GetIsObjectValid(oTarget))
  34.     {
  35.         if(!GetIsReactionTypeFriendly(oTarget))
  36.         {
  37.                 if(GetCreatureSize(oTarget) != CREATURE_SIZE_HUGE)
  38.                 {
  39.                     if(!ReflexSave(oTarget, nDC))
  40.                     {
  41.                         ApplyEffectToObject(DURATION_TYPE_INSTANT, eDam, oTarget);
  42.                         ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eKnockDown, oTarget, 6.0);
  43.                     }
  44.                 }
  45.             //Get next target in spell area
  46.             oTarget = GetNextObjectInShape(SHAPE_SPHERE, RADIUS_SIZE_GARGANTUAN, GetLocation(OBJECT_SELF));
  47.         }
  48.     }
  49.     location lLocal;
  50.     lLocal = GetLocation(OBJECT_SELF);
  51.     //Apply the VFX impact and effects
  52.     eAppear = EffectDisappearAppear(lLocal);
  53.     ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eAppear, OBJECT_SELF, 6.0);
  54.  
  55. }
  56.