GetMarkerIcon: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
(OOP) |
||
(3 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
__NOTOC__ | __NOTOC__ | ||
This function returns the icon | {{Server client function}} | ||
This function returns the icon name for a marker. | |||
==Syntax== | ==Syntax== | ||
<syntaxhighlight lang="lua"> | <syntaxhighlight lang="lua">string getMarkerIcon ( marker theMarker )</syntaxhighlight> | ||
{{OOP||[[Marker]]:getIcon|icon|setMarkerIcon}} | |||
===Required Arguments=== | ===Required Arguments=== | ||
* '''theMarker''': A [[marker]] element referencing the specified marker. | * '''theMarker''': A [[marker]] element referencing the specified marker. | ||
Line 10: | Line 11: | ||
===Returns=== | ===Returns=== | ||
Returns ''false'' if the marker passed is invalid or a string containing one of the following: | Returns ''false'' if the marker passed is invalid or a string containing one of the following: | ||
* ''' | * '''"none"''': No icon | ||
* ''' | * '''"arrow"''': Arrow icon | ||
* ''' | * '''"finish"''': Finish (end-race) icon | ||
==Example== | ==Example== | ||
<syntaxhighlight lang="lua"> | <syntaxhighlight lang="lua"> | ||
icon = getMarkerIcon ( | newmarker = createMarker ( 1000, 1000,1000, "checkpoint", 255, 0, 0 ) | ||
outputChatBox ( "marker | icon = getMarkerIcon ( newmarker ) | ||
outputChatBox ( "The default marker icon is " .. icon ) | |||
</syntaxhighlight> | </syntaxhighlight> | ||
==See Also== | ==See Also== | ||
{{Marker functions}} | {{Marker functions}} |
Latest revision as of 01:50, 13 December 2014
This function returns the icon name for a marker.
Syntax
string getMarkerIcon ( marker theMarker )
OOP Syntax Help! I don't understand this!
- Method: Marker:getIcon(...)
- Variable: .icon
- Counterpart: setMarkerIcon
Required Arguments
- theMarker: A marker element referencing the specified marker.
Returns
Returns false if the marker passed is invalid or a string containing one of the following:
- "none": No icon
- "arrow": Arrow icon
- "finish": Finish (end-race) icon
Example
newmarker = createMarker ( 1000, 1000,1000, "checkpoint", 255, 0, 0 ) icon = getMarkerIcon ( newmarker ) outputChatBox ( "The default marker icon is " .. icon )
See Also
- createMarker
- getMarkerColor
- getMarkerCount
- getMarkerIcon
- getMarkerSize
- getMarkerTarget
- getMarkerType
- setMarkerColor
- setMarkerIcon
- setMarkerSize
- setMarkerTarget
- setMarkerType
- isElementWithinMarker