Jump to content
Sign in to follow this  
Mongoose_84

using an entire array as a single parameter

Recommended Posts

i tried this without any success.

executing a script:

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">

[x, y , [z1 ,z2, ...]] execVM 'script.sqf';

(i want the number of elements in z to be variable)

in the script:

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">

_x = _this select 0;

_y = _this select 1;

_z = _this select 2;

but passing on an array like this doesn't work the way i expected. what do i have to do instead? help.gif

edit: allright, allright... dunno whether it was the fact that i didn't create a new array before using it as a parameter (instead of creating it right in the parameters-array) or just the missing "then" again, that caused the problem, but it works now - so nevermind...

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  

×