#arma3_scripting

1 messages Β· Page 573 of 1

winter rose
#

there is the needReload one iirc

#

@austere hawk

coral owl
#

How can I filter the quotes out of a string? Quotes ---> "

#

I thought BIS_fnc_filterString could work for it but.. I am not sure how to escape the quote symbol ;)
"

still forum
#

quote symbol: '"'

coral owl
#
_messageDOWN = [_messageDOWN,'"'] call BIS_fnc_filterString;
``` returns an error...
#

maybe I can't use the same var..

still forum
#

"an error" ah. Very useful information.

#

why do you want to filter quotes out?

coral owl
#

I even made a worse mistake: this function filters things based on what you want to keep, not remove.. so it's not right for me

#

I use str(something) to make variables become text, but they also include "THE TEXT THAT HAS BECOME STRING" and I don't want the opening and closing quotes

still forum
#

I have a way to filter out chars

#

why don't you.. only turn non-text variables into text?

#

if you str a string, you add another pair of quotes, and also double quote all inner quotes

coral owl
#

if I do str(name _unit) I do get quotes..

still forum
#

yes

coral owl
#

I'd like it without quotes

still forum
#

as I said, don't double quote things, so you won't have that issue

coral owl
#

aah

still forum
#

If you don't want quotes, why do you call str to put quotes around the string then :U

coral owl
#

I hear the angels!

#

right you are

still forum
#

Knew right of the start that your problem is probably elsewhere and you are trying to use a VERY overcomplicated workaround for your very simple problem

coral owl
#

That's me! Nice to meet you! 🀝

#

Excited to try this out and report back..

#

it werkz!

#

Thanks @still forum so happy to have solved this!

snow cipher
#

what?

tough abyss
#

Hey guys, so I'm currently using this addAction to add a sound to objects. It worked great until I did some more testing on my dedi and found out the sound was only played localy (guess I didn't read the wiki enough lol) I'm trying to get the say3d action to go on every player in a loop using the forEach player but I'm getting syntax errors. could anyone help me out? Thanks in advance

this addAction [ "QRF Alarm" , {PYTH_alarmPosts = nearestObjects [[11498.6,17725,5.73599], ["jenk_cobra_siren_object"], 2000, false]; 
    {_x say3D ["QRF", 1000, 1, true]} forEach PYTH_alarmPosts
} ];```
winter rose
#

@tough abyss see remoteExec

tough abyss
#

ahem...

this addAction [ "QRF Alarm" , {PYTH_alarmPosts = nearestObjects [[11498.6,17725,5.73599], ["jenk_cobra_siren_object"], 2000, false]; 
    remoteExec [{_x say3D ["QRF", 1000, 1, true]} forEach PYTH_alarmPosts]
} ];
```??? πŸ˜•
winter rose
#

@tough abyss you didn't read the remoteExec wiki page, did you πŸ˜„

tough abyss
#

I did. The question you should have asked is 'you didn't udnerstand the wiki page did you?'. To which I would gladly answer yes

#

I understand it's to execute a said command on clients instead of server? I didn't understand how to apply the usage to my command tough

winter rose
#

I believe the following should work:

{ [_x, ["QRF", 1000, 1, true]] remoteExec ["say3D"] } forEach PYTH_alarmPosts
#

@tough abyss the first right-hand remoteExec parameter is "functionName", which is a String

tough abyss
#

I think I understand? Kinda

#

Thanks tough πŸ˜…

ionic anchor
#

Im trying to set a custom rvmat to an SUV in game (altis life) but it just doesnt show, even if i try arma 3 default rvmats, any help would be great

private _className = typeOf _vehicle;

// -- SUV 
if (_vehicle isEqualto "C_SUV_01_F") then {_vehicle setObjectMaterialGlobal [0, "rvmats\vehicles\suv.rvmat"];};

still forum
#

vehicle is never EqualTo a string

#

a vehicle is a object, a object is never a string

ionic anchor
#

would i use _vehicle isKindOf ?

winter rose
#

yes, or typeOf

ionic anchor
#

cheers

winter rose
#

@ionic anchor you already have the ```sqf
if (_classname == "C_SUV_01_F")

ionic anchor
#

ill give that a try as well, cheers dude

ebon ridge
#

Under what circumstances with a vehicle not be effected by gravity? We use setPosWorld in our unflip script placing the vehicle 2m above the ground, but for some reason it doesn't fall?!
https://www.youtube.com/watch?v=-0BWEXYi5a4

#
_hO setVectorUp [0, 0, 1];
_hO setPosWorld ((getPosWorld _hO) vectorAdd [0, 0, 2]);
hollow thistle
#

Might be caused because it's empty. Add minimal downward velocity and it should fix that.

ebon ridge
#

oh interesting thanks

#

Perhaps related, is there any trick known to kick vehicle AI into immediately following their assigned waypoint? We have a system that will spawn vehicles onto a road in convoy formation, then give lead vehicle order, but we find the time it takes for the vehicles to respond can be anywhere for a few seconds, to literal minutes

#

We need a way to tell server to prioritize starting them immediately

alpine ledge
#

is there a way to disable the thing where objects / vehicles are not rendered when the game thinks the player shouldn't be able to see them? trying to make a cutscene and because of the animations, some characters flicker in and out of existence

austere sentinel
#

Are you asking to keep them rendered, or to remove things that "shouldn't" be visible?

alpine ledge
#

keep them rendered

#

setFeatureType didn't seem to do the job

austere sentinel
cosmic lichen
#

maybe?

alpine ledge
#

i don't think that would be the case; the character's in question are stood right next to me

#

well, stood next to me in terms of the animation anyway

cosmic lichen
#

If that's the case there's not much you can do I think.

austere sentinel
#

^
Rendering is right on the edge of what SQF can do iirc

alpine ledge
#

mmm, preloadObject didn't work either - bugger GWvertiPeepoSadMan

cosmic lichen
#

Might help if you post a short video

dim terrace
#

I think animations could have to small bounding box

#

you could try attaching character to something big and invisible

alpine ledge
#

wouldn't that mean the player then can't turn their head?

#

can't seem to get recording software to detect arma 3 now either eyeclawpepe

young current
#

how large area are you moving in?

#

or how far are the other characters moving from their point of origin

#

is this made with custom RTM or with vanilla moves?

alpine ledge
#

custom RTM, vanilla map, entities themselves are all pretty much ontop of each

young current
#

is there lot of other objects in the scene that could block the visiblity?

#

are the characters close to each other when the animations start?

#

in world space

alpine ledge
#

few objects, but none that block LOS, in world space characters are pretty close together

young current
#

what is pretty close?

#

also whats the initial orientation

alpine ledge
#

like a few feet away from each other

young current
#

is the player facing the other character?

alpine ledge
#

right now i'm just running around the cutscene as a civ to test, and it's only 1 character that pops in and out depending on where i stand

young current
#

ok so its something you play on 2 other characters

alpine ledge
#

he dissapears both when i'm viewing from the civs pov and from the intended player pov

young current
#

so what kind of angles does the this popping happen

dim terrace
#

if its custom RTM then I'm 100% sure its bounding box issue

alpine ledge
#

seems to be when i'm directly infront of him

young current
#

mark the original location of it and see if that stays in the view

dim terrace
#

boundingSphere = 30; try adding it to your animation config

alpine ledge
#

peepoCheer success!

#

moved his origin around a bit and now he stays rendered all the time

#

must've just placed him in a weird spot PeepoShrug

#

thanks all, probably would've taken me hours to figure that out iLOVEyou

young current
#

🀞 it wasnt something lewd

#

πŸ˜›

alpine ledge
tough abyss
#

I'm new to arma 3 Zeus and scripting, how do I put an image into a billboard whether it's static or a showcase of images, cheers

winter rose
#

hi new to arma 3 Zeus and scripting, I'm dad!

still forum
#

So you are talking about zeus? not Eden?
You'd need a module or some other way to execute a script

winter rose
#

@tough abyss ^

young current
#

does anyone happen to know if there is a range limit on doTarget command?

exotic flax
#

I'm not sure, but it could be limited to view distance (like a lot of stuff in Arma)

young current
#

player view distance?

#

interesting idea, I'll try that out

ebon ridge
#

Nobody got any idea about this then?

Is there any trick known to kick vehicle AI into immediately following their assigned waypoint? We have a system that will spawn vehicles onto a road in convoy formation, then give lead vehicle order, but we find the time it takes for the vehicles to respond can be anywhere for a few seconds, to literal minutes

winter rose
#

you can delete the waypoint?

ebon ridge
#

sorry are you saying deleting a waypoint is a way to force AI to immediately follow their next waypoint?

#

not sure what you mean

winter rose
#

oh, you mean the initial timer
that's AI calculating the path, don't put the waypoint too far

ebon ridge
#

ah okay, we generate a full set of waypoints immediately for the entire route

winter rose
#

if the first WP is far the AI will take some time before having the good path - but will proceed as soon as the calculation is done

ebon ridge
#

kk thanks, i was hoping for some kind of trick that would force immediate pathing evaluation

#

but we can probably do something with waypoint hacking πŸ˜„

winter rose
#

the pathfinding is immediate
the further the distance, the longer the calculation though

ebon ridge
#

Sure, but i guess its sharing CPU time with all other stuff that keeps running at the same time, meaning the time it takes depends on server load. I want to stop other non essential stuff happening and give all resources to pathing (or at least I want to try it and see what the implications are). An example of what I am looking for would be a function you can call on a unit that requires the evaluated path, which I could then call atomically to block everything until path is evaluated.

#

However I have seen problems that seems like they shouldn't be related to path finding, where it isn't the lead vehicle that takes ages to move its one of the following ones. i.e. Standard convoy setup, lead vehicle will start off, but trailing ones (usually it happens to armor) will take a long time to move.

winter rose
#

convoy and AI don't go well together anyway.

ebon ridge
#

I mean is there a non AI convoy option? We virtualized our convoys to avoid the problems, but at some point we have to actually spawn in vehicles when the player is near.

winter rose
#

I mean is there a non AI convoy option?
players driving?

ebon ridge
#

and immediately the problems start

#

oh okay that isn't an option here

#

its coop vs AI

worn forge
#

Arma's driving AI is horrible. That's what Lou is getting at. The only advice I can give is use LIMITED as the waypointSpeed. They'll go slow, but they'll have half a chance of making the corners.

ebon ridge
#

lol yeah im definitely aware the driving AI sucks, we wrote a fairly involved system just to avoid it πŸ˜„

#

and yeah they do seem to do a lot better at slow speeds.

#

I think they made a mistake of using PID controller for the driving, its quality is highly dependent on the ds/dt

fleet bear
#

Hello! Need to set a variable for a placed mine. But it appears to be a part of CfgAmmo, so setVariable command doesn't work. Is there any way to overcome this?

worn forge
#

He4to, what are you trying to accomplish?

fleet bear
#

working with OCAP replays. Want to make markers for placed mines

worn forge
#

single player or multiplayer (I have some code for that)

fleet bear
#

multiplayer, though the script runs on dedicated only

#

i tried to create a Location on the mine, and setVar to it, but it seems to work not as intended

worn forge
#
tieMarkerToMine = {
    // run on server
    params ["_mine"];
    if ( isNil "_mine" ) exitWith {};
    _markerName = format ["mine_marker_%1", round time];
    createMarker [_markerName, getPos _mine];
    _markerName setMarkerShape "ICON";
    _markerName setMarkerType "MinefieldAP";
    _markerName setMarkerColor "ColorBLUFOR";
    [_mine, _markerName] spawn {
        params ["_mine", "_markerName"];
        //systemChat format ['%1 %2', _mine, typeOf _mine];
        if ( typeOf _mine in ["SatchelCharge_Remote_Ammo", "DemoCharge_Remote_Ammo", "DemoCharge_Remote_Ammo_Scripted"] ) then
        {    sleep 2;
            waitUntil {sleep 1; playSound3D ["A3\Sounds_F\weapons\Mines\electron_trigger_1.wss", _mine, false, getPosASL _mine, 0.2]; !alive _mine};
        }
        else
        {    _markerName setMarkerDir (getDir _mine);
            waitUntil {sleep 1; !alive _mine}; };
        deleteMarker _markerName;
    };
};```
this function on server, will be called by player with...
#
player addEventHandler ['AnimDone', {
    params ["_unit", "_anim"];
    if ( _anim == "amovpercmstpsraswrfldnon_ainvpercmstpsraswrfldnon_putdown" ) then
    {    [_unit] spawn {
            params ["_unit"];
            sleep 1;
            _minePlaced = (allMines select {_x distance _unit < 2}) select 0;
            if !( isNil "_minePlaced" ) then
            {    _minePlaced remoteExecCall ["tieMarkerToMine", 2]; };
        };
    };
}];```
#

In my tieMarkerToMine function, I also have it spawn a beeping noise that you may not wish to have

fleet bear
#

oh) thought about that, EH on player) thx, will try on the server

worn forge
#

This is because on our pub server players are clueless to placed charges

wispy cave
#

(not all players)

young current
#

We do not condone cheating here.

dusk sage
#

+rep einstein's reincarnation

wispy cave
#

A hit eventhandler that checks which parts have been damaged and disallows damage to the tailrotor?

winter rose
#

hello there, I have a question about simple objects:
Q: I created a magazine as simple object through its "modelSpecial" P3D, but it is not of the proper colour (sand/black/lush/etc)
it seems I cannot texture it through setObjectTexture/setObjectMaterial, any way to texture it? it has a hiddenSelection

#

A: it seems I got my answer: (super) simple p3d created objects cannot be textured, and classname simple objects can only be from CfgVehicles. It seems I am screwed on this one

cunning crown
#

Can't you use p3d path to create simple objets?

winter rose
#

@cunning crown that's what I do, but (super) simple objects (created from p3d) can't be retextured

#

and "standard" simple objects (created from classname) can only be created from CfgVehicles, not CfgMagazines

cunning crown
#

Ohhh... well you could create multiple model for each textures you want πŸ˜„

winter rose
#

nope 😦

#

it's the same 3D model, and the game says "use this texture"
and I can't replicate this behaviour

ebon ridge
#

vehicles seem to always stop when they get to a waypoint, any way to get them to roll through them?

// Add waypoints starting from closest one
for "_i" from _closestPosIndex to ((count _wpPositions) - 1) do {
    pr _x = _wpPositions#_i;
    pr _wp = _hG addWaypoint [POS_TO_ATL(_x), 0];
    _wp setWaypointType "MOVE";
    _wp setWaypointFormation "COLUMN";
    _wp setWaypointBehaviour "SAFE";
    _wp setWaypointCombatMode "GREEN";
    _wp setWaypointCompletionRadius 100;
    _waypoints pushBack _wp;
};
worn forge
#

Your waypoint completion radius is quite high, they might be stopping early. Also if you set their behaviour to careless that makes them much more easy drivers

fading sandal
#

@ebon ridge convoy's are easy make sure all the vehicles in the convoy are grouped in the line formation and ai is on safe and they will follow the road fine

dark ocean
#

how to stop playaction

copper raven
#

switchMove probably

dark ocean
#

dont fount

#

found

copper raven
#

?

winter rose
#

@dark ocean use ```sqf
theUnit switchMove "";

#

or less "strict",```sqf
theUnit switchMove animationState theUnit;

quasi rover
#
if (cond_A) then { "password" serverCommand "#restart";};
call bns_fnc_aaa;
call bns_fnc_bbb;

if cond_A is true, then bnc_fnc_aaa and/or bnc_fnc_bbb is called or not?

winter rose
#

Called yes

#

If you wanted them to not happen, place them in an else block @quasi rover

quasi rover
#

thx, I just thought the call-stats are not called, because Sever goes to restart process.

winter rose
#

I believe that the server would take some time to restart
you could use an exitWith though

quasi rover
#

good idea. thx again.

thick merlin
#

Hey guys, Iam messing with a scripted waypoint with a script.I was using a game logic at the waypoints desired position but would like to use the position .

#

Iam using this code i sourced from the A3 land waypoint -

#

'private ["_pos"];
_pos = _this param [1,[],[[]],3];

winter rose
#

yes…?

thick merlin
#

soz bud.iam tryn to remember how to add the code in its own box.

#

Anyway..:)

#

when i run this code the scripts works correct but i'am concerned about this code -

#

_this param [1,[],[[]],3];

#

iam not sure what to do with all that code and if its okay to leave it all in there?

#

the script needs that line but just unsure if all of it was okay

worn forge
#

If it's vanilla code and it works, don't mess with it πŸ˜›

#

Say, does anyone know if it's possible to add diary entries to the existing Briefing sections of the diary? I imagine one would just need to know the engine subject names.

thick merlin
#

Ryko,Thanks bud.πŸ‘

#

Yes it is possible.Theres a few tutorials on youtube covering tasks.I think thats what your after

winter rose
worn forge
#

Thanks Lou, I've been all over those. The whole point is I don't know the name of the "Briefing" subject, though I'm tempted to just throw darts at the name "briefing"

velvet merlin
#

is there a way via SQF to force AI in player lead group standing when the player commanded them "prone"?

#

disableAI "move", setUnitPos, setUnitPosWeak all dont help

winter rose
#

from Tank Destroyers Showcase:
(Diary)

localize "STR_A3_Diary_Signal_title"
localize "STR_A3_Diary_Execution_title"
localize "STR_A3_Diary_Mission_title"
localize "STR_A3_diary_situation_title"

(Showcase)

localize "STR_A3_diary_showcase_title"
localize "STR_A3_diary_summary_title"

if for the briefing-briefing, I believe it's tasks you have to work with @worn forge

worn forge
#

So "Briefing" is just a blank? When a task is created it automatically populates a "Tasks" entry underneath "Briefing"

winter rose
#

@velvet merlin what about a looping setUnitPos?

#

@worn forge I will have to check once home

worn forge
#

πŸ‘

velvet merlin
#

setUnitPos is lower prio that player GL stance command - aka ignored

#

you can force via _x playAction "PlayerStand"; in a loop, but its limited use

winter rose
#

ok, I thought it was same level.
but I also don't get the use case of setUnitPosWeak so there is that πŸ˜…

velvet merlin
#

setUnitPosWeak is FSM level

#

danger.fsm/danger cause reaction

gray hemlock
#

Is it possible to edit vehicle parameters such as enginePower at runtime with sqf?

young current
#

no

gray hemlock
#

Bummer

young current
#

you can fiddle with speed limit stuff

#

with script commands

gray hemlock
#

Gonna end up being a bit of a mess I think. Working on vehicle upgrades for the engine.

young current
#

Arma is not quite meant for such

#

you could always make different vehicle classes with different parameters

gray hemlock
#

That's what I was thinking, but then limiting the upgrades to vehicles that have a seperate config. Like I said, got options, but the easy one isnt possible.

fleet hazel
#

Guys. What is a team for finishMissionInit?

winter rose
#

sorry, what?

fleet hazel
#

When loading the server Exile runs the file in which the command finishMissionInit. What is this command for?

winter rose
dawn hull
#

Hello im trying to recode a sqf file to C i could use some help its been a wile since i programmed a long time heres what im trying to do


class MainClass
{
    private static void {
var this select 0 animate["gear_nose_1", 0];
var this select 0 animate["gear_nose_2", 0];
var this select 0 animate["gear_nose_3", 0];
var this select 0 animate["gear_nose_3_1", 0];
var this select 0 animate["Gear_Nose_d_1", 0];

var this select 0 animate["Gear_Nose_d_2", 0];
var this select 0 animate["Gear_Left_1", 0];
var this select 0 animate["Gear_right_1", 0];
var this select 0 animate["Gear_Left_2", 0];
var this select 0 animate["Gear_right_2", 0];
    };
};```
still forum
#

sqf file to C? what? why?

#

also thats not C, that's somewhat C#

dawn hull
#

dz standalone usse C for scripts im building a addon

still forum
#

no it doesn't

dawn hull
#

hmm

still forum
#

it uses Enscript

#

and you can't just convert a SQF script, the API is completely different

dawn hull
#

i see

#

so where should i start ?

still forum
#

Well for one, if you want to do DayZ stuff then go to DayZ modders discord, the people there actually know that stuff

dawn hull
#

here

winter rose
dawn hull
#

it says scripts are in C

still forum
#

they aren't

dawn hull
still forum
#

they have the .c file extension

dawn hull
#

oh

still forum
#

file extensions say NOTHING about what's actually inside

dawn hull
#

im so confused

still forum
#

you can have sqf scripts named file.c
or textures named texture.sqf

restive leaf
#

DayZ Modders discord would be more help @winter rose

winter rose
#

ah, I don't know this one

dawn hull
#

ok ty guys

still forum
#

they should change the file extension to ens :U

#

But noone gonna listen to meh

restive leaf
#

How very DOS of you

#

Do you still use 8 character file names too (without the extension)? 😜

winter rose
#

whatthe.f~1

restive leaf
#

Jeez... I remember when System V expanded from the 8.3 format

acoustic abyss
#

Hey everyone. I am curious about something.

I'd like to give the impression that a vehicle has been driving through some woods. Is there some way I could simulate/spawn knocked over trees at the start of a mission?

violet gull
#
private _trees=nearestTerrainObjects[_myCarPos,["TREE"],50];  //Gathers all trees within 50m of _myCarPos
{_x setDamage 1}forEach _tree;

Place car in the woods and you'll get the idea. You can also place narrow triggers to gather trees within it to sorta simulate it demolished trees in its "path" also. Maybe something sorta like this:

private _trees=nearestTerrainObjects[_myCarPos,["TREE"],200];  //Gathers all trees within 200m of _myCarPos
{
if(_x inArea myLittleTrigger1 || _x inArea myLittleTrigger2)then{_x setDamage 1};//Deletes trees inside of myLittleTrigger1 or myLittleTrigger2, if also within 200m of _myCarPos
}forEach _tree;
#

@acoustic abyss

#

Something like that maybe

acoustic abyss
#

Ah! Setdamage on Trees? I had no idea. Thank you.

violet gull
#

Keep in mind that killing tons of trees, especially on maps like Livonia, will destory FPS initially because it plays a tree falling sound for each tree lol

acoustic abyss
#

Well, now I get to a related issue: this is for a later part of a mission, when the (coop) players are supposed to track down an NPC. How long/far do these damaged trees persist? I could execute the triggers 100 meters away, but that might make an odd sound...

#

By the way, I am loving your animated profile photo. 'Tis the awkward that just keeps on giving.

winter rose
#

@acoustic abyss trees remain dead πŸ˜‰

violet gull
#

❀️

restive leaf
#

That is a major feature of RV engine it seems @winter rose Many other engines either have trouble or just don't handle peristant destructibility

alpine ledge
#

i guess that answers the age old question about trees making sounds when they fall with noone around to hear FeelsFunnyMan

restive leaf
#

We shall see what ARMA 4 will give us though given that part of Bohemia does not think destructibility should be a thing it seems πŸ™ƒ

cosmic lichen
#

Is there a way to get access to the complete stringtable file when it was loaded by arma?

queen cargo
#

Think you Lack a comma

cosmic lichen
#

Definitely, had to read it twice πŸ˜„

misty bramble
#

Is there an event that I can subscribe to that is called when a car engine is started?

#

or when gas is pressed

verbal saddle
misty bramble
#

Thanks man I really appreciate it

misty bramble
#

Are single line comments in sqf // ?

exotic flax
#

yup, and multiline /**/

misty bramble
#

Got it, thanks

misty bramble
#

Does anyone know how to grab the object that uses an addAction?

#

Like, if when an object runs an action, the action script being able to get info about the person using it

young current
#

such has to be included in the action

#

if you explain more what you are trying to do, then perhaps someone can answer you how it might be possible

#

@misty bramble

misty bramble
#

So, I have an script that I attached to a car with addAction. Is there a variable that I can use in the script that is a reference to any player trying to use the action?

#

err lemme try a bit better

#

I have a script called script.sqf, and the code inside that script is intended to be added to a car with addAction. Is there a way to access the object that executes the action through script.sqf

#

like just have any property like _objectThatCalledThisActionInGame

young current
#

is it only for player?

misty bramble
#

yeah

young current
#

then player

#

player is always local

misty bramble
#

so, it will work even if there are more people on a server?

young current
#

yes

misty bramble
#

thank you!

tender fossil
#

What could be the reason that my iniDB (the original version) database is not initializing on my Windows Server 2019 server?

#

It works fine on my friend's PC (Windows 10)

#

The read and write permissions should be fine (execution too)

tender fossil
#

Argh, Arma 2 is driving me nuts

#

Now it doesn't play the custom sounds I've added to the mission

still forum
#

Is there a way to get access to the complete stringtable file when it was loaded by arma?
@cosmic lichen no, not for you. I can get it for you if you need

cosmic lichen
#

@still forum I'd much appreciate that if you could do that ❀️

still forum
#

what ones do you need? vanilla only?

#

are you aware of synixe's stringtable browser?

cosmic lichen
#

Would be nice to have all of them if possible and no, I am not aware of that browser

still forum
#

maybe that already does what you need

#

There's a json file in the github that has all of them (except ebo I assume)

cosmic lichen
#

That is indeed what I was looking for. Thanks a lot!

wooden heart
#

Hey guys, I'm having an issue that is causing a server crash with Fault address: D928A839 00:D928A839 Unknown module.

I'm making a server mod that calls an extension and the server crashes whenever the extension is called like so from within an event handler:
_whitelist = "TaskForceRaider" callExtension str(_pl_uuid);

any ideas for where I should start with this since I'm scratching my head a little...

still forum
#

I'd say your extension is broken.

#

build the extension with debug symbols. then look at the mdmp the server creates on crash (assuming windows)

wooden heart
#

Yep its windows. I have a feeling it's because its trying to return a bool (also written in C#/.net)

still forum
wooden heart
#

Yeah that is the wiki article I followed. I'll try build the dll with debug symbols and take a closer look, cheers πŸ˜„

ebon ridge
#

You should be able to run the arma server through VS so it will attach and you can debug your crash with full info (if its C# make sure to use mixed mode debugging). I do this with arma + ADE anyway.

queen cargo
#

sqf-vm can also be used for more info 🀫

ebon ridge
#

can it load extensions?

queen cargo
#

yup

#

"full" support

#

with the only downside being that as of now, there is no way to use the callback mechanic

woeful sundial
#

_wPos = screenToWorld [0.5,0.5];
hi with this i'm getting the exac position that i'm pointing at but the Z coordinate is always 0 and i want to get also the height of my cursor. is there a way to do this?

young current
#

The command returns the terrain position. You are looking at.

#

@woeful sundial

woeful sundial
#

i know but if i want the height of my cursor relative to the pointed object?

still forum
#

what cursor?

#

Do you mean you want stuff like buildings and objects to be hit, instead of the terrain behind them?

woeful sundial
#

yep

Do you mean you want stuff like buildings and objects to be hit, instead of the terrain behind them?
@still forum

still forum
woeful sundial
#

i found this lineIntersectsSurfaces

#

let me try i have an idea

#

oh the second example is top thx πŸ™‚

austere sentinel
#

Is there a non-local version of isDamageAllowed?
As I understand it, it will only return false if called on a player's unit or manned vehicle, regardless of whether they're invulnerable or not

winter rose
#

no, because allowDamage is local

#

you can for example track it via setVariable @austere sentinel

austere sentinel
#

You'd think a damage prevention command would be a server-only thing πŸ˜†

Using setVariable is a good tip, that should keep me from having to set up CfgRemoteExec at least

still forum
#

You'd think a damage prevention command would be a server-only thing
You'd think doing damage would be a server-only thing πŸ˜„

jovial citrus
#

I have some problems with setPos not synchronizing in MP for all clients. Does anyone know a workaround/fix for this?

#

it takes a long time to synchronize*

winter rose
#

have either a better network, or reduce the server's load
there is no "hack/settings" for that, besides #server_admins server settings @jovial citrus

jovial citrus
#

I see, I suppose it is the server load then

#

Thanks

young current
#

How is the setpos run in this case?

#

@jovial citrus

jovial citrus
#

locally, and in another situation on the server. Not using remoteExec in either case. Problems are more with the local command though (i.e. for the person who's machine it's called on).
Is that what you meant?

#

Could it depend on where the object was created? I know it is for setVectorDir etc, but not seeing any warning for setPos about it :/

young current
#

Is it used a lot? Like each frame kind of situation? Are there local created vehicles involved?

jovial citrus
#

No not done on each frame, although the mission has a lot of stuff going on. All the objects in question are created on the server

tender fossil
#

Does anyone know what could cause an iniDB database to fail on Windows Server 2019 while it works fine on home PC (Windows 10)?

#

I've tried almost everything, including turning UAC off for a moment with no results

winter rose
#

I am convinced I am not teaching you anything new
about issues/differences between Home/Server usually being permissions, running services or OS specifics - though, it would be more #server_admins

tender fossil
winter rose
#

I'm not dead yet!!1!

tough abyss
#

Anybody here willing to lend me a hand converting this script into a function?

#

Would appreciate it tons!

winter rose
#

depends on the script/function, as always

tough abyss
#

I’ll shoot you a private message!

rustic plover
young current
#

where do you see those?

rustic plover
#

I think that suffix data for big files (models, sounds, images)

young current
#

_F is to differentiate files from Arma or Arma2 files. It refers to futura

#

but also those naming rules apply only on textures

#

no other file have any rule

#

well config.cpp and model.cfg needs to same

rustic plover
#

Futura means vehicles, equipment which now not exist else?

winter rose
#

Futura was codename for arma3

young current
#

the texture naming rules are for the part when the source file is converted to .paa file

#

the conversion methods depend on the suffix

winter rose
#

also, talk* page in Czech

young current
#

@rustic plover is there a particular reason you are wondering this?

rustic plover
#

@young current yes, I just want to standardize my mod making process

young current
#

modTagPrefix_filename.correctExtension

#

and textures need the suffix.

#

other than that, there are no requirements

#

but using logic with naming is useful

worn forge
#

Looking for a little ACE assistance. I'd like to remove the join group option from AI units, but keep it for players. I'm trying this;

{    [_x,0,["ACE_MainActions","ACE_JoinGroup"]] call ace_interact_menu_fnc_removeActionFromObject; } forEach (allUnits select {!(isPlayer _x)})```
... but it's not working. Halp?
austere sentinel
#

@rustic plover Other than the CO/CA etc suffixes there is none. Just like coding styles, pick your method and keep it consistent.

#

@worn forge Try getting rid of the select and just use an if (!(isPlayer _x))

worn forge
#

Well if I just put my cursor on an AI and run

[cursorObject,0,["ACE_MainActions","ACE_JoinGroup"]] call ace_interact_menu_fnc_removeActionFromObject;```
it also doesn't work, so I don't think selection is the problem
tough abyss
#

@young current mind opening ur DMs? Small project for $$ if you’re willing to help

winter rose
#

@worn forge

Say, does anyone know if it's possible to add diary entries to the existing Briefing sections of the diary? I imagine one would just need to know the engine subject names.

I didn't forget you πŸ˜‰
I tried ```sqf
player createDiaryRecord ["Diary", ["Subject", "Text"]];

worn forge
#

Hey! Cool! Thanks Lou.

#

Now who's gonna fix my ACE problem? πŸ˜›

winter rose
#

don't look at me πŸ‘€ πŸ˜„

young current
#

@tough abyss no.

#

sounds sketchy

tough abyss
#

Nope, not sketchy. Just need help converting a script into a function

#

Thanks anyways

austere sentinel
#

A script is pretty much already a function. Usually just adding params ["_arg1","_arg2", ...]; to the top does it in most cases
& compiling obv

young current
#

@tough abyss you could just put it into pastebin.com, link it here and see if anyone can point you to right direction with it.

tough abyss
#

Will do, thanks bud!

#

Anybody able to point me in the right direction to get this working?

surreal peak
#

@tough abyss what part is wrong?

tough abyss
#

Not entirely sure.. I’m attempting to isolate the notification system from this car radio script, and turn it into a function that server admins can use to broadcast msgs. I haven’t been able to get it working yet

#

See the little pop up that is shown when the song is switched

#

I’m trying to isolate the system from this script

#

@surreal peak

surreal peak
#

I assume u didnt make thje original scriuot then>?

tough abyss
#

No but the first person I contacted was the script author and he said that he doesn’t make ARMA scripts anymore but he gave me permission to take over the script

#

I have a screenshot as proof but I can’t send images in this channel

surreal peak
#
/* 
    ჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻
    ჻჻  
    ჻჻  Joe Willis - Anzus
    ჻჻
    ჻჻  Description : AutoRadio HUD Control File
    ჻჻
    ჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻჻ 
*/
#

u want this?

tough abyss
#

Yea I’m trying to convert that into a function and add a text variable and remove the music stuff so I can have a stand-alone notification system

young current
#

oof. Anzus.. It is sketchy after all.

austere granite
#

Sick privates

#

Sick #define CTRL(var1) ((uiNamespace getVariable "AutoRadioMenu") displayCtrl var1)

lunar plume
#

I'm trying to configure ace in a mission but in a script but I can't do it because I don't understand everything I'm also trying to pass the mission in hard first person mandatory start plane helicopter longer etc is what you could help me

worn forge
#

Garrick you're going to have to be a bit more specific about what you need help on, and perhaps use some punctuation... I found your sentence very hard to understand

lunar plume
#

yes ok

#

I want to configure ACE for a mission in script form but I can't do it

worn forge
#

you mean use ace as a series of scripts rather than as a mod?

lunar plume
#

yes exactly

#

secondly I want to get past the difficulty of the veteran's mission

worn forge
#

Um good luck

lunar plume
#

its not possible ?

worn forge
#

I'm sure it's possible, but it would require a pretty in-depth understanding of how ACE is put together, there is an underlying system and all the different sub systems hook into that. You are far better off just integrating the ACE mod into your server

lunar plume
#

yes but I do how to configure it on the mission as the modules have been removed.

worn forge
#

ESC -> Configure -> Addon Options

#

It's all run through CBA, you can even export your options and then make it mission-based rather than server-based

lunar plume
#

so if I set / adjust addon / mission this changes the ace configuration for all players?

worn forge
#

In particular 3.1 for your needs I think

lunar plume
#

so this is the script configuration

#

thk

lunar plume
#

Great, I passed. Thank you very much @worn forge , but now I'm coming to my second question.

#

I'd like to go through the mission in veteran mode because of the difficulty of driving and the first-person obligation.

viral basin
#

Is there a way to get the player out of the unconscious state after using

player setUnconscious true;

scriptwise?

surreal peak
#

player setUnconscious false; ?

viral basin
#

πŸ˜‚ i already did that. doesn't work. i should mention that i don't meant the state value but the animation. the player is still lying on the floor and doesn't get up.

lunar plume
#

Did you look in the eden multiplayer settings? @viral basin

viral basin
#

oh you mean the revive options? do they have to be turned on?

lunar plume
#

yes or you can use the .ext description to set up the revival system as you wish

viral basin
#

but i can use it with **true ** and **false **on NPCs without any problems. the npc is standing up normally but if i use it on my own player it only works if my player is a medic otherwise player setUnconscious false would just do nothing.

lunar plume
#

then I can't say, but I might have something that works.

winter rose
#

@viral basin it is buggy if the player has no primary weapon

viral basin
#

oh okay, there is no way around?

winter rose
#

you still could switchMove

viral basin
#

yeah i know, but this is not as smooth unfortunately :/

winter rose
#

maybe playMove then, but I can't assure it will work

#

any way, there is no "normal" way, you have to go around this bug one way or another. or stay stuck!

#

"unconsciousOutProne" seems to be the one @viral basin

#

and playMove works.

viral basin
#

yeah it did, thank you very much!

lunar plume
#

How can we hide the map position of players and AI with ACE?

worn forge
#

Look into blufor tracking settings

opal turret
#

Hello folks, bit of a deep one.

Currently working on a persistent campaign. The important stuff I want to keep such as randomly spawned compositions, player vehicles and markers are all getting saved as variables to the profileNamespace via manual save, after a side mission has been completed or, in the case of the compositions, after they've been created.

My question is: how do I run a script, like the composition creation for example, only once on the first session then skip it from then out and load from the profileNamespace every session after?

Would saving a global counter to the profileNamespace work? or would that get overidden during startup as well? or perhaps there's a way to remove the execVM line from the initServer.sqf?

Any help would be greatly appreciated.

sacred slate
#

can i some how do execvm ..\my\subdir, or at least full path?

young current
#

depends where you want to run the file

sacred slate
#

any place as root as possible

young current
#

if its in the mission folder then yes mission folder is considered the root

sacred slate
#

how is the syntax? ..\ didn't worked.

young current
#

yourfolder\another\yourfile.ext

sacred slate
#

ah so .. is yourfolder\

#

thx

young current
#

irl it would be missionfolder\yourfolder

#

yes

sacred slate
#

great

young current
#

or \ in the beginning

#

one or the other should work

opal turret
#

@sacred slate Example:

[] execVM "scripts\core\system\compile.sqf";

If the file is in the root mission folder it would look like:

[] execVM "compile.sqf";

sacred slate
#

thx

#

@opal turret is it possible to reach C:\Users\bla\Documents\Arma 3 - Other Profiles\bla\missions

young current
#

no

opal turret
#

πŸ‘†

sacred slate
#

will a steam validation or update clean out \scripts\core\system\

young current
#

from where?

#

user\missions folder?

sacred slate
#

from C:\Program Files (x86)\Steam\SteamApps\common\Arma 3\Missions

#

i thought this would be scripts\core\system\

young current
#

Yes but if you talk about steam accessing your files you don't talk in the games file structure

#

And no I don't think those would be affected

worn forge
#

@opal turret to your question on mission persistence. The way I have implemented it is in a number of saved arrays representing the progress in a typical capture-the-island mission. I haven't tried saving a massive array of objects and positions, but I imagine it's possible.

#

Removing the execVM line isn't possible, but you could build in an if... Then statement such that if the mission is starting in a persistent state, that command isn't run.

opal turret
#

That's along the lines of what I was thinking. I could load the nameSpace first then use an if then statement to find if there's already objects in an array to tell whether or not to run a script.

Cheers for the help.

young storm
#

hey does anyone know how to make ai disappear and reappear? I can do one or the other with triggers but not both..would be more immersive if I could reload em in

winter rose
#

@young storm hideObject?

young storm
#

@winter rose wont that just hide them asoon as i pass the trigger? They wont unhide after it?

#

I wanna be able to load an unload them at will you know?

winter rose
#

@young storm to unhide them, use the on deactivation field

#

I don't know how you want to trigger this?

austere sentinel
#

^
If you're looking to do a "if player is more than X meters away from the AI" you'll have to write a script (either in the AI's init field, or an actual script file if the AI is dynamically spawned).

winter rose
#

If it is performance related, there is the already not bad in-game dynamic simulation, too

austere sentinel
#

Is it possible (or sane) to have recursive calls in a script?
e.g. I have helo_init.sqf that is execVMing itself at one point in the script (inside basically a custom respawn with a Killed EH)

Side Note; It seems that having a base cleanup script completely ruins the editor respawn module πŸ˜†

winter rose
#

@austere sentinel not ideal, make it a function?

austere sentinel
#

It gets called in editor init fields. Where would I make it into a function that those would have access to it?

winter rose
#

CfgFunctions :)

austere sentinel
#

also in actual scripts in which the function thing isn't an issue

#

I hate that I expected that answer πŸ˜†

winter rose
#

or initServer. Sqf?

austere sentinel
#

initServer gets called after vehicle/unit init fields set in the editor

#

Although I guess I could just manually init in a forEach

#

I'll just do CfgFunctions. I've been avoiding it because I'm lazy, time to stop that 😁
Thanks lou!

#

Also was it the recursion that wasn't ideal, or execVM?

young storm
#

@winter rose ill give it a shot , i may pm you with another question if thats okay?

#

@austere sentinel im doing a zues op from the ground up but wanna reduce the zeusing im doing, so i dont think thats dynamically spawnin em?

#

Tryna tell a story from an anime inspired lol )

austere sentinel
#

dynamic meaning anything that isn't manually placed in eden editor

young storm
#

Ohh

#

Everything will be placed by me

#

Ill try that solution tomos lou mentioned

#

Oh and lou uhm as in trigger i just use the triggers..when a player enters the field thats connected to the modules, or if i dont understand sorry lol im a tad thick xD

#

@austere sentinel you good at scripting?

austere sentinel
#

Outside of arma, yes. In arma, very much no πŸ˜†

young storm
#

@austere sentinel aha ooo i see, pity cuse im useless in both lol i need a sensei xD

winter rose
#

Also was it the recursion that wasn't ideal, or execVM?
mostly the repeated usage of execVM on the same file, you would repeatedly read from the file which is "far from optimal", but in a respawn matter it is not time-sensitive
still, if you can load it once in RAM and reuse it, it's better

#

Oh and lou uhm as in trigger i just use the triggers..when a player enters the field thats connected to the modules, or if i dont understand sorry lol im a tad thick xD
@young storm
I am not sure I got that part?

young storm
#

when you said > I don't know how you want to trigger this?
@winter rose

I mean as in i have it set so i use a trigger that does it thing by a player entering the field, if that makes sense? Its nearly midnight so im a tad braindead lol. But as for my whole i want to hide /unhide the ai depending on what side i pass through the trigger for my scenerios flow i thought just using the basic thingy was enough? If i still dont make sense nevermind lol

winter rose
#

a trigger can only trigger if <the entity/entities> enter or exit the area you defined, not which way you enter/exit it

#

anyway, I think you should tell what is the actual end result you expect

#

depending on what side i pass through the trigger
unless you mean side as Arma side, e.g blufor/opfor/etc

young storm
#

Okay so like

#

You know how in a game like minecraft you have rendering , you load/unload the game and as you explore places things pop up an when you go away they dissapear till you come back. What im trying to do is that but with the ai positions i have set up, for the sake of frames/less micromanaging ai for ops, trying to use the trigger like that where i pass through they dissapear behind however far from the triggers boundaries, so if i turn around after that, i want them to reappear, rinse and repeat as much as the scenerio requires transit in that area

#

If i still dont make sense just ignore me on this topic lol i trieddddd super sorryyy

#

@winter rose

winter rose
#

then on activation - hideObject false
on deactivation - hideObject true?

#

I think you should go with the Dynamic Simulation system really.

#

@young storm

young storm
#

Oh okay ill try that ! In the modules i didnt see an option for both , ill take another look tomorrow, what do you mean dynamic simulation system tho? Sorry @winter rose

winter rose
#

the dynamic simulation system is integrated in-game and its settings can be set in Eden
basically, you can set if a player or a defined "triggering" unit will "wake" surrounding units, or not

when "asleep", unit simulation will freeze, saving computation time

lunar plume
#

hello I'm trying to install the virtual garage in a mission but the controls don't work ?

winter rose
#

what are you doing to "install the virtual garage"? @lunar plume

lunar plume
#

I use the commands indicated on the BIS but it doesn't work.

winter rose
#

@lunar plume which is…?

young storm
#

@winter rose roger ill give that a squiz,thanks for your time :)

lunar plume
#

that's it

winter rose
#

I use that, it works

#

first example```sqf
["Open",true] call BIS_fnc_garage;

lunar plume
#

I think it's probably tampering with one of my scripts. I'll look into it.

#

thank you @winter rose

distant egret
#

Hey does anyone know if it is possible to open an utility (https://community.bistudio.com/wiki/Arma_3_Utilities) outside of the debug console?
Even if I spawn the command in the debug console it just wont work. Giving an error of Undefined variable in expression.
Or is this an safety feature?

winter rose
#

Even if I spawn the command in the debug console it just wont work. Giving an error of Undefined variable in expression.
in Eden?
@distant egret

distant egret
#

Aye

winter rose
#

it should totally work in the debug console (and not anywhere else)

#

be sure not to have trailing/heading spaces or anything else like commented lines though

#

it's -just- utils X (1..5)

distant egret
#

Works in-game as well as long its directly executed from the console.

austere sentinel
#

mostly the repeated usage of execVM on the same file, you would repeatedly read from the file which is "far from optimal", but in a respawn matter it is not time-sensitive
still, if you can load it once in RAM and reuse it, it's better
@winter rose
Yeah that makes sense. I moved it (and a lot of other stuff) into CfgFunctions. Appreciate the tip.

Regarding CfgRemoteExec (sorry if this belongs more in #arma3_config if so I'll move it there)
Am I understanding that

class CfgRemoteExec {
    class Functions {
        class TAG_fnc_fncName { allowTargets = 2; };
    };
};

Would make it so the function can be sent from server -> client and not vice versa?

winter rose
#

yup

#

server can remoteExec , not clients

#

wait

#

maybe it's "a client can remoteExec but only to the server"

austere sentinel
#

Ok, how would I be able to reverse that? just allowedTargets = 1?

winter rose
#

@distant egret and where else would you want use it? πŸ€”

distant egret
#

Basically I've created an Eden menu strip with an jukebox thingy I made, but it isn't as fancy as the one BI provides. So I want to execute utils 4 to open up the jukebox util.

#

The one I made was opened with createDialog, I might be able to do the same if I can find the utils Dialog configs. But I just find it weird that the utils can only be opened when you use it through the console.

#

Not that the Utils are that harmful πŸ˜› .

winter rose
#

I don't know the internals unfortunately.

worn forge
#

Cfgremoteexec has no effect on the server. The server can remoteExec anything to any client any time. Cfgremoteexec determines what commands and functions can be sent by clients, and to where

winter rose
#

@austere sentinel ^
the server can always remoteExec everything indeed

worn forge
#

Cfgremoteexec - "we trust the server, but we don't necessarily trust the client"

winter rose
#

Do we trust the server though

queen cargo
#

in a real scenario?
no, never trust anything
everything can be compromised

worn forge
#

If we don't trust the server you have bigger problems than scripting

restive leaf
#

I don't trust my servers... after all, I know who writes the code for them 😭

austere sentinel
#

I don't trust my servers... after all, I know who writes the code for them 😭
@restive leaf I'm in this picture and I don't like it

exotic flax
#

Well, I don't write all code for all the mods/missions on our server, and I can't check everything either... So I also don't trust the server at all times

austere sentinel
#

I write everything, and trust it less for that reason 😁

carmine oak
#

Possible to change decal textures and or create own decal?
i want to "change" the ground texture using one

young current
#

change, no. create, yes. change ground texture, maybe but for large areas its not good

carmine oak
#

@young current is there a wiki link? i had troubles finding any information on this

young current
#

no

#

so no wonder it cant be found

#

it is a simple model if you have any knowledge of how arma models work

carmine oak
#

got any resources for creating custom models in mission? On wiki page it says it possible

young current
#

there are no resources for creating custom models in mission, there quite a bit about just creating models though. BI forums are a good starting point

#

a tip for looking up stuff: start with broader terms

#

how to make decal model for a mission -> how to make model for a mission -> how to make a model

#

then you start finding stuff

austere sentinel
#

Is there a way to dynamically find a suppressor for a weapon via script?
I'd really rather not make an array of [<weaponName>,<suppressorName>] arrays πŸ˜’

worn forge
#

I'm pretty sure there is config class which references the appropriate attachment items for a weapon

austere sentinel
#

Only thing I found was CfgWeapons>>weapon>>Muzzles but it seems that thats for stuff like UBGLs

potent depot
#

Anyone know how to distinguish if a client has an interface or not on the server end? Example, determining if the client it is checking is a headless or a player?

#

Im currently only feeding the server the client id. Im just wondering if the server can derive it or if it must be sent to it by the client as well?

winter rose
#

the mission EH onPlayerConnected only triggers for players @potent depot

#

what do you want to achieve precisely?

potent depot
#

Its a data sync function being called by remoteExec by the clients. It is being called by both players and HC but it needs to sync different data dependent on which. Im currently only feeding it the client ID of the calling client. I was wondering if the server can distinguish from the ID or if it needs another param. onPlayerConnect doesnt quite work for me as a player wont necessarily be connected to a curator on connect.

#

I think the simplest solution for me is probably an additional param

#

@winter rose ^

winter rose
#

Hmm yep, maybe

potent depot
#

thought so

winter rose
#

though I would wonder why the server isn't the one sending the data, instead of the client asking for it (but your architecture might require that, idk)

sturdy cape
#

can i setVariable on TerrainObjects?

still forum
#

yes

#

but they might spontaneously disappear

steady terrace
#

question, where is the config file that you call with configFile located on my computer?

still forum
#

nowhere

#

its generated in-memory from the config files included in every single pbo

steady terrace
#

oh dear

#

alright, thanks

#

then is there a way I could loop through it in game without knowing all the names?

still forum
#

you could look at a all in one config dump

#

just google

young storm
#

Is it possible to make a trigger float btw? So you can activate ontop of a building?

#

Tryna use my briefing musuc effectively

still forum
#

you can add a height limit via script into the trigger condition

#

count (thisList - (thisList unitsBelowHeight 20)) > 0
only counts units higher than 20m

young storm
#

Uhmmm for the retarded what do i do that lol

#

Ohhh

still forum
#

that into trigger condition

#

I think that should work 🀞

young storm
#

Roger, that goes into the INIT thing right?

still forum
#

no

#

that into trigger condition

young storm
#

Oh okay ill go check that out ty

#

Btw why do i needa sync the trigger to players for the music to register?

#

@still forum

still forum
#

dunno

#

I don't know triggers πŸ˜„

young storm
#

Yet you know the script thing lol

still forum
#

yeah ^^

young storm
#

The tables are upside down o..o

#

N nice xD

winter rose
#

I don't know triggers πŸ˜„
WHO are you

#

@young storm triggers have a "Z" size too, set it to what you want, and you can also set its altitude like any other object by pressing alt while dragging it

young storm
#

Lol who are you xD
And ill keep that in mind @winter rose , however when i did it, it raised the trigger flag icon and the depth of trigger field stayed the same so the second i entered it from the ground it did what i wanted it to do but not at a higher level in the building where i wanted it to be triggered, so ill try the Z an retry the alt n see if i missed something ty mate

winter rose
#

yes, triggers are of unlimited height unless you set it - default is -1 (unlimited), set it to IDK 5 or 10 and you're good

#

you will see the blue area limited in height anyway

still forum
#

told ya i don't know triggers πŸ˜„

young storm
#

Roger ill try that, i have yet to try the ai solution you presented me yesterday too @winter rose

#

@still forum same

oblique arrow
#

Hm since I'm thinking about it now, how would I figure out where a projectile thats shot from an autocannon hits the ground with a script?

winter rose
#

Fired EH and check if isNull the bullet, I guess

oblique arrow
#

would I just check if the bullet isNull repeatedly or?

#

and if I wanted to replace it with UXO I'd somehow have to figure out the spot it hits the ground at, but also delete it before it explodes

winter rose
#

I am afraid a loop check is required, and also you couldn't delete it before it explodes (unless you check altitude / object distance / etc)

oblique arrow
#

huh rip

young storm
#

Rip

restive leaf
#

@austere sentinel getArray (configFile >> "CfgWeapons" >> weapon >> "WeaponSlotsInfo" >> "MuzzleSlot" >> "compatibleItems");

#

Similar things for other attachments

dim terrace
#

@restive leaf That is bit unreliable method since its not going to work with i.e. accessories defined as params in class. I would rather advise (["LMG_Mk200_F"] call BIS_fnc_compatibleItems) select {101 == getNumber (configFile >> "CfgWeapons" >> _x >> "itemInfo" >> "type")};

#

201 is optics, 301 side rail, 302 bipod

vague geode
#

Is it possible to have a flag pole in a warlords secotor which automatically displays the flag of the current owner of the sector? E.g. when BLUFOR is in control the flag pole would fly a NATO flag and after OPFOR takes the sector the NATO flag would be lowered automatically and once it reaches the flag pole's foundation a CSAT flag would be hoisted instead.

oblique arrow
#

Hm I dont know about the lowering animation, but couldnt you make that by checking the faction that currently owns the sector and then checking for that factions flag?

austere sentinel
#

@restive leaf @dim terrace you two are awesome, tyvm

vague geode
#

@oblique arrow I would need to trigger the checking when a sector was conquered because checking constantly would take a huge toll on performance for obvious reasons.

sacred slate
#

is there somthing to adress the currenty controlled unit, if you team switch? i thought player would work, but i think it is bound to the scenario player

oblique arrow
#

Oh ye fair, start checking once it starts being captured until its fully captured @vague geode

vague geode
#

@oblique arrow Honestly it would be enough to check once it is actually fully captured but I have no clue how to do that...

oblique arrow
#

Only checking once its fully captured would mean that you dont get a nice battlefield like flag movement system though @vague geode

slate sapphire
#
in our warfare there is a bounty system that trigger when unit die and get who is the last player that hit the vehicle before explosion, then give bounty to that player,Β  Β 



I used a old script that let player attach satchel to vehicles, I manage to mod a bit so vehicle always explodeΒ  I had to do that due to some RHS vehicle that are randomly invincible and create game breaking situations.



I tested for now hosting the mission within the editor and works but the script generate an elicopter explosion and doesn't give the bounty to the player, I would like to fix that, and somehow link the explosion to the player that detonate it. so the unit killed script will recognize who was the killer.
vague geode
#

@oblique arrow That's impossible anyway since if you kill and enemy while already taking the sector the bar will be reset. If the flag would work like it does in Battlefield it would jump up again if that happens. What I am going for instead is that once the sector is fully conquered the flag starts lowering, gets replaced by the new owner's flag which will then be hoisted.

PROs:

  • no weird glitching
  • less strain on the server performance
oblique arrow
#

huh okay

#

although

#

That's impossible anyway since if you kill and enemy while already taking the sector the bar will be reset
You could work around that by giving the flag a maximum amount of height that it can go down/up in each move

#

so it still lifts up in a normal manner even if the cap gets reset it moves back up nicely

#

And

What I am going for instead is that once the sector is fully conquered the flag starts lowering, gets replaced by the new owner's flag which will then be hoisted.
then you could just check once at the end of the cap and start a script that slowly changes the flag the way you described, although you'd also have to check every now and then if anything has changed in the sectors state so you dont get it moving up and down at the same time or some wacky behaviour like that

#

Although having it work like that isnt as nice imo since it doesnt visualise the capping progress

vague geode
#

@oblique arrow Sure, but it makes things more difficult than they have to be. I would like to work with a design principle noted by the U.S. Navy in 1960 called KISS. Besides in a real conflict there aren't two spectators that look at the tide of battle and raise or lower the combatant's flags depending on how well the situation seems to go for each side. In real life after a sector or an objective is secure someone hoists the flag and if the enemy takes a sector or an objective they tear down the flag and hoist their own instead and that's what I am aiming for.

oblique arrow
#

heh fair

vague geode
#

then you could just check once at the end of the cap and start a script that slowly changes the flag the way you described [...]
@oblique arrow Yeah, but HOW do I do that exactly?

oblique arrow
#

I havent looked at the warlords scripting so I cant give you an exact guide

vital dome
#

What would be the best way to learn scripting really?

vague geode
#

@vital dome I can code, that's not the problem. I just have to know what event gets triggered when a sector changes its owner, how I can catch that event for a specific sector and how I can get the sectors owner.

vital dome
#

I think ya gave the wrong tag NikoLaugh

oblique arrow
austere sentinel
#

@vital dome Read the basic syntax tutorials, pick a very small idea and start coding. When you run into a problem, read the wiki first, then ask here if that didn't help.

#

Its really just a matter of grinding it out at first

oblique arrow
#

^ Imo starting to code is the best way to learn coding

#

how I can catch that event for a specific sector and how I can get the sectors owner.
I recommend taking a look at the way warlords works to find out @vague geode

vague geode
#

@oblique arrow Yeah, but HOW do I do that exactly?
@vital dome Oh, maybe I misunderstood you. I thought you were refering to my question from the message above.

#

I recommend taking a look at the way warlords works to find out @vague geode
@oblique arrow Any idea where I can do that?

oblique arrow
#

A good first step is propably to crack open one of the warlords mission files using something like pbo manager to de-pbo it and then opening it up in the editor

cunning crown
#

If you have your P drive setup you should have all the file already unpacked and debinarized, it's easier to search for things in the game like that

alpine ledge
#

@vague geode (sectorYouWant getVariable "BIS_WL_sectorSide") == EAST/WEST/RESISTANCE does what you're looking for

slate sapphire
#
in our warfare there is a bounty system that trigger when unit die and get who is the last player that hit the vehicle before explosion, then give bounty to that player,Β  Β 



I used a old script that let player attach satchel to vehicles, I manage to mod a bit so vehicle always explodeΒ  I had to do that due to some RHS vehicle that are randomly invincible and create game breaking situations.



I tested for now hosting the mission within the editor and works but the script generate an elicopter explosion and doesn't give the bounty to the player, I would like to fix that, and somehow link the explosion to the player that detonate it. so the unit killed script will recognize who was the killer.

@slate sapphire anyone could help me, is there a way to assign to an explosion a player so the kill event handler will recognize it

exotic flax
#

you probably need to set a variable on the vehicle with the player who placed the explosive device, and in the Killed event handler you should check if death was by an explosion in a vehicle with that variable set.

slate sapphire
#

mind to help me with that I am a bit lost

exotic flax
#

that is as much help as I can give... especially because the main issue is most likely caused by how you attach the explosive to the vehicle (since the game doesn't know who placed it).

slate sapphire
#
_nearVehicle = (nearestObjects [_unit,["Air","Ship","LandVehicle"],5]) select 0;
    _explosive = _class createVehicle [0,0,0];
    _explosive attachTo [_unit,[0,0,0],"leftHand"];
    _random0 = random 180;
    _random1 = random 180;
    [_explosive,_random0,_random1] call BIS_fnc_SetPitchBank;
    [_explosive,_nearVehicle,_unit,_random0,_random1] spawn
    {        
        _explosive = _this select 0;
        _nearVehicle = _this select 1;
        _unit = _this select 2;
        _random0 = _this select 3;
        _random1 = _this select 4;
        
        sleep 1.5;
        _explosive attachTo [_nearVehicle];
        [_explosive,_random0,_random1] call BIS_fnc_SetPitchBank;
        _unit setVariable ["charges",(_unit getVariable ["charges",[]]) + [_explosive]];
        [_explosive,_unit] spawn EtV_TimedCharge;
#

using a 2013 script I've found searching in forum

#

I adapted to my need it seem it works and I am now trying to add also that to the bounty system of the mission.

exotic flax
#

my initial answer already gave some pointers on how to do that

slate sapphire
#
if(alive _x) then
        {
            "HelicopterExploSmall" createVehicle (position _x);
            deleteVehicle _x;
            _target = (nearestObjects [_x,["Air","Ship","LandVehicle","Car","Tank"],15]) select 0;
            if !(isNil _target) then {_target setDamage 1; };
            
        };
    } forEach _explosives;
    _unit setVariable ["charges",[]];
exotic flax
#

since nobody here will make a full working script, unless they already have one laying around

slate sapphire
#

I understand that I am not asking that

exotic flax
#

But like I said; problem is that 1) explosive is not placed by player, but by script and 2) vehicle explosion is not caused by player but by script
So only way to fix your issue is by storing and retrieving WHO

#

and for that you'll need setVariable and getVariable

slate sapphire
#

the logic I knew what I don't know is how to pass to the killed event handler

slate sapphire
#

Call Compile Format ["_vehicle addEventHandler ['Killed',{[_this select 0,_this select 1,%1] Spawn UnitKilled}]",_side];

#

_killed = _this select 0;
_killer = _this select 1;

exotic flax
#

Most likely you'll need to check _killer, which should be the vehicle in your case. And if that has the original player in the variables (who placed the explosive) then you know

slate sapphire
#

that's working

#

if I assign a variable to the vehicle with the player that placed the satchel

#

after the spawn of UnitKilled function can i get that value

#

using _killed getvariale "satcheowner" ?

exotic flax
#

for example

slate sapphire
#

_nearVehicle setVariable ["saboteur",_unit];

#

this in my code will set the name of who placed the satchel

#

in the killer event handler if I can read that

#

example if !nil _killed getVariable "saboteur" then... killer = .....

tough abyss
#

Hey guys. I'm having a mission where players in the main base need to prep crates for logistics deployment. The issue is when they have to fill a crate with 50 uniforms/vest ect as they have to pull them out an arsenal. does anyone know of a script that I could add where they could interact with the crate and edit it's content easely?

slate sapphire
#

testing

austere sentinel
#

@tough abyss You're probably going to have to build a UI (which means easy for them, not for you πŸ˜‰ )
If you want to simplify it somewhat for yourself, you can set pre-determined crates (i.e. Crate1 has 50 Vests, Crate2 has 30 vests, 10 grenades ... )
Take a look at https://community.bistudio.com/wiki/addItemCargoGlobal

tough abyss
#

Damn, is there no pre-done script? I'm not familiar with A3 scripting :/

#

I looked at VAS but sadly I couldn't adapt it to crates

exotic flax
#

@tough abyss I usually setup some crates in Eden or with Zeus with all the items in it, either with fixed items or limited Arsenal.
You could take a look at the source code of Achilles or ZEN, since they have an UI for inventory management (or take a look at how Eden editor is handling it)

tough abyss
#

O_o that souds like a lot of work when you don't know the language lol. thanks for the try though

worn forge
#

Short answer =no there is nothing built in

exotic flax
#

technically there is, just not available in-game πŸ˜‰

slate sapphire
#

@exotic flax can't believe it works !! thanks a lot mate πŸ‘

#

it give me only the vehicle bounty not the crew but I can be happy of the result πŸ™‚

vague geode
#

@vague geode (sectorYouWant getVariable "BIS_WL_sectorSide") == EAST/WEST/RESISTANCE does what you're looking for
@alpine ledge Thanks, but how do I call the method only when a sector changed sides?

restive leaf
#

Thanks @dim terrace Appreciate that info, will update the script that uses the older code

alpine ledge
#

@vague geode ah i see what you want now
well you'd need to detect when the side has changed, so you could use a while loop in combination with something like ```sqf
_oldSide = (yourSector getVariable "BIS_WL_sectorSide";
waitUntil { (yourSector getVariable "BIS_WL_sectorSide") != _oldSide };

then put whatever code you want after
sacred slate
#

how can i call the fnc_wpGarrison from lambs danger on a group?

#

its call lambs_wp_fnc_taskGarrison

sacred slate
#

how can i target non vehicle only groups? i want only the pure infantry groups to recive lambs_wp_fnc_taskGarrison

vague geode
#

@alpine ledge Is there no event that gets called when a sector changes owners because if I use 50+ while loops (one for each sector) at the same time all the time the toll on the server performance would be extreme...

alpine ledge
#

well i had a look at the warlords FSM files and it looks like that's how it does it

#

you don't need 50 while loops though

vague geode
#

@alpine ledge Ok. There is a function that changes the sector colour on the map etc. when it changes owners maybe I can work this in that somehow...

alpine ledge
#

could do; when warlords runs its init script, it runs the sector handle FSM for each, so you could do it that way too

vague geode
#

@alpine ledge Thanks for the help.

lunar plume
#

hi i have problems with the EOS script

exotic flax
#

Hi, I don't use "EOS script", or even have a clue what it is

#

so perhaps a bit more information could help us understand your problems

lunar plume
#

yes I specify this script allows to make appear enemy units or other but I have a recurring error that for the appearance of vehicles I have a little difficulty to understand what arma wants me to do to fix it

worn forge
#

post or pastebin the error

lunar plume
#

OK

exotic flax
#

what is the error?

worn forge
#

he's gonna paste it

oblique arrow
#

Or not heh

lunar plume
#

or yes i have send in PM

worn forge
#

via Garrick...

_position=(_this select 0);
_side=(_this select 1);
_faction=(_this select 2);
_type=(_this select 3);
_special = if (count _this > 4) then {_this select 4} else {"CAN_COLLIDE"};

_vehicleType=[_faction,_type] call eos_fnc_getunitpool;
    _grp = createGroup _side;

    _vehPositions=[(_vehicleType select 0)] call BIS_fnc_vehicleRoles;
    _vehicle = createVehicle [(_vehicleType select 0), _position, [], 0, _special];

_vehCrew=[];

        {
    _currentPosition=_x;
    if (_currentPosition select 0 == "driver")then {
            _unit = _grp createUnit [(_vehicleType select 1), _position, [], 0, "CAN_COLLIDE"];                    
            _unit assignAsDriver _vehicle;
            _unit moveInDriver _vehicle;
            _vehCrew set [count _vehCrew,_unit];
            };
    
    if (_currentPosition select 0 == "turret")then {
            _unit = _grp createUnit [(_vehicleType select 1), _position, [], 0, "CAN_COLLIDE"];
            _unit assignAsGunner _vehicle;
            _unit MoveInTurret [_vehicle,_currentPosition select 1];
            _vehCrew set [count _vehCrew,_unit];
            };
            
        }foreach _vehPositions;
    
_return=[_vehicle,_vehCrew,_grp];

_return
oblique arrow
#

huh weird

#

(the sending via pm thing that is)

worn forge
#

Now

#

what's the error you receive

lunar plume
#
_position=(_this select 0);
_side=(_this select 1);
_faction=(_this select 2);
_type=(_this select 3);
_special = if (count _this > 4) then {_this select 4} else {"CAN_COLLIDE"};

_vehicleType=[_faction,_type] call eos_fnc_getunitpool;
    _grp = createGroup _side;

    _vehPositions=[(_vehicleType select 0)] call BIS_fnc_vehicleRoles;
    _vehicle = createVehicle [(_vehicleType select 0), _position, [], 0, _special];

_vehCrew=[];

        {
    _currentPosition=_x;
    if (_currentPosition select 0 == "driver")then {
            _unit = _grp createUnit [(_vehicleType select 1), _position, [], 0, "CAN_COLLIDE"];                    
            _unit assignAsDriver _vehicle;
            _unit moveInDriver _vehicle;
            _vehCrew set [count _vehCrew,_unit];
            };
    
    if (_currentPosition select 0 == "turret")then {
            _unit = _grp createUnit [(_vehicleType select 1), _position, [], 0, "CAN_COLLIDE"];
            _unit assignAsGunner _vehicle;
            _unit MoveInTurret [_vehicle,_currentPosition select 1];
            _vehCrew set [count _vehCrew,_unit];
            };
            
        }foreach _vehPositions;
    
_return=[_vehicle,_vehCrew,_grp];

_return
worn forge
#

...

#

yes that is the code you're running

#

you said you got an error when you ran it, what is it

lunar plume
#

i m read the error

worn forge
#

I'm sure I speak for everyone when I say we're eagerly awaiting what this error is

lunar plume
#

well I try to see if the error wants to appear but no way it appears when it wants like a car that breaks down and when we go to the mechanic everything works.

#

well my error is on line 11 it tells me the problem is here but I don't know what to change.

worn forge
#

the error should also be written to your .rpt file, located inc:\users\YOU\appdata\local\Arma 3\Arma3_x64... .rpt

lunar plume
#

I just want to figure out how to fix it.

worn forge
#

we can't possible know how to help you unless you tell us what arma is complaining about

lunar plume
#

yes ok i have the error

#
'...] call BIS_fnc_vehicleRoles;
_vehicle = |#|createVehicle [(_vehicleType select 0), ...'
Error Type Quelconque, Chain expected 
Error Variable indΓ©finie in an expression _tempunit
File E:\Documents\Arma 3 - Other
Profiles\Perceval\mpmissions\Takistan.takistan\eos\functions\eos_SpawnVehicle.sqf
...,line 11
#

its the error

worn forge
#

It doesn't relate to the code you've provided. No one is jumping up to help you because you don't seem to understand what you're doing, and the thought of helping you get to where you need to be is daunting

lunar plume
#

So I try to learn the script and understand the little bugs to better understand despite that I'm looking for what arma wants since this morning but I don't understand why so I came to ask to see if someone knows this script and could enlighten me in my search for a repair.

oblique arrow
worn forge
#

I wouldn't expect people in this channel to do a thorough debug and fix your code for you, if your question was a bit more simple, or you had identified the error accurately, we could probably help you

#

If it's not a script you designed, obvious first place you should go for answers is the author of that script

lunar plume
#

yes I did some research on the internet to find out but it doesn't give much I checked again if I had followed the instructions and everything was good so I looked at each script but the thing seemed precise so I came to ask

worn forge
#

Here is a clue, your problem variable is _tempunit but it doesn't appear anywhere in eos_SpawnVehicle.sqf, assuming that is the code you have provided above

lunar plume
#

yes it is a code i have provided

#

i know i m search inside the code

worn forge
#

If that's bangabob's EOS script you're running, he hasn't posted on the Bohemia forum since 2017, so I don't think you'll get assistance from him. You could post on the BIS forum thread for help

lunar plume
#

ok I didn't think about the BIS thanks for the advice I'll ask the creator thanks a lot

haughty fable
#

Hello, i need some help with a script (im totally new)

#

Can someone help?

worn forge
#

Just post your problem

haughty fable
#

I want to put the Check Pilot and Check Gunner Scripts on my mission, but how do i do it?

worn forge
#

Yeray, contact the author of that script

#

(what is going on today?)

haughty fable
#

wow thanks for the help

worn forge
#

You should have a glance at the description of this channel, "Discussion about anything related to Script creation and usage", you are asking us to dissect someone else's code for you

alpine ledge
#

it tells you how to execute them on the page anyway GWseremePeepoThink

worn forge
#

^

haughty fable
#

Thats the problem

#

I dont know how to save it

alpine ledge
#

save what

haughty fable
#

scripts\b2_checkPilot.sqf

#

Where

alpine ledge
#

in the mission folder

haughty fable
#

But i cant

alpine ledge
#

why

haughty fable
#

it says the access route doesnt exists

worn forge
#

o.O

alpine ledge
#

what is "it" in this case

#

arma? windows?

haughty fable
#

windows

#

When i try to save that script with the name of scripts\b2_checkPilot.sqf

#

in the mission folder

worn forge
#

is there a file named "mission.sqm" in your mission folder?

haughty fable
#

yes

alpine ledge
#

maybe it's just the way i'm reading this, but you don't name the file scripts\b2_checkPilot.sqf - you put it b2_checkPilot.sqf in a folder called scripts in the mission folder

worn forge
#

^

haughty fable
#

so i have to create a folder called scripts?

alpine ledge
#

yes E_FeelsNeatMan

haughty fable
#

ohhh

#

im stupid sorry xD

alpine ledge
#

then put the sqf file in there, then execute it like it says on the forum page

haughty fable
#

ok, i'll try it

#

And now i have to put what he said before on a text called init.sqf?

#

this: ["Helicopter","B_Helipilot_F"] execVM "scripts\b2_checkPilot.sqf";

worn forge
#

if that's what he said

alpine ledge
#

if that's what it says to do, then yeah, put that line in a file called init.sqf in the mission folder

haughty fable
#

It means: Error, undefined variable

#

in the expression _crewtype

alpine ledge
#

_crewType hasn't been defined: did you include it when you executed it?

haughty fable
#

include it where?

alpine ledge
#

show me your execVM line

haughty fable
#

on the init?

alpine ledge
#

yeah

haughty fable
alpine ledge
#

get rid of the first line

haughty fable
#

ok

#

Let me try it now

alpine ledge
#

that line is just the example, doesn't contain any information to pass to the script πŸ˜›

#

well, it does but not the kind it's looking for

haughty fable
#

oh ok

austere sentinel
#

Not sure if this is the right channel but;
I wrote an extension, and it seems to be working (as in I get the proper return code, no error code, and the return value string when using callExtension)
The issue is that I can't create and write to a file, or open a terminal (i.e. using std::cout). Is this just an OS permissions error?

haughty fable
#

Now it "works" but when i try to get into the heli with the actual pilot it keeps saying Required class: Helicopter pilot

alpine ledge
#

that's what the script is supposed to do πŸ˜›

haughty fable
#

no

#

but im with the pilot

#

I should be able to drive

alpine ledge
#

but are you "B_Helipilot_F"

haughty fable
#

yes

alpine ledge
worn forge
#

Β―_(ツ)_/Β―

#

I'm "with" the pilot, sentence suggests you are accompanying someone

haughty fable
#

do you have team viewer?

#

Because i dont know what can i do

#

I'm "with" the pilot, sentence suggests you are accompanying someone
@worn forge no, i mean im controlling the pilot

alpine ledge
#

well the script itself is working, but without knowing the ins-and-outs of it there's not much more i can do GWseremePeepoThink

worn forge
#

Zeus controlling? Or you are B_Helipilot_F from mission start

haughty fable
#

Mission start

worn forge
#

It sounds like the script matches up the class of the vehicle (Helicopter) with the type of the unit (B_Helipilot_F) and spits back an error if they don't meet the requirement. The script is working (it's giving you feedback) but it's not what you expect, so either there is a bug in the script or a bug in your implementation

haughty fable
#

maybe i have to put the exact name of the heli?

worn forge
#

You could try that, is it a vanilla heli or modded?

haughty fable
#

vanilla

worn forge
#

Try the exact class name

alpine ledge
#

don't think it would be that: at a glance on the forum page, the vehicle check is isKindOf and the player check is typeOf so "Helicopter" should be fine

#

dunno PepoShrug

#

i don't see any reason why it wouldn't work the way it's intended

#

assuming everything is set up properly

haughty fable
#

i guess so

#

Look

#

Do i have to put that too in the init?

#

Or only what appears on the information of the script?

alpine ledge
#

try it with just those 3 lines: it should mean that only B_Helipilot_F can sit in pilot or gunner seats

#

everyone else should get kicked out

haughty fable
#

You mean the lines i had or the ones i uploaded?

alpine ledge
#

put those 3 lines in the image you showed me

haughty fable
#

ok

#

and remove the ones i have?

alpine ledge
#

sure

#

tested it on my end, works fine

haughty fable
#

Yes it works great, thank you!

#

Now if i want to change it to planes?

alpine ledge
#

change "Helicopter" to "Plane"

haughty fable
#

And i can change the unit name too right?

austere sentinel
#

_veh isKindOf "Air" would cover both, no?

worn forge
#

yup

alpine ledge
#

yeah, you'll probably want "B_Fighter_Pilot_F" i guess

haughty fable
#

Tanks a lot @alpine ledge and @worn forge :)))

worn forge
#

Yeray you should pay great attention to what you changed that enabled it to work

haughty fable
#

Yes i did

steady terrace
#

thanks @still forum the AIO config is what I needed!

steady terrace
#

I've mostly gotten what I wanted out of it, but now I'm wondering how to best spawn something in when you don't know the cargotype?

if I want to spawn say "tfa_v_jpc_marksman_mc"(a platecarrier) into a crate, I'd think I could do something like

SpawnCargoInBox=
{
    params["_item", "_holder"];
    
    switch true do
    {
        case(isClass(configFile >> "CfgMagazines" >> _item)): {_holder addMagazineCargo [_item, 1]};
        case(isClass(configFile >> "CfgWeapons" >> _item)): {_holder addWeaponCargo [_item, 1]};
        case(isClass(configFile >> "CfgGlasses" >> _item)): {_holder addItemCargo [_item, 1]};
    };
};

but it uses addWeaponCargo, which causes it to spawn as any old object, not something you can wear. using addItemCargo does work though. what am I missing?

vital dome
#

I am wondering what kind of code could be used as an animation that starts for all players. Something that can be thrown in an init.

winter rose
#

nope. not in an init.

vital dome
#

Hmm, where could such code work then?

winter rose
#

when do you want this anim to execute?

vital dome
#

Basically just at the beginning, but anytime else can also be useful to know.

winter rose
#
{ [_x, "animationName"] remoteExec ["playMove", _x]; } forEach allPlayers;

in the initServer.sqf for example, but making sure the mission is already started

vital dome
#

πŸ‘

grave kite
#

how do you list all instances of an object of a given type?

surreal peak
#

@grave kite what type of objects? Will these be simple objects or regular ones?

#

Also how often will the code be run? Is it a one time deal or will it happen at regular intervals?

grave kite
#

in this context, im trying to list alive civ placement modules, once, in the debug menu; but i would also like to know how to do it in general

surreal peak
#

I'm not sure if that will return modules

grave kite
#

thxs ill give that a shot

surreal peak
#

From the looks of it they should work

grave kite
#

nice

surreal peak
#

Make sure you dont overuse allMissionObjects cause it will chug depending on the misson, as a debug thingy its fine

grave kite
#

20:23:32 ALiVE [m_78|80] Module ALiVE_amb_civ_placement INIT COMPLETE TIME: 0.387695
20:23:32 ALiVE [m_79|90] Module ALiVE_mil_placement INIT
in the above lines, is the "m_78" native to the engine, or is it Alive doing that

surreal peak
#

What is that an output of @grave kite ?

grave kite
#

its in the rpt file, in regards to the Alive mod civilian placement module

#

ill get output like
20:23:32 ALiVE [m_77|80] Module ALiVE_amb_civ_placement INIT COMPLETE TIME: 0.392578
20:23:32 ALiVE [m_78|80] Module ALiVE_amb_civ_placement INIT
20:23:32 ----------------------------------------------------------------------------------------
20:23:32 ALIVE AMBCP - Startup
20:23:32 [TIMER STARTED]
20:23:32 ALIVE AMBCP - Startup completed
20:23:32 ALIVE AMBCP - Count clusters 0
20:23:32 [TIMER ENDED : 0.387695]
20:23:32 ALIVE AMBCP - Warning no locations found for placement, you need to include civilian locations within the TAOR marker
20:23:32 ALiVE [m_78|80] Module ALiVE_amb_civ_placement INIT COMPLETE TIME: 0.387695
20:23:32 ALiVE [m_79|90] Module ALiVE_mil_placement INIT

#

im trying to figure out what module, location its actually referring to

#

i guess another way to ask the question would be, how do scripts find the world location of module placement in the eden editor?

copper raven
#

getPos

grave kite
#

ok thats works aswell
_civPlacements = allMissionObjects "ALiVE_amb_civ_placement"; {getPos _x } forEach _civPlacements;
prints [27035.9,21442.9,7.767]

#

now i need to figure out how to match m_78 to the correct object

surreal peak
#

Is "m_78" an identifyer for the module?

grave kite
#

im guessing so

#

im assuming at this point that its not the engine creating that id, but the Alive mod

surreal peak
#

What is the end result you are trying to achieve?

grave kite
#

im trying to work out which module the error is referring to

young storm
#

So i found the dynamic simulation option on ai an a module that stops ai simulation after a certain distance, how do i know it works/is that equivalent of rendering/unrendering things for the sake of frames?

surreal peak
#

@grave kite so just to confirm:
You have mutliple civi placement markers, one of which is throwing a TAOR errror.

grave kite
#

yes

surreal peak
#

And this modile is referneced by m_78

grave kite
#

yes, in the rpt file log

surreal peak
grave kite
#

yes

surreal peak
#

Which makes me believe in one of the modules you have accidently selected an option for TAOR

round scroll
#

anyone aware of how to make an AI Heli hover at 30 meters above terrain? I gave it a Hook waypoint and that makes it hover over the location, but at around 70 meters. Neither flyInHeight not flyInHeightASL seem to work then. I pushed it down with a loop of setVelocity[0,0,-10] but this means it just 'wiggles' between 30 and 40 meters and is not stable vertically

surreal peak
#

So it might just be worth going to the eden editor and just look through all of these

grave kite
#

yep, i've been over it with a fine tooth comb, they all look right. my guess is that one of the modules, with its TAOR marker, isnt picking up civilian buildings for some reason. but im not sure which one.

winter rose
#

@round scroll flyInHeight , with a normal waypoint

young storm
#

@round scroll is this for reppelling?

#

Rappelling*

#

@winter rose reckon you can answer my question i sent a few mins ago since nobody else will lol

#

??**

surreal peak
#

I think we need more detail

round scroll
#

@young storm trying out the rescue basket system for SP for the CH-46

young storm
#

@winter rose yes

#

@round scroll rescue basket whatt? This sounds cool

winter rose
#

@young storm I don't think it works with a module but just as a normal "setting".
if it's the default Dynamic Simulation Manager, it works.

#

if it's a 3rd party module, IDK

young storm
#

The module is from vanilla zues so hmm. Ill youtube it, But oki just to make sure. If i click tick on dynamic simulation, the ai will stop simulating till a player is relatively nearby? Thus more frames?

winter rose
#

that's the point, yes.

#

and if you set the proper thresholds in Eden as well

young storm
#

Where would i set the proper thresholds? @winter rose

#

Or how i guess lol

#

Sorry to bother you with this

young storm
#

I didnt review the screen shot or the link i saved, i only reviewed the solution you gave me, plus had to reinstall arma n fiddle with mod list cuse apperently i burnt through 220gb of storage lol , sorry mate

#

@winter rose you have my gratitude once again

worn forge
#

@steady terrace to your question, I've done pretty well by just using addWeaponCargoGlobal, addMagazineCargoGlobal, addItemCargoGlobal, and addBackpackCargoGlobal - it's fairly easy to determine if an item is a weapon, magazine or backpack, and then everything else goes as an item.

#

There are a few notable exceptions, though - binoculars can go as either a weapon or an item.

young storm
#

So you can smack the enemy with binocs? Lol @worn forge

worn forge
#

Yes, you shoot them out of your mouth apparently, looking at how Arma modelled them

young storm
#

Lol thats arma for you. Tossing perfectly good vehicles off bridges or exploding randomly or weird models etcπŸ˜…

steady terrace
#

@worn forge sorry I don't think I quite understand. My problem was that that function identifies a platecarrier as a weapon(because it is indeed included in CfgWeapons) even though it obviously isn't. How should I determine what type an item is then?

worn forge
#

check its class parents

#

Ie., V_Chestrig_oli (Chest Rig - olive) is indeed configfile >> "CfgWeapons" >> "V_Chestrig_oli"
but its parents are ["Vest_Camo_Base","ItemCore","Default"]
so you can do

_itemParents = [(configFile >> "CfgWeapons" >> _item),true] call BIS_fnc_returnParents;```
and then
```sqf
if ( "ItemCore" in _itemParents ) then { _item addItemCargoGlobal... }```
#

or something like that

#

You can't use isKindOf for CfgWeapons unfortunately so you have to go this more clunky route

steady terrace
#

Ahh! That's awesome, thanks!

worn forge
#

Although Lou is probably about to correct me that the alternative syntax of isKindOf allows you to compare other config types, never saw that πŸ™‚

winter rose
#

I don't want to be anal πŸ˜›

worn forge
#

(This actually will have an impact on some stuff of mine, should it work)... better to use

_item isKindOf ["ItemCore", configFile >> "CfgWeapons"];
winter rose
#

I was about to suggest checking the Item type, 101/201/301/302

worn forge
#

Not sure I understand the numbers reference Lou?

winter rose
#

there is a CfgWeapons >> _item >> "itemType" (iirc) >> "someOtherKey" that gets an item type, and the numbers define if it is a weapon item, vest, helmet etc

#

(@ work rn, can't check)

worn forge
#

well type for the V_Chestrig_oli is 131072, so I guess you'd have to find some kind of lookup table?

winter rose
#

your solution is way more readable though

worn forge
#

If you were desperate to segregate further down the line from just ItemCore you could convert the item type to text and then find for V_ > -1

vital dome
#

I'm wondering what to do for forcing on NVG for players

#

Thought it would be a bit like for example forcing on flashlights for AI.

#

But can't seem to find any syntax about such

worn forge
#

do you mean just making sure they have NVGs in their inventory?

vital dome
#

Negative, enabling them while they're on their head, aka turning them on

#

Like AI does automatically.

worn forge
#

why would you want to do this?

surreal peak
#

I can see a few reasons, e.g. some force is hacking their equipment

#

Or malfunctipns

vital dome
#

Creative, but it's basically just so people can see when the scenario starts, basically

worn forge
#

player action ["nvGoggles", player]; ?

winter rose
#

^ this is de wey

vital dome
#

Works with the debug, trying to just throw it up to do it automatically or with a trigger instead

worn forge
#

Just put it in initPlayerLocal.sqf or onPlayerRespawn.sqf, depending on how you start your mission

vital dome
#

It works! Thank you.

exotic flax
#

@worn forge try bis_fnc_itemType, and reading into that function will give you all the ID's (eg. type = 131072, itemInfo = 701 for vests).

safe forum
#

Hi all. I have a trouble with setVelocityTransformation.

disableSerialization;
interval = 0;
_disp = findDisplay 46 createDisplay "RscDisplayEmpty";
_ctrl = _disp ctrlCreate ["RscSlider", -1];
_ctrl ctrlSetPosition [safeZoneX + 0.1, 1, safeZoneW - 0.2, 0.1];
_ctrl ctrlSetActiveColor [1,0,0,1];
_ctrl ctrlCommit 0;
_ctrl sliderSetPosition 0;
_ctrl sliderSetRange [0,1];
_ctrl sliderSetSpeed [0.1,0.5];
_ctrl ctrlAddEventHandler ["SliderPosChanged", {interval = _this # 1}];
ctrlSetFocus _ctrl;
box = "Land_VR_Shape_01_cube_1m_F" createVehicle [0,0,0];
controlPointASL = AGLtoASL (player getRelPos [70, -30]) vectorAdd [0, 0, 30];
fromPosASL = getposasl frame_1;
toPosASL = getposasl frame_2;
onEachFrame
{
    hintSilent format ["Interval: %1", interval];
    box setVelocityTransformation
    [
        fromPosASL,
        toPosASL,
        [0,0,0],
        [0,0,0],
        vectordir frame_1,
        vectordir frame_2,
        vectorup frame_1,
        vectorup frame_2,
        interval
    ];
};

As u can see, at interval 1, a test cube doesn't have same position, as a frame_2. How I can fix it?

https://sun9-43.userapi.com/c858336/v858336791/199f46/iRCMUBdAXzM.jpg

surreal peak
#

what do you want the end result to be?

woeful sundial
#

hi does someone know how to get the turret camera from a jet or from helicopters where the copilot has a camera to control and rotate i want to PIP it

woeful sundial
worn forge
#

sounds like you're already headed in the right direction

warm storm
#

How do I make it so when I give players virtual arsenal with only a certain selection they cant just use their saved loadouts, or they can but when they leave the arsenal it deletes restricted items

surreal peak
#

@warm storm quick google suggests:

[ missionNamespace, "arsenalOpened", {
    disableSerialization;
    _display = _this select 0;
    {
        ( _display displayCtrl _x ) ctrlSetText "Disabled";
        ( _display displayCtrl _x ) ctrlSetTextColor [ 1, 0, 0, 0.5 ];
        ( _display displayCtrl _x ) ctrlRemoveAllEventHandlers "buttonclick";
    }forEach [ 44146, 44147 ];
} ] call BIS_fnc_addScriptedEventHandler;```
#

palce into initPlayerLocal.sqf

warm storm
#

thank u

woeful sundial
#

sounds like you're already headed in the right direction
@worn forge yea but my vehicle is not a UAV and is controlled by a player

bright flume
#

example
getModeInfo:[""mobileradar_01_generator_f.p3d"",""a3\structures_f_enoch\military\radar\mobileradar_01_generator_f.p3d"",false] vs
getModeInfo:[""mobileradar_01_radar_f.p3d"",""a3\structures_f_enoch\military\radar\mobileradar_01_radar_f.p3d"",true]

young current
#

Not a 100% reliable indicator.

bright flume
#

okies Im just sorting objects atm right now. figured a hacky but legit way to extract all the different models used in Livonia

young current
#

Extract in what sense?

bright flume
#

what you see

#

trying to get a index list of all AI usable terrain stuff in Livonah

young current
#

Object positions then?

bright flume
#

that someone else might be able to get... πŸ™‚ right now trying to get atleast the object names/model names so maybe Alive can detect them. if that doesnt work then atleast I know classes to specify as think deWRP has a length limit to what it can dump? or it just dont like Livonia

#

if I gotta do the hard way I got a way I can get every position just gonna take time

young current
#

Isn't livonia terrain ebo?

bright flume
#

exactly... the problem.

young current
#

Ssoo what are you doing with the wrp

bright flume
#

if dewrp just wont like it then I'll go the hard route..

young current
#

Alrighto

bright flume
#

just right now trying to get the core list of buildings see if I get that throw in the alive indexer so it knows how to group them FSM exam might pick up on them in a 'live' setting not sure... data spread out over so many different files its hard to exactly know what needed where since it can be done automatically

still forum
#

DeWrp shouln't have a output length limit, its just dumping to console

bright flume
#

console itself has a limit

still forum
#

I'm piping directly to file

bright flume
#

okies well try it with just the Land objects option. that should strip out all the BS and leave only buildings and such. just played with the Altis.WRP file

harsh vine
#

i have been checking all my files but i cant seem to find whats cause this issue : ```sqf
'font/is not a class ('font'
accessed)

winter rose
#

it's either a config issue or a parsedtext issue (I doubt it though) @harsh vine

harsh vine
#

ok im getting my magnifying glass nowπŸ”Ž

winter rose
#

iirc it can come from a missing font entry, beware

young storm
#

@winter rose your dynamoc sim seems to do wonders than me just tryna hide units via the module thanks!!

winter rose
#

noice

young storm
#

Also quick question anyone, i wanna have helos use their search lights at night, ive noticed i gotta switch it on manually at the second phase of editing which is the live scenerio itself,compared to vics that do it automatically using the careless setting. So one have i missed something to make helos do this? Or is there a script to put in the INIT box to make this happen? If anyone replies im going to bed so please @ me so i can see easier :)