home *** CD-ROM | disk | FTP | other *** search
/ Revista CD Expert 42 / CDGAMER42.iso / Egoboo / egoboo.exe / egoboo / modules / healer.mod / objects / blob.obj / script.txt < prev    next >
Text File  |  2000-05-26  |  2KB  |  78 lines

  1. //------------------------------------------------------------------------------
  2. // ZZ> Set up basic things
  3. IfSpawned
  4.   SetTurnModeToSpin
  5.   tmpx = selfx
  6.   tmpy = selfy
  7.   tmpargument = 0
  8.   SetXY
  9.  
  10.  
  11. //------------------------------------------------------------------------------
  12. // ZZ> Handle being bumped by absorbing self into bumper ( if on other team )
  13. IfStateIs0
  14.   IfBumped
  15.     SetTargetToWhoeverBumped
  16.     IfTargetIsOnHatedTeam
  17.       // Send a death message
  18.       tmpargument = MESSAGEDEATH
  19.       SendMessageNear
  20.  
  21.  
  22.       // Do some damage
  23.       tmpargument = rand & 1023 + 2560 // 10 - 15
  24.       DamageTarget
  25.  
  26.  
  27.       // Play the absorb sound
  28.       tmpargument = 0
  29.       tmpdistance = rand & 2047 + 10000
  30.       PlaySound
  31.  
  32.  
  33.       // Play the death animation ( blob poofs at end of action... )
  34.       tmpargument = ACTIONKA
  35.       DoActionOverride
  36.  
  37.  
  38.       // Make sure it doesn't absorb twice
  39.       tmpargument = 1
  40.       SetState
  41.  
  42.  
  43.       // Give some experience as a consolation prize...
  44.       tmpargument = 10
  45.       tmpdistance = EXPSECRET
  46.       GiveExperienceToTarget
  47.  
  48.  
  49. //------------------------------------------------------------------------------
  50. IfTimeOut
  51.   tmpargument = rand & 15 + 20
  52.   SetTime
  53.  
  54.   // Move around
  55.   tmpargument = 0
  56.   GetXY
  57.   tmpx = rand & 512 + selfspawnx - 256 + tmpx > 1
  58.   tmpy = rand & 512 + selfspawny - 256 + tmpy > 1
  59.   ClearWaypoints
  60.   AddWaypoint
  61.   tmpargument = 0
  62.   SetXY
  63.  
  64.  
  65.   // Play the random sound
  66.   tmpx = rand & 255
  67.   tmpy = 100
  68.   IfXIsLessThanY
  69.     tmpargument = 1
  70.     tmpdistance = rand & 2047 + 10000
  71.     PlaySound
  72.  
  73.  
  74.  
  75. //------------------------------------------------------------------------------
  76. End
  77. //------------------------------------------------------------------------------
  78.