Jump to content

Export functions


Gtagasje

Recommended Posts

Hi,

I saw "export function" a while ago in a script, and I don't know what this is. So I got some questions about it.

1. What do exported functions do?

2. Are exported functions helpfull in scripts like police/clan systems?

3. How do you export a function?

I hope these can be answered, because I really dont know what exported functions are.

Thanks in advance.

Gtagasje.

Link to comment

exported function is a function (that exists in resource's code) that was exported in resource's meta.xml like this:

<export function="functionName" type="server" />  

type can be "server" or "client".

other resources can call an exported function by using call function.

function will be executed in its own resource and (can) return data to the resource that called it.

you can read all about it in call wiki page.

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...