VR-Forces 5.2 Lua Function Documentation

taskVisualizationUtil

(For high level concepts about how to use Lua to write scripted tasks, please see VR-Forces User's Guide.)

Utilities that make using some common task visualization functions easier.

Usage:


 vis = require "taskVisualizationUtil"  
vis.visualizeTask("moveRoute", "line", pointList, vis.BLUE, 4)

Function List

cleanupVisualizations () Deletes all visualizations that have been created with visualizeTask()
visualizeTask (sName, sGeometryType, aPoints, aColor, nSize) Wraps vrf:updateTaskVisualization.

Table List

BLUE RGBA = {0,0,255,175}
CORNFLOWER RGBA = {0,191,255,175}
GOLD RGBA = {255,223,0,175}
GREEN RGBA = {0,128,0,175}
ORANGE RGBA = {243, 147, 26, 175}
PINK RGBA = {255,20,147,175}
RED RGBA = {255,0,0,175}


Functions

cleanupVisualizations ()
Deletes all visualizations that have been created with visualizeTask()
visualizeTask (sName, sGeometryType, aPoints, aColor, nSize)
Wraps vrf:updateTaskVisualization.

Parameters:

  • sName: string name for the visualization. Each visualization graphic shoud have a different name.
  • sGeometryType: "point", "line", or "area".
  • aPoints: either Location3D or table of Location3Ds
  • aColor: table of 4 integers RGBA. Can use the color tables defined in this module.
  • nSize: integer. Sets the thickness of a line, or the diameter of a point ball.

Tables

BLUE
RGBA = {0,0,255,175}

CORNFLOWER
RGBA = {0,191,255,175}

GOLD
RGBA = {255,223,0,175}

GREEN
RGBA = {0,128,0,175}

ORANGE
RGBA = {243, 147, 26, 175}

PINK
RGBA = {255,20,147,175}

RED
RGBA = {255,0,0,175}

Copyright© 2025 MAK Technologies, Inc. All rights reserved.