setMarkerIcon
Client-side
Server-side
Shared
Pair: getMarkerIcon
Manual Review Required
Please finish this page using the corresponding Old Wiki article. Go to Contribution guidelines for more information.
This function allows changing the icon of a checkpoint marker.
OOP Syntax Help! I don't understand this!
- Method:marker:setIcon(...)
- Variable: .icon
Syntax
bool setMarkerIcon ( marker theMarker, string icon )Required Arguments
- theMarker: The marker to change the visual style of
- icon: A string referring to the type of icon, acceptable values are: "none" : No icon "arrow" : Arrow icon. Only 5 arrows can be visible at the same time. "finish" : Finish icon (at end of race)
Returns
- bool: value
Code Examples
shared
This example creates a finish marker as you'd expect for the end of a race.
local newMarker = createMarker ( 0, 0, 2, "checkpoint", 1, 255, 0, 0)setMarkerIcon ( newMarker, "finish" )