CreateSearchLight: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
m (Added Template:OptionalArg)
m (Corrected "See also" section template)
Line 32: Line 32:


==See also==
==See also==
{{Client_world_functions}}
{{Client_searchlight_functions}}

Revision as of 17:52, 8 December 2015

This function creates a searchlight. A searchlight a spotlight which looks like the one available in the Police Maverick.

Syntax

searchlight createSearchLight ( float startX, float startY, float startZ, float endX, float endY, float endZ, float startRadius, float endRadius [, bool renderSpot = true ] )

OOP Syntax Help! I don't understand this!

Method: SearchLight.create(...)


Required Arguments

  • startX: the X coordinate where the searchlight light cone will start.
  • startY: the Y coordinate where the searchlight light cone will start.
  • startZ: the Z coordinate where the searchlight light cone will start.
  • endX: the X coordinate of the direction where the searchlight will point to.
  • endY: the Y coordinate of the direction where the searchlight will point to.
  • endZ: the Z coordinate of the direction where the searchlight will point to.
  • startRadius: the radius of the searchlight's light cone in its beginning.
  • endRadius: the radius of the searchlight's light cone in its end.

Optional Arguments

NOTE: When using optional arguments, you might need to supply all arguments before the one you wish to use. For more information on optional arguments, see optional arguments.

  • renderSpot: if true, the searchlight will lighten the surface where it ends.

Returns

If every argument is correct, this function returns a searchlight element. Otherwise, it returns false.

Example

-- TODO

See also