Jump to content
Sign in to follow this  
mrkarp

Calling scripts from an addon

Recommended Posts

Hello, simple qeustion Google, and "search" has not been able to answer.

Say I have a mod installed, @example.

I have it loaded on the server with -mod=@example

Then in the missions init.sqf I have

call compile preProcessFile "\example\foldername\blah.sqf";

I continue to recieve errors that said script is not found.

Now I've seen many addons use this method of calling scripts located within the addon, such as DayZ, inidb, etc.

With DayZ its begins with "\z\addons\dayz_server\foldername\blah.sqf", but with inidb its "\inidb\blah.sqf" with out the addons part.

I have tried both methods with no avail.

Just confused on the syntax I am supposed to use.

Share this post


Link to post
Share on other sites

Try

 MYscript = compile preprocessFileLineNumbers "\@example\example\foldername\blah.sqf";

then call it with:

 call MYscript;

If I'm understanding you correctly this may work.

Edited by Mikey74

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×