home *** CD-ROM | disk | FTP | other *** search
/ Superpower (Alt) / SUPERPOWER.iso / q / patch / mbq705 / abomb2.qc < prev    next >
Encoding:
Text File  |  1996-08-06  |  901 b   |  24 lines

  1. void() W_SetCurrentAmmo;
  2. void() BecomeExplosion;
  3. void(entity inflictor, entity attacker, float damage, entity ignore) T_ABombDamage;
  4.  
  5. void() ABomb_Explode =
  6. {
  7.     if(other == self.owner)                         //Don't explode if
  8.         return;                                 //you touch it
  9.     bprint("it's the end of the world as we know it...\n");   //Tee Hee...
  10.     self.effects=14; // EF_MUZZLEFLASH && EF_BRIGHTLIGHT && EF_DIMLIGHT
  11.     T_ABombDamage(self, self.owner, 8000, world);
  12.  
  13.     sound (self, CHAN_WEAPON, "weapons/r_exp3.wav", 1, ATTN_NORM);
  14. //    self.origin = self.origin - 8*normalize(self.velocity);
  15.  
  16.     WriteByte (MSG_BROADCAST, SVC_TEMPENTITY);
  17.     WriteByte (MSG_BROADCAST, TE_EXPLOSION);
  18.     WriteCoord (MSG_BROADCAST, self.origin_x);
  19.     WriteCoord (MSG_BROADCAST, self.origin_y);
  20.     WriteCoord (MSG_BROADCAST, self.origin_z);
  21.  
  22.     BecomeExplosion ();             //And become an explosion
  23. };
  24.