IsRadarAreaFlashing: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
No edit summary
 
(Added OOP pair)
 
(10 intermediate revisions by 6 users not shown)
Line 1: Line 1:
[[Category:Incomplete]]
{{Server client function}}
 
__NOTOC__
__NOTOC__  
This function allows detection of whether a radar area is flashing or not.
This fake function is for use with blah & blah and does blahblahblabhalbhl


==Syntax==  
==Syntax==  
<syntaxhighlight lang="lua">
<syntaxhighlight lang="lua">
bool isRadarAreaFlashing ( radararea radararea )               
bool isRadarAreaFlashing ( radararea theRadararea )               
</syntaxhighlight>  
</syntaxhighlight>  
{{OOP||[[radararea]]:isFlashing|flashing|setRadarAreaFlashing}}


===Required Arguments===  
===Required Arguments===  
*'''argumentName:''' description
*'''theRadararea:''' The radar area you wish to check the state of flashing
 
===Optional Arguments===
{{OptionalArg}}
*'''argumentName2:''' descriptiona
*'''argumentName3:''' description


===Returns===
===Returns===
Returns ''true'' if blah, ''false'' otherwise.
Returns ''true'' if the radar area is flashing, ''false'' if it is not or if it doesn't exist.


==Example==  
==Example==  
This example does...
This example checks whether the radar area in the variable ''glenpark'' is flashing, and announces it if it is.
<syntaxhighlight lang="lua">
<syntaxhighlight lang="lua">
--This line does...
function checkArea(sourcePlayer)
blabhalbalhb --abababa
    if ( isRadarAreaFlashing ( glenpark ) ) then          -- if the radar area in the variable glenpark is flashing
--This line does this...
        outputChatBox ( "Glen Park is under attack!!!" )  -- announce it
mooo
    end
end
addCommandHandler("checkArea", checkArea)
</syntaxhighlight>
</syntaxhighlight>


==See Also==
==See Also==
{{FunctionArea_Functions}}
{{Radar area functions}}

Latest revision as of 17:38, 26 November 2014

This function allows detection of whether a radar area is flashing or not.

Syntax

bool isRadarAreaFlashing ( radararea theRadararea )               

OOP Syntax Help! I don't understand this!

Method: radararea:isFlashing(...)
Variable: .flashing
Counterpart: setRadarAreaFlashing


Required Arguments

  • theRadararea: The radar area you wish to check the state of flashing

Returns

Returns true if the radar area is flashing, false if it is not or if it doesn't exist.

Example

This example checks whether the radar area in the variable glenpark is flashing, and announces it if it is.

function checkArea(sourcePlayer)
    if ( isRadarAreaFlashing ( glenpark ) ) then          -- if the radar area in the variable glenpark is flashing
        outputChatBox ( "Glen Park is under attack!!!" )  -- announce it
    end
end
addCommandHandler("checkArea", checkArea)

See Also