home *** CD-ROM | disk | FTP | other *** search
/ Revista CD Expert 42 / CDGAMER42.iso / Egoboo / egoboo.exe / egoboo / modules / advent.mod / objects / torch.obj / script.txt < prev    next >
Text File  |  1999-10-16  |  1KB  |  50 lines

  1. // ZZ> This function makes an item fall to the floor when spawned
  2. IfSpawned                //
  3.   tmpargument = ACTIONJB          //
  4.   DoAction                  //
  5.   KeepAction                  //
  6.   MakeCrushValid
  7. IfCrushed
  8.   tmpx = selfx
  9.   tmpy = selfy
  10.   tmpdistance = selfz
  11.   tmpargument = 5
  12.   SpawnExactParticle
  13.   SpawnExactParticle
  14.   SpawnExactParticle
  15.   SpawnExactParticle
  16.   GoPoof
  17.   tmpargument = 1
  18.   SendMessageNear
  19. IfDisaffirmed
  20.   tmpargument = 2
  21.   SendMessageNear
  22. IfDropped                // Make it lie on floor
  23.   KeepAction                  //
  24. IfHitGround                // Make a sound
  25.   tmpargument = 0              //
  26.   tmpdistance = rand & 2047 + 10000      //
  27.   PlaySound                  //
  28. IfUsed                    // Spawn damage particle
  29.   tmpx = selfattached              //
  30.   tmpy = 0                  //
  31.   tmpargument = 0              //
  32.   IfXIsMoreThanY              // Is the flame still there?
  33.     tmpargument = 1                // Yes
  34.   tmpdistance = SPAWNLAST          // Model vertex to attach to
  35.   SpawnAttachedParticle              //
  36. IfGrabbed                // Tell them what they've won...
  37.   SetTargetToWhoeverIsHolding          //
  38.     tmpargument = [XFIR]            // Burn hands...
  39.     IfTargetHasAnyID
  40.       tmpargument = 3
  41.       SendMessageNear
  42.       DetachFromHolder
  43.       tmpargument = 256
  44.       DamageTarget
  45.     Else
  46.       IfTargetIsAPlayer
  47.         tmpargument = 0
  48.         SendMessageNear
  49. End                    // All done
  50.