CreateFlare
Appearance
| Environment: | Mission Scripting | |
|---|---|---|
| Function: | CreateFlare | |
| Function Description: | Creates a flare effect at a specified coordinate using a given color; if no color is provided, it defaults to white. The function converts the color input to lowercase and maps it to the corresponding flare color in the trigger system, with a fallback to white if the color is unrecognized. | |
| File Location: | cmm.MapCommandFunctions.lua | |
| Syntax: | CMM.CreateFlare( table coord , string color ) | |
| Return Value: | nil | |
| Parameters: | Name | Description |
| coord | The 3D position where the flare should be created. | |
| color | Optional color name for the flare effect; valid values are green, red, white, or yellow; defaults to white if not specified or invalid. | |
| Example: | CMM.CreateFlare({x=100,y=200,z=50}, "red") | |
| Example Description: | Creates a red flare at position {x=100,y=200,z=50} and logs the color value to the environment log. | |
| Related Functions: | ||
| Notes: | ||