#arma3_scripting

1 messages Β· Page 567 of 1

ebon citrus
#

I hope it helped atleast a little bit. I'm making a massive batch of muffins for a school yard sale, so im a bit busy. Good luck 🐣

unborn ether
#

What's the a,b sizes in meters of map grid (aka mapGridPosition). Is it static? I want to create a rectangular marker that fully fits one grid. Cheers.

cosmic lichen
#

From 32 to 33 it would be 1000m

#

The size of grids on the map however, depends on the zoom level

cunning crown
#

And on the map itself

cosmic lichen
#

Largest zoom => Grid size 100, smallest zoom grid size 1000m

#

@cunning crown Oh does it? Didn't know that.

cunning crown
#

In CfgWorlds >> WorldName >> Grid you have the different zoom level and the cell size

unborn ether
#

Yeah tanks, found some math in BIS_fnc_gridToPos

drowsy axle
still forum
#

uh... what

drowsy axle
#

Apparently, EC_BWA3_Units.sqf doesn't exist. By SQFLint.

still forum
#

Well..

#

I'd say SQFLint doesn't work properly then

drowsy axle
#

Okay

astral dawn
#

SQF-VM is our savior βš”οΈ

oblique arrow
#

Hm setPos does altitude as well, no?

#

Because I have this script

[
bunker_exit,
"Enter bunker",
"\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_connect_ca.paa",
"\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_connect_ca.paa",
"_this distance _target < 3",
"_caller distance _target < 3",
{},
{},
{ player setPos(getPos (bunker_enter))},
{},
[],
5,
0,
true,
false
] remoteExec ["BIS_fnc_holdActionAdd", 0, bunker_enter];

And its only doing position without altitude

ebon citrus
#

what is bunker_enter?

#

this should explain how things work

oblique arrow
#

Bunker_enter is an object

ebon citrus
#

yep, alright. Just made sure you wren't using markers

#

the above biki entry should get you sorted out

tender fossil
#

Why does the second line of: ```sqf
diag_log format ["TEST1 : %1 TEST2 : %2",_itemsneeded,_amountsneeded];
diag_log format ["TEST1 : %1 TEST2 : %2",_itemsneeded pushBack "test",_amountsneeded pushBack 1];

return this? ```sqf
 "TEST1 : [""Wood""]       TEST2 : [10]"
 "TEST1 : 1       TEST2 : 1"
#

Is it a bug or intended behavior?

winter rose
tender fossil
#

@winter rose I feel so stupid right now... ahaha

winter rose
#

Good 😁 hahaha np

faint fossil
#

@winter rose Hey, good morning. I got some progress and stuff with my unitPlay project - I found some amazing pilots to fly some paths for me
however currently I'm still using the original method I saw on a youtube tutorial, so it only works once. (which is a problem)
here's my current setup: radio trigger that has rec = [] spawn h1; for activation (heli name is hm1)
and in h1.sqf:

h1 =[[0,[3614.00.190832,0.62 more numbers and stuff 7668,-0.754729],[368.046,175.288,11.4204]]];
[hm1, h1] spawn BIS_fnc_Unitplay;
#

And uh I think I'm going to revise my original idea to use only a radio trigger to spawn in a wave and have the heli delete itself when it dies (I figured that part but)

#

How do you spawn in a heli and do unitplay at once?

winter rose
#

by trigger? you can createVehicle and moveInDriver

livid musk
#

Guys I am having trouble with spawning a working TFAR radio on the ground, currently I spawn a radio in a weaponholder but I can't use it when I pick it up

#

Does anyone have some advice on how to make the radio work

ebon citrus
#

you can't use it?

#

like ctrl+p doesnt work?

livid musk
#

cant equip it

livid musk
#

So what happens is, I spawn a weaponholder, put an object in it with the name of one of the radios and then when try to pick it up and equip it, it just doesn't let me

ebon citrus
#

did you spawn the right item?

faint fossil
#

So uh how do you use a radio trigger to run code in an sqf file

ebon citrus
#

does it have to be radio trigger?

#

cant you just addaction?

winter rose
#

@faint fossil in the trigger, use execVM
but indeed, if you can do it another way, it's good too

ebon citrus
#

yeah, sorry for skirting the question

faint fossil
#

thanks! I'll try addaction as well

ebon citrus
faint fossil
#

It's the thing that makes a scroll wheel option right

#

oh thanks

ebon citrus
#

yep

oblique arrow
#

theres also the imo fancier hold action heh

livid musk
#

This is how I spawn it in@ebon citrus : Radio = "TFAR_anprc152"; ground2 = "GroundWeaponHolder" createVehicle getpos player; ground2 addWeaponCargoGlobal [Radio,1]; ground2 setPos [getPos player select 0,getPos player select 1 ,0.00];

ebon citrus
#

player assignItem "TFAR_anprc152";

#

see if that works

#

like after you have picked up the radio

livid musk
#

The thing only is, is that my endgoal is to have a loudspeaker system with a lot of spawned radios. Players shouldn't be able to pick them up. I want them to work more or less as a static radio but placeable in the eden editor

ebon citrus
#

and you want them to transmit voice of a specific frequency?

livid musk
#

yeah that is the original plan

ebon citrus
#

you can make the object non-interactable if you set it's health to 0

still forum
#

you need to static radio initialize them anyway

ebon citrus
#

so try to setdamage 1 on the groundweaponholder

still forum
#

just placing a radio in a weapon holder doesn't work

ebon citrus
#

Dedmen probably knows more about tfar

#

i cant find their documentation

still forum
#

radios need to be initialized, and get a unique ID

#

if you have TFAR 1.0 you can also just pre-place them in 3DEN, instead of doing it manually via script

livid musk
#

I tried however they despawned when spawned far from the players during my testing

ebon citrus
#

despawned?

livid musk
#

yeah or didn't spawned at all

ebon citrus
#

do you have some sort of cleanup script?

faint fossil
#

so uh what am I doing wrong? I'm putting this in init.sqf in the hopes that it'll add a scroll option:

player addAction ["Start path", {
    private _helithing1 = [[1000, 1000, 1000], 180, "B_Heli_Light_01_armed_F", WEST] call     bis_fnc_spawnvehicle;
    private _wpdata1 = [PATH GOES HERE];
    [(_helithing1 select 0), _wpdata] spawn BIS_fnc_Unitplay;

    _helithing1 addEventHandler ["Killed", {
        params ["_unit", "_killer", "_instigator", "_useEffects"];
        deleteVehicle _unit;
    }];
}];
still forum
#

There are already TFAR classes, that are a ground holder with a weapon. Which you can just createVehicle, instead of filling a ground holder manually @livid musk

livid musk
#

@ebon citrus Looks like im running wreckManagerMode = 3;

#

I'll have a look into those then Dedmen

faint fossil
#

uh in the context of this thing:

this addAction ["Start 5", {
    helithing5 = [[1000, 1000, 1000], 180, "B_Heli_Light_01_armed_F", WEST] call bis_fnc_spawnvehicle;
    wpdata5 = [very long path];
    [(helithing5 select 0), wpdata5] spawn BIS_fnc_Unitplay;

    (helithing5 select 0) addEventHandler ["Killed", {
        params ["_unit", "_killer", "_instigator", "_useEffects"];
        deleteVehicle _unit;
    }];
}];

is there way to make "very long path" a separate file so the code isn't like 20 km long?

tender fossil
#

Does CfgFunctions support nested folder structure?

exotic flax
tender fossil
#

Thanks @exotic flax! Just found the article too πŸ˜›

jade abyss
#
class CfgFunctions
{
    class myTag
    {
        class myCategory
        {
            class myFunction {file = "my\Path\To\myFile.sqf";};
            class myFunction {file = "different\Path\To\myFile.sqf";};
        };
    };
};
austere granite
#

might as well just write your own cfgFunctions thing if you want that

#

Is there some magical thing I gotta do to change camera FOV?

#

tried both setcamfov and campreparefov with no luck either way

#

(Yes im commiting)

#

fixed, needed to make sure _cam cameraEffect ["internal", "back"]; was called as well as opposed to just calling switchcamera

dense tendon
#

I guessed it's probably best fitted here. For an campaign I need to have all missions as folders and have to write an config for them right? After that I just slap it together with the arma tools mod builder?

ebon citrus
winter rose
#

@austere granite camSETFov - please check the wiki πŸ˜…

austere granite
#

Yeah whatever it was

#

Was using that

#

Neither worked till after cameraEffect

winter rose
#

yes, switchCamera is more about units/vehicles than camera (although its page says otherwise)

indigo spire
#

Hi i need a script to make an ai unit perform an animation, i cannot seem to get it to work on my server. If the units variable name is say Matt can someone give me a clue. Many thanks in advance

cosmic lichen
ebon citrus
#

do also note playMove and PlayMoveNow if you want a smooth transition

indigo spire
#

Thank you πŸ™

vagrant mango
#

@cosmic lichen Do believe yo utagged the wrong person πŸ™‚

cosmic lichen
#

Yeah, Discord thought it would be funny to not put the last person who posted here on top of the list. Sorry for that.

tender fossil
#

Is there any way if they don't have a classname?

cunning crown
#

Maybe with the 3d model?

tender fossil
#

How'd you do that

cunning crown
tender fossil
#

Thanks! It printed this: ["b_rhizophora_f.p3d","a3\vegetation_f_exp\shrub\b_rhizophora_f.p3d",false]

#

Now I just need to figure out a way to monitor whether there are these objects in the proximity of player πŸ™‚

#

Hmm, a quick look at the scripting commands list did not reveal anything special

#

Is there any command available that can check model info of an object apart from getModelInfo or createSimpleObject?

#

Or wait, I think I can use getModelInfo itself

marble flare
#

is there a command that checks the steam workshop ID?

ebon citrus
#

of what?

#

if it's mods, then that information is contained in publishedId in meta.cpp in the root folder of the mod. This is as far as i know, outside the configuration, but let me look into it

#

what do you need this for @marble flare? there might be an easier solution

winter rose
#

yes?

tender fossil
#

Well, I found out there's a command nearestTerrainObjects that is a perfect fit to solve my issue

winter rose
#

well of course it doesn't ; but you can kill an array of handles this way yes

#

you would have to store all your handles in an array, e.g with pushBack

#

but afaik there is no "get all handles" command

#

what makes you want to do that, though?

#

I get that; but why

#

your check would also be terminated by the hack, no?

#

use BattlEye and eventually passworded servers

noble storm
#

Trying to make a script that utilizes the Vehicle Respawn module's "oldVehicle". I'm trying to get a waypoint to go to the position of oldVehicle, but every time the vehicle respawns on "Preserve" setting, the oldVehicle is teleported to 0,0,0. Any ideas on workarounds or solutions?

dreamy kestrel
#

why is it when we spawn Huron containers, i.e. fuel, ammo, etc, on the carrier deck, they bounce? eventually they sustain damage and destroy themselves.

ebon citrus
#

Make them simple objects

#

Or just enableSimulation false

dreamy kestrel
#

we place them so they can be engaged. that's the point, for repair, ammo, fuel.

#

for now I am trapping a special case and _asset allowDamage false.

winter rose
#

@dreamy kestrel maybe they are spawned some cm under the bridge level, making them bounce/collapse/explode ?

spark kiln
#

So has anyone tried making a weapon that fires zeus lightning on a target or a laser designator with the same function?

ebon citrus
#

Yes

#

Many times

#

100% vanilla

#

Let me know if you want the script

proud carbon
#

Hey, on my script I am trying to set an AI unit as an ace medic. what is the command for such?

ebon citrus
#

@proud carbon have you tried [unit] setUnitTrait ["Medic",true];

spark kiln
#

Yes
@ebon citrus oh god that's perfect , exactly what I needed

dreamy kestrel
#

@winter rose it is a possibility, the spawn proxies did seem a bit awkwardly placed. thanks for the suggestion.

ebon citrus
#

@spark kiln you want it?

#

i mean, it's free, but it needs some touching up for most purposes. Drop a DM or something and i can help you get it going

noble storm
#
_wp_2 setWaypointScript "simpleDrop.sqf";```
how would I properly put the params for the script in this line?
ebon citrus
#
[groupName, 1] would be the first in-editor waypoint
[groupName, 2] would be the second, etc.
restive leaf
#
[_grp, 2] setWaypointScript "somescript.sqf [1,2,3,4,5,6,7,8]";
noble storm
#

Thanks Grahame, that's what I needed. Guess it was a bit ambiguous.

ebon citrus
#

everything is correct from what i can see

#

a bit weird variable naming convention, but hey, you do you

#

wait, you meant, how to pass parameters for the .sqf script

#

what an ambiguous question

restive leaf
#

@noble storm Yeah, that description could be better but it is right if not clear: The script receives the following arguments in _this variable: [group, position, target] + [the optional passed arguments]. The optional arguments are appended to the end of the return array.

ebon citrus
#

good job grahame for spotting that

#

i cant see jack without my glasses on anymore cry

#

it's like using a 4k display for the first time... you can never go back

restive leaf
#

LOL... I actually really did buy a new pair of glasses today 🀣

ebon citrus
#

i got mine a couple weeks ago

restive leaf
#

My old ones hung together with duct tape

ebon citrus
#

proper harry potter stuff right there

tough abyss
#

anyone figured out the spectrum analyzer device yet? Is there new info on it for the contact dlc (not platform)?

random estuary
tough abyss
#

nope I said for the contact dlc. It says speciffcally in that artilcle that that info is for the platform version.

#

also tried looking through the configs and functions...

#

filtered by configFile, Contact, EM_Interface, and got relatively little information back about how the spectrum analyzer actually works.

random estuary
tough abyss
#

yeah, I blanketed all the channels, don't worry. thanks.

#

I figure I just need to be talking to someone with advanced scripting knowledge.

#

(which is also above my paygrade)

winter rose
#

data is still ebo'd, so… all you have is in-game config access and function library

tough abyss
#

yeah I know.

#

That doesn't stop someone who's better than me at arma scripting from figuring it out though πŸ™‚

winter rose
tough abyss
#

Yeah. I'd like to know who gives the ok to convert ebo to pbo... That's really what I need.

young current
#

BI makes those decisions

#

While waiting for that to happen you can try to see how the analyzer weapon is configured and what kind of UI things are connected to it

#

those can be seen from the in game config viewer or possibly you can make a contact config dump

#

if there are any internal sqfs in work those you will have to wait for untill the ebo->pbo stuff happens

tough abyss
#

might as well say bi makes those decisions. I want to know WHO at BI makes that decision.

winter rose
#

why? to pressure on them?

tough abyss
#

Oh yeah, I'm really going to affect them with "presssure" lol.

winter rose
#

then why πŸ˜„

tough abyss
#

It's a self answering question really.

winter rose
#

apparently not Β―_(ツ)_/Β―

tough abyss
#

for you maybe.

#

It's pretty simple though. Just need the person's name.

winter rose
#

this is why I am asking; now given this is a discussion channel… maybe enlighten us?

young current
#

We dont know who makes the call.

tough abyss
#

right. just thought I'd shoot from the hip.

#

not expecting much from discord chats, but you never know I guess.

winter rose
#

not expecting much from discord chats
yeah, some people keep not answering πŸ˜„

tough abyss
#

yeah dealing with mild trolling is always fun too.

unique sundial
#

BI janitor makes those decisions, but there is a new one each week

winter rose
#

I messaged him, he should send me the ebo→pbo tonight obviously

noble storm
#

You finally caught me. You'll have the pbo tonight. Check under your pillow when you wake up

tough abyss
#

kill me now.

#

At least I got the attention of the guy who wrote the article on live feeds for drones on tv screens. that was pretty cool.

#

if that is the real Killzone_Kid.

oblique arrow
#

Nah he's an imposter, he killed the real one and took up the name but dont tell anyone about it since its a server secret hehehe

#

(/s)

tough abyss
#

lulz

spark zenith
#

sorry to disappoint

winter rose
#

what was your original message? 😁

spark zenith
#

well probably not something fit for public channels

winter rose
#

woops. best to refrain indeed

tough abyss
#

mhm

ebon citrus
#

πŸ€”

#

What's going down?

#

And why would you need the contact spectrum device?

tough abyss
#

never mind, this has degraded far enough.

ebon citrus
#

Ok

tough abyss
#

moving on, nothing to see here

ebon citrus
#

Anything other than the signal label i can get working on the platform version

winter rose
#

It's a self answering question really.
so don't stress it Nica πŸ˜‰

ebon citrus
#

Been making a drone-jamming minigame

tough abyss
#

cool

#

I'm just pouring through the configFile campaign stuff to see if I can figure out what I want.

ebon citrus
#

What's the bohemia stance on reusing content inside epbo's?

tough abyss
#

meh, they'll be pbos eventually.

ebon citrus
#

Wrong channel to ask that question, i assume

winter rose
#

define "reusing"

ebon citrus
#

Redistributing under alp-sa

#

Specificly code

tough abyss
#

pretty awesome if you can decrypt ebos...

#

that's next level.

ebon citrus
#

I can get the sqf's out. Not the p3d's and textures though

#

And it's a tedious process

winter rose
#

you can use the functions, but technically not extract them to have them used outside of Contact I would believe

ebon citrus
#

I see... better no in that case then

tough abyss
ebon citrus
#

Do not redistribute our games or any files extracted from it, do not reverse engineer it, do not hack it, do not create any alterations of our games.

That solves it

tough abyss
#

if you really want to use something there's a "contact us" form at the bottom of the page.

#

(from the link I gave above)

coarse schooner
#

anyone know anything about forcing a vehicle to deploy countermeasures? i can't find much on the internet or wiki

#

smoke on a tank

ebon citrus
#

@coarse schooner have you tried the "useWeapon" action?

#

On the vehicle commander

#

Im pretty sure i saw someone using it like that in a "auto-countermeasure"script

coarse schooner
#

ohh interesting lemme try thnx

#

this did not work:

(vehicle player) action ["useWeapon", (vehicle player), cmdr_tank, 0];

the commander instead fired his machine gun.

#

changing the integer didn't do anything either perhaps a different action~~ but idk which ones actually exist or what arguments they need~~

winter rose
cunning crown
#
private _vehicle = tank;
_vehicle action ["useWeapon", _vehicle, commander _vehicle, 5];

Did work for me

ebon citrus
#

"Fire" could maybe work, dofire unlikely

cunning crown
#

With a Slammer Up; For the Marshall it the weapon index was 0

coarse schooner
#

perfect heyoxe thank you

ebon citrus
#

Finding the index is just a matter of testing

coarse schooner
#

yea I only went up to 4 smh xD

ebon citrus
#

I believe it goes up to 20

#

But most of them are unused

coarse schooner
#

thanks guys

dreamy kestrel
#

Q: is _this#0 the same as saying _this select 0?

unreal scroll
#

@dreamy kestrel Yes.

Have the following problem:

<-- here all params are ok
[{
params ["_veh","_group","_frompos"];
(_veh getvariable ["OT_Deployed",false]) or (_group getvariable ["OT_Ejected",false]) or ({alive _x} count units _group isEqualTo 0)
},{
params ["_veh","_group","_frompos"];
<-- and here the group is null, but others are ok.
...code;
}, [_veh,_group,_frompos]] call CBA_fnc_waitUntilAndExecute;

How it could be? What I missed?

worn forge
#

What's the error?

unreal scroll
#

As the group variable value doesn't pass, then the group is stuck. CBA functions doesn't throw any error for code inside it.

#

Hm... I found the issue. Seems like the condition string should be all in parentheses.

noble storm
#

Getting an error about Local variable in Global space for this. Anything special I need to do to _blackfishVehicle, or should I just make a new variable that's global and put it there?

_wp_2 setWaypointScript "simpleDrop.sqf [_blackfishVehicle]";```
still forum
#

syntax error

#

what u tryin to do

#

oh wow.. not even syntax error.. wtf is that 🀣

noble storm
#

Trying to take the vehicle from BIS_fnc_spawnvehicle and pass it onto a script that'll drop out cargo

still forum
#

Yeah you can't pass local variables into other scripts

noble storm
#

Alright so should I just make a global variable to pass on then?

still forum
#

you need to make it a global, or store it otherwise like with setVariable onto the group

noble storm
#

Alright, thanks

astral dawn
#

What errors cause an arma spawned script to self-terminate?

#

So far I've noticed, a local variable is nil -> just shows error

#

expected object, got number -> crash

robust brook
#

@astral dawn send code

astral dawn
#

It's a general question not related to a specific script I have

#

I just noticed that sometimes it terminates the script and sometimes it doesn't. There must be some rule which causes it to terminate it.

ebon citrus
#

@astral dawn thread. If it's the main thread, the script crashes. If it's a spawmned thread, it keeps on wokring

#

well, the thread in which the error occurs in usually what crashes

#

ort "terminates"

still forum
#

If it's the main thread, the script crashes. If it's a spawmned thread, it keeps on wokring
what... no

#

main thread means unscheduled I assume? everything else that's not unscheduled is spawned

astral dawn
#

Not always, sometimes it keeps on working. Maybe I will just post scripts to show both behaviors here.

queen cargo
#

My advice: fix everything and nothing will error

winter rose
#

^

winter rose
#

So! back on topic, @astral dawn iirc sqs scripts would continue running sometimes even after error - maybe it was due to line-based scripts

#

but it was back in OFP, I don't remember later behaviour properly

astral dawn
#

Error handling is just non existant. I was trying to make a reasonable crash dump by logging each object I am calling a function on, and reading the last one, then making a crash dump of it.

#

Of course later I found out that sometimes it does not crash immediately upon error.

#

But will go on and crash later, on another object.

winter rose
#

it should throw the error on the spot though

astral dawn
#

'Just make no error' is not an answer too, sorry.

jade abyss
#

@astral dawn .rpt -> Check the very first error msg that shows up, when scrolling down. JUST fix that, then recheck again.

winter rose
#

it always depends on your usage, we need more info for a more precise answer πŸ™ƒ

jade abyss
#

Other could just be followUp Errors

astral dawn
#

I understand that Dscha. It just didn't terminate the script immediately. So I was confused. Trying to implement some error handling in SQF.

queen cargo
#

good luck on that

#

try using try-catch, that might help

still forum
#

try using try-catch, that might help
how? It doesn't catch script errors

queen cargo
#

nope

#

but allows for custom error handling

astral dawn
#

Not script error

queen cargo
#

with loads of fancy call wraps, one can archive proper error handling

astral dawn
#

As I understood from wiki

winter rose
#
if (myObj == objNull) then { throw 'error'; }
```?
queen cargo
#

at the (heavy) cost of performance

jade abyss
#

@winter rose still pointless

winter rose
#

the code I suppose πŸ˜„

jade abyss
#

usage of params + if-check for standard Var = safeside in sqf

winter rose
#

yes, hence the "make no error first"

what is the use case @astral dawn ?

jade abyss
#

No need to overcomplicate everything all the time...

still forum
#

@winter rose == objNull never returns true

winter rose
#

yeah well, let me wake up πŸ˜„

#

isNull πŸ‘€

#

a sentence I had some issues with when learning coding: "sometimes, you want the code to crash"

#

it is sometimes indeed pointless to continue running your script in x or y state

astral dawn
#

Use case is to get automated crash dumps in rpt when spawned thread crashes.

winter rose
#

but doesn't the error message bring you enough info though? or use SQF-VM, or Dedmen's debugger?

#

unless it is for higher purpose (idk)

astral dawn
#

Not enough of course, I want more data

jade abyss
#

Was about to say the same πŸ€”

#

like?

astral dawn
#

Like why not have a crash dump when I can easily organize it? Only problem is thread actually crashing not on first script error, which makes it more complicated.

jade abyss
#

erm

astral dawn
#

Well we have a framework with lots of objects (OOP objects) and lots of code to do lots of things to control a whole army of bots, idk why there is confusion πŸ™„
Users have errors sometimes, but on our local tests with ADE enabled we couldn't really catch such error to get a proper call stack dump with ade at least.

jade abyss
#

Then it's a design problem :/

queen cargo
#

na
a user error problem
better known as the "i did nothing wrong" syndrome

primal marten
#

Apologies I am sure there is a simple answer to this. How do I create and ACE Virtual Arsenal in an area? I want the players to walk into a room and get the scroll wheel option to open an ACE Arsenal as opposed to it being tied to a box. Many thanks in advance.

astral dawn
#

What? Are you referring to us @queen cargo ? We surely did something wrong in the code. I was hoping that dumping data could reveal what exactly.

queen cargo
#

nah

#

the users reporting the issues

#

they just did not gave you all info required

astral dawn
#

Well aim is to have all what is needed in the rpt file (:

queen cargo
#

"did nothing wrong" said the CEO to the IT tech who tries to find out why the latest ransomware just infected the company network

jade abyss
#

This is helpful in wich way?

queen cargo
#

start working backwards from whatever caused the crash and check every variable, every method and everything else what could potentially interfere with it

still forum
#

start working backwards from whatever caused the crash
The issue here is, detecting and logging the crash

#

finding the cause once you have a log isn't the problem

jade abyss
#

diag_log everything :meme:

astral dawn
#

This is helpful in wich way?

Programs are making crash dumps for data to be analyzed later, aren't they? In which way is it helpful?

#

Although we can't dump local variables :(

#

So help is limited

queen cargo
#

logs are useful
but not the ultimate solution

biggest problem still is and always will be the inability of SQFs try catch to actually catch script engine issues πŸ˜…

jade abyss
#

@astral dawn That wasn't directed to you

astral dawn
#

Ok sorry!

jade abyss
#

πŸ‘

astral dawn
#

Chat is asynchronous

jade abyss
#

As mentioned before: diag_log everything

#

Each line, checking input/ouput of files/functions/calls/commands, where you assume the problem is*:
diag_log ["scriptName","_dataName =",_data]
stuff like that

astral dawn
#

sure I have considered this option πŸ˜„ but it will generate 100s of megabytes of data for some common code until the crash

still forum
primal marten
#

@still forum thanks sir! So use the add action then "[player, player, true] call ace_arsenal_fnc_openBox"

still forum
#

yes

#

you'll have to either add the action to the player, or to the building and up its range a bit

#

to the building would be more efficient, not sure how reliable that'll be tho

jade abyss
#

@astral dawn

sure I have considered this option πŸ˜„ but it will generate 100s of megabytes of data for some common code until the crash
Probably, but better having a huge pile of logs (at least for a while) where you can see Errors/Data and beeing able to fix them afterwards, than just having a crashing Server Β―_(ツ)_/Β―

still forum
#

The problem is on the players/users side

#

you don't want to throw huge piles of logs at them when in 95% of plays nothing bad happens

jade abyss
#

Why not?

#

Also:
Just simply checking the previous .rpt's, knowing which functions are failing, add the diag_logs there, done.

fleet hazel
#

How do I remove a weapon from a car?

jade abyss
#

Be more precise

#

Are there other weapons/items in that car?

fleet hazel
#

Yes. There are many items in the car. I only need to remove 1 weapon.

jade abyss
#

Yeah, no

fleet hazel
#

I can't find the commands.

jade abyss
#

You have to store all the stuff, then clear it up, then readd it

#

It's a missing command since... always :/

fleet hazel
#

This madness

jade abyss
#

I don't like it either, but something we have to live with Β―_(ツ)_/Β―

#

Workaround:
Store all Weapons in an Array, remove the desired weapon (by configname for example), readd it to the car.

fleet hazel
#

Do developers know about the problem?

jade abyss
#

We just had that topic about 1-2 weeks

#

And a couple years ago too

#

It's a missing command since... always :/
☝️ 😦

fleet hazel
#

What does he think about it @lavish ocean

#

This creates big problems.

astral dawn
#

Maybe CBA has a function like that

jade abyss
#

Probably

still forum
#

it does yes

fleet hazel
#

Will this problem be solved?

still forum
#

unlikely

astral dawn
#

I don't understand arma's inventory system, with its maybe a hundred of functions for specific item types

winter rose
#

addItem now works for everything, weapons/items/magz right?

astral dawn
#

Yes? I dunno. Is there a wiki article which explains how to work with inventory the 2020 way?

worn forge
#

It's because the game has been iterating for 20 years. Flashpoint didn't have attachments, then Arma 2 did, so they added the capability, so you have old commands and new commands. Heck, getUnitLoadout is super useful, but that doesn't mean they'd take items away.

winter rose
#

Arma 2 didn't have attachments? πŸ€”

#

Arma 2 brought itemMap, itemGPS etc
Arma 3 brought vests/containers, attachments and finally non slot-based inventory

worn forge
#

Didn't it? I may be getting them mixed up. Anyway, points stands, they kept on changing how things worked and added new commands, didn't get rid of the old ones

still forum
#

Arma 2 didn't no. You had seperate weapon classes for each configuration, seperate model each

worn forge
#

That would have sucked.

still forum
#

and all that without arsenal being a thing :u

winter rose
#

*gives pill to Dedmen* it's alriiight, it can't hurt you now. this is all in the past!

#

we have ragdoll now πŸ˜„

hollow thistle
#

Sometimes I wish we didn't. πŸ˜„

winter rose
#

although an "arsenal" existed since ArmA, but not the one we know
some kind of big showcase where you would unlock gear with points

#

ah, it was the "Armory" - my bad

cosmic lichen
#

I remember those ammo boxes with 100 variants of m4's. That was fun...not

ebon citrus
#

Please dont mention arma 2 inventory scripting

#

Gives me the creeps

vernal mural
#

Using BIS_fnc_getCfgSubClasses it is possible to retrieve a class' subclasses. It is very useful, and I would like to know if there is a similar command/function allowing to retrieve a list of attributes for a given class ? I browsed through the wiki's functions list but I didn't see anything suitable

hollow thistle
vernal mural
#

oh quite interesting, should do the trick

#

thx !

#

ah heck, it returns properties in config format (smth like bin\config.bin/whatev). I'm gonna have to fiddle around with substrings and stuff

still forum
#

no it doesn't

#

thats what you get when you str a config type

#

just don't do that

#

use configName and others

vernal mural
#

was not aware of this command, configName. I'm always amazed by the amount of small, usefull commands/functions that I never had to use but which exists anyway. Thx for the tip

slow pollen
#

Hello guys i have something to ask i got Grad Peristance working atm still need to test some things out

now i want to make the list buy menu working how do i get all the weapons / items in there how do i know the class/display name.

and how can i add weapons etc from mods

alpine ledge
#

@slow pollen you can use the config viewer in the EDEN editor to see the classnames of everything
Weapons, uniforms, optics etc. will be in cfgWeapons, magazines will be in cfgMagazines

tough abyss
#

how do i make random task generator?

vernal mural
#

what do you mean "task" ?

tough abyss
#

how do i make like random mission appear on map

vernal mural
#

do you already have experience with scripting already ? if I understand well what you are asking for, that's not gonna be easy to explain from scratch...

snow cipher
#

Is there a current fix for the floating above chairs?

#

The one with acex fix pretty much broke after the jan. update

young current
#

sounds like something some mod does so you may need to ask the mod makers

snow cipher
#

I see

#

What would be the right channel if there's any?

young current
#

well depending what mod it is, its makers might be here or you need to reach them wherever they have a contact point, their own discord, BI forums etc

slow pollen
#

@alpine ledge So can i copy and paste it or is it a bit more work

alpine ledge
#

you'll need to copypaste them individually, but they should all be in the same location roughly so it's not too much effort

faint oasis
#

i have a question ? i have created a script for bring an helicopter and unload the troops in but when i set the "TR UNLOAD" the helicopter come to the point but don't unload anything so anyone know why ?

slow pollen
#

ah cool thank you

faint oasis
#

@ebon citrus thx and i don't have tried this. I will try it but i don't understand because i don't put the waypoint on the vehicle i put it on the group.

#
_wp1 =_new_group1 addWaypoint [_landing_pos, 0];
_wp1 setWaypointType "TR UNLOAD";
ebon citrus
#

the target group of TR UNLOAD is the vehicle crew

#

NOT the units you want to unload

#

The group will move to the waypoint (spatial or object), where any units from other groups who are in cargo spaces of the original group's vehicles will disembark.

faint oasis
#

yes i'm sorry i don't have post all of the script but the unit who is crew of the helicopter is the new_group1 and the unit to unload is new_group2

ebon citrus
#

then get the driver of the vehicle

#

try that

#

as detailed in the post

faint oasis
#

ok i will test it

#

@ebon citrus yes but when i add (driver _new_vehicle) addWaypoint [_landing_pos, 0];

#

i have an error

#

because we need a group

#

and if i add group driver _new_vehicle it's same of "_wp1 =_new_group1 addWaypoint [_landing_pos, 0];"

ebon citrus
faint oasis
#

so i don't know how to do that

ebon citrus
#

yeah, the addwaypoint takes a group

#

have you tried setting the driver of the vehicle as the commander?

#

let me fire up arma 3

faint oasis
#

no i will test it

#

with that : group player selectLeader player;

#

?

ebon citrus
#

does the helicopter land?

faint oasis
#

no the helicopter don't land

#

i have created 2 waypoint

ebon citrus
#

could it be that there is no room to land?

faint oasis
#

he come to the first waypoint

#

and he wait

#

in the air

#

sorry for my english

ebon citrus
#

no worries

#

i mean, one way is to just "land" the helicopter and then force the gorup outsiode it to get out

#

but that's sort of hacky

faint oasis
#

yes i have do that

#

i have create a scripted waypoint for land my helicopter

#

he worked but my helicopter when he is on the ground go up and the unit get out in the air

#

so i will remove all of the waypoint when my helicopter is on the ground but after that my helicopter shutoff his engine so i will add ""Engine on""

#

but i don't understand why bohemia doesn't add this feature and the land feature because we need to create a scripted waypoint

ebon citrus
#

yeah, i see what you mean now

#

HOLD

#

@faint oasis this one work for me without issue :


wp = (group (driver this)) addWaypoint [getPosATL m_0, 0];
wp setWaypointType "TR UNLOAD";

#

when ia dded it to the init of the vehicle

#

jsut make sure that the object m_0 is a helipad(invisible)

#

the TR UNLOAD favors the closest helipad

faint oasis
#

oh ok

ebon citrus
#

so you want to spawn an invisible helipad nearby where the helicopter will land

faint oasis
#

i will test it

dreamy kestrel
#

hello, looking for a reasonable way to calculate breathing rate given fatigue/stamina.

#

starting with, I suppose, fatigue/stamina comprehension, i.e. what those numbers mean.

restive leaf
dreamy kestrel
#

Would be helpful to know "out of how many seconds", not just, "seconds until depletion". In order to gauge relative windedness.

#

or is it feasible to ask for the [0..1] interval from fatigue?

young current
acoustic abyss
#

Hey y'all,

Would someone have tips for the setObjectTextureGlobal command?
I have used it on the User Texture object for a .jpg . This displays fine in singleplayer, but in multiplayer games, the texture quickly flashes, then disappears. Does this sound familiar to anyone?

young current
#

how do you execute the code in MP?

restive leaf
#

Nope. I retexture my UGVs with a Russian camo and it works fine in MP

#

Like this in the spawner for UAVs and UGVs: sqf if (_vehicle isKindOf "LandVehicle") then { _vehicle setObjectTextureGlobal [0, "x\addons\EpochZMod\data\UGV.paa"]; _vehicle setObjectTextureGlobal [2, "x\addons\EpochZMod\data\UGV.paa"]; _vehicle removeMagazinesTurret ["96Rnd_40mm_G_belt",[0]]; };

jagged trout
#

Any tips for smoothing out unitplay movements in helicopters on low player count servers? Everything I find through the google machine is posts from 2015 saying that unitcapture and unitplay dont work at all in MP... but it does.

#

Were talking like 6-10 player coop mission hosted on a dedicated server.

ebon citrus
#

Set the fps parameter higher

#

I personally cannot see jitter beyond 34

jagged trout
#

Cool, I was thinking that but figured I'd asked before re-recording.

#

I think I recorded at 20, default.

ebon citrus
#

I dont know about the traffic intensity of unitplay though

winter rose
#

@acoustic abyss you did put it in the init field, didn't you?

ornate sky
#

Why do some anims work only with switchMove, and not with playMove(Now)?

hollow thistle
#

Because playMove needs to have transitions configured

#

So if there's no smooth transition from current anim to played it won't work.

acoustic abyss
#

@winter rose it's an external addaction script. Trying to get a kind of slideshow to work, without mod dependencies.

winter rose
minor lance
#

Hello!

#

We have a problems with speed in vehicles. For some players (Very limited amount) the speed of the vehicle is like in "Mph" and for the rest is not. We have some speed radars and theese people get their fine at 50 km/h when normal people get it at 80km/h If i measure the speed with a script, its ok. If i remoteexec the vehicle speed from driver to me, its ok... ANy clue?

cunning crown
#

Your script is broken; Arma 3 speed is in km/h and the velocity in m/s

#

Maybe that you have a modded server and user can select in which unit the speed is displayed and you're script use these Β―_(ツ)_/Β―

minor lance
#

But arma 3 has only km/h support :/

winter rose
#

script plz

restive leaf
#

Maybe that you have a modded server Speed trap... hmm... probably Life server

#

But if we see the script then we should be easily able to spot the problem

hollow thistle
#

useImperialSystem=0; in <profileName>.Arma3Profile

restive leaf
#

Well, I did not know that that existed...

minor lance
#

Let me check user profile

winter rose
#

anyway, script - because just that shouldn't do anything if the script is, well, well done

restive leaf
#

Sounds like the player playing the cop has imperial units but the rules on speeding are only presented in metric so they can't work out when to give out a speeding violation 🀷

#

Rather than a broken script

winter rose
#

but imperial units option only impacts UI, not speed command output

restive leaf
#

But the user will presumably be presented with mph with that setting ... For some players (Very limited amount) the speed of the vehicle is like in "Mph" and for the rest is not

#

But seeing the script would confirm

winter rose
#

We have some speed radars and theese people get their fine at 50 km/h when normal people get it at 80km/h
it's this part that I worry about

restive leaf
#

I assume being Life they chase the perp and ticket them... it's what they do

minor lance
#

if(_speed < 30) exitWith {};
if(_speed > 50) then {...};
...

#

Not too much to see there

#

Waiting for the user still

winter rose
#

are you obtaining _speed with the speed command, or calculating with velocity ?

#

Β―_(ツ)_/Β―

hollow thistle
#

That pasted snippet is useles, it gives no context where the value comes from. πŸ™ƒ

minor lance
#

vehicle speed from driver
@minor lance

With

speed objectpatent player
young current
#

why are you using objectparent and not vehicle?

minor lance
#

Just testing

#

I've never used velocity command

#

Only setVelocity

dusk sage
#

It doesn't matter that he's using objectparent, it's good

#

Just make sure you check if it's null @minor lance

dreamy kestrel
#

hmm, perhaps this is too fancy for A3 to include/code generate?

#define COMPILE_FINAL_LOCALE_FUNC(parent, children, name) MY_prefix_##name = compileFinal preprocessFileLineNumbers "my\prefix\##parent##\##children##\##name##.sqf"

which in practical usage, something like this:

COMPILE_FINAL_LOCALE_FUNC(shared, functions, fnc_test);

Which, if I understand the preprocessor docs, I think, should yield something like MY_prefix_fnc_test compiled from "my\prefix\shared\functions\fnc_test.sqf", should it not? However, an extra space is being injected somehow, i.e. MY_prefix_ fnc_test, contrary to the docs.
What am I missing?

cunning crown
#

an extra space is being injected somehow
...(parent, children, name)...
^ ^ Here are your extra spaces;

queen cargo
#

Yup

dreamy kestrel
#

seriously? okay, wow. thanks.

#

quite an inclusive interpretation of the macro params...

queen cargo
#

You can try sqf-vm to debug stuff like that
Will be much easier then running the game everytime to test you ist define πŸ˜‰
https://forums.bohemia.net/forums/topic/210118-sqf-vm-an-sqf-emulator/

dreamy kestrel
#

thanks, I'll give that a looksee. anything I can do to up my game, so to say.

dreamy kestrel
#

hmm, A3 does not seem to like includes within the scope of a class ... {}, in particular class CfgSounds { ... }, drops right off my screen when I do that.

solar forge
#

If I'm having some code that isn't having the desired effect (or any effect it seems) when I execute it, but it is proven to work on many other machines/players, and additionally doesn't throw up any errors in the rpt, whats the best way to approach an issue like this?

still forum
#

3 does not seem to like includes within the scope of a class ... {}
doesn't make much sense, the preprocessor doesn't know what a "class" is

dreamy kestrel
#

got 'er sorted.

astral carbon
#

Hi, how can I delete a Unit that I created?

#

Ex, I used "some_unit_name" createUnit [position some_position, group some_group];

still forum
#

store the unit you created in a variable

astral dawn
#

"type" createUnit ... doesn't return anything

astral carbon
#

Huh, like this?


_pos = getpos someloc;

test = "some_unit_name" createUnit [_pos, _group];```
#

as in 'test'?

#

"type" createUnit ... doesn't return anything
Huh it doesn't? Just read up on the site. hm then what would be the best way to go about spawning an AI and deleting an AI directly from a script?

winter rose
#

use the main syntax that returns the unit:

// group createUnit [type, position, markers, placement, special]
_unit = group player createUnit ["B_RangeMaster_F", position player, [], 0, "FORM"];

https://community.bistudio.com/wiki/createUnit

#

@astral carbon

astral carbon
#

Gotcha, thanks man

astral carbon
#

Hmm

#
_pos = getpos scp173loc;
_scpGroup = creategroup east;
scp_173 = group _scpGroup createUnit ["O_SCP_173", position _pos, [], 0, "FORM"];```

Any idea on why that doesn't actually work?
#

The error is something like, it expects an object - not a group (line 3)

hollow thistle
#

You're trying to get group of a group

#

Drop group operator

astral carbon
#

rpfacepalm didn't notice that

#

I'll try that

#

Error position (type array), expected Object,Location

hollow thistle
#

Yeah, you're trying to get position of position array

solar forge
#

Sorry to ask again, I'll try to simplify my question from earlier I think I worded it in a complex way:
How should I debug code that isn't working but isn't throwing up errors in the rpt?

astral carbon
#

Huh thanks guys, it works.

hollow thistle
#

Well, you need to debug it... Depending on what it is.

#

Run it line by line.

#

Try running in scheduled so it errors on nils.

#

There's no universal way.

solar forge
#

Okay right,
so I should try each of the parts step by step

astral carbon
#

Hm so I can't use deleteVehicle on the main syntax that "returns the unit". Nothing happens (I use deleteVehicle scp_173 in this case)

#

Actually I lied, appreciate it everyone!

astral carbon
#

How can I check if a player is in a trigger after sleeping for a few seconds? I found out player inList is a thing that you can put inside the condition but I need to put it inside the on activation or smth. some sort of wait x seconds, check if InList, then whatever. Not sure if that's possible. I can't let this trigger detect if you're in the list right away as I need to give them the ability to run away before any action happens.

ebon citrus
#

You cant sleep within the trigger activation field, if i recall correctly. You'll have to spawn another task

finite sail
#

you can set a timer within the trigger

#

timer type and timer vallues

dreamy kestrel
#

Hello, I need a way to get the player's looking directional vector for a breathing service. The breathe itself is working, but I want the breathing to be oriented in that vector.

exotic flax
#

eyeDirection is probably the best you can get at the moment

#

the wiki page does has some examples which could get some better results (to also get vertical direction)

dreamy kestrel
#

great thank you.

dreamy kestrel
#

Okay, so eyeDirection is interesting, problem is, getRelPos is working from the object out, and does not take a 3D vector.

#

literally flow calculation something like this, private _flow = (getPosASL _proxy vectorFromTo (_proxy getRelPos [10, 90])) vectorMultiply 0.5. This is always perpendicular to the player's orientation. Not where his head is turned.

#

which itself may need a slight adjustment, where the _proxy object is attached in the first place when the head is turned.

#

Actually, the key is here I think... that is always out from the mouth... _proxy attachTo [player, [0, 0.1, 0], "head"], which I think is a lot simpler than I had feared.

exotic flax
#

Only problem with attachTo head is that it won't rotate based on the head movements (it's basically a static proxy to indicate where the head is relative to the body).

#

guess something like this is what you're looking for

_proxy = "anything you want";
onEachFrame {
   // get player head position
   _head = ASLToAGL eyePos player;
   // get vector 1m from head
   _vector = (_beg vectorAdd (eyeDirection player vectorMultiply 1));
   // set proxy at vector
   _proxy setPosASL _vector;
};
ebon citrus
#

if it's breath, you probably dont want the particle effect to be literally ATTACHED to the players head movement, but rather spawned at the direction

copper raven
#

local variables declared outside onEachFrame scope aren't inherited

slow pollen
#

Hello i got my money system and store working

is there anyway i can make Personal Storage for people so whenever they bought stuff but dont want to use it for that mission they can store it and acces it

surreal peak
#

@slow pollen By stuff do u mean items/ vehicles or both?

slow pollen
#

sorry i mean Items

#

only items

surreal peak
#

would this be a multiplayer server?

slow pollen
#

yes

surreal peak
#

I suppose you could have an array assigned to each player and simply add/remove items from this array to represent a vault sort of thing

#

maybe something like this?

slow pollen
#

oke going to check it out thanks

tender fossil
#

😦

winter rose
#

what is it @tender fossil ?

#

oh. I see.

ebon citrus
#

Im confused

winter rose
#

hi confused, I'm dad!

primal marten
#

Hi All, I know this should be so simple and i have been trawling and trying to find a solution. For a mission I want to give the players some camera's or spotting scopes, they can place these and a feed is then set back to their tablets. This would allow them to use these for surveillance. Is there a script already out there which would allow such thing? Many thanks in advance,

worn forge
#

The real simple solution to this is the Remote Designator backpack

primal marten
#

Never used or seen that will check it out

worn forge
#

Is there a command that tells you the current VTOL status of a VTOL airframe? Ie., something that tells me that it's currently using vectored thrust mode?

young current
#

the animation source for the vectoring perhaps.

rustic plover
#

How I can remove handler from addPublicVariableEventHandler?

#

I know the way by changing event handler to {}. Is it correct?

winter rose
#

changesqf {call em_submenu_playerselect} to```sqf
{_this call em_submenu_playerselect}

#

what is _target?

#
player addAction [name _x, {call em_submenu_playerselect}, _target];
``` ↓```sqf
player addAction [name _x, em_submenu_playerselect];
#

(be sure to define it before though)

#

em_submenu_playerselect

#

wait.

#

without any other change at all, do

player addAction [name _x, {_this call em_submenu_playerselect}, _x];
#
_selectedPlayer = _arguments```too
#

no need for _this select 3

#

copypaste your current code?

#
player addAction [name _x, {_this call em_submenu_playerselect, _x}]
``` doesn't quite look like what I sent you
#

… thanks πŸ˜…

#

yes, because the addAction code is a new scope that doesn't know at all the _selectedPlayer variable

#

pass it as an argument here once again

#
player addAction ["DEBUG", { params ["_target", "_caller", "_actionId", "_arguments"]; hint format ["Selected %1", name _arguments]; }, _selectedPlayer];
#

by new scope, I mean that the addAction code between brackets { } is not aware of _selectedPlayer; it's a totally new and different script

#

you pass it to the new addAction

#

even if _arguments are named the same, they are not the same variable

rustic plover
#

remoteExec returns result of remote command?

winter rose
#

addAction is not a good way to do menus

rustic plover
#

@winter rose it's means that not?

winter rose
#

UI is always a mess anyway

#

@rustic plover Return Value: Anything - Nil in case of error. String otherwise. If JIP is not requested this is an empty string, if JIP is requested, it is the JIP ID. See the topic Function for more information. it returns nil in case of error

rustic plover
#

@winter rose ok, if i want to get remote result, i must to use BIS_fnc_MP, yes?

winter rose
#

no

#

BIS_fnc_MP, as its page says, is obsolete

#

what is it that you want to do? it will be faster

#

yeah?

#

argument is not local, it's another player I suppose
youshould use remoteExec

#

remoteExec

#

no, remoteExec

#

if what you want to set captive is not local to your computer, it won't work

rustic plover
#

I know that getPlayerUID returns "" if unit is not local and I try to find a solution if this

winter rose
#

language (please edit)

#

religion has nothing to do with that, actually

#

"foul language"
but well, rules are rules, I didn't write them, I try my best not to get kicked ^^

#

works?

#

noice

#

@rustic plover the client would have to send it to the server, or setVariable it on itself and then the server could getVariable it

@odd pollen you do what you want with it, it's a unit reference as good as another; setDamage, vehicle, etc - help yourself!

#

nope. unless client-side you setVariable save its cursorObject and the server gets it

#

it's remote_Exec_, not remote_GetResult_

rustic plover
#

@winter rose ok, I show you my code example:

// Non-sheduled scope
// ...
[[], {
_return = call { /* some code with return */ };
player setVariable ["someReturnValue", _return, true};
// or by publicVariable method
}] remoteExec ["call", _unitId];
// Will it be correct while low server perfomance?
// Or when count of players is 200+?
// Maybe some delay needs to be there (but non-sheduled scope limitations...)
_clientReturn = _unitId getVariable ["someReturnValue", nil];

What do you think about it?

winter rose
#

you clearly need the delay, as immediate execution of remoteExec is not guaranteed

but basically, yes - you can do that

rustic plover
#

Do you know some ways to delay in non-scheduled scope? I think while {true} do {} execution may helps, it'll take little bit of time

winter rose
#

don't

rustic plover
#

duck

winter rose
#

unscheduled is meant to be unscheduled, don't wait anything

rustic plover
#

... and BIS wiki has 502 error

winter rose
#

yep

astral carbon
#

rip

#

o they use nginx, nice

#

Anyone know what side (e.g north, east, etc) Bluefor is?

#

Wait is it north? I know opfor is east

winter rose
#

west

astral carbon
#

Ohh thanks

#

This is the right syntax right?

_group = createGroup west;

ainame join _group```
#

or joinAs? not sure what the difference is lol

winter rose
#

[unit] join _group

astral carbon
#

gotcha

cunning crown
astral carbon
#

Oh thanks for the link!

#

I appreciate it

winter rose
astral carbon
#

Lol

winter rose
#

yes

rustic plover
#

@odd pollen change

name _x

into

"<t color='#FF0000'>" + name _x + "</t>"
#

addAction parses title into structural text

violet gull
#

Is it me or do AI not move to precise positions anymore via script?

This code telling the AI to move to a front passenger wheel only has the AI either walk 5 to 10 meters close to it or just walk to a random position within 20 meters of the vehicle.
grp addWaypoint[(v modelToWorld[_selPos#0+.5,_selPos#1,-1.4]),-1.4]

#

Even disabled nearly all AI features, aside from anim, move, path, and teamSwitch

#

Same result with agents with moveTo as well

violet gull
#

Seems to only be doable if the simulation is disabled or if it's a simpleObject

astral dawn
#

I was doing some doMove to make bots walk to vehicles, behaviour was same as you describe

wispy cave
#

quick question, is the WeaponAssembled EH persistent over respawns?

still forum
#

@winter rose
https://discordapp.com/channels/105462288051380224/105462984087728128/672944692685439016
Makes no difference at all. If you don't pass _this, then it will get passed anyway because lower scope can read higher scope variables..

@winter rose
https://discordapp.com/channels/105462288051380224/105462984087728128/672946485440282645
NO! VERY bad advice. Action code is stored as string, meaning its always recompiled. The second one will have to recompile the whole function.
player addAction ["DEBUG", { hint format ["Selected", name _selectedPlayer] }];
The addAction code is a completely new script, local variables don't carry over into it. And I'm sure endigma has been told that several times already.

winter rose
#

oh, didn't know this code string thing!

thick merlin
#

Hey guys,

#

I am in need of some script help please.Ive done some research but i still cant seem to get the script to work correct.

#

Iam using this script in a scripted waypoint so that the waypoint will hold whilst the script is running

#

heres my code from my pz1.sqf

#

Its in the scripted waypoint special script exec box in that waypoint

#

{_x assignascargo h1} foreach units grp1;
{[_x] ordergetin true} foreach units grp1;
{ _x enableai "move" } forEach units grp1;
{ _x setunitpos "up" } forEach units grp1;
activate1 = true;

waitUntil {{_x in h1} count (units grp1) < 1};

h1 vehicleChat "Show this text";

#

my issue is the waitUntill section toatlly loses me.Any help woulf be greatly appreciated.:)

#

I have limited script skills so this is getting a bit tough to pull off on my own.:(

#

Thanks.

still forum
#

why 4 foreach loops when you could just do everything in a single one?

#

global variables without prefix is bad

#

the waitUntil should probably use findIf, because thats what you actually do there

thick merlin
#

cos my scripting skills require me to keep it simple as can be.

#

the waitunitll is just to make the script hold untill the group is in heli

worn forge
#

@wispy cave , yes :)

ebon citrus
#

Try to use codeblocks

brave jungle
#
_sides = [West, East, Independent, Civilian];
_curSelFac = [(_sides select (_sides find str lbCurSel 2100))] call BIS_fnc_getFactions;

Getting zero divisor error, but doesn't find return a number

wispy cave
#

Tnx @worn forge πŸ˜„

ebon citrus
#

Makes code snippets more readable

#

I know this is a bit rich, but please newline πŸ˜‚

#

But anyways, what exactly is the problem?

#

You dont know how waitUntil works?

brave jungle
#

isn't the WIKI down atm

#

i'm getting 502s

ebon citrus
brave jungle
#

oh i'm a melon

#

πŸ˜‚

ebon citrus
#

πŸ˜‚

#

Me too

finite sail
#

waituntil can be really tricky, for example, if one of @thick merlin s guys dies, for whatever reason, the waituntil might never release

still forum
#

@brave jungle yes it returns a number. That being -1 if it didn't find anything.
And your code cna never find anything, because _sides doesn't contain any strings

#

you can string functions using ;
@odd pollen no you cannot. Your code doesn't work.

finite sail
#

oh yeah, sides arent strings.. fallen for that one many a time

brave jungle
#

ye

wise frigate
#

Quick question,
I am looking for a way to have a vest change to another vest when the script is triggered. The main issue I am finding is finding a way to move all the contents of the vest into the new vest. Any ideas on how I could start this?

finite sail
#

wait for the biki to start working again would be the first advice πŸ™‚

thick merlin
#

Thanks for the help so far guys.:)I'am aware of doing some things a little tidier but atm I'am keeping things easy for myself to read and to spot typo's.Scripting is not my forte so cut me a little slack.:)

astral dawn
thick merlin
#

config looks ok

dark tulip
#

oh crap, sorry, thinking script, I'll delete and move it over there, thanks

#

@thick merlin thanks! not sure where I am messing up this undercover script setup

thick merlin
#

looks ok by what i could see.double check filepaths

#

Regarding my waituntill issue i did some research and spawning it in the script was required.I also messed around with this -

#

[] spawn {
waituntil {sleep 1;!(grp1 in h1);(vehicle player == player);h1 vehicleChat "Show this text"};
};

#

still no luck

#

anyone see any glaring issues?

#

Its giving a "Generic error in expression" error.

hollow thistle
#

what

#

spawn = scheduled

#

It's just that that code is just plain wrong.

#

waitUntil expects boolean return

finite sail
#

ah yes πŸ™‚

hollow thistle
#

vehicleChat returns nothing,

#
[] spawn { 
    waitUntil {
        sleep 1;

        !(grp1 in h1) && (vehicle player == player) // return
    };
// ...
};
#

(linking web archive as wiki is dead atm)

rustic plover
#

oh no, initialization order's page is not web archived 😭

dreamy kestrel
#

wiki is down, anyone have any updates on it coming back up?

winter rose
#

Monday most probably

dreamy kestrel
#

thanks. well, not a great workaround, but a workaround nonetheless, with Chrome translate.

winter rose
tough abyss
#

Hi! Anyone knows if it's possible to add an image into a HintC text message?!

winter rose
#

@tough abyss ^

tough abyss
#

I'm trying it πŸ˜‰

#

thanks

tough abyss
#

I'm trying to attach an object to players like this
testObject attachTo [player, [0,0,0]];
and I have a few questions.

Do all players need to have a variable name to be individually identifiable using this command or is there another way?
If I want to attach the same object to all players do I need to create multiple instances of the same object with different variable names and attach one to each? I'm mostly asking because I don't know how many players there will be when I want/need to do this.

Thanks
https://web.archive.org/web/https://community.bistudio.com/wiki/attachTo

winter rose
#

Do all players need to have a variable name to be individually identifiable using this command or is there another way?
depending on the case, you can use allPlayers

If I want to attach the same object to all players do I need to create multiple instances of the same object with different variable names and attach one to each?
yes

@tough abyss

#

but, in a forEach you can have only private variables

tough abyss
#

@winter rose Thank you for the answer.
How would allPlayers work exactly? Would it create multiple copies of the object for each player?

winter rose
#

no. allPlayers is a command that lists all players, so it is an array of units

tough abyss
#

so basically allPlayers[0] allPlayers[1] allPlayers[2] and so on?

#

One attach command for each of those?

winter rose
#

what you can do is

{
  private _myObject = createVehicle /* params */;
  _myObject attachTo [_x, [0,0,0]];
} forEach allPlayers;
tough abyss
#

This is helpful. And once I no longer wish the object to be attached what do I do?

dreamy kestrel
#

Q: I've got a script that simulates snow falling... I'd like to do this over water, however, the particles are falling "through" the water surface.

winter rose
#

deleteVehicle on attachedObjects @tough abyss

#

@dreamy kestrel yes.

tough abyss
#

The object I want to attach is a light, not a vehicle

#

So basically, I will light up all players and then remove it. (with the possibility to attach again in the same session)

dreamy kestrel
#

is there a way to work with the particles and detect when they are hitting the water surface? or for the particles to "stop" at the water surface?

tough abyss
#
forEach allPlayers {
testObject attachTo [?????, [0,0,0]];
}

Something like this?

winter rose
#

@tough abyss if you createVehicle, use deleteVehicle

The proper syntax is the one I sent you

#

@dreamy kestrel I think so, but it is expensive - also, the wiki is down for now

tough abyss
#

It's a module

#

That light is a mod that exists as a module

#

Zeus can also spawn it

winter rose
#

no. a module is an editor helper that executes a script, eventually creating objects

tough abyss
#

Also, in your code you mention _x as a player. where did that come from

winter rose
#

_x is the magic variable from forEach

tough abyss
#

huh

#

ok

winter rose
#

it means "the one item I am iterating"

tough abyss
#

So how would I create a copy of your code snippet for my module?

winter rose
#

I can't know the module's code behind it

tough abyss
#

I can spawn it in the editor before hand and give it a variable name

dreamy kestrel
#

@tough abyss virtually everything in A3 is a "vehicle" in one way or another. players, units, are vehicles. player == vehicle player for instance, when the player is standing alone.

#

your "mod" is probably creating a light source, most likely a vehicle at some level.

dreamy kestrel
dark temple
#

Heya is this chat for scripting in the editor?

winter rose
#

Here or #arma3_editor, it depends if it is about… scripting, or the editor 😁
@dark temple

dark temple
#

Well my problem involves modules so I think scripting? Idk I’m kinda new

dreamy kestrel
#

how "quickly" is setDropInterval capable of dropping? so far running at _x setDropInterval 0.001, that is "heavier" snow fall than at 0.005, for instance. faster than that? adjusting for performance obviously.

dreamy kestrel
#

four decimal places appears to be the practical limit. anything less than that no discernible effect.

winter rose
#

@dreamy kestrel you can create multiple ones to get the proper amount

dark temple
#

Can someone who is a expert in modules help

young current
#

you will just need to ask your question, if someone knows how to help, they usually answer

dreamy kestrel
#

@winter rose interesting, good idea, thank you...

dark temple
#

I need to send a picture to the person. I’m not sure how to describe it

#

Idk it’s weird

#

Dm me or ping me if you can help

cunning crown
#

We cannot help if we don't know what's the issue

dark temple
#

I don’t know what the issue is either

#

I need to send a picture but it doesn’t send here

cunning crown
#

use imgur or any image sharing platform

drowsy axle
#

Is there a way to create a playable slot - mid mission?

jade abyss
#

nope

dark temple
#

I am using the artillery support module. Whenever I use a shell it say β€œsee getvariable β€œBIS_SUPP_supporting”)) |#||| !alive_provider
Delete marker _mrk...’
Error undefined behavior: waituntil returned nil. True or false expected.

#

Says not say

winter rose
#

Β―_(ツ)_/Β―

tough abyss
#

Hi @winter rose I was trying and trying how to add an inmage into a hintC box but nothing works, would you show me an example?!

winter rose
tough abyss
#

I was using something like

hintC "<img image='Img\icons\help_faid.paa' width='30' height='50' />";
hintC_EH = findDisplay 57 displayAddEventHandler ["unload", {
0 = _this spawn {
_this select 0 displayRemoveEventHandler ["unload", hintC_EH];
hintSilent "";
};
}];

winter rose
#

```sqf
/* your code here */
```

plz

rustic plover
#

What difference between ' and " in Arma?

#

For example:

_text = 'Hello world';
// and
_text = "Hello world";
#

I found something about it:

A string may consist of any number of ASCII characters and is enclosed by single-quotes (only in ArmA) or double-quotes
I can use single-quotes, but only in Arma series and it equal to double-quotes, yes?

still forum
#

none

#

same thing

rustic plover
#

Thanks, just I prefer single-quotes because it's looks better :)

#

But in macros i can't use double-quotes for some defines:

#define TEXT Hello world
#define EXAMPLE "TEXT" // pre-proccess to "TEXT"
#define EXAMPLE 'TEXT' // pre-proccess to 'Hello world'
#

It's normal?

still forum
#

Ah

#

yeah I guess thats the only difference between them πŸ€¦β€β™‚οΈ

misty root
#

Hello, I'm trying to change the saturation in game via a command, what is the variable of this one? Thank you! πŸ‘‹

rustic plover
#

πŸ€¦β€β™‚οΈ
Sorry for stupid questions

fair lava
#
[_this # 0, 8, 'ACE_Wheel'] call ace_repair_fnc_addSpareParts
#

is this valid syntax for sqf?

#

specifically the array access inside an array def

#

or do i need to put the element into a variable and then put that var into the array def

wanton swallow
#
drawIcon3D ["\RSC\targeticon.paa", 
            [1,1,1,1], _pos, 2 - (_distance / 50), 2 - (_distance / 50), 0, format["%1/%2", _obj getVariable "health", _obj getVariable "maxhealth"], 1, 0.03, "TahomaB"];
#

How to draw icon from mission files?

#

All time i getting "Can't open targeticon.paa"

tough abyss
#

Hey can someone help me with a script to create film grain, the bohemia websites arent working for me so im asking here

wanton swallow
#

drawIcon3D works with absolute file path. How to make correct relative path?

#

Found - getMissionPath

thick merlin
#

@[KP] veteran29. will try tonight.Thanks for your help and the linked documentation.πŸ™‚ πŸ™‚

thick merlin
#

@[KP] veteran29. Just tried that code and it too threw the same "Generic error in expression" error.

#

Heres a link to my test mission if that helps.

#

My research over these last few days that it is due to scheduled/unscheduled scripts.Thats where it goes over my head.

#

Any other ideas?

whole island
#

Hey guys, just a quick question. Is there a way to script a missions in a way to detect whether there is a ACE3 medical system adn set it's revive system accordingly? I mean, if there's ace - use it, if there's not, use the vanilla revive

ebon citrus
#

I use single quotes when i want double quotes inside a string

#

Like so

#

'Hello "World"'

#

Otherwise i use double quotes

#

Because the single quote is in an inconvenient place on the nordic layout

still forum
#

@fair lava valid.
Every array element is a "statement" you can do tons of stuff there. Its basically like one line of script, that will return a value at the end

tough abyss
#

Hi!!

Anybody knows how to change an image size in a hintC?!

I'm using that script but I'm going crazy trying thinks but nothing works.

My script.

`` private _image = "Img\icons\help_faid.paa";
private _txt = composeText [image _image, "Tutorial Text Here"];
"Help!" hintC _txt; ´´

Thank you so much.

ebon citrus
#

Hey, does anyone know any way to stop the player from reloading from backpack or will i have to jerry-rig it?thanks!

nocturne bluff
tough abyss
#

Ok thanks, I'll take a look.
Hope it works now.

broken snow
#

Im looking to make script a box so you get zeus when you go up to and interact with it. Anybody know how to do this?

dreamy kestrel
#

I did not see one, per se, but is there a way to determine the current state of how enableCamShake is set?

winter rose
#

is there a scripted way to create a ground weapon holder with a magazine-loaded weapon, besides using the unit action ["DropWeapon"] "hack"?

winter rose
#

oooh I keep forgetting about this one

#

too new

#

THANKS @runic spoke

runic spoke
#

πŸ‘

nocturne bluff
#

Flashy sparkling new

runic spoke
#

Yeah, I had to change some of my scripts when they added that. Great command that is.

winter rose
#

source of some other issues, but a really nice one nonetheless!

dreamy kestrel
#

if I wanted to remoteExec some code on a player _unit box, then I need owner _unit, correct? ... from the server, that is.

winter rose
#

just _unit is fine

dreamy kestrel
#

thanks. another Q: in the form, from say3D [sound, maxDistance, pitch, isSpeech], what is isSpeech default? true?

ebon citrus
#

Seems to be false

#

Dont quote me on that though. Experimentation is your best friend

dreamy kestrel
#

indeed, thanks. it's more for ambiance, really, assume that if I set it true that would incur downstream costs, i.e. 3D sound response from AI, that sort of thing

ebon ridge
#

Is there a way to set default Side that shows first in Role Assignment screen?

woven remnant
#

Hey folks - could use some help - I'm told it's possible to use saveGame; and loadGame; to save & load saves - but not sure how to actually use it - a friend mentioned I just need to login as admin and execute them?

fringe yoke
#

@woven remnant I may be wrong, but I believe that doesn't work for MP

still forum
#

oooh I keep forgetting about this one
how dare you @winter rose
The best command ever made by the best person ever with the best name ever :U HOW DARE YOU FORGET?!

winter rose
#

I didn't make this one!!1! :U

#

it's just new, why couldn't it simply exist on release Γ¨.Γ©

still forum
#

I wasn't there for release πŸ™ƒ

winter rose
#

that's on you

#

from now on I will personally blame you for evvverything πŸ˜„

still forum
#

Btw seems like things are moving 🀞
prepare for goodness impact

worn forge
#

Wait, what's movin'? πŸ™‚

still forum
#

You'll see when it happened. Just remember that I said smth is movin πŸ˜„

oblique arrow
#

Maybe its the inventory items that are moving heh

still forum
#

Maybe that too πŸ‘€

hollow thistle
#

and maybe much more!

still forum
#

i like the insider references, even tho I'm not sure if they are intended to be references πŸ€”

worn forge
#

Today's misc scripting question, anyone know if it's possible to set up a user's custom keyboard controls (Controls -> Keyboard -> Custom controls -> Use Action 1 ... 20) from script? I have a feeling it'd be necessary to do by mod, if at all.

hollow thistle
#

Not in any sane way.

winter rose
#

no can do (nor do you want to). Who would want his keys to be toyed through script??

worn forge
#

I've got some quality of life pilot functions I'd like the user to have access to, but it sounds like the best I can do is say, "You have some actions available, if you want them, go into custom controls and bind some keys to Use Action 1, 2, etc"

hollow thistle
#

Or use CBA keybinding system πŸ™‚

worn forge
#

Yeah, vanilla only πŸ™‚

hollow thistle
runic spoke
#

You know what would be great, is if a try-catch, caught script errors πŸ€”

winter rose
#

naaah, no self-respecting language needs that. I mean, C++ is from ~1983, SQS from ~2000, SQF from ~2003
time to evolve, man

#

Stop throwing rocks at me, dammit!

runic spoke
#

Or you can just use intercept and have the game crash, or actually catch the error 🀣

queen cargo
#

or use SQF-VM prior to add unit-tests πŸ˜›

#
// SQF-VM ONLY! Not for use in Arma
{
  // ... your code
}
except__
{
  diag_log format["test failed: %1", _ex];
}```
winter rose
#

noice! πŸ‘Œ

plain vale
#

So is there a simple script to use on units to designate a win state by taking them out?

#

something along the lines of "If i am dead then mission=win" but i need it for multiple units

#

basically set up a "blow these things X all up" mission wise

ebon ridge
#

Trying to automate workshop upload on github actions, 99% of the way there, and now blocked by steam guard. Is it possible to do this with a steam guarded account, anyone doing it already? Or even just anyone pushing to workshop via a CI setup?

dreamy kestrel
#

Q: windDir ... isn't wind cardinal direction named for the direction from which it is coming? i.e. wind blowing from N to S is a northerly wind.

winter rose
#

it returns an azimuth, a.k.a a 0..360 number

dreamy kestrel
#

yes, I see the wiki and the example. I think the example is confused.

brave jungle
#

Hiya getting an error with my select command:

_sidesstr = ["West", "East", "Independent", "Civilian"];
_curSelFac = [(str _sides select (str _sides find lbText [2100, lbCurSel 2100]))] call BIS_fnc_getFactions;

error at select - Generic error in expression
Surely find is giving me a number no?

winter rose
#

@dreamy kestrel I see what you mean, should be Southern

dreamy kestrel
#

as it relates to the windDir itself, that is the direction the wind is blowing?

brave jungle
#

@winter rose Plz be a rubber duck again πŸ˜„

winter rose
#

@brave jungle _sides not defined ?

also TELL THE ERROR YOU ENCOUNTER :v

queen cargo
#

@ebon ridge steamguard would be pretty damn useless if it was possible to circumvent it

winter rose
#

I'm no quack

brave jungle
#

legit just says (str _sides #select (str _sides - Generic error in expression

#

oh wait

#

have I

#

oh my

winter rose
#

yeah, your expr is a bit messy :p
try expanding it on multiple lines

queen cargo
brave jungle
#

stringed the array

#

yeah, your expr is a bit messy :p
try expanding it on multiple lines
@winter rose Yeah that too πŸ˜„

winter rose
#

πŸ˜„ πŸ¦†

brave jungle
#

See always

#

ty, will probs be back at some point haha

hollow thistle
#

@queen cargo you need to have arma on the account.

#

BI have set the arma workshop like that.

winter rose
#

@brave jungle anytime ^^

hollow thistle
#

Disabling the guard is just easier tho.

#

BUT, you can't upload public items with guard disabled.

winter rose
#

a soul for a soul

hollow thistle
#

So if you want to create new item on workshop you need to re-enable it remporarily.

#

also this is kinda getting into #arma3_tools direction I think.

ebon ridge
#

yeah so basically requires no steam guard, i don't understand you can't upload public items with guard disabled. though? As in I cant add NEW items, or I can't upload updates to any public items? Cos if its the latter its totally useless :/

#

i can see why so many modders hate steam workshop now...

#

@ebon ridge steamguard would be pretty damn useless if it was possible to circumvent it
Most systems have ways to create access tokens that give limited API access without requiring login or 2FA specifically for automation, e.g. github has this.

queen cargo
#

Thats true
Though... In steamcmd you log into your User Account πŸ˜… πŸ˜…

ebon ridge
#

yeah, i'll refer you to my previous statement on the topic of hating workshop πŸ˜„

#

thanks for the help, still would like to know if i can upload public items on a non steam guard account at all, as that wasn't clear

dreamy kestrel
#

Q: when working with particles and the source object in particular, what is the strength of that binding in terms of object "ownership" if you will? i.e. does the drop algo delete the object? or does that fall on the caller "before destroy"? i.e. via the drop call?

winter rose
#

I… am not sure to understand?

dreamy kestrel
#

i.e.

_wisp = _particleSourceName createVehicleLocal _pos;
drop [[_wispShapeName, 1, 0, 1], "", "Billboard", 0.5, 0.5 * _duration, _pos, _targetPos, 13, 1.3, 1, 0.1, [1, 10, 15], [[1, 1, 1, 0], [1, 1, 1, 0.1], [1, 1, 1, 0]], [1], 1, 0, _onWispDrop, _onWispBeforeDestroy, _wisp, 0, true, 0.1];

Drop has a life time, correct? What happens to _wisp at the end of that life time?

winter rose
#

nothing at all? it is the particle's lifetime, not the emitter's lifetime

#

you can drop every second a soap bubble that each will live for 5 seconds, but the emitter will not get deleted

#

also, that is not how you use particleSource πŸ€”

dreamy kestrel
#

can you be more specific?

winter rose
#

you are apparently creating a particleSource, but then are using the drop command

hollow thistle
#

@ebon ridge with steam guard disabled you can't make newly uploaded items PUBLIC

#

only friends and private

#

items already set to PUBLIC can be updated.

ebon ridge
#

awesome thanks

hollow thistle
#

I might have found a way to quite easily extract the steam guard secret, I'll try to find the time and update my GitHub Action with support for steam guard secret during the weekend.

#

no promises tho.

#

soonℒ️

ebon ridge
#

hmm not sure what you mean

#

secret is the phone code part?

queen cargo
#

Tbh
Should be the same method as with all 2FA
With the problem being that steam is not providing a way to use other Apps sadly..

ebon ridge
#

however won't github action run on various machines, so steam guard code would be required often/always?

hollow thistle
#

secret is the thing that allows you to generate the codes.

ebon ridge
#

i don't know how 2FA works, but isn't that hidden on a valve server somewhere? we can only see the validation code (public key?) part right?

hollow thistle
#

no

#

it's a TOTP challenge

dreamy kestrel
#

@winter rose I'm not aiming to create multiple wisps, just drop the one.

hollow thistle
#

current time + secret on your device = code
they have other part of the secret on their servers so they can validate the code

#

It's similiar to Public / Private key scenario

winter rose
#

@dreamy kestrel if you just want to drop one particle, just use drop indeed
if you plan to drop many, use setParticle* commands

still forum
#

he wants to know if drop will delete the vehicle

#

which doesn't make any sense

#

no it won't.

#

An object doesn't automatically get deleted when you shoot at it and it drops hit effect particles

winter rose
#

we covered that πŸ˜‰

dreamy kestrel
#

apparently playSound3D does not work with .ogg files? which is kinda funny because I think say3D does work with .ogg files...

winter rose
#

it should, no? what does the wiki say

brave jungle
#

have a problem with select. sqf _sidesstr = ["WEST", "EAST", "INDEPENDENT", "CIVILIAN"]; _curselected = lbText [2100, lbCurSel 2100]; systemChat str _curselected; _selectindex = _sidesstr find _curselected; systemChat str _selectindex; systemChat str _sides select _selectindex; but my final line, _sides select _selectindex; is the entire _sidesstr any ideas?

#

oh worth mentioning all of the params are passed and are correct, be it "WEST" and 0

finite dirge
#

What is _sides?

brave jungle
#

the array of sides that are not str format

#

_sides = [West, East, Independent, Civilian];

#

a bad method I know

#

but

#

can work on that later

restive leaf
#

It should play @winter rose

brave jungle
#

I dont get why it's the entire array though

#

because it'll give you 0 if you select west

restive leaf
#

Works for me in Eden Lou... so?

dreamy kestrel
#

I double check my paths, and the path is true, file exists. logs complain that "file not found".

brave jungle
#

send ur cfg

#

not all of it

#

just one entry

restive leaf
#

See jacmac's comment on the biki page michaelwpide