#arma3_scripting
1 messages · Page 63 of 1
So its always the same unit just in quantity of 1/2/3 ?
https://community.bistudio.com/wiki/createVehicleCrew has info on which seats get AIs in them
hideObjectGlobal is the one i use, and with a trigger you would probably only want to use remoteexec (useful if you need to execute on a specific side) if the trigger is evaluated only on server (the tick box)
{_x enableSimulationGlobal true; _x hideObjectGlobal false} forEach (allUnits inAreaArray trig1);
ahh, so if a trigger is activated that has fadeSound in it, I shouldn't have to remoteExec that to affect every player, right?
what would be the situations to use a server-evaluated trigger?
ty for this example btw
i think that does need to be global if the sound is being sent global (any way that executes on ppls machines if they got the sound playing on their end basically)
the sound in this case is just a vehicle they're in
was your issue that it basically executed the sound so many times it overlapped and got loud?
yeah
if so, evaluate only on server but use remoteExec and specify (or dont) who will hear it by deciding the targets.
it will only do the sound playing once and on the server when the trigger activates the dialogue, but since its broadcast to those players they will all hear it.
Asking for help again
Question ^
Ticket to have engine check that: https://feedback.bistudio.com/T171270
Unless there is reliable scripted formula to be had
Tried that, yeah, that seems to work on all vehicles, thank you 
Try setting things up like this in initPlayerLocal.sqf:
...
private _quarry = selectRandom _competitors;
player setVariable ["DAE_Quarry", _quarry, true];
...
player addEventHandler ["Killed", {
params ["", "_killer", "_instigator"];
//ACE stuff here if needed ...
if ((_killer getVariable ["DAE_Quarry", objNull]) == player) then {
//_killer killed their quarry.
} else {
//_killer killed someone else.
};
}];
```The EH is added to the player, but it is only added on their own machine, so you do need remote execution in that last if-statement.

Oo, perhaps.
Im confused though, surely this would make everyone on the civ side return that they are quarry and not just the randomly selected person?
If it works though, would i also be able to determine if a player was hunting you with this?
perhaps like a huntingYou array on each player that adds or removes units based on who is hunting you or is dead
surely its not player setVariable it has to be _quarry setvariable right?
try again on monday

Every object has its own varspace. _obj setVariable ["Varname", _value, true] adds a variable (Varname) with the value _value to the varspace of _obj. Because the last element in the array is true, the variable and its value are also broadcast to other machines in multiplayer.
Every player runs initPlayerLocal.sqf when joining, so every player unit gets a DAE_Quarry variable in the varspace of the unit. Thus, we can use A getVariable ["DAE_Quarry", objNull] (on any machine) to check which unit player A is hunting.
ahh ok ok so its to declare the variable my b, and i didnt notice _quarry in the value section it makes sense to me now
could i use variables to denote all players who are currently targeting you and check if they have that variable in the killed event handler? Or would that have to be an empty array on each player that appends the hunters somehow
does anyone know how to recreate this via scripting:
I need to make vanilla based ghosts 👻
have you tried setObjectTexture?
- setObjectMaterial
Yeah but I can't get the right combination. I tried a glass material and looked quite ghostly but would became fully invisible when they had the sky behind them
"a3\characters_f_bootcamp\Data\VR_Soldier_F.rvmat"
(and what makes you think that's not the case in this picture?)
you can create materials yourself
you don't need a mod for that
you can place them in mission folder
Exactly what I need!
Thanks, I will try that... I believe the guy who did the screenshot did it with materials already in the game, will try those first: https://steamcommunity.com/sharedfiles/filedetails/?id=292025962
They are not used anymore but the material is still there
you can just try addonFiles and find all .rvmat files
then try them one by one 😬
No need to
Don't you remember the old VR soldiers?
no 
I mean it depends how old you're talking about 😅
I started playing A3 around end of 2015
Like... 2014? 🤔
https://youtu.be/ESoQNAVUTug?t=57
As you can see in the BG
Welcome to Arma 3 Bootcamp!
Now available as a free update, Arma 3 Bootcamp challenges you to learn about the basic game mechanics of Arma 3. Extend your training via the singleplayer mini-campaign or multiplayer bootcamp scenario, practice combat procedures in a Virtual Reality training environment, and browse through Arma 3's extensive weapon...
Those are no longer in the game? And they are uniforms?
You've already reacted to the post
try the material POLPOX said first 
does this also work on props/objects/vehicles?
it might work 
It does
it does work then 😅
Pretty much the same with VR soldiers
Purista font on UI 
good ol' puristaMedium
Was there a post announcing switch to RobotoCondensed and reason why?
It made UIs look so generic to be honest
IIRC one of the dev made a Mod to make the font back
is there a way to know if a sound is done playing?
Say3D and PlaySound3D doesn't seem to handle sound durations, or is this something that i would have to evaluate on my side with time durations?
Asking since sounds overlapping are incredibly loud sometimes
Yeah, it was a bit hard to read sometimes, but gave Arma 3 unique look
say3D does
you can check the sound object with say3D I think
I guess it deletes automatically when done? 
thanks, have to check then
The material looks good, but it looks rather like a hologram but I can't seem to find those old VR uniforms: https://i.ibb.co/QmD5c0D/material-Ghosts1.jpg
Old VR uniforms aren't there anymore
Which sucks to be honest, I think p3d is still there
arent the old vr uniforms the ones that look like velcro?
I remember using those classnames recently, arent they just hidden from the arsenal?
@warm hedge @sick gazelle i'm trying to replace the names visible on the map with different ones. It seems like deleting and re-adding custom ones is the only way, correct?
It's likely the easiest way.
Isn't there a syntax for one of them to hide the config ones?
Yes
So get references to the config ones.
Hide them.
Create new ones.
???
Profit.
so you use the createLocation to overwrite existing data, or ?
As described here https://community.bistudio.com/wiki/createLocation, the alt syntax lets you make config locations partially editable.
_loc = createLocation old name
_loc setText "Chernogorsk"
Does anyone know if the use of an extension can be made to be used exclusively on the server?
The wiki says that all clients must have it installed to use in a mission file, but when using the command it doesn't throw any errors when I 'misspell' the extension for example. It seems like there may not be any 'check' to see if a client has the relavant extensions used within the sqf code before joining a server/blocking them from doing so if they don't.
I am curious if there is a way around this via only having the 'isServer' part of the code ever call the 'callExtension' in the first place.
I do not have a dedicated server to test this out on, and am curious if anyone else has dabbled in it.
Addons can differ between server and clients
Even between clients
Just have your extension addon only on server
There is also -serverMod= so addon is not listed for clients
There are warnings thrown to RPT on incorrect name or not found
isServer check would work just fine
trying this while Chernarus is loaded doesn't seem to work
does it have to be changed before the map is loaded?
Example 3 has example how to do it
Does anyone have a example mission with acedefaultloadout set up, want players to be able to load a public kit up (save time for newcomers) when they join, and for those kits to always be available . I had it set up in the past but someone did it for me and I have no idea for the life of me how to set it up, tried following the instructions on ace framework but clearly did it wrong as there was no public loadouts
edit unit loadout in 3den and then navigate to default loadouts part and save loadout like any other
There’s a better method, of the loadout permanently in the arsenal, trying to make it so I don’t have to be on there and make it public all the time, I want it accessible at all times
i literally just told you that method
no i already explained
Not very well, maybe you should avoid trying to answer peoples questions if that’s the help you offer
Can someone else try explain it who’s actually willing to be of assistance instead of being a stuck up child, TIA
i just told you precisely how you use the feature -- this isn't even a scripting question 🤷
I have no idea where this public loadout section is, my qeustion was about the ace framework and one of their scripts, do me a favour and stop replying because your not helping
edit unit loadout in 3den and then navigate to default loadouts part and save loadout like any other
quite clearly also written on the ace wiki
Well I don’t understand it, obviously, hence my I’m seeking more thorough help and why I’ve posted in the wrong channel,and your not willing to provide it, so I’ll carry on seeking help until someone has the time to talk me through it, someone will help eventually if your not willing to talk me through it
it is literally a button right next to the public loadouts tab you think they should be in
I know what button your talking about, I have no idea how that makes the loadout available in my mission every time the mission starts up
You could probably use an array if needed, yes.
I’m not trying to argue with you, simply trying to explain that I don’t understand, repeating the same sentence, or rewording the same sentence is not helping me
this is year 2 level reading comprehension
What are you talking about year to, this is to do with arma, not basic English, just stop replying if your gonna start with insults
read the damn docs
I did, just stop because we have established your not being helpful
right, so what is the issue aside from "i dont understand"
When I make a loadout and save it, I know how simple it is to then make it public, but I’m not understanding the steps after that, to make that loadout, available 24/7, even after a server restart, partly because I’m working a 9/5 and can’t really give it my all, Hence why I asked if you were free later
save to default loadouts
players access from default loadouts
do it in 3den and its available so long as its on the same mission
Ok so I need to always save them to that mission file, every time I make a new mission, I should repeat the process in editor? Am I getting that right?
yes
All it took was a bit of patience, thank you

@old radish TY for your help earlier. Thankfully most of what I have works rn after applying what you said 🙂
no problem
so it would be like, in the initPlayerLocal sqf something like this right?
player setVariable ["huntingArray",[""]];
and
_quarry getVariable "huntingArray";
huntingArray append player;
Ty very much.
Probably more along the lines of player setVariable ["DAE_HuntingArray", [_unit1, _unit2, ...], true] and _somePlayer getVariable ["DAE_HuntingArray, []], but I can only guess as long as I don't know more about the code context.
thanks a lot for your help so far, the previous code you gave me appears to be working at a glance (me testing with a second client, and with another AI to act as "innocent" player)
private _quarry = selectRandom _competitors;
player setVariable ["DAE_Quarry", _quarry, true];
_quarry setVariable ["DAE_HuntingArray", player, true];
displayHunter = _quarry getVariable "DAE_HuntingArray";
hint name displayHunter;
Returns my name, atleast in singleplayer if i put this setVariable ["DAE_HuntingArray", [], true]; in the ai units
this will probably not act like a string adding more values to the huntingarray though will it? it will just be replaced... If so thats a problem because multiple people can hunt you
Hi guys so i have this code https://pastebin.com/R1sTvCM5 so far. how can i make it so that the hole map shows on the breafing table ?
Pastebin.com is the number one paste tool since 2002. Pastebin is a website where you can store text online for a set period of time.
That's right, to append values to DAE_HuntingArray you need to do something like this:
private _huntingArray = _quarry getVariable ["DAE_HuntingArray", []]; //Get the current array.
_huntingArray pushBack player; //Add a new element to the array.
_quarry setVariable ["DAE_HuntingArray", _huntingArray, true]; //Broadcast the updated array.
yes exactly that should work, and then in the killed event handler i add another if statement like this right
"You killed your hunter." remoteExec ["hint",_instigator];
};```
What kind of things (that don't raise errors) could lead to a scalar NaN value 
using a command that returns a scalar with invalid ranges
e.g. log -1, sqrt -1, acos 2
I don't think any of the commands I am using have invalid ranges, here's the statement
// _dist is a valid number
// _cPos and _pos are both arrays
// SPEEDOFSOUND is a macro with a value of 343
time + ((_dist + (_cPos vectorDistance _pos)) / SPEEDOFSOUND)
oh wait do you mean it says "scalar NaN" when you str it?
if so it's due to passing nils to those commands
one of those vars is nil then
It's in a variable that I am viewing through advanced developer tools, don't know if watched expressions have str applied to them
I meant stringifying it in general
Is it always returning NaN or just in some cases?
Always. Currently going through the whole call stack to see what's making those variables nil 
I'm having some trouble getting a forEach to work with an array. The forEach will use the last vehicle (i.e. quadbike) class in the array but not both vehicle classes in the array.
Here's what I have for the code:
_unlocks = profileNamespace getVariable ["SOG_Garage_Unlocks", [[],[],[],[],[],[]]];
_cars = _unlocks select 0;
missionNamespace setVariable ["BIS_fnc_garage_data", [
{[
getText (configFile >> "CfgVehicles" >> _x >> "model"),
[
(configFile >> "CfgVehicles" >> _x)
]
]} forEach _cars,
[],
[],
[],
[],
[]
]];
This is what the profileNamespace variable has stored in it: SOG_Garage_Unlocks:```sqf
[["B_VKN_tahoe_UNM_PMC_01","B_Quadbike_01_F"],[],[],[],[],[]]
What is your expected output?
forEach returns the last iteration's value
I guess you need apply
The expected output would be populating the virtual garage list box for BIS_fnc_garage_data with the profileNamespace variable data
it should be cars apply {[(configFile >> "CfgVehicles" >> _x), getText (configFile >> "CfgVehicles" >> _x >> "model")]}
actually you can't store configs anyway
why are you storing configs? 
I'm trying to work with the BIS_fnc_garage and to set the BIS_fnc_garage_data it needs both the model and config of each vehicle you want to add.
It's a pain in the rear end, it seems in order to get BIS_fnc_garge to work with custom BIS_fnc_garage_data you have to use BIS_fnc_addScriptedEventHandler
you can just store the type of the vehicle
and get the config using what you already did
and you don't need to store the model either
since you can get that one from config
I don't think I'm storing the config or the model, just the classname in the profileNamespace and then using the classname from the profileNamespace for the script
you are
configFile >> "CfgVehicles" >> _x
returns a config
or the model
I mean the model path ofc. you can't store "models" anyway
the BIS_fnc_garage wiki show that I need to do that for BIS_fnc_garage_data I'm a bit confused, also the wiki states that the function is part of the Broken Functions group
oh right I thought both were profileNamespace 
_arr = [];
{
_arr append [getText (configFile >> "CfgVehicles" >> _x >> "model"), [configFile >> "CfgVehicles" >> _x]];
} forEach _cars;
missionNamespace setVariable ["BIS_fnc_garage_data", [_arr, [], [], [], [], []]]
I'll give that a try, thanks
The list box in the virtual garage still has all the vehicles, but when I embed what you sent me with the script I'm working with everything works:```sqf
player addAction ["Open Garage", {
_pos = player getPos [10, getDir player];
BIS_fnc_garage_center = createVehicle ["Land_HelipadEmpty_F", _pos, [], 0, "CAN_COLLIDE"];
[missionNamespace, "garageOpened", {
params ["_display", "_toggleSpace"];
private ["_arr", "_unlocks", "_cars", "_armor", "_helis", "_planes", "_naval", "_static", "_defaultClass"];
_arr = [];
_unlocks = profileNamespace getVariable ["SOG_Garage_Unlocks", [[],[],[],[],[],[]]];
_cars = _unlocks select 0;
_armor = _unlocks select 1;
_helis = _unlocks select 2;
_planes = _unlocks select 3;
_naval = _unlocks select 4;
_static = _unlocks select 5;
_defaultClass = _cars select 1;
{
_arr append [getText (configFile >> "CfgVehicles" >> _x >> "model"), [configFile >> "CfgVehicles" >> _x]];
} forEach _cars;
missionNamespace setVariable ["BIS_fnc_garage_data", [
_arr,
[],
[],
[],
[],
[]
]];
{
lbClear (_display displayCtrl (960 + _forEachIndex));
} forEach BIS_fnc_garage_data;
BIS_fnc_garage_centerType = getText (configFile >> "CfgVehicles" >> _defaultClass >> "model");
["ListAdd", [_display]] call BIS_fnc_garage;
}] call BIS_fnc_addScriptedEventHandler;
["Open", true] call BIS_fnc_garage;
}];
Use in to check if a value is in an array. I think you also need to change the condition, I'm pretty sure it should be _instigator in (_killed getVariable ["DAE_HuntingArray", []]).
I'm not sure if you're aware of this, so I'll point it out: With the current setup, player A runs initPlayerLocal.sqf when joining, thus adding a Killed EH to unit A (only on their own client, because it is initPlayerLocal.sqf). Similarly, player B also runs initPlayerLocal.sqf when joining, thus adding a Killed EH to unit B (also only on their own client). However, you never add a Killed EH to unit B on A's client and you never add a Killed EH to unit A on B's client.
Therefore, if player A kills player B, the Killed EH on B's client fires. However, there is no Killed EH on A's client that could fire when B is killed.
I don't follow. is this correct now?
Yes, I just posted the source code for anyone to use and edit if they'd like to, thanks again for the help
You don't get an error: "Error undefined variable in expression: "bis_fnc_garage_centerType"?
@wind hedge Correct because I've setup a default class in my profileNamespace variable array. You'll have to make sure you do the same, otherwise you'll get the error.
Here's what my profileNamespace variable looks like: SOG_Garage_Unlocks:```sqf
[["B_VKN_tahoe_UNM_PMC_01","B_Quadbike_01_F"],[],[],[],[],[]]
Made a version that works without profileNameSpace: ```sqf
BIS_fn_garageAddAction = {
defaultGarageClass = "C_Quadbike_01_F";
BIS_fnc_garage_centerType = getText (configFile >> "CfgVehicles" >> defaultGarageClass >> "model");
player addAction ["Open Garage", {
_pos = player getPos [10, getDir player];
BIS_fnc_garage_center = createVehicle ["Land_HelipadEmpty_F", _pos, [], 0, "CAN_COLLIDE"];
[missionNamespace, "garageOpened", {
params ["_display", "_toggleSpace"];
private _cars = ["C_Quadbike_01_F"];
private _armor = [];
private _helis = [];
private _naval = [];
private _static = [];
private _carsModelsArray = [];
private _armorModelsArray = [];
private _helisModelsArray = [];
private _navalModelsArray = [];
private _staticModelsArray = [];
if (count _cars > 0) then {defaultGarageClass = _cars select 0;};
BIS_fnc_garage_centerType = getText (configFile >> "CfgVehicles" >> defaultGarageClass >> "model");
{
_carsModelsArray append [getText (configFile >> "CfgVehicles" >> _x >> "model"), [configFile >> "CfgVehicles" >> _x]];
} forEach _cars;
missionNamespace setVariable ["BIS_fnc_garage_data", [
_carsModelsArray,
[],
[],
[],
[],
[]
]];
{
lbClear (_display displayCtrl (960 + _forEachIndex));
} forEach BIS_fnc_garage_data;
["ListAdd", [_display]] call BIS_fnc_garage;
}] call BIS_fnc_addScriptedEventHandler;
["Open", true] call BIS_fnc_garage;
}];
}; ```
@wind hedge Looks good to me, you can create a forEach loop for each of the other arrays like you did with the _cars / _carsModelsArray and replace the empty arrays in setVariable part of the script with the correct array names. (i.e. _armorModelsArray, _helisModelsArray and etc.)
The only issue is that the UI is missing a label for me... On the bottom right... I guess it would normally say "TRY" or something?
Same here, lol, not sure how to fix that, but it makes you the driver of the selected vehicle, I've also noticed a small filled in blank box top left corner of the UI as well, not sure what it's for either.
Does anyone know if there is a way to get the vehicle out of the garage? So we can apply a custom texture for example _vehicle setObjectTexture ""; etc
Current vehicle that garage shows?
That would work too... So that the custom texture is shown there and not only after closing the UI
_center = _class createVehicleLocal _centerPos;
missionnamespace setvariable ["BIS_fnc_arsenal_center",_center];
@wind hedge when you select close the vehicle should be in front of you, at least that's what my variation of the script does
Yeah I know, what I want is to apply a custom texture to the vehicle when the player closes the garage...
case "Exit": {
with missionnamespace do {
BIS_fnc_garage_center = BIS_fnc_arsenal_center;
Should be saved in BIS_fnc_garage_center
with missionnamespace do {
[missionnamespace,"garageClosed",[displaynull,uinamespace getvariable ["BIS_fnc_arsenal_toggleSpace",false]]] call bis_fnc_callscriptedeventhandler;
};
```also calls this scripted EH
Thanks! That might do it!
This is an example of the custom textures I want the garage to add on exit:
This is what it returned: 256584080# 911: quadbike_01_f.p3d
Thanks! This is as far I as got: ```sqf
VAL_fn_preGarage = {
// run when the garage is opened
private _nearEntities = [];
_nearEntities = BIS_fnc_garage_center nearEntities [["Car","Tank","Ship","Air"], 10];
if (_nearEntities isNotEqualTo []) then { {deletevehicle _x} forEach _nearEntities; };
};
VAL_fn_postGarage {
private _nearEntities = [];
private _spawnedVeh = objNull;
private _veh = objNull;
_nearEntities = BIS_fnc_garage_center nearEntities [["Car","Tank","Ship","Air"], 1];
call {
if (_nearEntities isEqualTo []) exitWith {systemChat "No vehicle spawned!";};
_spawnedVeh = _nearEntities select 0;
_veh = typeOf _spawnedVeh;
_spawnedVeh setObjectTextureGlobal [0,"mission\tex\VC\v_SUV_VC_Red.paa"];
};
};
[missionNamespace, "garageClosed",{
[] call VAL_fn_postGarage;
}]call BIS_fnc_addScriptedEventHandler; ```
going to test it now
is there a command to force the UI to close without adding the car?
closeDisplay
thanks! Instead of deleting the near vehicles I am just going to force the UI to close if there is already a vehicle there, with a systemchat "Move your vehicle!"
Worked like a charm! Thank you guys!
Quick question if i do something like:
this setPylonLoadout [1, "PylonRack_19Rnd_Rocket_Skyfire",true];
this setPylonLoadout [2, "PylonRack_19Rnd_Rocket_Skyfire",true];
``` In side composition will the pylon be set on the server even if is setPylonLoadout 🇱 🇪 ?
What is side composition?
sorry in Init of a object or a vehicle in this case. In Init of a humming bird.
It should be fine
If you do setPylonLoadout on a remote vehicle it just reverts on next update
You can also add if(local this) then {} check, but you also need to check turret locality (in case players occupy driver and gunner in lobby)
Why you can't create Logic with createVehicle but can with createVehicleLocal? 🤔
Yes it works with createAgent too
Why serverCommand can to not work?
Trying to do #kick on the server side
serverCommand "#kick Predator";
serverCommandAvailable "#kick"; == TRUE
serverCommandExecutable "#kick"; == FALSE
Wasn't serverCommand only for dedicated servers or something?
IIRC serverCommandAvailable means a client can login with #login and chat execute the command.
I'm trying on dedic
Oh, you also must call it with the password
Is it reason?
serverCommand can be executed only from User Interface Event Handlers, and this command also checks if that's the case.
Hmm, perhaps. Sorry for misleading info, I only used it with dedicated server and I remember it being pain in the ass.
As for dedicated server, it worked for me when I did it with alt syntax with the password
serverCommandPassword in server.cfg
Thank you it works with password.
Is there a script i could use to allow players, to do a scroll wheel, and spawn enemies, that are garrisoned in an area. Or at certain locations
Trying to make a MOUT town with AI that can be spawned in via computer, as well as CQB shoot houses that do the same.
I am trying to define 2 arrays. And then extend/join them so I don't need to write arrays for each class. What should be the syntax to joining arrays in description.ext ? ( look at list array )
// description.ext
letters[] = {"a", "b", "c"};
numbers[] = {0, 1, 2};
class Random
{
list[] = letters + numbers;
};
// description.ext
letters[] = {"a", "b", "c"};
numbers[] = {0, 1, 2};
class Random
{
list[] = {"letters", "numbers"};
};
private _random_list = [];
{
_random_list append getArray(missionConfigFile >> _x);
} forEach getArray(missionConfigFile >> "Random" >> "list");
--- OR ---
// description.ext
#define MY_LETTERS "a", "b", "c"
#define MY_NUMBERS 0, 1, 2
letters[] = {MY_LETTERS};
numbers[] = {MY_NUMBERS};
class Random
{
list[] = {MY_LETTERS, MY_NUMBERS};
};
I think remotexec is better, used it extensively with the ExileMod and never had any problem.
For case 2 you would need a "watchdog loop" constantly waiting for variable changes if i understood your idea right.
hmhm didn't know that one
interesting question then 
can't find it on the biwiki
ah yea but "This command is deprecated since the introduction of remoteExec and remoteExecCall."
Can just use scripted ehs or cba ehs
Why would that be substantially better than an ordinary remoteExec?
it isnt necessarily, was just pointing out that option 2 is still viable
It was already possible, the command is superseded by remoteExec but not actually removed (backwards compatibility/fringe use cases). There's just no point.
just use remoteexec
Is there a script i could use to allow players, to do a scroll wheel, and spawn enemies, that are garrisoned in an area. Or at certain locations
Trying to make a MOUT town with AI that can be spawned in via computer, as well as CQB shoot houses that do the same.
I have a AC-47 spooky gunship circling/loitering around a waypoint, left turn, so the MGs aim downward. I try to tell it to fire at some empty trucks with doSuppressiveFire position, but nothing happens. Code is sqf pos = getPosASL truck; (crew spooky) doSuppressiveFire pos; Any ideas what's wrong with this approach?
truck is an empty SOG PF Creators DLC truck, Spooky is the AC-47 Gunship from Unsung Redux
are they all in the same group
So, right now I am validating all of these variables using params but I am still getting Scalar NaN
Scalar NaN means one of your Number operations has nil involved
How can that be if every variable is validated by params
diag_log ["_dist", _dist];
diag_log ["_cPos ", _pos];
diag_log ["_pos", _pos];
diag_log ["SPEEDOFSOUND", SPEEDOFSOUND];
Something else is nil then
Basically diag_log the hell out of it
Each variable each step
Looks like the constant isn't being defined. ArmaScriptCompiler probably isn't doing includes properly but doesn't throw errors 
I've been having an issue with BIS_fnc_spawnGroup on my dedicated server. Everytime I spawn the ai they freeze and do not listen to commands
the script is simple, I have a trigger set to server only and when activated it fires this
[_grp1, 1000, nil, nil, getmarkerPos "hunt_1"] spawn lambs_wp_fnc_taskRush;
_grp1 setVariable ["acex_headless_blacklist", true];```
even stripping it down to bare bones
grp1 = [getMarkerPos "spawn_1", east, ["UK3CB_ION_O_Desert_SL", "UK3CB_ION_O_Desert_TL", "UK3CB_ION_O_Desert_MD", "UK3CB_ION_O_Desert_AA", "UK3CB_ION_O_Desert_AA_ASST", "UK3CB_ION_O_Desert_RIF_2", "UK3CB_ION_O_Desert_AR", "UK3CB_ION_O_Desert_RIF_1"],0] call BIS_fnc_spawnGroup;
it still doesnt allow me to command the units with zeus
they just wiggle lol
are you sure it's not because you spawn them somewhere that they can't path find?
possibly, its just a small ditch, ill place the marker on an open road
the strange thing is it works perfectly fine in lan mp, its just on my dedicated server
can Zeus even command remote targets? 
where do you run this code?
Ill be totally honest I dont know
Working on a project and I'm trying to make all units of the same arma base faction hostile to each other but the units within their patrol group be friendly. I'm using addRating to make them hostile to each other and I'm thinking to make the group members friendly to each other is to use a local script that runs only for each unit in the group where it sets the others addRating to a friendly number. Kinda failing at the local part tho or my thinking is wrong :/
just in the trigger
ive also tried using exec vm and having an sqf
neither of those matter
[getMarkerPos "spawn_1", east, ["UK3CB_ION_O_Desert_SL", "UK3CB_ION_O_Desert_TL", "UK3CB_ION_O_Desert_MD", "UK3CB_ION_O_Desert_AA", "UK3CB_ION_O_Desert_AA_ASST", "UK3CB_ION_O_Desert_RIF_2", "UK3CB_ION_O_Desert_AR", "UK3CB_ION_O_Desert_RIF_1"],0] remoteExec ["BIS_fnc_spawnGroup", zeusPlayer]
try with that. change zeusPlayer to the variable name of the, well, zeus player
whats the purpose of zeus player?
variable name of whoever is the zeus
ahh, yeah might as well try
Are you working with AI units? If so, then these are local to the server (i.e. whatever computer the mission is hosted on) so only it's settings will have an effect I think.
the goal is to have them on their own waypoint so I dont have to gm
they just dont listen to it, they freeze up. I moved the marker and ill change the code and variable
Engine limitation unfortunately. Maybe you can make all non-player group units as renegade (negative rating), but units in other groups will still shoot each other inside group.
Yeah cause I already have 4 factions in the project and want to make each group like their own faction in a way but kinda sucks how you are limited to only 4 factions
Well, you can set each faction into each side
Though having civilian as enemy prevents you from interacting with empty vehicles because they're civilian side 🤡
Have done that and these guys I'm referencing are their own faction but thought it would be better if they all were their own factions within their patrol groups
wait that's a thing?
that might screw some stuff up...
Yeah, if you make civilians enemy, you can no longer get into empty vehicles or access their inventories
Because Arma
If only we could call up a developer and have them implement a command to create factions...
Wait, did this change at some point?
Just tested, making civilian enemy no longer prevents you from interacting with empty vehicles, they still report their side as civilian though
I'm 100% certain it was like this even in Arma 3 at some point
Well I guess you can put your 4 factions into 4 sides then\
huh well I guess that works out
blufor, opfor, independent, civilian
yeah but still would be nice if the groups could be hostile to each other. But then again the chances they will run into each other are slim so I guess it don't really matter
@little raptor thank you, I didnt know I could remoteexec that function
i should be able to reword it to fit my needs
thank you again
you can remoteExec any function
but did it work?
well...?
using remoteExec ["BIS_fnc_spawnGroup", zeusPlayer] does that run on the client or on the server?
client
It runs it wherever whichever unit is referenced in zeusPlayer is local
okay, could I simply remove zeusplayer and have it run on the server?
Ill test it quickly
removing it makes it run everywhere
ahh
and you were running it on the server already (your trigger was server-only)
Wasn't running it server-only exactly what was causing the previous problem?
actually it doesn't 
why shouldn't it work on the server?
And running it everywhere will cause as many groups to spawn as there are connected machines
lol, I couldnt answer
I could use a headless client instead of running it on my machine
is it a linux server?
Granted I was only skimming the previous discussion, but I thought it was that it did "work", but Zeus couldn't give them orders because not local
Which also doesn't make a ton of sense, I've been Zeus giving orders to server-spawned units before
but that seemed to be the conclusion
the units were just flat out frozen after spawning until I used lepoards code
well it created them but they didn't follow any orders (not even server-only ones)
yeah
yeah which is why I said it makes no sense
probably related to this 
what is the version of Arma on the linux server?
I also operate on a Linux server, and I've had no issues spawning groups with fnc_spawnGroup and giving them LAMBS tasks 🤔
let me see
Hi guys i have a question is there a way to lock side turrets of a ghosthawk. or at least disable them from fireing ?
Will that disable them from fireing even if the player is all ready in a gunner seat ?
No, it only locks it, which means to prevent units from getting in or out of it
Yea well i need a way to disable fireing of a gunner seats with out takeing ammo and readding it.
There isn't one
You have to either lock the seat, or remove its ammo. There is no "safety switch" command.
Removing and readding ammo is very easy.
Well, I suppose you could also remove the weapon, but that's an either/or with removing the ammo
The problem with readding ammo i have is how to save how mutch is fired after the gun was locked.
Also i am planing to make this as a composition to play on Public Zeus.
@little raptor is the game version in a specific file?
or would it just be in the server console on start up?
give debug console access to the zeus player then run productVersion using server exec
game version is also mentioned in the rpt
["Arma 3","Arma3",212,150301,"Stable",true,"Linux","x64"]
try updating to the latest profiling 
Im guessing thats the latest update
Being a composition shouldn't matter (for this, anyway).
As a starter, try removing the weapon. I'm not sure if it removes the relevant magazines as well; if not, you're all good, the previous mags will still be there.
If it does, you'll have to use currentMagazineDetail to get the ammo count, which isn't fun but is possible.
no it's the latest stable update
not profiling
gotcha
there is a path finding fix too but it's related to amphibious vehicles
should x86 dlls be suffixed with _x86 as with 64 bit?
no
what's used for 32 bit dll then? 
nothing
oh
its usual name
I mean no suffix or anything myExt.dll
mydll.dll
mydll_x64.dll
mydll would get used on an x86 machine?
yes
as well as x32 machine?
there's no x32 machine
32-bit is x86
oh, right.
It has no suffix because back in the day, there was only 32-bit. 64-bit was added later.
Yeah, I'd figured -- just thought 86 bit was a thing for some reason lmao
will probably need a hand in a mo then once i've figured out the issue here as a3 is complaining of x64 dll being x86
written in c# using visual studio
have got unmanagedexports and dllexport installed too
@little raptor to be crystal clear, id upload the new server exe and change my launch params to use that one insead, and thats it?
despite building with this 
Ty i manage to get it to work here is the code. Now the question i have will this work on multiplayer do i need to remoteExec addaction if its compostion ?:
this addAction ["<t size='1.5'>Lock Left Turret</t>",{
params ["_target","_caller","_id"];
private _actMenu = (_target actionParams _id) select 0;
if(_actMenu isEqualTo "<t size='1.5'>Lock Left Turret</t>") then {
_actMenu = "<t size='1.5'>Unlock Left Turret</t>";
_target removeWeaponTurret ["LMG_Minigun_Transport",[1]];
}else {
_actMenu = "<t size='1.5'>Lock Left Turret</t>";
_target addWeaponTurret ["LMG_Minigun_Transport", [1]];
};
_target setUserActionText [_id,_actMenu];
},
nil,0.2,true,true,"","_this == currentPilot vehicle _target",50,false,"",""];
Yes, init code for a Zeus-deployed composition is only executed on the machine that placed it
Now i am confused a bit i made composition with setPylonLoadout witch is 🇱 🇪 that dosent need to remoteExec. but addAction witch is also 🇱 🇪 needs to be remoteExecuted ?
If you execute setPylonLoadout where vehicle\turret is local, game will update weapons\magazines state to other clients by itself soon after
addActions are fully scripted, engine doesn't broadcast them anywhere, so you have to do it yourself
Also
_actMenu isEqualTo "<t size='1.5'>Lock Left Turret</t>"
```
I know but how i would make it better ?
If your lock state means deleted weapon, check if you have that weapon
Also if that turret is occupied by remote player, remove\add weapon turret won't work
Anybody here familiar with ACRE scripting.
I'm looking for a way to set the voice volume to max loudness via script, but I'm having trouble finding the bit that is responsible for the voice volume.
this addAction ["<t size='1.5'>Lock Left Turret</t>",{
params ["_target","_caller","_id"];
[_target, ["LMG_Minigun_Transport",[1]]] remoteExecCall ["removeWeaponTurret", 0];
},
nil,0.2,true,true,"","_this == currentPilot vehicle _target && ('LMG_Minigun_Transport' in (_target weaponsTurret [1]))",50,false,"",""];
this addAction ["<t size='1.5'>Unlock Left Turret</t>",{
params ["_target","_caller","_id"];
[_target, ["LMG_Minigun_Transport",[1]]] remoteExecCall ["addWeaponTurret", 0];
},
nil,0.2,true,true,"","_this == currentPilot vehicle _target && !('LMG_Minigun_Transport' in (_target weaponsTurret [1]))",50,false,"",""];
Sure you can modify existing action, but it would be much cleaner to have two that show with opposite conditions
The problem with that is i allready have 4 actions 2 for animateing the doors and 2 for turrets. if i add 2 actions for each of the action then that would be 8 actions witch can be a lot of action in scroll wheele
They have a condition so they don't all show at the same time
The actions to unlock are only visible when the guns are locked, and vice versa
oh yea
I really wish that imlemented the JVM in arma3
Last Question how would i applay this with doors animateDoor what would be check to see if the door is allready open ?
this addAction ["<t size='1.2'>Open Left Door</t>",{
params ["_target","_caller","_id"];
_target animateDoor ["Door_L", 1];
},
nil,0.2,true,true,"","_this == currentPilot vehicle _target",50,false,"",""];
Use this command in condition to return animation state
you can just replace them. also they're not exes
you should probably check the platform target
I haven't used .NET 6 for a while tho
tried it with it as any cpu as well, no dice
you can try with .NET framework too
I haven't had problems with that one.
I have yet to try .NET 6 with Arma
wdym by that?
.NET 6 and stuff are ".NET Core" stuff meant for cross platform dev. windows specific is .NET Framework (tho it's much older)
It's targeting .net 6 for specific version of windows
like I said I haven't used .NET 6 in a while so... 
try with .NET framework 4.7.x first to see if it even works with that
iirc what I'm trying to use isn't supported in 4.7 
Even this callback doesn't do anything 😅
well just build something empty to see if it works at all
not found 
probably private
@little raptor I figured it out
what doesn't work in 4.7?
voice recognition system
have to use deprecated version with much worse accuracy
am I blind? 
I don't see anything in that code 
Lambs...?
oh, wrong cs file mb -- worker.cs contains it but still no callback from main
only basic basic stuff its all working properly
no remote exec needed
just a trigger set to server only
well just try without that stuff with .NET 4.7 to see if it even works
that extension.cs file can compile fine (if you remove Worker)
rgr i'll try a wiki example or something in 4.7
but I suspect the problem is the RGiesecke stuff
iirc I had problems with that too
and used a different thing instead
don't remember 
let me search
Ah, thanks -- I'll give that a try in a while and see how it goes, will post in #community_wiki to get the example updated if so
lol that also uses RGiesecke 
maybe not that? 
I want to make a more flexible radio system with diffrent antennas and radios, handheld and base units it would of been possible with the JVM dont think its possible with SQF is it?
I don't really remember
no I mean that library
this
Oh right
also uses RGiesecke
if it's nothing glaringly obvious in my code I'll assume it's exporting and troubleshoot using wiki example then
as callextension on my dll is returning ""
didn't your dll even print error?
this?
well does it still give that error or not?
nope
then what's the problem? 
no the other way around
nothing happens 
then it's the dllexport's problem
roger -- is there any way of me rectifying that on .NET 6.0?
or is it likely a versioning error
well all I know is that .NET core can be problematic
I'd personally start with .NET framework 4.7 first
I know 3.5 worked too
but that's way too old 
Yeah this doesn't date back to 4.7 
wait I'm building for .net but recognizer is for winrt 
i am a whole lot of confused
I got it working, you need to use .NET Framework 4.8 (if needed, otherwise just use newer .NET versions)
You should just be using the build dropdown option right?
What editor are you using? I just used the nuget package in Visual Studio and made sure that it's up-to-date
And yeah
Clean first and then rebuild just to make extra sure haha
visual studio yeah
I'll try again after a clean and rebuild then -- should be closing the gui it opens right?
@little raptor @hallow mortar for the frozen ai with fnc_spawnGroup it was the mod https://steamcommunity.com/sharedfiles/filedetails/?id=2073987581&searchtext=advanced fucking with everything
Here's example of my code: ```csharp
using RGiesecke.DllExport;
public class YourClass
{
[DllExport("_RVExtension@12", CallingConvention = CallingConvention.Winapi)]
public static void RvExtension(StringBuilder output, int outputSize, [MarshalAs(UnmanagedType.LPStr)] string args)
But just as an example
We've had the same issue actually, can confirm it's caused by this mod 😄
Funny coincidence
are you building separate dlls? I'm using wiki example with #if WIN64 and so on
wait ignore that
stupid questoin
(This just because Arma 2: OA is 32-bit)
Yeah I'd forgotten 😅
Odd that I'm doing the same thing in that case -- I'll try clean and rebuild and then try remove the if statements and see what that does
IIRC I had some issue with finding the correct calling convention but got it to work eventually
should just be "yourdll" callextension "functionstringthing" right
About like that yeah, AFAIK the BIKI page is correct
yes. like I said it doesn't work with .NET core properly
well the mod is old so... 
Ah, that's true actually, I was using .NET Core in the same project but in different app so I didn't recall it correctly
so just ignore dllexport's gui?
What GUI? Can you take a screenshot?
I've just used the code/project dependency via nuget
this thing
I guess you're not using nuget then or there has been some misunderstanding
I install it via nuget and that appears 
Can you share a link to the version you've installed via nuget?
Open source project .NET DllExport with .NET Core support (aka 3F/DllExport)
https://github.com/3F/DllExport
🚀 Quick start: https://github.com/3F/DllExport/wiki/Quick-start
🔖 Examples. Unmanaged C++ / C# / Java: https://youtu.be/QXMj9-8XJnY
🧪 Demo: https://github.com/3F/Examples/tree/master/DllEx...
I'm using this one, but I have no idea whether it works in Arma 3 though. But it should be the correct one I think
Most likely yes
that however causes problems with dllexport now being not found 
oh nvm uninstalled the wrong one ffs
I'm not aware of any reason why the interface would have changed (because it's only passing strings back and forth after all) so my guess is that it should work in Arma 3 too, you just need to add the RVExtension entry points stuff differently in Arma 3 vs. Arma 2
wiki has been quite confusing with which to use but i think it should be the other one with this version of .NET
What version are you using right now?
Ah, then I don't know since I'm moving to Arma 3 only now 😅
i think i do need to be using that gui but i now cant get it to open again 
Oh boy
biki is confusing me too because it says dllexport but links to unmanagedexports 
but then the sources takes you out to dllexport
@tough abyss check out ACRE: http://www.armaholic.com/page.php?id=19324 or TFAR: http://radio.task-force.ru/en/
yeah copy pasting biki example is giving same result on .net 6.0 -- but can't build on net48 targetframework 
hey ! im trying to make a player marker script on altis life to only show the player , its executed in initplayerlocal but its showing the marker for everyone else too
i have no ideia what im doing and why is not working
If you use a non ...Local marker command, the marker is made global. So if it's supposed to be a local marker, only use the local versions of marker commands on it.
createMarkerLocal [_marker, player]; its the one used , and according to the wiki its supposed to only show the marker on the machine who created it
do you think i may be executing this on the wrong init file ?
that part is fine. when you change something on the marker, like setMarkerColor (non-local), it makes the marker global. see yellow box here https://community.bistudio.com/wiki/createMarkerLocal
hi, I got a file containing this
{
#include "spawnAI\factionConfigs\vanilla\CfgGroupsNATO.cpp"
#include "spawnAI\factionConfigs\vanilla\CfgGroupsCSAT.cpp"
#include "spawnAI\factionConfigs\vanilla\CfgGroupsAAF.cpp"
};```it's being loaded after mission start and I want to exchange the files being included based on mission parameters
so if my parameter "IndepFaction" is 1 instead of the default 0 I would want to have this result
```class CfgGroups
{
#include "spawnAI\factionConfigs\vanilla\CfgGroupsNATO.cpp"
#include "spawnAI\factionConfigs\vanilla\CfgGroupsCSAT.cpp"
#include "spawnAI\factionConfigs\vanilla\CfgGroupsLDF.cpp"
};```with a file for LDF instead of AAF
how can I do this or would some workaround be more appropriate?
I doubt you can do that since afaik mission parameters are loaded from config too, so config is already parsed
yeah they are:
https://community.bistudio.com/wiki/Description.ext#Mission_Parameters
I didn't include this file in the description or any init files hoping to avoid that
but I guess if that is the case I'll just do something else
already got a workaround in mind but I would've preferred a solution like this
thanks anyway
then how would it be loaded if it's not being loaded by description.ext?
with loadConfig
works perfectly fine so far
oh right. you just pass the configs to some function then?
yup
I'll look into it, thanks
but for example SetmarkerText i culd no find a local version of it
SetmarkerTextLocal
tho __EVAL would complicate things. why not just create 2 versions of this file?
since you don't care how many configs you have anyway
even if there are more classes than that you can just #include those parts:
// file1.cpp
#include "otherCommonStuff.hpp"
#include "aafStuffBlabla.hpp"
and similarly one for LDF
I intend to add a lot more different files so I only wanted to load what is necessary and I also want the other included files to be changeable by parameters so making different files for every possibly combination would be very inconvenient
I'm trying to make it work with EVAL (to no success so far)
if it really doesn't work I'll try something else
I'm converting the configs into hashmaps anyway so instead of changing the root config file I'll just load the individual files and insert them in the hashmap
well yeah if you don't need configs why use configs?!
I thought you wanted to pass it to some BIS function or something
if it's your own function there's no need
that is a fair point
ig I just got tunnel vision since I started using configs and ran into more and more problems with them
never got the idea to just use something else tbh
r.e previous issue; currently no dll exports for .NET 6.0 as far as I can find
Think UnmanagedCallersOnly may be what I'm looking for but unsure
I'm not really familiar with .NET but isn't it possible to compile 2 different dlls with different .NET versions and use some .NET interface to interact between the two?
I'm not really familiar with .NET either, this is a learning exercise to me 
UnmanagedCallersOnly doesn't work for BI function I don't think
not bi functino
the arma dll specific bits
well why not ask this on stackoverflow or something?
because that tends to lead to poor suggestions and even worse results from my experience
💀
that's not what I said to ask...but if it can't tell that one right then meh
I can't even get the dll to work in .NET 4.8 afaik
I'll retry but was having issues
what was the issue?
same as before, nothing happening with no rpt error
let me try it myself in a minute
introduced in .NET 5.0 but unsure if it's compatible with RVExtensionRegisterCallback bits
Ah no, forgot -- it didn't build with this error
with targetframework of net48
well did you try that one with .NET 6?
yes, unmanagedexports doesn't support .NET 6.0 so does nothing
Just tested BIKI example w/ callback yet again in .NET 6.0 and same issue, added callback mission eh too and it also returned nothing
For those C#'ers out there. Can I keep using VSC or do I really need to get VS instead?
Would anyone mind helping me modify a template for Antistasi? I'm trying to incorporate modded uniforms into the game for only the player, but I can't seem to get the AI to keep their hands off of them
VS is better
VSC is only good for Python and JS
aha. i have progress, it crashes arma 🙂
Repackaging of UnmanagedExports 1.2.7 to be compatible with PackageReference and additionally upgraded the Microsoft Build Utilities (using Nuget package Microsoft.Build.Utilities).
A set of compile-time libraries (nothing to deploy) and a build task that enable you to export functions from managed code to native applications.
That ...
Exception code: E0434352 at 2E6DCD29 but no other useful info produced in rpt
well I just tried the example on wiki and it works
which .net version?
yes please as i think im going insane
package reference changes from 4.7 to 6 iirc which is why i used this one
question, I used
profileNamespace setVariable ["stalkov_01_8", (getUnitLoadout player)];
saveProfileNamespace;
to save everyones loadout. Does this save permanently? As in can I load people loadouts like a week later?
so long as theyre on the same profile
where does it save specifically? Can I find the file?
nvm its profilenamespace I will look up bohemia forum
profileNamespace getVariable ["stalkov_01_8",[]]
with .NET 6?
yep
& this nuget
callback is required for what I'm doing but I'll try w/o callback 
no still crashes 🥲
ffs, tried googling the error but couldn't find anything useful
the error means nothing
meh just try building multiple assemblies targeting different .NET versions then 
use 4.7 as starting point for Arma
6 for your stuff 
I'd assume that's just calling the 6.0 dll from a 4.7 dll in arma?
uh
if you can its beyond my knowledge
you just reference an assembly that targets a different .NET version I guess 
yeah separate projects
yeah those
I can try that I suppose 😅
but I need callback here which could probably cause issues, no?
no
i presume its as simple as something.soomething.callback and im just oblivious to it
yeah but how would i use that callback from the 6.0 assembly lol
you just reference the assembly
i think im overcomplicating this then 😅
just make a normal C# function in your 4.7 assembly which calls the callback. use this function in the v6 assembly and call it
Then I can do that vice versa -- call in 4.7 to 6.0 assembly?
the callback is defined in the 4.7 one.
oh ive misread what you said yeah
tho not sure if this creates a circular reference and if so can .NET support it?
because the 4.7 one refs the 6 and 6 refs the 4.7 
6.0 function called in 4.7, 6.0 function does callback
🤷 will find out
Mind sending your csproj for 4.7? Can't figure it out
This bit always confuses me
Extensions m8
which bit?
the TargetFramework part -- was using net48 before but that was throwing up errors
use this
when it shows that window, check Enable or whatever it was called
then apply
unmanagedexports still works with net 4.8, couldn't figure out how to use dllexport
this means nothing to me 😅
yeah that one is trash just use what I said
Then it's just build tab and regular steps?
yeah
also don't forget to define WIN64
once you're done it defines the DllExportAttribute in your namespace
yeah have been doing that -- trying to figure out how on earth you use this gui atm as had renamed the projects
if you have renamed the namespace you can just use notepad++ and batch rename all old namespace names
I actually had to do this with the .NET 6 one
I just lazily copied the same stuff from 4.7 and was getting errors with names 😅
It complains of not being able to load the csproj file and the browse just opens file explorer 😂
just remake stuff then 
sometimes it's easier
the 6.0 one I can access fine but that's not the one I need to access
DllExport command still throws error after hitting installed and apply
I'll just remake this solution from scratch, probably easier
is there a shorter way of checking if two numbers are more or less the same than this:
(_a + 0.001 > _b && _a - 0.001 < _b)```
(_a - _b) > yournumber?
same difference
no
this
i meant yes in agreement to this
so always true
no. what errors?
checked installed then pressed apply from here 🤷
those errors prevent you from building
are you using DllExport in your namespace?
uh
how am i supposed to?
the Gisecke thing doesn't work anymore
either namespace myNamespace or using myNamespace; at the top
not entirely sure what you mean as the gui just means 0 to me
open the GUI and show it to me again
it creates a bat file in your solution folder
just click it
DllExport.bat
this should be correct then
are the errors still there?
I've restarted VS already with the errors remaining
well try with using DllTesting; at top
I said using not namespace
did you select the DllTesting.csproj here?
yeah
yep
this one says you don't even have your own namespace tho?
me either. run the DllExport bat again
yes
pressed apply again for good measure, no difference
wait why have you put the solution and project in the same dir?
maybe try with 1 project at a time first
i had the same issue before when doing this
aha, restarting has worked
cool beans, shouldn't need dllexport for the .NET 6.0 version right?
no
perfect, sorted then. now it's just a matter of figuring out wtf to do which shouldnt be too hard
famous last words
for now just try your extension without the worker stuff
that is probably a good idea
Still getting the invalid nullable value 
wat?
caused by not overriding language version but then get issue with globalusings too, ffs
wat?
that's just from global usings
That's with langVersion 10.0 in the .csproj, without that it gives me this:
Yeah except I don't touch http or anything
yeah those are in .NET core I think
well anyway...
so you get that error from referencing the Worker assembly?
Nope, literally just building it
building what?
either the solution of dlltesting assembly
then what's that worker in there?
literally just this
also why are you even getting that error?
are you copying your csproj?
i haven't a clue, trying to target .net 4.8 without specifying language version so automatically goes to older one
4.8 doesn't even support C#10
that would probably be why its throwing the other error but i get later errors after build attempt saying it needs 10 
well don't use global usings
it's auto generated
that one needs C# 10
just start with a .net framework project first
nothing else
not even another empty project
build that
test it
if it works then do other stuff
console
do dlls not need to be made as a class library 
i have the stuff working in a console app already
im just in the "process" of putting it to dll
change it yourself
Oh right its to target 4.7.2 gotchu
yeah got that
copy pasted the wiki example back in there w/ namespace now and will do dllexport then build
ffs dllexport wont work now i hate this
doing the exact same thing as before, it's just closing without loading the relevant bits and still getting dllexport not found errors
have manually reselected the sln file like 3 times too
is sqf _array = keys (_array createHashMapFromArray []); better or worse than ```sqf
_array2 = [];
{_array2 pushBackUnique _x;} foreach _array;
_array = _array2;
close VS first
then run the bat
how big is _array?
well the second is worse that's for sure
but you can also try arrayIntersect
you are a wizard
roughly 10 to 100 elements i guess
never mind
yep thats the solution i actually want
thanks
check which namespace you saved it to
i see its incorrect on the gui but theres no drop down option for DllTesting 
omfg you can type into it
Just type it yourself. or just use whatever it gave you
fucking hell
who'd have thought you could type into a drop down box
thats worked fine now
now the only problem is visual studio is skipping building the project
ffs
this is like wack-a-mole with issues
wut?
just rebuild
does it have a target file?
should do but just to make sure how do i check in this version
well i flicked some option unrelated and its built now 🤷
finally
only took an entire day 
now try adding the rest
Its half past midnight here and have got in-laws coming tomorrow so will probably call it quits here tonight while I'm ahead
should just be a matter of adapting my previous code to get called from here anyways -- which it already was, just in the same project
just a matter of making it work across project
thanks for all the help leopard, been super useful 🙂
believe so yes
if you give it a unit (or list of untis) as a target, it will run on the machine on which that unit(s) is local
does arma 3 framework provide a way to monitor which players have connected to my arma 3 server and how long they have been connected / active. I want to integrate this into a webApp for my server.does arma 3 provide Api for that?
get players local time and send to webapp from your server
Is there any kind of simple-ish way to increase the fuel consumption rate for a vehicle as a multiplier/percentage?
Alternatively, a way to reduce the maximum fuel capacity
myfuelusagemultiplier = 10;
myfueleh = addMissionEventHandler ["EachFrame", {
private _vehicle = vehicle player;
if(local _vehicle) then {
private _old_fuel = _vehicle getVariable "old_fuel";
if(!isNil"_old_fuel") then {
private _fuel_delta = _old_fuel - fuel _vehicle;
if(_fuel_delta > 0) then {
private _new_fuel = _old_fuel - _fuel_delta * myfuelusagemultiplier;
_vehicle setFuel _new_fuel;
};
};
};
_vehicle setVariable ["old_fuel", fuel _vehicle];
}]
Will only work on current player's vehicle
Otherwise have some array with vehicles and forEach through it instead of vehicle player
you can also get multiplier off the vehicle _vehicle getVariable ["fuel_multiplier", 1]
so you can have different ones per vehicle
Can anybody tell me how to write a script that correctly gets the parent class of a weapon's fire mode? I'm trying to modify CUP weapons to adjust the way AI use them, but I keep running into issues where modes I try to modify appear to be inherited incorrectly. So I presume the script I wrote to find their parents must not be correct.
hmm okay, i was thinking making a system even more modular but i doubt arma would allow that
post your script here
Hi, Maybe some people around here could help us elucidate a bug we've got recently on our zeus private server.
This script, for some reason i'm not nearly qualified enough to apprehend, F's up the respawn system :
while {true} do {
this say3D ["musicname",30];
0 spawn {
sleep 1450;
};
};
We started placing one on a civilian weeping on a tomb to add a sound effect, and then decided to create a working radio with it in our base for the players to enjoy between missions (Also, some voice acted easter eggs and references to the players actions, because why not)
The first thing we noticed is that it makes a very noticeable FPS drop when you actually manage to go near the 3D sound.
The second is that the respawn functionality is F'd up, half the people just spawn on the "dev platform" (A platform outside of the map with the playable units and a couple of things) instead of being given the usual spawn point selection.
As the zeus, i've been a victim of that and when i'm there, I cannot enter the Zeus interface nor the ACE menu, and I'm unable to respawn thru the escape menu. Also, weirdly enough, the "save" button above "respawn" is overlapped with a "skip" button that doesn't do anything when clicked.
I've tracked down the issue to the latest mission file of our campaign, wich is precisely the one where we started using this script. Needless to say, if I remove the script from the unit/item's init, the game runs perfectly fine.
Any ideas anyone ? I'm starting to grow bald with all the hair pulling this error triggers in me 🤣
Our description.ext (nothing fancy)
I don't really understand. The script is obviously going to jam both the game and the scheduler?
Sorry for my lack of knowledge, what's a scheduler, and what do you mean by jam ?
There's no limit on how often that loop is running.
So it's just spamming say3d and spawning the tiny sleep as fast as it can.
Yeah, the idea was to have it play all the songs & voice files, then go back to the start and so on
What would be a better approach for this script ?
Maybe:
this spawn {
while {true} do {
_this say3D ["musicname",30];
sleep 1450;
};
};
removeWeaponTurret seems to be executed in the editor if you put it in an init field.
I've never heard about that functionality. Is there documentation for that?
The command also has no notes on the wiki page
I'll give it a try
I don't understand the difference, but it do be workin' !
Is there a way to hide the helicopter blades on a helicopter in multiplayer? I found some instructions using hideSelection, but it's not working. I'm using the correct part name that I retrieved using selectionNames.
For what purpose?
In aircraft carriers (and in some destroyers) rotor blades are meant to be retractable to save space. I want to simulate that by hiding the rotors, until a player uses an Action added to it that 'reattaches' them.
Well, hideSelection, as BIKI told you, is only for Simple Objects
Damn. 😕 So there's no other trick to do it? Other than ramming it into something and causing the blades to shear. 
well, you could just set the damage on the blades...
but that may not look how you want it to :P
Maybe if you attached a folded-blade object in the right place it'd look passable.
Hmm...
@warm hedge is there any logic to applying "Destruct" materials to a vehicle?
i can read thru the >> 'mat' array but its not as simple as just doing { _v setobjectmaterialglobal [_foreachindex,_x] } foreach _mat
Nnnnnope, unfortunately
Does anyone know how vanilla arma handles an explosive defuse? Like what takes place on the backend to inform the game that its defused. For context im trying to make my ied mod compatible with ALIVE's point system for ied defusal
Do bullets inherit the vehicles velocity it was shot out of?
What are trying to do?
That "Damage" class defines which textures and materials change into which on 0.5 and iirc 1 damage
Or 0.9
On this note, what does "ADDON" mean in sqf and is there a wiki page talking about it?
apply the “destruct” materials to a non-destroyed vehicle
i guess i could build a conversion table in editor by destroying the asset and checking object materials
Ah, you mean knowing which selection should materials be applied to
I guess there is no way to know what material is original one 🤔
GIB
ENTITY selectionMaterials STRING
ENTITY selectionTextures STRING
Wanted to suggest this for a long time:
https://feedback.bistudio.com/T171318
Wdym by "inherit"?
If you mean whether it "affects" the velocity, yes
There's no addon in SQF 
Afaik it converts them to an object
You can check what happens to it using nearestObjects [player, [], 10] before and after you defuse an explosive
As for making it compatible with ALIVE, you probably want to check your configs. Probably your inheritance is incorrect
what about getObjectMaterials <classname>
Should be possible with command in Additional Information
Let us get any textures and materials by LOD selections
yea
Now we need to nag KK or Dedmen until they implement it
Personally I have a need for a command to return default model textures and materials of hidden selections, right now I'm having to find them and define by hand for each class in my config, because there is no way to do it otherwise
Yep, not a reason solution for the issue
Just let us use whatever is in the engine already
its fine for tight outcome with pre defined list of assets
i will write a procedure to check at the start of mission whether current list of scope=2 assets are in the stored hashmap... if not, i will blow stuff up at [0,0,0] and read the change in object materials
so, first run with a new mod/dlc activated == will be a bit messy at [0,0,0] for a few minutes :d
i wonder if worth doing the same thing for texture selections
i dont know still just thinking about it
lineIntersectsSurfaces?
havent done editor tests yet
Good morning,
I can't automate the opening of a portal despite the usual lines of code. an idea ?
the portal is:
Sniper entrée regiment
I think, yes
Then explain what it is?
the line of code does not open it
What line of code? What it supposed to do?
...Just in case, you're talking about Arma 3 right?
Yes Arma 3
Not Reforger? I've looked your log and you posted only in Reforger/Enfusion topics
nom animate ["Door_1_move",1]
Ah finally it starts to make sense
Are you sure:
You named whatever nom properly?
animate is the correct command to do?
Door_1_move is the animation for it?
sliding gates uses this line of code. but this one, impossible
I completely have no idea which object it is but try to use animationNames nom to fetch available animations
Won't help anyhow
Wait, i put it in screen
You put what in what?
- use
animationNamesto get that object's animations list - use one of these names to open it
that's a mod, so nothing is guaranteed.
@meager granite this is sorta working for my uses ... not sure if it will work for mods tho (naming conventions etc)
0 spawn {
QS_array = [];
private _cfgArray = "(
(getNumber (_x >> 'scope') >= 2) &&
(
((configName _x) isKindOf 'LandVehicle') ||
((configName _x) isKindOf 'Air') ||
((configName _x) isKindOf 'Ship') ||
((configName _x) isKindOf 'Reammobox_F')
)
)" configClasses (configFile >> "CfgVehicles");
_cfgArray = _cfgArray apply {configName _x};
private _mats = [];
{
_mats = getArray (configFile >> 'CfgVehicles' >> _x >> 'Damage' >> 'mat');
_mats = _mats select {
(['destruct',_x] call BIS_fnc_inString)
};
if (_mats isEqualTo []) then {
_mats = getArray (configFile >> 'CfgVehicles' >> _x >> 'Damage' >> 'mat');
_mats = _mats select {
(['damage',_x] call BIS_fnc_inString)
};
};
QS_array pushBack [
_x,
_mats
];
systemchat str _forEachIndex;
} forEach _cfgArray;
copyToClipboard str QS_array;
};```
What's the use for these textures?
QS_array_hashmap = createHashmapFromArray QS_array;
_value = QS_array_hashmap get (typeOf cursorObject);
systemchat str _value;
{
cursorObject setObjectMaterialGlobal [_forEachIndex,_x];
} forEach _value;```
I don't think order of materials in "Damage" >> "mat" matters
It can be in any order
not the same order as hidden selections
Plus that array includes non-hidden-selections materials too
is for vehicle wrecks ... preventing vehicle total destruction (clamping at 0.89 dmg) and instead forcing players to recover the asset
i mean the order does appear to matter
mat[] = {
"A3\soft_f\MRAP_01\Data\MRAP_01_adds.rvmat",
"A3\soft_f\MRAP_01\Data\MRAP_01_adds_damage.rvmat",
"A3\soft_f\MRAP_01\Data\MRAP_01_adds_destruct.rvmat",
"A3\soft_f\MRAP_01\Data\MRAP_01_base.rvmat",
"A3\soft_f\MRAP_01\Data\MRAP_01_base_damage.rvmat",
"A3\soft_f\MRAP_01\Data\MRAP_01_base_destruct.rvmat",
"A3\soft_f\MRAP_01\Data\MRAP_01_int.rvmat",
"A3\soft_f\MRAP_01\Data\MRAP_01_int_damage.rvmat",
"A3\soft_f\MRAP_01\Data\MRAP_01_int_destruct.rvmat",
"A3\Data_F\Glass_veh.rvmat",
"A3\Data_F\Glass_veh_armored_damage.rvmat",
"A3\Data_F\Glass_veh_armored_damage.rvmat",
"A3\Data_F\Glass_veh_int.rvmat",
"A3\Data_F\Glass_veh_armored_damage.rvmat",
"A3\Data_F\Glass_veh_armored_damage.rvmat"
};```
base, + 1 = dmg, +2 = destruct
No I mean the order in relation to setObjectMaterial indexes
no idea i am just tinkering
If there was a way to get original object material for each selection, then you could've just searched through that array and index+2 would've been your destruction material for example
ideally yea
Back in the day I always asked to vote for my tickets, now there is no voting anymore so sub to my tickets to show that they matter for you too: https://feedback.bistudio.com/T171318
already done
thank you guys, i find it
p1 animateSource["door_1_sound_source",1]
im trying to disable the inventory of corpses and it works, but is there also a way to hide the gear icon of the corpse?
gear icon?
the icon which pops up when you look at the corpse
Doesn't lockInventory do?
he means the "Rearm" icon
and no there isnt
I think lockInventory was supposed to do it, but it doesnt block the rearm
Arma moment
it should be reported then
and we will purgeban it
burgepan lockInventory 0 not being useful
made a ticket
do we know if "allowFunctionsRecompile" works at all?
I tried years ago and didnt work ... would be handy for me at the moment
I think it stops CfgFunctions initialization from doing compileFinal?
Not sure about other compileFinals
Anyone know how to work Simplex Support Services mod? The scripting/coding on which player gets what assigned support is doing my head in...
I thought simply syncing each support module to certain players would work but my squad level RTO has access to all supports, including artillery meant for commanding officers.
I know there are instructions by the mod dev, but my dumb brain can't make heads or tails of it.
yes

third project that gets referenced by the main dll part and just puts it into the Worker project? 
make it a triangular dependency instead 😄
ffs
#arma3_tools please… I really can't see all this C#/C++ here
its arma scripting i promise ok