getResourceInfo | Multi Theft Auto: Wiki Skip to content

getResourceInfo

Client-side
Server-side
Shared

This page is incomplete! Help wanted!

Please finish this page using the corresponding Old Wiki article.
Go to Contribution guidelines for more information.


This function retrieves the value of any attribute in a resource info tag.

Syntax

getResourceInfo ( )

Code Examples

server

This function tells the server who's the author who made the currently running resource.

function outputAuthor()
author = getResourceInfo ( getThisResource(), "author" ) --Get the authors name
if author then --if it exists
outputChatBox( author .. " made this script." ) --tell the world his name
else --if it doesn't
outputChatBox( "I've no idea who made this script." ) --apologize.
end
end