#arma3_scripting
1 messages Β· Page 174 of 1
It's probably hard coded into the game's client in the connection process. You might be able to find some documentation on that code but whether or not thats something the mission file can interact with is another ball game entirely.
i meant the server list, it shows there if server is locked or not?
Same thing. You'd have to try to find any documentation on the code that the client uses and the mission file may not have access to that code. I'm hunting and I'm not really finding what I'm looking for as an answer to this, but to be honest if Bohemia was posting detailed code on how their clients communicate with and connect with servers I'd be fairly surprised. Strikes me as something that could lead to exploit generation. But you may have better luck
having script command for this wouldnt probably be a big deal to implement but not many use cases
im making my own server browser so i need it there π
It's in the A3S info or steam query
well steam query works but running that from arma server is like "ask the master server if we are using password"
a command to get that info would be much better
interpolating between two points, but with a "curve" if you will toward another known point. any idea how i would go about this? constrained by setvelocitytransformation
epic diagram provided also
curved line is what i want, straight line is regular interpolation (dont want)
i saw that when i was digging. would it work with setvelocitytransform?
π€·
quick turned into a hot minute with steam doing its restart update malarkey
okay:
so it works, but im not quite sure how to plug it in so to speak
(interval bezierInterpolation [_lastIndexPos,((_lastIndexPos vectorAdd _nextIndexPos) vectorMultiply 0.5) vectorAdd ((vectorDir Obj) vectorMultiply 25),_nextIndexPos])
as i have to define the start and end pos in setvelocitytransformation
so after some tinkering, solved the math issue but you kind of phase out of existence upon reaching your destination
probably gonna have to rework it
even weirder, it seems to work better, the less straight the curve
im an idiot, vectorSide instead of Dir
i get a lovely debug line drawing the path i wish it to take, however the problem persists with setvelocitytransform, it likes to fall apart the moment you reach the final point
Obj setVelocityTransformation [
interval bezierInterpolation [_lastIndexPos,((_lastIndexPos vectorAdd _nextIndexPos) vectorMultiply 0.5) vectorAdd (vectorside Obj),_nextIndexPos], // From point
interval bezierInterpolation [_lastIndexPos,((_lastIndexPos vectorAdd _nextIndexPos) vectorMultiply 0.5) vectorAdd (vectorside Obj),_nextIndexPos], // to point
[0,0,0], // from vel
[0,0,0],// to vel
(vectorDir Obj), //fromVectorDir
(vectorDir Obj), //toVectorDir
(vectorUp lastindex), //fromVectorUp
(vectorUp nextIndex), //toVectorUp
interval]; //
currently the code, i know it doesnt like it because when it reaches 1 / past 1 its going to throw a fit, if anyone has a fix, it would be appreciated
Use setVelocity etc after it reaches to 1
setvelocitytransformation after the bezierinterpolation?
and use setpos instead?
not too sure i follow
setVelocity to reset the velocity after setVelocityTransformation loop has ended
when it reaches 1, it simply selects the next index and continues running
its iterating through an array
hence the _nextIndexPos, _lastIndexPos
the interval is being modified by ```sqf
interval = interval + thrust;
so setvelocity shouldnt have any bearing on it
Okay then, I'm sure that I'm not understanding your goal
uhhhh. like a train taking a corner rather than direct
Then the interval should between 0 and 1?
yes
Then what it
when it reaches 1, it simply selects the next index and continues running
does mean? Another round of loop should happen?
its going to throw a fit
What does this mean
the object cant decide where it should go, and starts having unintended behaviour
which breaks the current setup
let me get back to my pc and ill explain better
so:
right now i have a system that does this. it moves between points using setvelocitytransformation.
it moves directly between them. i dont want this.
i want something more like this (red line)
thats where the bezierinterpolation comes in, putting it into the setvelocitytransformation either completely breaks, or when it reaches 1 it starts moving the object irratically and breaking the simple cycle of resetting the interval and giving the loop a new target
https://learn.scannerlicker.net/wp-content/uploads/2014/04/bezier0011.png
Bezier is this. Not really exact you want
quadratic curve seems more in line with what im doing but im not sure anymore
so uhh. how do i do it then
I wouldn't just use bezierInterpolation and setVelocityTransformation even, if you're doing railway something, but enough amount of setPosASL setVectorDirAndUp
And EachFrame too
previous iteration of this script showed that running on each frame setposASL and vectors etc floods MP network. it worked and produced the intended mechanic but it heavily restricted what could be done while it was running
setvelocitytransformation on the other hand seems to be alot more performance friendly for the server
Hm MP desync is a point indeed
I see, setVelocityTransformation is optimized for that purpose
i wouldnt be using it if i didnt have to
it kind of sucks to be honest
its great that it exists, just feels clunky to use at times
there is an alternative solution to this but it may just make me rip my hair out, i pre calculate alot more smaller points between the original points to simulate a curve between them
it would require rewriting most of the function however
so i really hope there is a way to create the curve within the setvelocitytransform
running my current setup with the bezier creating markers outside of the scope seems to be working fine, just cant figure out why it breaks when inside the loop
What break, what loop
its okay, i think i fixed it with some tinkering, fired the next index calculation just a tiny bit sooner and it stopped breaking it.
WOHOO
what a frking joke!
createLocation and getVariable have a fancy behaviour
GVAR_GVARS_missionContext getVariable [ "MissionReady" , false ]```
now lets play some QUIZ
which issue will be thrown π
A: No issue, No problem
B: No issue, Return valie is messed up
C: <ENTER ISSUE HERE>
see the answer here:
Looking for someone who can update this customized hetman mission to also include jets and planes even in custom factions and make them fly around ingame
Send me a dm for more info
Hello
It's surely pretty basic, but I've been stuck on this for the last 3 hours (and I've rarely had that much tabs open)
I'm preparing an op that will run on Dedicated, and I expect that most people will JIP because the dedicated server is usually opened 30 mins before the mission start, to find out any leftover game-breaking bug that slipped through the cracks during testing
After some research, I found that SetVariable has a JIP option
My code in init.sqf is :
private _players = allPlayers; _players setVariable ["blowout_safe", true, true];
The games tells me when I start my mission :
"Error setvariable : Type Array, expected Namespace,Object,Group,Display (dialog),Control,Team member,Task,Location"
I don't understand, as the setVariable wiki page do not say anything about using an array like this, and this script works on trigger.
Can anyone help me please ?
You need use for each to apply variable for each objects
See forEach
https://community.bistudio.com/wiki/forEach>
ok thanks I will
So if I understand correctly, I need to execute my code on every client using forEach
But the two ways I did find to get that list in MP both won't work : allPlayers and BIS_fnc_listPlayers
That becomes something like :
private _players = allPlayers; _players setVariable ["blowout_safe", true, true] forEach BIS_fnc_listPlayers;
maybe I can use setVariable without _players before ? I'm lost, any advice you can give me ?
You need just
private _players = allPlayers - entities "HeadlessClient_F";
{
_x setVariable ..
} forEach _players;
Where _x reference one object in array.
Where do you use your variable and how?
Currently you will set for every client true when ever client enters in game.
So you want set true on player when he joins, and will that value change middle of game?
Because you can use
//initPlayerLocal.sqf
player setVariable ..
And use true if you want every client get that variable from player object.
But if you use that variable on client only you don't need broadcast that for everyone.
Depends alot where and how do you use that variable
right I see thank you
I just want it to be set once and for all when a player joins, and that variable will stay this way during the whole operation, but by default it's set to false
I thought about using InitPlayerServer, and I read it's not ideal, and I was afraid that the variable would need to be executed globally for the server to interact with it (the variable protects you from the lethal effect of a server-wide event)
Variables set on objects are already global, global and synced are different
At that point just do something like:
// Do the big thing
private _players = allPlayers - entities "HeadlessClient_F";
_players = _players select { !(_x getVariable ["TAG_safeFromTheBigThing", false]) };
thanks π
I think it will be better:
private _players = allPlayers - (entities "VirtualMan_F");
Just change "TAG" to something unique to you, the mission, etc.
I'm using a slider GUI to rotate a GUI object all the way around one axis using a formula I found in the setVectorDirAndUp biki page, but I'm noticing that despite the fact that there seems to be more of an effect at the beginning and ends of the ranges than in the middle. This is the formula I'm using:
((ctrlParent _ctrl) displayCtrl 1600) ctrlSetModelDirAndUp [
[sin _yaw * cos _pitch, cos _yaw * cos _pitch, sin _pitch],
[[sin _roll, -sin _pitch, cos _roll * cos _pitch], -_roll] call BIS_fnc_rotateVector2D
];```
Is there a way to make it so it turns at a constant rate or is that... not possible with the VectorDir system?
That's for rotating a picture, not a model
Yeah
hello all, im having a question, how to create a mod that are with capability with "zeus play sound module"?, wanted to make a mod that add's a battlefield sounds and some kind of a radio transmissions
for example like this mod https://steamcommunity.com/sharedfiles/filedetails/?id=2461386136
hmm ... ^ @lavish ocean
Hey guys, I'm trying to achieve something with my very little knowledge of scripting and don't know where to start. I need to figure out how to end my mission when a specified number of players and ai are killed on the bluefor side. Its interesting because I'm using a script to recruit ai to your squad while ingame and these ai would need to be counted in that number. Any help would be great π
@snow herald if (idiot) exitWith {"Velocity shifting persons ukulele"}
Are remoteExec and publicVariable commands ordered?
Here is my code. I am saving info from a server onto a client and then remoteExecing a save to missionProfileNamespace.
if (!isMultiplayer) exitWith {};
{
_curatorUnit = getAssignedCuratorUnit _x;
if (isNull _curatorUnit) then { continue };
if (hasInterface and { _curatorUnit isEqualTo player }) then { continue }; // skip self hosted zeus
// _netId = netId _curatorUnit;
_netId = owner _curatorUnit;
_netId publicVariableClient "bax_persist_saveDate";
_netId publicVariableClient "bax_persist_databasePlayers";
_netId publicVariableClient "bax_persist_databaseObjects";
_netId publicVariableClient "bax_persist_databaseVariables";
_netId publicVariableClient "bax_persist_databaseInventories";
[] remoteExec ["bax_persist_fnc_zeusSaveDatabase", _netId]; // net id or unit reference would work here
} forEach allCurators;
addMissionEventhandler ["EntityKilled",{
if (side group (_this#0)) then {
// put a code to increment a variable
};
}];```First step might be EntityKilled event handler
Almost certain they are, but you better test
There also used to be a bug related with network messages being reversed at some points, not sure if it applies to these messages too or this bug even exists anymore
The bug was fixed but I don't know if it fixed it everywhere or only for where it was found - vehicle turrets
tl;dr; Yes but better test it
The order is meant to be guaranteed for live execution, but not for the JIP queue.
Which I still think is absolutely horrific, but there it is.
Is this really so?
For remoteExec JIP specifically - there's a separate JIP queue for engine messages which is guaranteed
#perf_prof_branch message
I don't think that means remoteExec JIP will definitely or even likely be out of order, but it could be
@timid oyster yes this can be done
theres many ways to do this but heres a start for you
//trigger
//Condition
{alive _x} count units USMC <=10;
//OnActivation
["end1"] remoteExec ["BIS_fnc_endMission"];
// then ofcorse in the description.ext
//Debriefing
class CfgDebriefing
{
class End1
{
title = "MISSION COMPLETE";
subtitle = "Hostiles Eliminated";
description = "All Enemy K.I.A";
backgroundPicture = "";
picture = "";
pictureColor[] = {0,0,0,0};
};
class End2
{
title = "MISSION Failure";
subtitle = "USMC KIA";
description = "Failed To kill All Enemy";
backgroundPicture = "";
picture = "";
pictureColor[] = {0,0,0,0};
};
};
many people don't realize there's so much stuff in the default game that is very easy to use, read read read more
i want to have an action on an object, that when called by a player, it will open their map and wait for them to click on a location before using that location to create a waypoint for a helicopter. i was going to use onMapSingleClick for this but on the biki page for it, it says to use MapSingleClick mission event handler for it instead. how am i meant to do this? its a mission event handler so i cant have it JUST for one person right?
oh god locality my worst nightmare
i still dont understand it at all (and probably never will properly lmao)
agh ill figure it out tomorrow, its too complicated for my pea sized brain π
dude ive read through ALL of this atleast 20 times. im just stupid lol ill never understand it properly no matter how much i read about it
basically local means which computer is handling the object
Action code is executed on the machine of the person who did the action.
If you addMissionEventHandler in action code, without using remoteExec, the EH will only be added on the machine of the person who did the action.
_object addAction [
"Teleport",
{
params ["", "_caller"];
openMap true;
addMissionEventHandler [
"MapSingleClick",
{
params ["", "_position"];
_thisArgs params ["_unit"];
_unit setPos _position;
openMap false;
removeMissionEventHandler [_thisEvent, _thisEventHandler];
},
[_caller]
];
}
];
*removeMissionEventHandler
Im looking at grabbing entities of particular categories. I have done some exploring of the inheritance and think i have got the right ones. Doing testing now, but would anyone have any insights or suggestions here?
Vehicles: ["LandVehicle", "Air", "Ship"] Has to be LandVehicle and not Land because Land includes man
Ground Items: ["WeaponHolder", "WeaponHolderSimulated" The simulated variant inherits from ThingX. Anyone know where the simulated variant is used by the game?
Objects: ["ReammoBox_F", "Static", "ThingX"]
I believe simulated is used for weapons dropped by killed units
So I am using nearObjects but that also picks up buildings from the map/terrain. Is there a way to exclude these or another command that gets only spawned objects (including 3den)?
For more context, this is for persisting an area of objects, which might include stuff built using ace fortify or placed by zeus. But NOT from the terrain.
umm notTerrainObjects = nearObjects - nearestTerrainObjects not sure if that works π
is there a local alternative to animateSource?
pretty much this is it
Depending on what type of objects you're after, you might be able to use nearEntities instead
If they're not necessarily entities you'll have to do what GC8 said
Im afk so ill test this later, but do you know if vehicles being driven are considered entities?
hey guys
I am using live radio beta and want to figure out how to place radios on the ground to play audio
class LandVehicle;
class Car: LandVehicle {
class ACE_SelfActions {
class GVAR(open) {
displayName = CSTRING(DisplayName);
statement = QUOTE(_target call FUNC(open));
condition = QUOTE(_target call FUNC(canOpen));
};
};
};
class Items_base_F;
class Land_FMradio_F: Items_base_F {
class ACE_Actions {
class ACE_MainActions {
selection = "interaction_point";
distance = 5;
class GVAR(open) {
displayName = CSTRING(DisplayName);
statement = QUOTE(_target call FUNC(open));
};
};
};
};
};```
the mod states here that ``` Items_base_F;
class Land_FMradio_F: Items_base_F {```
is the object I am looking for. is there a way to search for this in game?
Search for what in where?
This module won't show in the zeus menu... Any ideas?
I need it to only show in zeus and not editor
CfgPatches, units[]
I forgot about that. thanks
Yes
I can't use getVariable on locations either (1.55 dev)
But I can an error message:
11:46:45 Error in expression <LOC getVariable ["Test", 2]>
11:46:45 Error position: <getVariable ["Test", 2]>
11:46:46 Error Generic error in expression
classname LOC
""
Probably because that is a streamed location.
Can confirm, with a createLocation'd location only the simple syntax works,
How would i remove data from a hashmap, if the position matches ? 
[["UID",[["CLASSNAME1",[19325.8,14066.6,-0.0228806]],["CLASSNAME2",[19328.1,14070,-0.0228806]]]]]
I don't want to remove the whole key, only the value array where there position matches.
I bet there is some easy way somewhere hidden xD
Have you read the article? deleteAt allows deletion of array elements.
private _myMap = createHashMapFromArray [["a",1], ["b",2]];
_myMap deleteAt "b"; // _myMap is "a",1
I don't want to delete the key "b" i only want to delete the data if possition matches
And what's the problem?
So in hashMap or in class ?
get "UID" deleteAt "CLASSNAME2"
What you want delete?
You need be more specific, you can check does your data exist and delete if that exist
The whole "value block" inside the hashmap, so [["CLASSNAME1",[19325.8,14066.6,-0.0228806]] but only if the position is equal.
I tried find but no success, not too much experience with hashmaps yet
{
_uid = _x;
_objectPositions = _y;
{
if (((_x select 1) distance _position) < _delta) then {
_objectPositions deleteAt _forEachIndex;
};
} forEachReversed _objectPositions;
if ((count _objectPositions) == 0) then {
_hashMap deleteAt _uid;
};
} forEach _hashMap;
Thanks, i will try with that. 
Works β₯οΈ
{
_uid = _x;
_objectPositions = _y;
_position = [19325.8,14066.6,-0.0228806];
_delta = 1;
{
if (((_x select 1) distance _position) < _delta) then {
_objectPositions deleteAt _forEachIndex;
};
} forEachReversed _objectPositions;
if ((count _objectPositions) == 0) then {
TestHash deleteAt _uid;
};
} forEach TestHash;
Move _position and _delta outside the loop. Or even better make them constants using #define macro.
Yea just as a test to see if it works, gonna rework everything.
Thanks again π
Another optimization tip -- use https://community.bistudio.com/wiki/distanceSqr.
except in half of my tests distanceSqr ends up slower than distance somehow π€£
methodology: in debug console, prepare 2 arrays of 5000 elements with
MUH_arr1 = [];
MUH_arr2 = [];
for "_i" from 0 to 5000 do {
MUH_arr1 pushBack [random 1000, random 1000, random 1000];
MUH_arr2 pushBack [random 1000, random 1000, random 1000];
}
measure the runtime of
_accumulator = 0;
{
private _v1 = _x;
{
//code here
} forEach MUH_arr2;
} forEach MUH_arr1;```
with the measure button of debug console. Results vary between `distanceSqr` being 70-ish ms faster (with total runtime of 16.5k-ish ms) over those 25M runs when i accumulate the results into accumulator with `_accumulator = _accumulator + (_v1 <instruction> _x);` to it being 170-ish ms slower (out of total 4k-ish ms) when i just run `(_v1 <instruction> _x);` 
The main bottleneck is memory due to cache misses.
Not CPU cycles by using a heavy instruction like square root
Aren't CPUs like past the point where square rooting was an issue? π€
I'm pretty sure I've heard that this is optimized now, but don't remeber where
Can confirm, a year or so ago I did test distance VS distance2D VS distanceSqr
The difference was insignificant
So anyway... Good day. Is it possible to disable collision for an NPC? My player object can bounce poor fellas all over the base, which is not good
So far I've tried: disableCollisionWith and setPhysicsCollisionFlag with no luck
Not really. A square root's still much slower than a multiply (maybe 1/20 throughput? depends on CPU). It's more that the other overheads of SQF are so large that the square root is negligible.
A good rule of thumb with SQF is that perf cost is proportional to command count, although there are some commands that are actually slow (intercepts, sort etc).
Can anyone help me get this working?
https://github.com/diwako/ACRE2-Custom-Signal-Calculation
I put the folder into my mission folder as per the instructions but I'm not understanding the change the description.ext in the cfgfunction
Open the example.
theres an example?
Yes.
Would that be the mission.sqm file?
I don't know much about scripting, I'm trying to learn, and I was hoping to use something like this in upcoming missions. Idk where the cfgfunctions are and such
Open the link.
OK looking at lines of code.
Ah ok. So how do I access the cfgfunctions for the mission?
Cause I see the example, and what I need to add
As it's written in the description:
edit your description.ext's CfgFunctions class like in the example
again, not following. I'm still fairly new at making missions indepth.
What's the difference? The description tells you what to do.
I'm not seeing a description.ext in my mission folder.
Create it.
Oh
It's just a file: https://community.bistudio.com/wiki/Description.ext
class Header
{
gameType = Coop;
minPlayers = 1;
maxPlayers = 20;
};
disabledAI = 1;
OnLoadName = "Sideline";// Mission name (short)
onLoadMission=""; // Longer description
briefingName = "Asset Procurement";
overviewText = "Early in the morning team 2 went radio silent. Find them and the asset";
// loadScreen = "viking_2.jpg"; // custom load image
author="Laggies;
// Debug (and CBA target debug)
enableDebugConsole = 1;
enableTargetDebug = 1;
class CfgFunctions {
createShortcuts = 1;
#include "scripts\acre_custom_signal_calc\funcs.hpp"
how's this?
the class CfgFunctions { and below seems incomplete, you can remove (unless there is more below of course)
also, missing a double quote " in author
class Header
{
gameType = Coop;
minPlayers = 1;
maxPlayers = 20;
};
disabledAI = 1;
OnLoadName = "Sideline";// Mission name (short)
onLoadMission=""; // Longer description
briefingName = "Asset Procurement";
overviewText = "Early in the morning team 2 went radio silent. Find them and the asset";
// loadScreen = "viking_2.jpg"; // custom load image
author="Laggies" ;
// Debug (and CBA target debug)
enableDebugConsol e = 1;
enableTargetDebug = 1;
// VVVVVV this is the important part! VVVVVV
class CfgFunctions {
createShortcuts = 1;
#include "scripts\acre_custom_signal_calc\funcs.hpp"
}
Is this fixed?
class CfgFunctions {
createShortcuts = 1; // β this doesβ¦ nothing?
// ...
}
class Header
{
gameType = "Coop";
minPlayers = 1;
maxPlayers = 20;
};
disabledAI = 1;
onLoadName = "Sideline"; // Mission name (short)
briefingName = "Asset Procurement";
overviewText = "Early in the morning team 2 went radio silent. Find them and the asset";
author = "Laggies";
enableDebugConsole = 1; // debug
enableTargetDebug = 1; // CBA debug
class CfgFunctions
{
#include "scripts\acre_custom_signal_calc\funcs.hpp"
};
Shouldn't there be a ; after that last } ?
Yes
^
edited (so you can copy)
Do I need the path for the image or the image name itself?
both?
I have the image in it's own folder. within the mission folder
then ImageDir\image.jpg
hello brothers: how do i disable the respawn tab, in the game menu, when someone hits the ESC key, and trys to respawn that way
i saw it some where but i forget where
You can just do respawnButton = 0 in description.ext
Alternatively if you need to script it, you can just disable the control when the game is paused, although I can't check the idc currently
yes im about to try that
but dont that just disable the respawn in the retrive thingy
yeah thats what i want to do is disable the respawn when the game is paused oh btw Dart Thx for all your help that you gave me over the last some Months
Hello,
How to use "default" value if x vehicle doenst have maxSpeed defined, Just "for sure" case, because all that i tested have, but never knows.
private _max = getNumber (configFile >> "CfgVehicles" >> _type >> "maxSpeed");
and if "maxSpeed" is not defined, i want use lets say 150
if its not defined then getNumber will return zero
you can also do ```sqf
if(!isnull (configFile >> "CfgVehicles" >> _type >> "maxSpeed")) then
Seems so, thanks.
I will use "default" 50, so if under 50 or undefined then 50.
private _max = getNumber (configFile >> "CfgVehicles" >> _type >> "maxSpeed");
if (_max < 50) then {
_max = 50;
};
or check before getting with isNumber <configPath> 
_max max 50```to optimize it
how this works, never used
just
_max max 50
(0 max 50) == 50;
(150 max 50) == 150;```
_max = _max max 50 is equivalent to if (_max < 50) then {_max = 50;};
Aaawesome!
thanks guys.
sooo
private _max = (getNumber (configFile >> "CfgVehicles" >> _type >> "maxSpeed")) max 50;
Can this do oneline? XD
Yes
How would one make AI infantry fire with small arms upon vehicles?
I'm not sure its possible but I might just be silly
my ai fire like hell at my vehicles all the time
i guess it depends on how much of a threat the vehicles is to them
Maybe it's just me
Or the circumstance
Also I thought you went to bed?
i did but i was thinking about Arma 3WooHoo
I'll show you the scenario if you liek
you want to go in voice ?
sure
ok
it depends on the vehicle setup
Seems someone looked into this a while ago. Might be a better way to do it now, but
#arma3_scripting message
Hi. How make "tank death circle" script? How check actual move bind and it be continued when the crew is sent to 200/300?
Key sticking script
https://community.bistudio.com/wiki/inputAction with "MoveBack", "TurnLeft", "TurnRight", and/or "MoveForward"
Oh you want to hold the key, not check it
Does anyone know if it's possible to add a picture to the server directory while the server is running, then set a texture selection to that texture?
Basically allowing you to "upload" pictures to screens for example
No
Not even using filePatching?
Well, if the idea is to allow clients to upload one and share to everyone, no
I could do like an HTML file, and have ARMA open it, and based on what was passed, it could just show a different image or something.
Would require a weird http server in the middle, but it's not the first time we've done that lol
And urm... is there anything that Arma is involved?
Yes, it's opened through ARMA
So, open an interface through Arma, upload it into somewhere, use it in Arma as a texture?
Brainstorming something while at work, you can't have a "conditional" respawn point correct? You'd have to add/remove the point.
Being able to disable / re-enable a respawn point also works
I think you could do this with UI-to-texture and the CT_WEBBROWSER UI control. CT_WEBBROWSER is still on dev branch though, so not yet.
if (currentVisionMode player == 1) then
{
hint "nightvision active";
};
how would i go about making this for a vehicle flir?
currentVisionMode _x == [0] or currentVisionMode _x [0] would work?
i'll try
we have an forEach on that if
it's currently
if ((currentVisionMode _x != 0)) then
{
Script
}; forEach _Units
to detect if the ai is using any sort of thermal
so would we need to make it
if ((currentVisionMode _x != 0) or ((currentVisionMode _x) == 2)) then
{
Script
}; forEach _Units```
For what purpose? currentVisionMode shouldn't do anything with AI
Or at least, that wouldn't do anything you expect
trying to adjust a script that makes AI see lasers
it's only working with infantry currently
it gets an array of units within an area near the point the laser is pointing and executes a script that increases the knowledge of the AI of the play using the laser
Then check their hmd and fetch its config so you'll know the goggle they use is NV/TI compatible
I believe currentVisionMode really do nothing with AIs
but doesn't that only work with AI that has an helmet with AMD?
if (currentVisionMode _x != 0) selects all the ai that has some sort of modified vision and applies the script
we just need to select the vehicles that either have flir or have the driver using nvg too
Okay I stand correct. You're correct but I don't even know if they would use Thermal anyways
CSAT units in vehicles have they nvg's on
i just need to select them when they have that
i say "i just" but i know is not that simple
Okay, what is your current question?
how can i add the vehicles that have their Vision mode different than 0 (no vision mode), to that if
Do you mean expand the filter to vehicles?
yes
_Units = (_Pos NearEntities [["Man", "Car", "Tank"],20]) select {!isPlayer _x}; where _Pos is the point where the laser hits
we can confirm that the _Units array gets the vehicles, we need to include them in the If()then{}forEach
Fetch all vehicle and check their config. There are many ways to define them, can't point what parameters do right now
go the long way, k, i'll see what i can do
Also,sqf if () then {} forEach; you say is not the syntax you can use
ty
i'm trying to understand what you said here, you mean this shouldn't work?
Indeed
Params ["_Speed"];
// Intersecting positions
_BegPosASL = EyePos Player;
_BegPosAGL = ASLTOAGL _BegPosASL;
_EndPos = (_BegPosAGL vectorAdd ((Player weaponDirection (currentWeapon Player)) vectorMultiply 1000));
_EndPosASL = AGLTOASL _EndPos;
// Intersecting objects
_ins = lineIntersectsSurfaces [_BegPosASL, _EndPosASL, player, objNull, true, 1, "FIRE", "NONE"];
_ins select 0 params ["_OriginalPos"];
if (isNil "_OriginalPos") exitWith {False};
_Pos = ASLTOATL _OriginalPos;
// Area to scan for units
_Units = (_Pos NearEntities [["Man", "Car", "Tank", "APC", "Air", "Static", "Helicopter"],75]) select {!isPlayer _x};
// Check each unit and reveal if able to see laser.
{
if ((currentVisionMode _x != 0)) then // If using nightvision or thermal
{
if (((_x getRelDir _Pos) > 300) or ((_x getRelDir _Pos) < 60)) then // If looking in the general direction of the laser position
{
_Knowledge = _x knowsAbout Player;
if (_Knowledge < 3.8) then
{
_Value = [1, _Knowledge + (4*_Speed)] select ((_Knowledge >= 1) && (_Speed != 0));
[[_x,_Value,Player],
{
Params ["_Unit","_Value","_Player"];
_Unit Reveal [_Player, _Value];
}] remoteExec ["BIS_FNC_SPAWN",_x];
};
};
};
} forEach _Units;
the script currently
and it works
oh i see now
You saysqf if () then {} forEach;
And your code is sqf {if () then {}} forEach []
Totally different
Quick question am I doing something wrong here:
getMissionLayerEntities "EastMarkers" params ["_objectsEast", "_markersEast"];
{
if(side player != east || side player != civilian) then
{
_x setMarkerAlphaLocal 0;
};
}foreach _markersEast;
systemChat format ["%1",_markersEast];
I have a layer of east markers with all of the markers that i want only to show to East side players.
This script is located in InitPlayerLocal.sqf.
But when i hop on as a Opfore i cant see the markers.
P.S. _markersEast array isnt empy it shows there.
Because you are not a civilian either?
i guess that worked but isnt the or if 1 of them is true then execut ?
Being an OPFOR means false || true so true
I mean yea but if you are opfor and execute this code:
if(side player != east || side player != civilian) Witch should be true || false
run code but it dosent get executed.
nvm i see where i goofed i am coocked nvm,

So like this:
//InitServer.sqf
LEG_EastMarkers = getMissionLayerEntities "EastMarkers";
//InitPlayerLocal.sqf
LEG_EastMarkers params ["","_markersEast"];
{
if(side player == west) then
{
_x setMarkerAlphaLocal 0;
};
}foreach _markersEast;
``` ?
if you add publicVariable "LEG_EastMarkers"; to your InitServer as well - it may even work 
if (playerSide != east) then {
_markersEast = (getMissionLayerEntities "EastMarkers") param [1, []];
{
_x setMarkerAlphaLocal 0;
} forEach _markersEast;
};
Despite this, the command works on client side, but returns only markers, not objects.
I think this would be correct way for this to execute.
//InitServer.sqf
LEG_EastMarkers = getMissionLayerEntities "EastMarkers";
publicVariable "LEG_EastMarkers";
//InitPlayerLocal.sqf
LEG_EastMarkers params ["","_markersEast"];
{
if(side player == west) then
{
_x setMarkerAlphaLocal 0;
};
}foreach _markersEast;
You execute the command on server and get the array of all of the markes to a var. Next you share that var with all of the clients and then compare their side and localy hide the markes on their side.
Also Initorder is correct becouse InitServer executes before InitPlayerLocal so its not possible to have LEG_eastMarkers empty if you run it this way.
Yes, it mostly will work, but you can avoid sending values over network if you use my code.
IDK what is under the hood of getMissionLayerEntties but its a serverExec.
Read what I wrote.
Also, since the order of execution is not guaranteed (initPlayerLocal.sqf may be executed before initServer.sqf), in some cases your code may not work.
what do you mean ? https://community.bistudio.com/wiki/Initialisation_Order
If you need guaranteed order, use init.sqf.
But again, you can avoid sending values over network.
I see. Will try both methods and see witch one works.
Use my solution.
Howdy yall, Does anyone know of a script for the use action teleporting that changes time when you use it? Preferably with a fade to black.
or a script that makes a localized area dark when you enter it like a bunker
@faint burrow hay m8 thats really awsome thx you m8
and hello again @faint burrow your 1 of the good guys in here
even tho im not very good i can tell who is good π
Note that for most of the init scripts, Arma doesn't wait until they complete before running the next one. So some code in initPlayerLocal.sqf might run after code in init.sqf in MP, for example.
If you want to guarantee that the whole of one runs before some code in another, then you should enforce that with global vars & waituntils or similar.
@dapper cairn what i would do to change the time at any time in game is i would have my parms of time set ofcorse, then as you say black out the view, then call the time to a diff pram in the params
Also testing that it works may not be sufficient, because mod selection, client vs localhost, linux vs windows may all change timings.
Hello is there a simple way to get the ISO time via scripts? I cant seem to find anything
ISO? there is https://community.bistudio.com/wiki/date command
Sorted all good
ISO = International Standards Organisation
Hello, I'm looking for some help with an issue I'm having which I cannot find solution to...
I am trying to save a variable on a dedicated server, to which this code is running on the dedicated server, my problem is, it's not getting saved on the .vars file, this is the code I'm testing with:
missionProfileNamespace setVariable["my variable",123];
savemissionProfileNamespace;
I DeRap the .vars file and I notice that it didn't get saved, checking bistudio's wiki about setVariable, I am doing everything correct to save my variable, yet it does not do it, what could be causing my issue? am I missing a setting on the server or on the mission file?
this is what I get in the .vars file
#define _ARMA_
version = 2;
class MissionProfileVariables
{
items = 0;
};
Any help would be appreciated
Which vars you read?
ArmA 3 Server > Servers >_"weird numbers and letters" > users >"repeats same weird numbers and letters" in there it creates a file named after the mission file and then .vars
MyMission.vars
I delete the file, run the setvariable line through the debug console, I get a "true" feedback, the file is generated again, and still without my variable
- You sure what you read is the correct profile's vars?
- You sure you run the code in Dedicated properly?
or am I being dumb and not waiting for the file to finish?
current testing I'm using the Server Exec button, I'll add redundancy and run it through
[missionProfileNamespace,["myVar",123]]remoteExec["setVariable",0];
ran it as such, it updated the .vars file, still same issue
I would make it sure if your Debug Console is actually running your code
it is, as the file gets generated
this is frustrating me, and I appreciate helping me out
What about more obvious ones, like systemChat or diag_log
like a feedback on the variable to then print on systemChat?
Yes
Indeed theoretically your code should work. I also would to try if getVariable to see if you can see 123
getVariable returns empty
hmmm
do I need to have "save" enabled on the mission or set something on the description.ext beforehand?
How did you test it? AFAIK just run on server button in Debug Console won't simply transfer the return value to your (local client's) Console
And no, description.ext etc is not involved
I believe I could be missing a setting or parameter enabled to allow it to save the variable
well, I'm not checking feedback from the debug console itself, although on the bottomline it does return me feedback
my feedback is on DeRap'ing the file it generates
I'm gonna check my own client's probably it's saving it there
Okay... I think I want to start it from very simple checks (again)
- What code do you run to set? In what context?
- Does the code even run? (Does
diag_logreturn anything/prints properly?) - What code do you run to get? In what context? Can you confirm it is
nilor123, and how? - Just in case, which folder you actually look?
I just tried
- Launch a Dedicated
- Login as a client, run a random mission
- Run Server Exec
sqf missionProfileNamespace setVariable["my variable",123]; savemissionProfileNamespace; - It produces
MP_COOP_m01.vars - DeRap returns
cpp class MissionProfileVariables { items = 1; slots = 15; class Item0 { name = "my variable"; class data { singleType = "SCALAR"; value = 123.0; }; readOnly = 0; }; };
1.- ```sqf
if(!isServer) exitwith{};
_marker = AllMapMarkers select {markerColor x == "ColorGreen" && "z" in _x};
profileNamespace setvariable ["INS_mission_progress",_marker,true];
basically saving map markers colored green, been running a hint to make sure the markers get selected, it does work
2.- where can I check the diag_log? that seems very helpful, I am unexperienced with it
3.- basically what's on 1, then I locate the location of the .vars file generated and I check to see if it's there
4.- B:\SteamLibrary\steamapps\common\Arma 3 Server\Servers\_242ed36d75bc497699a6938e948daba0\users\_242ed36d75bc497699a6938e948daba0
this is the path to the server and its folder, its the only one I run on my PC for testing
I don't know why Discord failed to format it properly... but anyways
discord being discord
Just like Arma
pretty much lol
yeah I should be seeing that as well, that's what puzzles me, why is it not generating it? I'll load a random mission see what happens
- Not sure, I mean, because I see no
missionProfileNamespacemention? diag_logwill be printed into your RPT, in this context, your server's RPT
nothing popped up on the rpt file, hmmm
I keep getting 22:28:07 Server: Object 2:4349 not found (message Type_114) but I think that's related to triggers
Just in case... are you sure your Debug Console is actually enabled?
No, I don't mean you see it properly. It sometimes not work
I don't reacall what I've done to make it work, but give me a bit
Yes
ah
well, if I server exec a hint, I shouldn't see it, lemme try that
yeah didn't see the hint, so I think it is indeed running it on server
https://steamcommunity.com/sharedfiles/filedetails/?id=2000131738
Just in case actually. Do you run this or similar Mods on both client and server?
I mean, I just recall without this Console work funky
I see that on the image it says "NO CBA" could CBA be causing the issues?
It just mean Without CBA it does look like this
Instant
ran it globally as well, no difference
hmmm, there's gotta be a setting I'm missing
gotta test a blank mission see if it works
"Enable Saving" shouldn't affect it, right?
Indeed not related
Indeed
maybe I should verify my files
well POLPOX, I really appreciate your help with this issue, I will post an update here if I find the solution to this issue, I'm going to try and figure out if its my system or the mission file itself
Maybe try without Mods (except the console) and try a simple mission like I've done (Stratis' Escape 10)? Otherwise I'm lost as well
I just tried the console mod you gave me, it worked and saved to missionprofileNamespace
it finally worked!
so, seems that what fixed my issue was to run
enableDebugConsole = 2;
and then my debug console actually worked
Everything was a twist all the time 
anyone know if there is a way to use " inside of a typeText command without messing it up?
typeText?
yeah, BIS_fnc_typeText
Im trying to to display coordinates but the " from the coordinates creates issues
"'" '"' etc
thank you for all the help! you solved my issue
thanks
Good day to everyone.Please tell me a banal thing.How can I give a public variable of an object of a certain class so that it works in all subsequent scripts that will access it?Thank you in advance.
an object of a certain class
What does this mean
I think he wants to run a script on all objects of the same class
If it is, it doesn't stand with
give a public variable
Yes, I want the script to work for all objects of a certain class.
forEach to iterate with an array, use vehicles, allMissionObjects or allObjects etc to find all objects. typeOf or isKindOf to filter
And is it possible to give a public variable to this class?
And what it does mean
why do you need to give a public variable to a object ?
To use it in all subsequent scripts.I want to write it to the object's init file.
why dont you just fetch a object class ?
{
//apply here what ever you need.
}foreach (nearestObjects [[0,0,0],["MyClassName"],worldSize,true]);
Thanks, I'll try.
In the mod's config file, I use
class EventHandlers;
``` and from the config, I run an online file for this object
```sqf
class EventHandlers: EventHandlers
{
init="Zov = [_this select 0] execVm '\Conteiners\Screepts\CON_ARTTS.sqf'";
};
, in which I write the following command:
ATTACH_CONN = player addAction ["ΠΡΠΈΠΊΡΠ΅ΠΏΠΈΡΡ ΠΊΠΎΠ½ΡΠ΅ΠΉΠ½Π΅Ρ ΠΊ ΠΏΠΎΡΡΡ", {(_this # 0) setDir 30;(_this # 0) attachTo [player, [0.17,-0.16,0.02], "pelvis",true];
player execVm "\Conteiners\Screepts\CON_ARTTS2.sqf";
player removeAction ATTACH_CONN;}];
The command runs the following script, but it does not work (_this #0);.
I want to give a public variable to an object in an init script so that the following scripts work with this variable
Do you mean _this # 0 in addAction doesn't work?
No writes an error
#(_this #0)
Although everything works in the first file.
All the commands I mean
Do you mean No, the _this # 0 in the addAction doesn't work, and returns an error?
detach (_this # 0);
(_this # 0) setPos (getPos player);
DETACH_CONN = player addAction ["ΠΡΡΠΎΠ΅Π΄Π΅Π½ΠΈΡΡ ΠΊΠΎΠ½ΡΠ΅ΠΉΠ½Π΅Ρ",{player execVm "\Conteiners\Screepts\CON_ARTTS.sqf";player removeAction DETACH_CONN;}];
This is the second script, it doesn't work here.
Okay. I'm not going to solve two issues in the same time. Which/what is your primary issue right now?
Was curious if anyone has done much work with RHS humvees and making them sturdier in combat. Attempting some eventhandlers but im worried they arent playing nice with RHSs custom damage models. I just want my players to be able to utilize some of the RHS vehicle while giving them a stronger, albeit unrealistic, advantage over the enemy, Im in it to make it more fun for them and not have to constantly get new humvees because a few stray AK rounds cause the engine to start smoking
Don't use setPos with getPos. Those two commands do not consistently use the same altitude calibration, which can result in objects being moved into the air or below the ground, and they're slow compared to alternatives.
Use getPosATL and setPosATL, or getPosASL and setPosASL.
I have one problem.I want to give the object 2 add actions, the first one attaches this object to the player, and the second one detaches it and sends it to the player's position.
And what is the problem?
I described the problem above.
You didn't. You only stated your concept
You've got like 3 different layers of translation difficulties going on here between the two of you. Choose your words carefully, and explain everything as clearly as you can, to make it easier to understand each other.
Fucking Π―Π½Π΄Π΅ΠΊΡ translators
Better to sort the points.
- What is the code you want to solve?
- Is there any error messages?
I need a command that gives addactions to Objects of a certain class in the game.
You're almost there actually, but you're adding the actions to player rather than the object.
There are some other problems with the code, but that's the big one.
Can you try to translate the titles of the actions for me, so I can clearly see what each one is meant to do? I'll try to write some code that does what you want.
Okay. Thing I want to ask to make it sure is, is that scripts, really have to be a part of a Mod?
Yes, I made a container that will be located in the "Supplies"-"Ammunition" tab.And I also want to attach Additional addactions to it, besides the standard "Open drawer", so that the container can be carried with you.
Does your mod require CBA? It's OK if not, but if it does, then there's some tech we can use to make this a bit better.
The point I wanted to ask was, your initial question actually sounded like a question regarded to a script that is used in a mission. Being a script in a mission and a script in that regard, is actually different concept, so we actually have to sort things up
So this code is your first script: #arma3_scripting message
This code is your second script: #arma3_scripting message
Are we right?
class CfgPatches
{
class Conteiner_Arts
{
units[]=
{
"Box_Bioconteiner"
};
weapons[]={};
requiredVersion=0.1;
requiredAddons[]={};
};
};
class EventHandlers;
class cfgVehicles
{
class box_east_ammo_f; //ORIGINAL AMMO BOX
class Box_Bioconteiner : box_east_ammo_f
{
scope = 2;//show it on editor
accuracy = 1000;
displayName = "ΠΠΎΠ½ΡΠ΅ΠΉΠ½Π΅Ρ Π΄Π»Ρ ΡΡΠ°Π½ΡΠΏΠΎΡΡΠΈΡΠΎΠ²ΠΊΠΈ Π±ΠΈΠΎΠΌΠ°ΡΠ΅ΡΠΈΠ°Π»Π°";
model = "\Conteiners\objects\Bio_Conteiner.p3d";
class TransportMagazines//MAGAZINES IN AMMO BOX
{
class MY9mm_Mags//another classname
{
magazine = "";
count = 2;
};
};
};
class Box_Conteiner_Artefakts : box_east_ammo_f
{
scope = 2;//show it on editor
accuracy = 1000;
scopeCurator=2;
editorsubcategory = "ΠΠΎΠ½ΡΠ΅ΠΉΠ½Π΅ΡΡ";
editorCategory = "ΠΠΈΠΎ ΠΈ ΠΡΡΠ΅ΡΠ°ΠΊΡ-ΠΠΎΠ½ΡΠ΅ΠΉΠ½Π΅ΡΡ";
displayName = "ΠΠΎΠ½ΡΠ΅ΠΉΠ½Π΅Ρ Π΄Π»Ρ ΡΡΠ°Π½ΡΠΏΠΎΡΡΠΈΡΠΎΠ²ΠΊΠΈ Π°ΡΡΠ΅ΡΠ°ΠΊΡΠΎΠ²";
model = "\Conteiners\objects\Bio_Conteiner.p3d";
class EventHandlers: EventHandlers
{
init="Zov = [_this select 0] execVm '\Conteiners\Screepts\CON_ARTTS.sqf'";
};
class TransportMagazines//MAGAZINES IN AMMO BOX
{
class MY9mm_Mags//another classname
{
magazine = "";
count = 2;
};
};
};
};
This is a mod config
OK, so no CBA.
I'm going to work on this for a bit and then I'll get back to you with some code.
ok
Answer this please? @steady minnow
Well, probably yes, judging by the fact that I'm trying to write them for the Arma 3 game.
And sqf player execVm "\Conteiners\Screepts\CON_ARTTS2.sqf"is calling the second script?
Do you want the player to be able to carry more than one container at the same time, or just one at a time?
Yes
Just this container
The error itself is becausesqf player execVm "\Conteiners\Screepts\CON_ARTTS2.sqf"which means your second script's _this is player not an array. Which means, player # 0 is invalid, so syntax error
I see a lot to optimize your codes, but I may explain later if you want to
ΠΠΊ
Try this.
Notes:
- In
config.cpp, at the bottom, inCfgFunctions, you MUST replaceYOUR_MOD_PBOPREFIXwith the actual name or prefix of your mod's PBO. - I think I've accounted for everything, but you need to test it. Please report any errors exactly.
Oh, the container probably floats in midair after being detached. Simple fix. In the "put down" function:
_container setPosASL getPosASL _unit;```
You can use `vectorAdd` to adjust the altitude if needed, depending on the container model.
Is there a way to make an object render before all other objects in a scene, so that all other objects appear on top of it? I'm trying to make a space sky box/sphere and have asteroids appear that are outside of the sphere position wise.
Currently I've got it moving with the player, but it obscures anything that's more than about 2km away, as that's the radius of the sphere.
Thanks Thanks NikkoJT
, I'll test it and let you know.
This error occurred during the launch of the mission
The container is attached, but there is no detaching action.This error occurred while running with the container attached.
Negation cannot be before code.
RPT file Where can I get it?
Replace curly brackets {} with () on the second isNull objectParent part of the statement?
My game doesn't crash.
Why? It's better to move negation into curly brackets.
Sure, that'd work too I guess.
And it's better from code optimization point of view.
Either way it'll fix the latest error I think.
The article says Crash File, but RPT is not a crash file. Just read and see where the RPT is
And? I wrote why you need RPT file.
Actually, the error is about missing comma
I found this file, but there is a lot of information about errors, how to find the right one in this mess.
By time and code piece causing the error.
Well, everything is explained.
Not for me.For me, it's a dark forest.
Error ΠΠΎΡΠ΅ΡΡΠ½Π° ]
Error !: Π’ΠΈΠΏ code, ΠΎΠΆΠΈΠ΄Π°Π»ΡΡ ΠΡΠ»Π΅Π²ΠΎ
What's not clear here? It's written in Russian.
By the way, you already have answers:
#arma3_scripting message
#arma3_scripting message
#arma3_scripting message
#arma3_scripting message
#arma3_scripting message
Did I understand correctly?
" ",
"(_originalTarget == _this) && (isNull objectParent _this)"
Yes (about comma).
Don't ask, try it -- your PC won't explode.
Because you hasn't fixed them.
I understood because it's in the Config.
The second error has gone away, a new one has appeared.
Without content it's hard to say where your issue is,
There was no second square bracket
_unit removeEventHandler ["Killed", _unit getVariable ["pronix_var_dropContainerEH",0] ;
Easy with RPT file, yea?
It's working now, but only half.The second action appears and works, but is not deleted when activated.And when the first action is activated for the second time, the second inscription of the second action appears in the left corner, and so on.
hello all: Could someone show me a script, that would put a solid flag 3D icon, above my flag marker named flag1,
i cant seem to get it to work
A new error has appeared
There is an error in this condition in the config file
condition = "alive this && {isNull (objectParent player) && !(isNull objectParent this)}";
On the map or on the ground?
I understand that this condition applies to this post.?So that the player can only carry one container at a time.
Addaction condition?
Special variables passed to the script code are:
_target,
_this,
_originalTarget,
_actionId
Where _target references object where current action is added.
So if you check alive this , should be
alive _target
@steady minnow yeah my flag marker is on the ground yes but i would like the 3D icon ofcorse to be up in the air say like 10 hight
its not realy a pressing issue but i would like to know how to do it for another mission im making
it will be for training mission to help noobs for Arma 3
ok cool ill try again
The second action from attaching the Container from the belt works and detaches the container, but it does not remove itself, And when the first action is reactivated, a new second action appears.And so on ad infinitum. Can you tell me how to fix it?
As example, here is my code to render icon and name above unit head:
drawIcon3D [
_texture,
[1, 1, 1, 1], // color
_x modelToWorldVisual [0, 0, ((_x selectionPosition "head") select 2) + _offset],
_size,
_size,
0, // angle
name _x,
2 // shadow
];
The issue has been resolved.The creator of the code did not prescribe disabling the second function when it was activated.Fixed it .Everything is working.Thanks to all the panelists and many thanks to NikkoJT for their help.
im lost on why its saying this, any help?
_vehiclesList = (getPosWorld _objectToLoad) nearEntities [["Car", "Armored", "Air"], _distance];
```^ this is the line its saying is incorrect
What's the value of _distance?
ive been doing some testing and it should be 25 but its reading back as "command" and i have 0 clue why
Β―_(γ)_/Β―
No, CfgVehicles UserActions. Different rules.
Well, show where _distance is defined
gimme a second ill have to send it in a pastebin
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.
Hi, sorry for the bugs and the delay. It's been a rough day :U
Which action is not being removed?
The two actions in CfgVehicles cannot be removed, because they're part of the object. Instead, they use their Condition to decide when they appear.
The other action, on the player who is holding a container, is meant to be removed when they put it down. It includes a system for doing that. I'll double-check it in a minute though.
It's receiving the addAction params
_loadActionCode = {
params ["", "", "", "_arguments"];
_arguments params ["_objectToLoad", "_distance"];
...
};
Just be more attentive: https://community.bistudio.com/wiki/addAction
fix one issue and another comes out of nowhere, love it
this code was working literally yesterday idk what i did π
Issue found. It's my mistake. I forgot a piece of the logic.
This is the way to fix it as intended: In fn_playerDropContainer.sqf, place this line into the action code, after pronix_beltContainer_fnc_putDownContainer
[_target, false] remoteExec ["pronix_beltContainer_fnc_playerDropContainer",0,"pronix_beltContainer_dropAction" + netId _unit];```
getting a weird error saying that a number is provided but it isnt a number (picture attached) i've checked that _pos1 and _currentpos are both coordinates (_this is a unit amd veh1 is a object) any ideas as to what it could be?
_projectile = "Sign_Sphere25cm_Geometry_F" createvehicle position player;
_projectile setObjectTexture [0, "#(rgb,8,8,3)color(0,0,1,1)"];
_projectile setPos (getPos _this);
_pos1 = veh1 modelToWorld [0,0,20];
_pos1obj = "Sign_Sphere25cm_Geometry_F" createvehicle _pos1;
_currentPos = getpos _projectile;
_projectile setVelocityTransformation
[
_currentPos,
_pos1,
[0,0,0],
[0,0,0],
[0,0,0],
[0,0,0],
[0,0,0],
[0,0,0],
0
];
I guess the last 4 arrays cannot be filled with only zeroes.
I dunno what the issue is with setVelocityTransformation, but I can tell you there is another problem with this code:
_projectile setPos (getPos _this);```
Do not do this. `setPos` and `getPos` are slow and do not reliably use the same method of determining altitude, which results in wrong vertical positioning. Use matching pairs of `getPosASL`/`setPosASL` or `getPosATL`/`setPosATL` instead.
```sqf
_currentPos = getpos _projectile;```
Do not do this. `setVelocityTransformation` requires all positions to be in ASL format; `getPos` does not return ASL format. This will result in wrong vertical positioning. Use `getPosASL` instead.
hasnt made a difference when it is given different dirs
thx for the info will do
anyone know how to set a markers parameters before using BIS_fnc_showMarker? Because using setMarkerType before or after BIS_fnc_showMarker causes it to not fade in
I also tried using BIS_fnc_hideMarker with the time set to 0 before BIS_fnc_showMarker but that caused it to flash before fading in
@faint burrow wooohoo awsome thx m8 looks awsome
Hi, i have a question ? Is it possible to update the UI on a texture ? Because when i run the displayupdate command on the UI it's not updating on the screen, is it normal ?
I used that code
screen_test setObjectTextureGlobal [0, "#(rgb,1024,1024,1)ui(""RAM_MI_M"",""screen1"")"];
private _display = (findDisplay "screen1");
private _glistbox = (_display displayCtrl 1678);
_glistbox lbAdd "PlayerTest";
_glistbox lbSetCurSel 0;
displayUpdate _display;
your code seems to work alright (the only changes in my testing being the display class and control id) 
Hey folks, its me again, trying to understand some basic concepts in Arma.
I want to run a script when a unit is killed. What is more efficient and more stable, Eventhandler killed or Trigger on !alive unit?
oh ok, it's really strange then, i'm using a combobox, maybe it's because of that, i can be wrong though
So, that means, Triggers and eventhandlers are practically the same? Not by what they do, I mean also about how the engine handles them.
And for the other question: No, I think we will never arrive there π
no. EH is "Do X when we are there". Trigger on !alive is "ask "Are we there yet?!" every frame, do X when the answer is positive"
Okay, if thats the case, EHs are a lot more economic compared to Triggers.
Just wanted to be sure and not do guesswork. Thanks man, that helped a lot.
oh ok so i found why it wasn't working. Apparently, you need to wait between the "setObjectTextureGlobal" and the "displayupdate" commands
Hello I'm making a composition for a carrier group with props in them. However in this composition I've added teleport points from which you can teleport between the ships.
This teleport script is based on a .sqf in the mission folder.
Is there a way to embedd the .sqf in the composition, so that when one uses this composition they don't have to add textfiles in the mission folder?
An example of one of the teleport points Init:
this addaction ["<t color='#00FFFF'>Move to ATLAS</t>","ATLAS.sqf",[],1,true,true,"","_this distance _target < 8"];
this addaction["<t color='#FFFF00'>Move to LIBERTY</t>","LIBERTY.sqf",[],1,true,true,"","_this distance _target < 8"];
An example of script in the .sqf in the mission folder:
_tele = _this select 0;
_caller = _this select 1;
_caller setPos (getpos (ATLAS));
player setPosASL [
getPos player select 0,
getPos player select 1,
16
];
Yea its easy you just put the code in addaction like so:
//Atlas
this addAction
[
"Move to ATLAS",
{
params ["_target", "_caller", "_actionId", "_arguments"];
private _pos = getposASL ATLAS;
_caller setPosASL _pos;
},
nil,
1.5,
true,
true,
"",
"true",
8,
false,
"",
""
];
//Liberty
this addAction
[
"Move to LIBERTY",
{
params ["_target", "_caller", "_actionId", "_arguments"];
private _pos = getposASL LIBERTY;
_caller setPosASL _pos;
},
nil,
1.5,
true,
true,
"",
"true",
8,
false,
"",
""
];
Thank you so very much, appreciate it! π
asked this already and didnt get a respons plz let me know if against rules to repost but im getting a weird error saying that a number is provided but it isnt a number (picture attached) i've checked that _pos1 and _currentpos are both coordinates (_this is a unit amd veh1 is a object) any ideas as to what it could be?
_projectile = "Sign_Sphere25cm_Geometry_F" createvehicle position player;
_projectile setObjectTexture [0, "#(rgb,8,8,3)color(0,0,1,1)"];
_projectile setPosASL (getPosASL _this);
_pos1 = veh1 modelToWorld [0,0,20];
_pos1obj = "Sign_Sphere25cm_Geometry_F" createvehicle _pos1;
_currentPos = getposASL _projectile;
_projectile setVelocityTransformation
[
_currentPos,
_pos1,
[0,0,0],
[0,0,0],
[0,0,0],
[0,0,0],
[0,0,0],
[0,0,0],
0
];
Check _pos1. I assume a value in that array is probably returning as NaN
when using {systemchat str _x;}foreach _pos1; it returns a co ordinate and i can also spawn a debug object there with no issues
modelToWorld returns PositionAGL, not PositionASL, but that wouldn't cause that error
yeah pretty sure it isnt the co ordinates but something else in the setvelocity transformation but they seem to all match what can be used in biki and modifying the numbers doesnt seem to fix it
!code
```sqf
// your code here
hint "good!";
```
β
// your code here
hint "good!";
Hey there!
I'm currently working on a lockpicking system for one of my missions, where specific doors can be unlocked. My issue is that I'm not smart enough to figure out a way to hide the Add Action once the door has been unlocked. Any ideas?
[
this,
"Lockpick door",
"\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_connect_ca.paa",
"\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_connect_ca.paa",
"
call {
private ['_intersects','_select_door'];
_intersects = ([cursorObject, 'VIEW'] intersect [ASLToATL eyepos player, (screentoworld [0.5,0.5])]);
_select_door = if (count _intersects > 0 && {(_intersects select 0) select 0 in ['door_10','door_6']}) then [{format ['bis_disabled_%1', (_intersects select 0 select 0)]},{''}];
if (_this distance _target < 15 && _select_door in ['bis_disabled_door_10','bis_disabled_door_6']) then {
MGI_select_door = _select_door; true
} else {false};
};
true",
"true", {}, {},
{
if (_target getVariable [MGI_select_door,1] !=0) then {
_target setVariable[MGI_select_door,0,true]
} else {
_target setVariable[MGI_select_door,1,true]
}
}, {}, [], 5, nil, false, false
] call BIS_fnc_holdActionAdd;
check https://community.bistudio.com/wiki/BIS_fnc_holdActionAdd arguments for removecompleted
Or remove it using https://community.bistudio.com/wiki/BIS_fnc_holdActionRemove.
anyone have an idea what this could be?
Is that your entire code so far?
not so far my entire code is this and it is a file in a mission called on an object with sqf t execvm "FlyingBlob_attack.sqf";
where t is the init name of a csat unit
it does require cba and will give a error if IMS isnt loaded but should still work
Shall try after I eat my dinr
thank you enjoy your food
Nah, is a boring one
What about the rest?
no effect
...Hold on, can vector being 0,0,0 do anything with it?
could be pretty sure i changed it to have atleast something above 0 but will test
Before I do anything with it...
_pos2 = [(_vpos#0 + _Ppos#0)/2, (_vpos#1 + _Ppos#1)/2,(__vpos#2 + _Ppos#2)/2];```You sure this is correct?
yeah im using it to get the midpoint between the object and the "target" so that i can give weird movement to _projectile as it moves towards the other object though the two underscores is a typo
Well
The typo could be the reason, since that nil usage won't return an error in that calculation
But using it in somewhere else, just like setVelocityTransformation
though the error was with the first setvelocity trans which afaik doesnt reverence later pos2 at all (unless im reading it wrong)
You are
The error is about setVelocityTransformation gets an invalid argument
Unless you are talking about something else
setVelocityTransformation in line 113 is clearly throwing the error
is that the one referencing pos2 and pos3? for me line 113 is blank
Well, 114 to be exact
ah ok thanks i should be able to make it work from this
Also available on #perf_prof_branch but then you'd have to force all your players to use it. Which might be an option (I'll be doing that for a mission next month).
POLPOX might have found the source of the script error, but there are some other oddities in this code.
- line 69-71, this tells other machines to execute...an essentially empty script that doesn't do anything
- you create
_projectileand then immediately do 3 differentsetVelocityTransformationon it in the same frame. Granted I don't know the command too well, but I'm pretty sure only one of those is actually going to have any effect - there are a couple of spelling errors in global variable names (
Invicible,Disentegrated). If those variable names really are spelled like that everywhere then OK (coughdammagecough), but if the spelling errors are only in this script, you need to fix them. - using proper indentation would make this a lot easier to read. e.g.
_gruntBoy addEventHandler ["Suppressed", {
params ["_unit", "_distance", "_shooter", "_instigator", "_ammoObject", "_ammoClassName", "_ammoConfig"];
if (!(alive _unit)) exitWith {};
if ((_distance < 2) and (currentWeapon _shooter == "WRS_Weapon_ShockGun")) exitWith {
_unit setDamage 1;
};
_unit reveal [_instigator, 4];
}];```
-->
```sqf
_gruntBoy addEventHandler ["Suppressed", {
params ["_unit", "_distance", "_shooter", "_instigator", "_ammoObject", "_ammoClassName", "_ammoConfig"];
if (!(alive _unit)) exitWith {};
if ((_distance < 2) and (currentWeapon _shooter == "WRS_Weapon_ShockGun")) exitWith {
_unit setDamage 1;
};
_unit reveal [_instigator, 4];
}];```
Hey, just a thought I had. What's better practice : call/spawn some functions from a file in the mission file inside the init of an object, or directly putting the code inside the object ? I would say the second but I guess it depends on the script itself ?
I would say the first.
Using functions is better for longer pieces of code. The code only exists once, meaning it only has to be compiled once (faster), it takes up less file size, and if you need to change it, you only have to change it once to account for everywhere it's used. Plus, you can easily run them on objects created later as well, if you need to.
If we're talking single-line simple pieces of code like just this engineOn true or whatever then it doesn't really matter.
Ok, yeah it makes sense now Idk why I thought it was better. Thanks !
This is the way
I'm back with my container.The problem with deleting the second action was solved , but another one arose .After the first "attach container" action is triggered, it is deleted and the second action appears in the row of actions in the left corner of the screen, but after 5-8 seconds, the row of the first one appears again in the row of actions, and so on. Strange.And every time the player approaches the container at a distance of about 1 meter, this error appears on the screen. :
Correction of the message.After the container is attached to the player, if you stand still, the first action does not appear, but if you leave the container from this place for some distance, the first action appears.
Ok, desperate and dumb question for the day. Does anyone know if CBA comes in a script version. I'm trying to run an all script server and some of the scripts require CBA which is a shame, as I don't want any mods (well unless the function comes in a script version i.e. tinter furniture).
No. Ask what exactly is required so we actually can help it
Likely your bracket mismatch
no, you'll have to rewrite your own versions if you want. such as the frame handlers. but really, just use CBA. pretty much everyone has it.
Oh, I don't
Can you change player respawn logic per-vehicle?
I don't want respawning players to spawn in the driver / gunner seats. I could use an EH to move them to a different seat, I'm just wondering if there's a more direct way.
Good day. Is there a way to detect if player moves items from main container to secondary via inventory UI? Seems like both 'Take' and 'Put' event handlers do not fire in this scenario 
I solved the problem with the Attach and Detach eventhandlers, everything works.Can you tell me if it is possible for the box in the config to limit the number of equipment slots to 3 .?
Sorry, but I don't see it in biki. Only InventoryClosed and InventoryOpened π€
Could you share a link please?
Nah, I'm talking about usecase where player moves item from box container to ground weapon holder
But thanks. So there is none, I think I know how to Π·Π°ΠΊΠΎΡΡΡΠ»ΠΈΡΡ this via polling of items in ground container
passing a vehicle into my fn_init which looks like:
params ["_trainobj"];
_trainobj setvariable ["FLCSL_isTrain", true, true];
_trainobj setvariable ["FLCSL_carriages", _carriages, true];
_trainobj setvariable ["FLCSL_interval", 0, true];
_trainobj setvariable ["FLCSL_nextIndex", objNull, true];
_trainobj setvariable ["FLCSL_lastIndex", objNull, true];
[_trainobj] call FLCSL_fnc_trainMove;
and the trainmove function then runs this:
_handler = [{
params ["_args", "_handle"];
_args params ["_trainObj"];
_interval = _trainobj getVariable "FLCSL_interval";
if (isNil "_interval") exitwith {systemchat "interval isnt set"};
systemchat str _interval;
},
0,
[_trainObj]]
call CBA_fnc_addPerFrameHandler;
lo and behold _interval is throwing its exitwith, any ideas? its completely unset. however i can retrieve the value from debug console
diag_log the _trainObj to make sure its the same one as you expect?
if the train object gets deleted, the getVariable would return nil. Maybe its deleted?
Can you tell me if it is possible for the box in the config to limit the number of equipment slots to 3 .?
Not really. Arma 3 doesn't limit inventory capacity by number of items. It's limited by size. (maximumLoad config property.) So you could limit it to "enough space for 3 STANAG magazines", for example, but that would allow you to take more than 3 items if they were smaller, or fewer larger items.
Try if you exec your train move function next frame
https://cbateam.github.io/CBA_A3/docs/files/common/fnc_execNextFrame-sqf.html
Make sure to try #arma3_config if you have questions about config specifically
It remains in existence, which confuses me even more
You think it could be executing too fast for it to detect?
Yes.
I faced the same kind of issue when I added vars globally,
And when I use a little delay to call, it worked.
I used waitUntilandexecute, but I assume the next frame works too.
That's incredibly strange
I'm gonna have to use waituntilandexecute for the handler though as executing onframe math the next frame would lead to unintended consequences
Hey fellas, is anyone aware of a way to detect if the player's vehicle is open topped?
Tried stuff like lineIntersect between the players head and 1m above them, but it just detects the box model. Cheers
new problem, execute next frame wont work as its within a perframehandler.
waituntilandexecute just suspends forever and still wont get the variable
it is never able to fetch the variable within its own scope, object is valid also
triple checked that, it always returns the _trainObj
just never gets the variable
Where do you create your object and where do you add variables?
And where your function gets executed?
On client all of them?
Or on server -> client
Or do you call x function with your object And in function call another function with object
so as its singleplayer as of right now:
me locally
and yes, im calling a function (the init) and then that passes it into the move function
actually just narrowed down the problem even further
setvariable seems to not be firing at all within the init
right, think i just fixed it
combination of issues it appears
params ["_trainobj"];
if (isNil "_trainObj") exitWith {systemchat "train object is not valid init"};
[{
_this select 0 setvariable ["FLCSL_isTrain", true, true];
_this select 0 setVariable ["FLCSL_trainThrust", 0, true];
_velocity = _this select 0 getVariable "FLCSL_trainThrust";
if (isNil "_velocity") exitwith {systemchat "thrust isnt set inside init"};
_this select 0 setvariable ["FLCSL_carriages", _carriages, true];
_this select 0 setvariable ["FLCSL_interval", 0, true];
_this select 0 setvariable ["FLCSL_nextIndex", objNull, true];
_this select 0 setvariable ["FLCSL_lastIndex", objNull, true];
[_this select 0] call FLCSL_fnc_trainMove;
}, [_trainobj]] call CBA_fnc_execNextFrame;
that appears to have fixed it
firing it next frame. and also using _this select 0 instead of refering to it as _Trainobj within the execnextframe
making trains in arma 3 is actually making me go feral. hard coding is no issue. scaling it is killing me
Hi ! I need help regarding CBA Custom Event, I really struggle to understand it and use it.
I've read the GitHub wiki pages but I really struggle to understand how the event is "detected" and how I can make it detect my own event.
Just for exemple, I have a "Sit" Script, with an Ace Action. When the player use the sit action I want the action to be destroyed, but I also want it to go back when the player leave. I don't really want to use a loop for this (Because tbh I'm a bit afraid of tanking performance with it) so I search to use an event handler. There the publicaVariable one, but again it use a publicVariable, my script is local to an object (And I have multiple object to sit so I don't want to bombard the network with this).
The script doesn't use the Sitting functions from ace (I can't use them because the object i'm using is not compatible so I have to make my own)
How would I do that with CBA custom Events ?
Got it - checkVisibility between eyeline and above head works.
You create an event handler with CBA_fnc_addEventHandler. Whenever the event is raised, it will execute your event handler's code
Just for exemple, I have a "Sit" Script, with an Ace Action. When the player use the sit action I want the action to be destroyed, but I also want it to go back when the player leave.
Don't do this. Just edit the action's condition so that it doesn't appear when someone is sitting on it
E.g. you could set a variable on the object like TAG_isOccupied to true and sync it over the network, and then just check that variable in your action's condition.
Why didn't I thought about the conditions !!! I don't know why I keep making things far more complex than they are. You're a boss Dart, thank you
Yeah I understood the first part with CBA_fnc_addEventHandler. It's how to raise the event I don't understand. Is it when a variable is updated like publicVariable ? Or when I use the CBA_fnc_localEvent or the other command ?
You'd one of the xEvent functions, yeah
// Register the event handler
["TAG_someEvent", {
systemChat str _this;
}] call CBA_fnc_addEventHandler;
// Emit the event
["TAG_someEvent", ["parameters", 1]] call CBA_fnc_localEvent;
// There's also globalEvent, serverEvent, and targetEvent
publicVariable isn't really relevant for events. It's how CBA internally does the networking for events, but that's not something you need to be concerned with
Ok I guess I need something to trigger the event. I thought just changing the value would triggered it. Thank you for your help Dart !
If you're just setting some "isOccupied" variable, do you need an event at that point?
Hey guys, do you know if it is possible to give commands like Flank Left, or Advance which you normally do from Radio Menu, but do it via a script commands? I struggle to find any related commands on BIKI. Thank you
Were you doing something like publicVariable "TAG_someEvent"?
No not at all I know publicVariable only trigger something if I use addPublicVariableEventHandler It's just that the Docs said it work similary so I assumed that when I change the value of isOccupied the event would have raised
Tbf Right now I didn't use any kind of security, the action didn't disappeared when using it (So technically everyone can sit on the same spot at the same time)
This seems to work only for vehicles, are you sure about it?
ah i thought you meant vehicles. no idea..
Thank you anyways.
does anyone know a way to force an nvg to swap between it's modelOff and uniformModel without actually activating the nvg effect?
Can't, you'd have to use another version of the nvg itself that just uses the other model
it seems I cant use the object with a setVariable, as my object is not passed inside my condition so my condition has no way to know if the object is occupied or not. The condition is set in ace_interact_menu_fnc_createAction which the object is not passed. But I use the object with ace_interact_menu_fnc_addActionToObject to add it to the object
ah, rip. thx
Quick question regarding simulation types for cfgAmmo, does changing from shotShell to say shotSmokeX change the behaviour of how the init event handler is run? Say using shotSmokeX the init would run on all clients seperately, and on shotShell would it just run on the client that fired the bullet?
Have seen some reports of shotSmokeX causing duplicate submunitions from 8 months ago but not really sure what their solution was..
Yes, the object is passed
The first two parameters passed to the statement, condition, etc. are _target (the object being interacted with) and player (the player's currently controlled unit)
These are also just defined outright, so you don't need a params to define them
private _action = [
"TAG_sit", "Sit", "", {
_target setVariable ["TAG_isOccupied", true, true];
}, {
!(_target getVariable ["TAG_isOccupied", false]);
}
] call ace_interact_menu_fnc_createAction;
[_object, 0, ["ACE_MainActions"], _action] call ace_interact_menu_fnc_addActionToObject;
Ooooooh I get it now ! Its working ! Thank you for your help and patience Dart !
Is there a way to prevent a vehicle from being one-hit-killed by weapons fire?
I want to prevent a fighter jet from just instantly detonating upon death since I want to force the player to eject before crashing. Like, ensure that no hit can 100% take away all of the aircraft's hitpoints. Always leave like, 1 hit point, or whatever.
If I can get fancy with it, crashing into the ground should still insta-kill the vehicle and the player, but this is not a strictly required feature. I'll accept some jank.
Maybe an onhit event handler to assure damage never drops below a certain threshold?
HandleDamage EH may help
Saw someone do a similar thing before, this was their implementation (at the time, it may have changed)
}
else {

hey everyone, is there a way to add a language to arma 3 ? chatgpt says it possible but i wanted to ask the experts here first
No if you mean completely new lang.
yeah i meant to add a new lang
Which one?
Hebrew
Unfortunately, A3 doesn't support that lang.
yeah man no worries but thanks brother
Theoretically possible. By making a font set, making a translation and overwrite one of a language A3 has to offer and call it a day. But anyways, don't trust ChatGPT in this context
so Theoretically i need to add a hebrew font instead of a a3 lang?
Heavy on the Theoretically on that one, definitely not worth the work
class Set_Base_Skin
{
displayName="Default";
exceptions[]=
{
"isNotInside",
"isNotSwimming",
"isNotSitting"
};
condition="!(isNull objectParent player)";
statement="_target setObjectTextureGlobal [0, 'land\veh\data\base\camo1.paa', 1, 'land\veh\data\base\camo2.paa', 2, 'land\veh\data\base\camo3.paa']";
showDisabled=0;
runOnHover=0;
priority=2.5;
};
How this not working? AceSelfActions
to player?
_target = yourVehicle?
Maybe try with
"(objectParent player) setObjectTextureGlobal [0, 'land\veh\data\base\camo1.paa', 1, 'land\veh\data\base\camo2.paa', 2, 'land\veh\data\base\camo3.paa']"
Are you tried via debug that setObjectTextrure works, -> your textures is avaible
The class name is ACE_SelfActions, not AceSelfActions
Also you should make prefix your actions
That setObjectTextureGlobal call looks mighty strange
Yeah, completely wrong
I feel I am going crazy, I want to save data onto the ServerProfile and it be useable across all missions on that server.
An example is a units loadout being saved automatically and loaded to them when they join any mission. I swear this was possible (on the server side) before but I cant only find 2 persistant profiles: ProfileNameSpace (cleint side I need Server Side) or missionProfileNamespace which is mission speicfic and wont work across all missions.
I did think about saving to the profileNameSpace with a unique ServerID as part of the var name, but again the only unique ID for servers I can find is ServerName which the admin of the server could change and break my saves.
Any ideas?
Can't you save them in server's profileNamespace with player id as key?
to do that from the cleint I just have to remoteExec the setVariable comamnd with sending the PlayerUID ?
That, or make server get player's id from within the remoteExec'ced function starting with remoteExecutedOwner 
ill try that
hi guys quick question. How can i add a group of AI to a HighCommand player. Basicly i have Opfor officer who is highcommand and Bluefor players who are hunting him down. Now i would like to add groups of AI via zeus and give control to the Opfor officer. I know i can add groups with HcSetGroup
https://community.bistudio.com/wiki/hcSetGroup
But will this work in Multiplayer and add it to the Opfor highcommand ?
Whether it actually works as intended is another thing and you might need to test it, but that is what it's supposed to do.
Hi
Setting up a trigger to end a mission if a particular side is less than 10%
What is "100%" in this context
Myb something like this:
Note _totalNum should be a total number of enemis that you have adjust that number based on how many enemis you have put down.
//Codition:
private _totalNum = 100;
private _currentAliveSide = {alive _x} count units east;
private _num = floor ((_currentAliveSide / _totalNum) * 100);
if(_num < 10) then {
true;
};
//On Activation:
["END1"] remoteExec ["endMission", 0, true];
I'll give this a try, ty
All units of the side at mission start
Hey need a hand with this script for randomly creating injured sounds
sqf ``` private _sounds = [
"A3\Missions_F_EPA\data\sounds\WoundedGuyA_03.wss",
"A3\Missions_F_EPA\data\sounds\WoundedGuyA_04.wss",
"A3\Missions_F_EPA\data\sounds\WoundedGuyA_05.wss"
];
_sound = selectRandom _sounds;
[Bloke] spawn {
while {lifestate (_this select 0) == "HEALTHY"} do {
playSound3D [selectRandom _sounds, position _this, 0.3, 1, 10];
sleep 5;
};
}; ```
the error is Undefined variable in expression: _sounds
been looking at the wiki and google and cant find a soulution
would love a hand
_sound var is out of scope
You need to pass _sounds the same as the bloke variable
Also you are playing the sound when healthy
im fixing it up lol
im gonan find the write injured state for it to occur
but if its healthy and health 100 then i dont need to worry about that
What does this mean sorry,
I would like to learn what I did wrong
Check here: https://community.bistudio.com/wiki/Variables#Scopes
Simple example:
//bad:
private _num = 10;
[] spawn {
systemChat format ["%1", _num];
};
//good:
private _num = 10;
[_num] spawn {
params ["_var"];
systemChat format ["%1", _var];
};
spawn creates a new separate script thread. Local variables from the original scope don't exist in the new scope. You need to pass _sounds as an argument and retrieve it from _this using select or params.
Alright thanks guys Ill read up on that link legion sent and hopefully fix it up
[Bloke, _sound] spawn {
params ["_unit", "_sound"];
// now you can use _unit and _sound in the rest of the spawned code
};```
Hey implmented it, and also fixed up some of the coding
however the code is just firing at all. not even a script error
Heres the updated code
"A3\Missions_F_EPA\data\sounds\WoundedGuyA_03.wss",
"A3\Missions_F_EPA\data\sounds\WoundedGuyA_04.wss",
"A3\Missions_F_EPA\data\sounds\WoundedGuyA_05.wss"
];
[InjuredMan, _sounds] spawn {
params ["_unit", "_sounds"];
while {lifestate (_this select 0) == "HEALTHY"} do {
playSound3D [ (selectrandom _sounds), Injuredman, false, GetposASL Injuredman, 0.3, 1, 10];
sleep 5;
};
};```
I'm kinda stumped lol
instead of Injuredman in spawn use _unit
That thing you've circled in red is not relevant. That line is showing the return value from the script, not the progress of the script, which in this case is a script handle (internal engine reference to an instance of a running script) which doesn't translate well to a human-readable format. It's just too long for the box.
Oh sorry I thought it was the progress lol
i'll try that
You should replace (_this select 0) with _unit as well. Not the problem, they refer to the same thing, but being able to have a simple variable name like that is half the point of using params.
I notice you are still using while {lifestate ... == "HEALTHY"}, which means the script will only run while the unit in question has less than 0.1 damage. If the unit is more injured than that, the script will exit. So if you're starting with an injured unit then nothing will happen.
Yeah I know, hes at full health but the thing is that a player will come over and heal him. the sound will stop
thats the reason for all this lol
I get it, it's just that the logic is currently backwards. Make sure you switch to != when you make the final version.
π thanks broski
To diagnose this, try putting a systemChat into the while loop. That will help show whether the loop is exiting early, or if it's actually running but you just can't hear the sounds.
UUpdated the code to _unit to replace the Injuredman and now a new error has appeared
Error Type Array, expected String
happening at the playsound3d
but I dont understand that, I need that in rder for the code to work?
ill add that rn
Btw, you've got the sound radius set to 10 metres, which is actually not that far in Arma, and it will be pretty quiet even when you're fairly close.
Can you show the exact phrasing of your new playSound3D?
playSound3D [ _sounds, _unit, false, GetposASL _unit, 0.3, 1, 10];
_sounds -> selectRandom _sounds
The volume multiplier is also set to 0.3, which may be making it too quiet to hear, especially when combined with the small radius. If you still don't hear the sounds, try setting the volume higher.
Theses settings worked great when I had just one sound without trying for it to be randomized, but looking at it now ill up the sound due to properly gunfire and other sounds
Sorry where do I place this?
Where you have _sounds in your playSound3D. You had it there before, remember.
Hey it works
thanks so much
gonna now change it so it doesnt play when the guys healthyπ
(damage _unit) > 0
Keep in mind that the while loop exits once the condition stops being true; if he gets injured again later after being healed, it won't automatically start again.
hold up let me cook by myself real quick
"A3\Missions_F_EPA\data\sounds\WoundedGuyA_03.wss",
"A3\Missions_F_EPA\data\sounds\WoundedGuyA_04.wss",
"A3\Missions_F_EPA\data\sounds\WoundedGuyA_05.wss"
];
[InjuredMan, _sounds] spawn {
params ["_unit", "_sounds"];
while {lifestate (_Unit) != "HEALTHY"} do {
playSound3D [ selectRandom _sounds, _unit, false, GetposASL _unit, 10, 1, 10];
systemchat "code fired" ;
sleep 5;
};
};
Heres the horribly written script if anyone wants it
you might wanna delete the systemchat tho
You can still change _this select 0 to _unit to make it a bit cleaner
thanks @hallow mortar and @fleet sand
just edit the message, no one will know
also its not _Unit its _unit
Variable names aren't case sensitive
I have lost a script that made it possible to export loadouts/inventory from playable characters in Eden editor. Executed from the menu.
Please, anyone who knows what I'm talking about haha, been searching for ages but can't find it
pressing Ctrl+C will export SQF loadout in the clipboard, you only have to Ctrl+V it in a file or on another unit layout
That will work but I'm looking to export loadouts from many playable characters and then import to ace arsenal
Did you mean something like this:
AllPlayableUnitsItens = [];
{AllPlayableUnitsItens = AllPlayableUnitsItens + [(headgear _x)] + [(goggles _x)] + (assignedItems _x) + (backpackitems _x)+ [(backpack _x)] + (uniformItems _x) + [(uniform _x)] + (vestItems _x) + [(vest _x)] + (magazines _x) + (weapons _x) + (primaryWeaponItems _x)+ (primaryWeaponMagazine _x) + (handgunMagazine _x) + (handgunItems _x) + (secondaryWeaponItems _x) + (secondaryWeaponMagazine _x)} forEach (playableUnits + switchableUnits);
AllPlayableUnitsItens = AllPlayableUnitsItens select {count _x > 0};
AllPlayableUnitsItens = AllPlayableUnitsItens arrayIntersect AllPlayableUnitsItens;
copyToClipboard str AllPlayableUnitsItens;
Where you execute this in console and just import it to arsenal ?
Holy shit, this is it!! Haha, thank you, thank you! 
Im creating a mission. This will run on dedi server.
In this mission there are 2 towns: town-a and town-b. In town-a squad-a is garrisoned, in town-b squad-b is garrisone. Everyone are player. If a player dies, ramdomly respawn in either towns and i need a trigger that joins them into the squad where they were respawned. I did some research and it seems joinSilent work only with AI and singleplayer or local server. Is there a solution to my need? Pls help
To my knowledge joinSilent works fine with players, have you tested this or just looked it up?
I am not really a script master, so i tried this
[_player] joinSilent Alpha;
Its not working... not working so much, the game does not let me click OK in the trigger window
I says: Type Nothing, expected Bool
[player] joinSilent alphaGroup;
Make sure to name the variable of the group alphaGroup
_player is a private variable, so would have to be defined by you, player is the standard variable for that machines βplayerβ aka the machine running the code
You sure expected Bool error here is relevant with joinString
Seemed a strange error yeah, but I did notice that issue at least
Undefined variable will NOT throw that error
You are entering that code into the condition
I just relized
^
All right, i tested, surprise surprise, not working
Somebody pls help
You could be a little less passive aggressive and Iβd be more willing to help
the trigger doesn't know what _player is
I write it to my code because those are used to work... yeah its not obiuos to you, sorry
Can you post what your latest code is?
In what way does it not work? Is there an error, or does it just not do anything?
Not used to work*
The latest code
Will it be possible to change the vehicle displayName in the running mission?
https://community.bistudio.com/wiki/setName
No.
why is this popping up?
The code in the error doesn't match the code in your SQF file
Make sure you're editing the right file (in the right mission), and you've saved the SQF file since editing it
Hey! Quick beginner question!
I already have a cfgFunction section in my description.ext, looking like this:
class CfgFunctions
{
class A3_Missions_F_Tacops
{
tag = "BIS";
project = "arma3";
#include "\A3\Missions_F_Tacops\cfgFunctions.inc"
};
};
but I would like o add one more function to it, to be specific, this:
{
#include "INC_undercover\cfgFunctions.hpp"
};
How would I combine and format the two, so the script doesn't break?
if the second hpp also contains class cfgFucntions you cant include it
depends entirely whats inside the files and where that data needs to go
Copies the code from a target file and pastes it where #include directive is.
https://community.bistudio.com/wiki/PreProcessor_Commands##include
does it make sense to paste the entirety of that file to where you have#include? π
makes sense to me, why?
It's a question for the original person, because only they know what's actually in the file they're including.
ah ok , i didnt see quote link
_MyVariable = 1;
addMissionEventHandler ["EachFrame", {
_thisArgs params ["_MyVariable"];
_MyVariable = _MyVariable + 1;
},
[_MyVariable]
];
How do I change the value of _MyVariable isnide of EachFrame (and keep it changed and not revert back to 1)?
_thisArgs set [0, _MyVariable]
and if I try to access _MyVariable outside of EH it will have the correct value, not 1, right?
Not sure if that's "officially" supported though, it's a bit weird to do that
maybe just use a global variable
It's a local variable, how would you access it after the EH ran?
_MyVariable won't get updated.
The "set" is only editing it's copy in the arguments array
here is the issue, I'm going to run this "function" multiple times, which means if I make it global, it the variable will keep spasing out because it will keep getting assigned different values due to different instances running at the same time
that's why I'm trying to keep it local, if there is another way to go about this, please let me know
I want it update inside it's current instance is what am saying, if there is multiple instances, each instance will have it's own var instead of one global var for multiple instances
idk if I'm being clear
This should work: #arma3_scripting message
couple of options:
- dynamically generate a unique global variable name (use
setVariableand+orformatto manipulate the name as a string) - use a unique object's namespace - if this function is related to an object, you can use that, or you could create a dummy object to use
oh yeaaah, I forgot about object namespace, alright i will try all of the approaches you people gave me, and settle on the most suitable one (dynmically generating a global var is not ideal for me)
thanks!
_vectorDir = [
(PosOne#0 - PosTwo#0),
(PosOne#1 - PosTwo#1),
(PosOne#2 - PosTwo#2)
];
is this a proper way to get vector dir from PosOne to PosTwo?
vector1 vectorFromTo vector2
it says vector to vector, is it suitable for position to position?
Positions are vectors
that's what I thought too, but I was unsure
but there is another thing
z coordinate is defaulted to 0
how do I get Z then?
I guess I use Z of the second position?
delta of posone Z and posTwo Z?
It's defaulted to 0 if no Z value is provided (2D position).
Looks like you're using ACE's fire system, if you are, just use: ["ace_fire_burn", [Unit, Intensity]] call CBA_fnc_globalEvent
Unit is the unit you want to set on fire, Intensity is a number from 1-10
Thanks!
Seems like running ace3 disables the hold action icon. Any workaround?
The action itself works, but the circular bar/icon is not visible .
It shouldn't, did you try with just CBA / ACE?
Hey guys got a question, i want to increase fuel consumption on all vehicles in my server from mission to mission each week. i was hoping this would be a setting i could change in ace but apparently not and i would need to run a script each operation using https://community.bistudio.com/wiki/setFuelConsumptionCoef
how would i get this to work on all vehicles as i dont want to call it for every single vehicle class?
{_x setFuelConsumptionCoef 5} forEach vehicles
would this go in in my init.sqf of each mission?
If you want yes
if you want you can create with
https://cbateam.github.io/CBA_A3/docs/files/xeh/fnc_addClassEventHandler-sqf.html
to vehicles, and use last example
["Car", "init", {(_this select 0) engineOn true}, true, [], true] call CBA_fnc_addClassEventHandler; //Starts all current cars and those created later
if you want apply your code to cars that is created due mission.
thanks guys appreciate it!
I have a script that works great but I would like to have one more almost the same script, but with other units to call for
How do I fix that? hopefully you don't declare me stupid, cause I have really bad knowledge in this
And where is your issue
"Do this for me, for free".
How do I fix that?
Replace global vars by local ones, and change unit class names.
So i applied this in my init.sqf and tried it with no luck so i tried upping the value to 1000 which i know is the max value and it didnt make a difference at all either your syntax makes perfect sense but im not quite sure what could be causing it to not work
double checked addon settings to see if there is anything that could be overriding it and couldnt find anything there
Then either you didn't ran the code, or some Mod is doing that and overwriting
Yes, and further testing, for example Zeus enhanced alongside ace and cba, create an Intel item, and that hold action icon is missing. Also tried DRO, dynamic recon ops, and noticed that Intel objects pickup doesn't have the icon, the action itself works, but the icon is missing. These are quick things to test the issue.
haha what? how are people even going to ask for help in here without getting all these "funny" answers? Thought this was a place for help?
Your issue here is, you didn't stated the issue you have or what kind of support/assist you need. βI need help with it, can you help me?β is not helpful/good way to ask, because nobody knows what you got without you say
"I would like to have one more almost the same script, but with other units to call for
How do I fix that?"
Is in my world more than OK info for requesting help
Well, help can be either free or paid. For me your question looks like I described.
You need to add other classes to Overchoice_ReinforcementUnits array.
You can copy the class name by right clicking on a unit in the editor. And go to log.
Since it is not clear from his question what he wants, I believe that he needs several actions: "Call infantry reinforcements", "Call armored reinforcements", etc. If so, then #arma3_scripting message.
yes, fixed that, thanks! If I want to have one script that is for "infantry" and one script for "vehicles", Can I just make a copy of the script I have now? and just change the classes in the new copy of the script?
How much will it cost to get a script fixed?
So in zeus i knkw how a concious person can get aceheal with addaction like this:
_This addAction ["Medical Treatment","[player] call ACE_medical_treatment_fnc_fullHealLocal"];
But can somebody help me how to heal an unconcious person, or just whatever person that gets inside the medical vehicle vehicle, in zeus not in the editor?
If you're using ZEN there should be an option to grant a full heal in the ZEN context menu (rightclick or V)
The whole idea is that i dont interact with them
This way i can be focusing on other things
```sqf
// your code here
hint "good!";
```
β
// your code here
hint "good!";
How can i delete the RPG? trying detach and delteVehicle didnt work
the event handler does not know what_rpg7is here
this removeWeaponTurret ["Laserdesignator_mounted", [0]];
this lockTurret [[0], true];
_drone = this;
createKamikazeDrone = {
params ["_drone"];
private _rpg7 = createSimpleObject ["\A3\Weapons_F_Exp\Launchers\RPG7\rocket_rpg7_item.p3d", position _drone];
_rpg7 attachTo [_drone, [0, 0.085, -0.12]];
_rpg7 setDir 90;
_rpg7 enableSimulation false;
_drone addEventHandler ["Hit", {
params ["_drone", "_source", "_damage", "_rpg7"];
private _charge = "SatchelCharge_Remote_Ammo" createVehicle (getPos _drone);
_charge setDamage 1;
detach _rpg7;
deleteVehicle _rpg7;
}];
};
publicVariable "createKamikazeDrone";
[this] remoteExec ["createKamikazeDrone", 0];
but i used the params thing inside it
does that not work?
params is "fill those local variables with contents of _this array". It doesn't magically grab values out of thin air 
you could e.g setVariable it on the drone
I basically need a command that works within zeus executions to check if a player is unconcience in a unnamed vehicle
_This addAction
[
"Medical Treatment",
{
if !(isNull objectParent player &&
myUnit getVariable ["ACE_isUnconscious", false];) then {
[player] call ACE_medical_treatment_fnc_fullHealLocal;
}
},
nil,
1.5,
false,
true,
"",
"true",
4,
false,
"",
""
];
Would this work?
or could I maybe make the last "false" into a "true" π€
keeping in mind it is a mp server
[_This, ["Medical Treatment",
{
if
!(isNull objectParent player && myUnit getVariable ["ACE_isUnconscious", false];)
then
{
[player] call ACE_medical_treatment_fnc_fullHealLocal;
}
}
,nil,6,false,true,"",4] ]
remoteExec
["addAction",0,_This];
Or this, I think this may be a multiplayer fitting one, but im not knowledgable enough
^
getting this:
17:04:01 Error in expression <(_this select 0) addaction (_this select 1)>
17:04:01 Error position: <addaction (_this select 1)>
17:04:01 Error Type Number, expected String
You are passing 6 as the condition argument
I thought that would be the priority argument π¬
you passed 6 as priority
https://community.bistudio.com/wiki/addAction just count them here
So then I guesss this?
[_This, ["Medical Treatment",
{
if
!(isNull objectParent player && myUnit getVariable ["ACE_isUnconscious", false])
then
{
[player] call ACE_medical_treatment_fnc_fullHealLocal;
}
}
,nil,6,false,true,"","True",4,false,"",""] ]
remoteExec
["addAction",0,_This];
lmao
It did fix that error but when running it gave a new one:
17:15:51 Error in expression < !(isNull objectParent player && myUnit getVariable ["ACE_isUnconscious",>
17:15:51 Error position: <myUnit getVariable ["ACE_isUnconscious",>
17:15:51 Error Undefined variable in expression: myunit
Where are you defining myUnit?
hmmm, nowhere, found it somewhere to check if any player in vehicle is unconscious, as I do not know what other command to use
myUnit is a variable, not a command I think
hmm
then how else would i get the thing I want without the variable
I think you need to code selection of the vehicle the player is interested in/looking at, then loop through the units in the vehicle and if there is an unconscious unit in the vehicle, then add the action. I'm not aware how the ACE function works though, so take this with a grain of salt
[_This, ["Medical Treatment",
{
if
!(isNull objectParent player && /*myUnit getVariable ["ACE_isUnconscious", false]*/)
then
{
{[player] call ACE_medical_treatment_fnc_fullHealLocal}forEach crew vehicle player;
}
}
,nil,6,false,true,"","True",4,false,"",""] ]
remoteExec
["addAction",0,_This];
some fixes but still not the one we were just talking about....do you know the base arma one?
You need to do deeper refactoring there I'm afraid
If you're new to SQF or it's coding paradigm, I recommend reading the SQF tutorials on official wiki
Maybe start here https://community.bistudio.com/wiki/Introduction_to_Arma_Scripting
I got a problem with my drone. When i fire the first time the rocket disapears but when i then try to reload it, it stays hidden, is that because the Fired event handler keeps it hidden?
I tried using a while loop and the MagazineReloading eventhandler and they all didnt work
https://pastebin.com/arMb8q2a
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.
Your fired eh wont give you error.
But you have wrong syntax there
_drone addEventHandler ["Fired", {
params ["_drone"];
private _rocket7 = _drone getVariable ["rocket7", objNull];
hideObjectGlobal _rocket7, true;
}];
should be
//syntax: object hideObjectGlobal hidden
_rocket7 hideObjectGlobal true;
hey, have any of you done it or know how to do it and is it even possible for a selected Ai soldier to shoot with dummy ammunition?? (blank cartridges) I know it's funny, but I want to make it look like I'm doing the task with helpers, and in fact, I'm the only one who can kill enemies.
(such an army cod) ;p
Just an idea: use the related event handler and delete the projectile in it
It's an idea, I'll try it. and if I can't do it myself, can I ask you for help tomorrow??? I don't have much experience with advanced scripting such as event handlers. but I'll try to do it myself. thanks for your help, ysl
No worries, although if you get stuck, it's better post the code directly on this channel so you have more eyes reviewing the code and probably quicker response too
ok, thank you. π
now, I guess the problem solved itself. Because I just found an article on the Internet about RHS having blank ammunition. thank you anyway
I feel like i saw a script for this kicking around a while back and cant for the life of me find it
im looking for something aimed at armoured vehicle AI that will make them stop and engage when they detect an enemy, if they lose track of the enemy or destroy it then continue their path
figured id ask before trying to write something new
any ideas/suggestions?
ammo1 = unit1 >>ammo1<< _weapon; 
Why are you making these all global variables
setammo doesnt work to make a launcher infinitely reload
workaround found ```sqf
ammo1 = currentMagazine unit1;
weapon = currentWeapon unit1;
unit1 removeWeapon weapon;
unit1 addWeapon weapon;
unit1 selectWeapon weapon;
unit1 addItemToBackpack ammo1;
bc in context of this performance doesnt matter
That has nothing to do with performance
You're just making a bunch of random global variables
- some vars were outside eachframe eh
Then prefix them
https://community.bistudio.com/wiki/addWeaponItem works for force-adding ammo/magazine to the weapon 
Gang:
Most pragmatic way to script a "Show" module to hide synced layers/units when the player leaves the trigger area?
Trying to accomplish this with one persistent trigger that can be reactivated by re-entering the trigger area
i think one way to do this is sync the trigger to group leaders then when its time to hide the groups (synchronizedObjects) just loop the group units and hide the units and disable their AI
Hi ! I'm trying to play a sound with playSound3D, I've created my sound in the CfgSounds class inside my description.ext.
Using the class name of the sound defined in CfgSound works with PlaySound , but not playSound3D, is this normal behavior ?
PLaysound3d is different
You use it like this
playSound3D [getMissionPath "mySound.ogg", player];
So, I want to achieve the same effect as BIS_fnc_cinemaBorder; but I want the player to be able to walk. Is there some way to get around it or is there another way of doing a similar effect?
Maybe try :
disableUserInput it disables or enables the keyboard and mouse input during cutscenes.
With your solution ^^. It's weird that PlaySound3D can't use the sounds of CfgSounds. Thank you
maybe try a GUI solution ? Have an image with black border, and show it when you want your cutscene ?
say3d will however, this is an example from a mission I am working on
carter_NPC say3D "Carter_Dialogue_Greeting";
i forgot say3D existed, but I prefer PlaySound3D, it has Global Effect without using remoteExec
weird BIS_fnc_cinemaBorder doesnt prevent me from walking
Weird, for me once it fades out its fine
i just run the wiki example : [1, 2, true, true] call BIS_fnc_cinemaBorder;
Yeah same
must be some other command then that does that
stuff like ```cam cameraEffect ["internal", "BACK"];
On the wiki it says cinema border will disable input
Error GIAR stack size violation, Error missing ) ....line 113
private _mgmaction3 = ["Adjust Eyes 1","Adjust Night Sight","",{
setAperture 2;},{true}] call ace_interact_menu_fnc_createAction;
//one below is line 113
private _mgmaction41 = ["Adjust Eyes 2","Take off Respirator (Black)","",{
player addEventHandler ["InventoryClosed",
{
params ["_unit", "_container"];
if
(vest player in
[
'EF_V_AAV_Diver_Black',
'EF_V_AAV_Diver_Coy',
'EF_V_AAV_Diver_Olive'
];
)
then
{
player addVest "EF_V_AAV_Scout_Black";
}
else
{
};
};
},{true}] call ace_interact_menu_fnc_createAction;
which line is that in pasted code?
private _mgmaction41 = ["Adjust Eyes 2","Take off Respirator (Black)","",{
ok
I added an extra } at the end because it was missing, but error is the same
maybe I missed or have too many ";" ? if then else have weird way of using them
well it certainly is missing one ]
Your are missing ]
first ;)
oh that might be it, where?
Your aren't closing your addeventhandler
["InventoryClosed",
{
//Your code
}];// this one
},{true}] call ace..
So ] should be between } and ;
I seeee
I got confused and was looking if it was
};
}],{true}] cal....
Okay I will test
hmm, I am getting same error...
but before giving me an error about 113 it also gives me one about missing ) at 123 which is
'EF_V_AAV_Diver_Olive'
]; //this one 123
also in if codition it wouldnt be vest player it would be vest _unit
But also you are creating EH Inventory Closed witch fires when a player closes the inventory and you are calling this from a ace action witch fires when player interacts.
So its unessery to even have a EH when you can just call the action and in codition you can set when that action would be active.
Oh ye, my bad, oversight, I copied my old code that would change stamina settings based off if player has gasmask equiped
edit, everything works now. Except that the vest looses all items on change, but I can easily fix that
Very appreciated but what I meant was like, the syntax of script that I can put into "on deactivation" within a Show/Hide module, that would hide the synced layer when I leave the radius.
Im basically having a syntax problem lol
dont know about layers, i think there are editor commands for that
Hey, I'm stumped here. This script isn't working.
What I want it to do:
- After
circusis killed, anyone who enters this area will be immediately teleported to a new location.
What actually happens: - The script fires but players entering the area do not get teleported.