GetResourceLoadFailureReason: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 5: Line 5:
==Syntax==  
==Syntax==  
<syntaxhighlight lang="lua">
<syntaxhighlight lang="lua">
string getResourceLoadFailureReason ( resource )
string getResourceLoadFailureReason ( resource theResource )
</syntaxhighlight>  
</syntaxhighlight>  


===Required Arguments===  
===Required Arguments===  
*'''resource:''' The resource you wish to check.
*'''theResource:''' The resource you wish to check.


===Returns===
===Returns===
Line 15: Line 15:


==Example==  
==Example==  
<!-- Explain what the example is in a single sentance -->
<section name="Server" class="Server" show="true">
This example does...
<!-- Add the code below, an emphasis should be on making it clear, not optimized. You could provide two versions if you wish, one clear and well commented, the other optimized -->
<syntaxhighlight lang="lua">
<syntaxhighlight lang="lua">
--This line does...
-- Add example..
blabhalbalhb --abababa
--This line does this...
mooo
</syntaxhighlight>
</syntaxhighlight>
</section>


==See Also==
==See Also==
{{Resource functions}}
{{Resource functions}}
[[Category:Incomplete]]

Revision as of 12:56, 13 June 2009

This function retrieves the reason why a resource failed to start.

Syntax

string getResourceLoadFailureReason ( resource theResource )

Required Arguments

  • theResource: The resource you wish to check.

Returns

If the resource failed to load, returns a string with the failure reason in it. If it loaded successfully, returns an empty string. Returns false if the resource doesn't exist.

Example

Click to collapse [-]
Server
-- Add example..

See Also