DCS func createInfraRed
From DCS World Wiki - Hoggitworld.com
Envrioment: | Mission Scripting | ||
Function: | createInfraRed | Added with: 1.2.0 | |
Member Of: | Spot | ||
Syntax: | Spot Object Spot.createInfraRed(Object Source , Vec3 localRef , Vec3 point , number laseCode) | ||
Description: | Creates a laser ray emanating from the given object to a point in 3d space.
localRef is technically an optional variable, however the functions format requires an entry to be made. If not used, simply replace with nil If optional variable laserCode is not present the beam will automatically be set to a IR beam. If laserCode is specified the beam is a laser which can be used to guide laser guided bombs. Laser code is any 4 digit number between 1111 and 1788.
| ||
Return Value: | Spot Object | ||
Return Example: | |||
Examples: | The following will create a laser emitting 1 meter above the jtac unit toward the targeted group. The laser code is 1337.
local jtac = Unit.getByName('jtacBob') local target = Unit.getByName('BMPAirDefenseSystemGroup1_unit1'):getPoint() local ray = Spot.createInfraRed(jtac, {x = 0, y = 1, z = 0}, target, 1337) | ||
Related Functions: | Spot Functions: createLaser. createInfraRed, destroy, getCategory, getPoint, setPoint, getCode, setCode | ||
Notes: |