Difference between revisions of "OnHitWith"

From the Fallout3 GECK Wiki
Jump to navigation Jump to search
imported>Jokerine
(Filled in missing info.)
imported>Jokerine
m (typo'd)
 
(One intermediate revision by the same user not shown)
Line 12: Line 12:
=='''Examples'''==
=='''Examples'''==


   begin OnHitWith
   begin OnHitWith '';makes the calling actor play an animation, like the targets at the beginning of Fallout 3''
    Player.Additem Caps001 10
  if isAnimPlaying == 0 
  end
  PlayGroup Forward 1
  endif
end


   begin OnHitWith WeapPowerFist
   begin OnHitWith WeapPowerFist '';removes caps when the calling actor is hit''
     Player.Removeitem Caps001 10
     Player.Removeitem Caps001 10
   end
   end

Latest revision as of 15:52, 10 December 2015

Link to TES4 Construction Set Wiki: OnHitWith.


Description[edit | edit source]

This block will run when the scripted target is hit by a weapon. If the parameter is left blank, a hit with any weapon will make it run.

Syntax[edit | edit source]

Begin OnHitWith WeaponID

Examples[edit | edit source]

 begin OnHitWith ;makes the calling actor play an animation, like the targets at the beginning of Fallout 3
  if isAnimPlaying == 0  
  PlayGroup Forward 1 
  endif
end
 begin OnHitWith WeapPowerFist ;removes caps when the calling actor is hit
    	Player.Removeitem Caps001 10
 end

See Also[edit | edit source]

Notes[edit | edit source]

  • Formlists may be passed as a parameter.