From Eternity Wiki
Jump to: navigation, search

JumpIfTargetInLOS(statenum, fov, proj_target)

This function can be called from a map object or player weapon frame.

  • If called from the player weapon, it will check if there is an autoaim target in sight (in the crosshair). If there is one, the player weapon frame will jump to statenum. The other two arguments aren't used.
  • For map objects (monsters, projectiles etc.), it will check if their current target is within sight and jump to statenum if so.
fov specifies the total horizontal angle spread that the target may be seen in. If it's 0, it will be solely checked based on regular sight checks. In any case, specific details such as reject map test must pass.
proj_target is useful only for seeker missiles. If nonzero, the calling object will check if its homing destination is in sight, not the originator.