FindClosestReferenceOfType - Game: 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">
ObjectReference Function FindClosestReferenceOfType(Form arBaseObject, float afX, float afY, float afZ, float afRadius) native global
ObjectReference Function FindClosestReferenceOfType(Form arBaseObject, float afX, float afY, float afZ, float afRadius) native global
</source>
</syntaxhighlight>


== Parameters ==
== Parameters ==
Line 21: Line 21:


== Examples ==
== Examples ==
<source lang="papyrus">
<syntaxhighlight lang="papyrus">
; Find the closest diamond reference to 0,0,0, limiting the search to 5 units
; Find the closest diamond reference to 0,0,0, limiting the search to 5 units
ObjectReference closestDiamond = Game.FindClosestReferenceOfType(Diamond, 0.0, 0.0, 0.0, 5.0)
ObjectReference closestDiamond = Game.FindClosestReferenceOfType(Diamond, 0.0, 0.0, 0.0, 5.0)
</source>
</syntaxhighlight>


== See Also ==
== See Also ==

Navigation menu