AR/getBanTime: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
(Created page with "__NOTOC__ {{Server function}} This function will return the time the specified ban was created, in '''seconds'''. ==Syntax== <syntaxhighlight lang="lua"> int getBanTime ( ban theBan ) </...")
 
No edit summary
 
(One intermediate revision by the same user not shown)
Line 1: Line 1:
__NOTOC__  
__NOTOC__  
{{Server function}}
{{Server function}}
This function will return the time the specified [[ban]] was created, in '''seconds'''.
هذه الوظيفة سـ ترجع للوقت الذي تم التبنيد فيه بالثواني


==Syntax==  
==Syntax==  
Line 9: Line 9:


===Required Arguments===  
===Required Arguments===  
*'''theBan:''' The [[ban]] in which you wish to retrieve the time of.
*'''theBan:''' الباند الذي ترغب ان تتحقق من وقته


===Returns===
===Returns===
Line 15: Line 15:
* Returns '''false''' if invalid arguments are specified if there was no banning time specified for the [[ban]].
* Returns '''false''' if invalid arguments are specified if there was no banning time specified for the [[ban]].


==Example==
==مثال==
<syntaxhighlight lang="lua">
<syntaxhighlight lang="lua">
function retrieveBan(theBan)
function retrieveBan(theBan)
Line 26: Line 26:


==See Also==
==See Also==
{{Admin functions}}
{{AR/Admin_functions}}
[[ru:getBanTime]]
[[ru:getBanTime]]

Latest revision as of 19:15, 1 September 2012

هذه الوظيفة سـ ترجع للوقت الذي تم التبنيد فيه بالثواني

Syntax

int getBanTime ( ban theBan )

Required Arguments

  • theBan: الباند الذي ترغب ان تتحقق من وقته

Returns

  • Returns an integer of the banning time in the format of seconds from the year 1970. Use in conjunction with getRealTime in order to retrieve detailed information.
  • Returns false if invalid arguments are specified if there was no banning time specified for the ban.

مثال

function retrieveBan(theBan)
    local ban = getBanTime(theBan)
    if ban then
        outputChatBox("The time of ban is: "..ban, getRootElement(), 255,255,255, true)
    end
end

See Also