ProcessTrapHit - ObjectReference: Difference between revisions

Jump to navigation Jump to search
m
Convert source tags to syntaxhighlight
imported>Jlundin
No edit summary
 
m (Convert source tags to syntaxhighlight)
 
Line 6: Line 6:


== Syntax ==
== Syntax ==
<source lang="papyrus">
<syntaxhighlight lang="papyrus">
Function ProcessTrapHit(ObjectReference akTrap, float afDamage, float afPushback, float afXVel, float afYVel, /
Function ProcessTrapHit(ObjectReference akTrap, float afDamage, float afPushback, float afXVel, float afYVel, /
   float afZVel, float afXPos, float afYPos, float afZPos, int aeMaterial, float afStagger) native
   float afZVel, float afXPos, float afYPos, float afZPos, int aeMaterial, float afStagger) native
</source>
</syntaxhighlight>


== Parameters ==
== Parameters ==
Line 28: Line 28:


== Examples ==
== Examples ==
<source lang="papyrus">
<syntaxhighlight lang="papyrus">
; Process a trap hit on the player with just a little bit of damage, and no pushback or stagger, with a position
; Process a trap hit on the player with just a little bit of damage, and no pushback or stagger, with a position
; velocity, and material from somewhere else (probably OnTrapHit)
; velocity, and material from somewhere else (probably OnTrapHit)
Game.GetPlayer().ProcessTrapHit(SpikeTrap, 1.0, 0.0, xvel, yvel, zvel, xpos, ypos, zpos, material, 0.0)
Game.GetPlayer().ProcessTrapHit(SpikeTrap, 1.0, 0.0, xvel, yvel, zvel, xpos, ypos, zpos, material, 0.0)
</source>
</syntaxhighlight>


== See Also ==
== See Also ==
*[[ObjectReference Script]]
*[[ObjectReference Script]]
*[[OnTrapHit - ObjectReference]]
*[[OnTrapHit - ObjectReference]]

Navigation menu