Call of Duty 4: Scripting Reference - Objective::Target IsInCircle

From COD Modding & Mapping Wiki
Share/Save/Bookmark
Jump to: navigation, search


Target_IsInCircle( <target entity>, <player>, <fov>, <radius> )

Module: Objective
SP Only

Summary:

Returns whether a target is within a given radius from the center of the player's screen


Call this on:

Example:

level.player Target_IsInCircle( enemy_chopper, level.player, 65, 100 );

Required arguments:

  1. <target entity> The entity that is the target
  2. <player> The player entity
  3. <fov> The player's field of view
  4. <radius> radius of the circle, centered at the center of the screen


Optional arguments:

none


Notes:

none