Call of Duty 4: Scripting Reference - Client::BeginLocationSelection

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


BeginLocationSelection( <location selector>, <selector size> )

Module: Client

Summary:

Causes the player to begin selecting a location. A map HUD element should be visible for them to see where they're selecting. Works with endlocationselection(). When the user confirms or cancels, they will recieve a notify "confirm_location" or "cancel_location". The former notify contains the location they selected, as a vector.


Call this on: A Player

Example:

self BeginLocationSelection( "map_crosshair", 0.1); self waittill("confirm_location", loc );

Required arguments:

  1. <location selector> Name of the material to use as a cursor on the map. Must be precached with precacheLocationSelector()


Optional arguments:

  1. <selector size> The radius of the cursor material in world units. Cannot be larger than the entire south-to-north span of the minimap. If not specified, will be 15% of the south-to-north span of the minimap.


Notes:

none