Difference between revisions of "ObjectUnderReticle"
Jump to navigation
Jump to search
more type safety...
imported>JT m (converted from set to let since the example was NVSE only, but forgot to convert the "to" as well... heh) |
imported>JT (more type safety...) |
||
Line 23: | Line 23: | ||
let target := ObjectUnderReticle 0 2048 ;Check for object within 30 m/96 ft | let target := ObjectUnderReticle 0 2048 ;Check for object within 30 m/96 ft | ||
if ( GetType target == 42 || GetType target == 43 ) | if ( target && IsFormValid target && ( GetType target == 42 || GetType target == 43 ) ) | ||
;We have an actor under the crosshairs! | ;We have an actor under the crosshairs! | ||
target.Kill PlayerRef ;player kills target using cosmic mind rays | target.Kill PlayerRef ;player kills target using cosmic mind rays |