Mongoose_84
Dec 22 2006, 11:17
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';
[/QUOTE]
(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;
[/QUOTE]
but passing on an array like this doesn't work the way i expected. what do i have to do instead? http://forums.bistudio.com/oldsmileys/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...
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';
[/QUOTE]
(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;
[/QUOTE]
but passing on an array like this doesn't work the way i expected. what do i have to do instead? http://forums.bistudio.com/oldsmileys/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...