#arma3_feedback_tracker

1 messages · Page 4 of 1

solid marten
#

ticket repro plz

gray wharf
#

@dreamy bane ↑ here's your shot!

dreamy bane
#

IDK if it can be reproed in vanilla, I found out this issue with IFA3 planes

#

but like Lou pointed out it just takes couple of line changes, to fix it

regal nimbus
#

I remember we had to workaround that in Antistasi and I don't think it was IFA planes at the time.

desert trench
#

no vanilla assets with "airplane" sim

#

needs a mod for a repro

#

but you can make a simple override mode for one of the vanilla planes

daring wagon
#

Would it be worth making a ticket for a new Eden Eventhandler? It's lacking a "entityCreated" EH

solid marten
dreamy bane
#

understood

desert trench
#

would nearGroups and nearestGroups be feasible and considerable better performance wise vs doing that in sqf? (especially with an optional side filter)

#

atm we do allGroups, side/friend relation and then distance checks, or nearEntities, get the leader and from that the group - but not ideal and quite expensive if you have a lot of groups (150+)

#

in the same vein would be allLeaders <side> and nearLeaders [distance,side]

desert trench
#

@real bronze i am asking about performance optimization

#

if you have many groups, reducing the initial set via engine itself is crucial

#

filtering via sqf is way way more expensive

real bronze
west onyx
#

@sterile nova any chance the configs of the Contact DLC Offroad variants can be applied to the base game Offroad? they are quite simply better, but players cannot use them if they dont have the Contact DLC, even if they look identical

#

contact DLC offroad has "Vehicle Cargo" transport carrier configs while the base game ones do not, for instance

#

however they're behind a paywall :\

sterile nova
#

Didn't that cargo clip with the characters in the back?

#

For contact it was acceptable since over there we could script it

west onyx
#

ah ok. i havent tested that stuff. a non-paywalled variant of the contact offroads would be good though

#

I use both base and 'covered' contact variant, players are not understanding why they can get into one but not the other, due to the model being the same

#

left is paywall, right is base game

devout wave
#

To be clear, this is about offroads that are Contact DLC assets but not exclusive to the Contact Optional Data, right? So they're still in the game outside of the campaign scripted context Reyhard mentioned, they just have normal DLC access restrictions

west onyx
#

yea they are available without running Contact DLC, but yes they have DLC access restriction. i think in this case they should not as they're a variant not a separate base model

#

and for mission maker, they are simply superior since they are vehicle cargo enabled. you can see them in menu (eden and zeus) as "Offroad (Covered)"

lavish cargo
#

ops

#

i meant this one

desert trench
dreamy bane
#

how would nearGroups determine the group pos though? by leader?

sinful kettle
#

can we get a new syntax for count? "string" count "substring"? (counts number of times "substring" occurs in "string")

gray wharf
#
"aaa" count "aa"

1 or 2? ^^

solid marten
solid marten
sinful kettle
sinful kettle
desert trench
dreamy bane
untold sky
desert trench
dreamy bane
desert trench
dreamy bane
#

Ah, I probably misread something earlier 🙂

desert trench
#

np

#

technically nearGroups and nearLeaders would be based on nearEntities but with different result filtering (and possible an additional parameter for simulation state)

fading tulip
#

seems to also be present in TB, not an extreme altitude change either

daring wagon
daring wagon
gray wharf
#

add entityDeleted for Eden… and missionEH too :p

solid marten
desert trench
#

Dedmen hope you dont mind me touching that subject 🙏 Did you ever look into the particle implementation of RV engine?
Potentially one area with the biggest FPS wins? or is this all due to using outdated DX tech?

untold sky
#

¯_(ツ)_/¯

desert trench
#

any other *takers? 😬

untold sky
#

no

inner yacht
desert trench
#

Well you kinda can but look towards and away from smoke - but even with modern hardware you can easily loose 10-30 fps with a couple in the screen view

near cedar
#

yeah turning down particle quality helps. but i also noticed vehicle smokescreens seem to impact perf less than smoke grenades 🤔
it has been a while since i've delved into it though. At one point i thought it was a CPU limitation but that needs to be verified.

#

I also think there's a difference between the smoke being very close or farther away

inner yacht
#

The Splendid Smoke Rework mod tries to fix the vanilla smoke screen issue and does a fairly good job at mitigating the issue as much as a mod is able to

sleek scaffold
inner yacht
near cedar
#

probably worth doing some sort of sensitivity analysis w.r.t performance and usability vs AI, that varies smoke properties and figures out an optimum

#

wonder if there are new PhysX particle effects that are more efficient 🤔

#

The PhysX particle feature has been removed from PhysX version 4. The standalone library PhysX FleX is an alternative with a richer feature set.
notlikemeow

#

But the fact that it is removed from 4.1 and Arma uses 4.1.1 makes me think that Arma doesn't use PhysX for particles at all...

limpid rune
#

they were tested out at one point, the property still remains but it c rashes your game if you use it now

sleek scaffold
prime moss
#

Well, the following can only be modded, but I would love to see this done via the missionfile.
So that you can create your own face with a custom texture from the missionpath and load this texture multiplayer capable on a unit.
E.g. something like this setFaceTexture "faces\bruceWillis_co.paa";

But maybe also with a cfgfaces entry in the description.ext, so in the way it is modded. I don't know how this could work best. Anyway, that would be cool for some custom characters in missions, without extra mod dependencies needed.

I haven't opened a post in the feedback tracker yet because the google account login still doesn't work. But if this would be considered useful here, I can post it there again with a new account ✌️

near cedar
near cedar
#

maybe worth adding the details of the mod and performance uplift to the first ticket?

dreamy bane
#

idea: what if you pass non-local argument to command that requires local argument, could there be error message if so?

untold sky
#

Could

unborn acorn
untold sky
#

too late, RC went out yesterday

gray wharf
#

and 2.14? :3

solid marten
desert trench
#

so 2.12 is only getting hotfixes on new/changed stuff, right?

unborn acorn
#

so this fix not incl in 2.12, correct? because i can't hear fixed sounds in RC now

untold sky
#

There will be atleast one more update to RC

solid marten
neon swan
#

It is not in RC. The RC build that is currently live is from Jan 30

sinful kettle
#

Is it possible to have an optional bool flag for getVariable to set the variable automatically if it doesn't exist?
_obj getVariable ["var", default, setIfDoesntExist]

alpine tulip
#

“It is always possible if we struggle enough” - Dedmen, most likely

devout wave
#

That would be convenient. Should it also get the public flag from setVariable?

gray wharf
real bronze
outer frigate
#

Mashallah

sinful kettle
#

I guess no

bright yacht
devout wave
#

The workaround I would advise is to wait for the update fixing it to come out. The change is already applied to the internal build as KK noted on the FT ticket, so it will be in either 2.12 (next update, currently on RC branch so probably arriving in the next month) or 2.14.

untold sky
#

RC build is from 30th as Neil said above. According to ticket KK fixed it on 5th feb

devout wave
untold sky
#

It didnt

devout wave
#

Then that's unfortunate for people who like to drive cars into rivers, I suppose.
Well, the best workaround is still to wait for 2.14. In the meantime you can always spawn a new one.

bright yacht
untold sky
bright yacht
desert trench
#

need a sanity check by someone before posting on the FT

p:\A3\functions_f\respawn\fn_getRespawnPositions.sqf

Description:
Return scripted respawn positions available for the given unit

Parameter(s):
    0: OBJECT, GROUP, SIDE or NAMESPACE
    1 (Optional): BOOL - false to return positions, true to their names (default: false) 
                  NUMBER - 1 to return positions, 2 to return their names, 3 to return show info
_target = _this param [0,player,[objnull,grpnull,sideunknown,missionnamespace]];
...
switch (typename _target) do {
    case (typename objnull): {
        _objectPositions = if (isnull _target) then {_default} else {_target getvariable [_varName,_default]};
        _groupPositions = if (isnull group _target) then {_default} else {(group _target) getvariable [_varName,_default]};
        _sidePositions = missionnamespace getvariable [_varName + str (_target call bis_fnc_objectSide),_default];
    };
    case (typename grpnull): {
        _groupPositions = if (isnull _target) then {_default} else {(_target) getvariable [_varName,_default]};
        _sidePositions = missionnamespace getvariable [_varName + str (_target call bis_fnc_objectSide),_default];
    };```
so if you supply a group, it tries to `_target call bis_fnc_objectSide`
#

however p:\A3\functions_f\sides\fn_objectSide.sqf

/*
    Author: Karel Moricky

    Description:
    Returns object side as defined in config (i.e., not affected by dynamic changing)

    Parameter(s):
    0: OBJECT
    1: BOOL - false (default) to return actual object side, true to return the default one (set in config)

    Returns:
    SIDE
*/

private ["_object","_static"];
_object = _this param [0,objnull,[objnull]];
_static = _this param [1,false,[false]];

if (_static) then {
    (getnumber (configfile >> "cfgvehicles" >> typeof _object >> "side")) call bis_fnc_sideType
} else {
    if (_object call bis_fnc_isUnitVirtual) then {
        _object getvariable ["bis_fnc_objectside_side",side _object]
    } else {
        if (isnull group _object) then {side _object} else {side group _object}
    };
};```
#
Error in expression < ["_object","_static"];
_object = _this param [0,objnull,[objnull]];
_static = _>
  Error position: <param [0,objnull,[objnull]];
_static = _>
  Error Type Group, expected Object
File A3\functions_f\sides\fn_objectSide.sqf..., line 16
 ➥ Context:     ...
    [] L45 (A3\functions_f\respawn\fn_getRespawnPositions.sqf)
    [] L53 (A3\functions_f\respawn\fn_getRespawnPositions.sqf)
    [] L19 (A3\functions_f\sides\fn_objectSide.sqf)```
#

so why is bugged here:
a) if (isnull group _object) then {side _object} else {side group _object}
or
b) _sidePositions = missionnamespace getvariable [_varName + str (_target call bis_fnc_objectSide),_default];

#

(or both 🙄)

#

[my take is b]

sinful kettle
#

_object = _this param [0,objnull,[objnull, grpNull]]; should fix it

desert trench
#

well depends if fn_objectSide is meant to accept groups or not

sinful kettle
#

well yeah that too. tho idk why they would call it if it doesn't blobdoggoshruggoogly

desert trench
#

can you do "side terrainObject/missionObject" ?

#

anyhow this list missed group

#

_sidePositions = missionnamespace getvariable [_varName + str (_target call bis_fnc_objectSide),_default];

#

this seems also bad as addRespawnPosition stores it as:

#
_varName = "BIS_fnc_getRespawnPositions_list";
_target = _targetOrig;
if (typename _position == typename objnull) then {_position = _position call bis_fnc_objectVar;};

if (typename _target == typename sideunknown) then {
    _varName = _varName + str _target;
    _target = missionnamespace;
};
_positions = _target getvariable [_varName,[-1,[],[],[],[]]];
...
switch (typename _target) do {
    case (typename missionnamespace);
    case (typename sideunknown): {
        _target setvariable [_varName,_positions];
        publicvariable _varName;
    };
    case (typename grpnull);
    case (typename objnull): {
        _target setvariable [_varName,_positions,true];
    };
};```
#

_sidePositions = missionnamespace getvariable [_varName + str (side _target),_default];

#

this should be the correct one imo

#

missionnamespace getvariable ["BIS_fnc_getRespawnPositions_list" + str (side group player),"default"];
[0,[0],[[8416.69,11340,0.00143051]],[""],[true]]

#

with
_respawn = [independent, getPos player] call BIS_fnc_addRespawnPosition;

#

TLDR:
p:\A3\functions_f\respawn\fn_getRespawnPositions.sqf
L53

_sidePositions = missionnamespace getvariable [_varName + str (_target call bis_fnc_objectSide),_default];
=>
_sidePositions = missionnamespace getvariable [_varName + str (side _target),_default];

#
dreamy bane
#

Please nevermind, it could be TADST too that's messing up things because I just noticed it has " -filePatching" in the parameters field even when I tried to disable filepatching

west onyx
#

has probably been an issue for 9 years but no one noticed 😂

west onyx
# untold sky It didnt

can community vote to delay 2.12 for a couple weeks to allow time for some small tweaks? there were a couple nice fixes/tweaks that didnt quite make the deadline (heli rollover and water engine dmg), and it seems about 6 months between updates now

#

all in favor of 2.12 being pushed back 2 weeks … @jaunty narwhal @solid marten

desert trench
#

back with some more weirdness i am not sure its a bug:
emptyPositions still considers dead bodies in the vehicle - is this intentional/meaningful or rather a bug?

like you can assign units to these positions, so technically they are not blocked and thus be considered empty, no?

paper lichen
#

When players go into a vehicle they pull the dead body out as well. So why should it be different for AI?

#

Or is emptyPositions not seeing them as empty?

desert trench
paper lichen
#

Uhm, yea that would be weird 🤔

desert trench
#

you need to use atm: {alive _x} count (crew vehicle) vs available crew positions

#

can be closed - i guess. well maybe not. would still be handy

#

this is also strange (if true). that command could benefit by some attention

#

https://forums.bohemia.net/forums/topic/236150-looking-for-advice-on-emptypositions-command/
another potentially related problem is when players get out of a vehicle, they still remain assigned to that vehicle and position - doubt this can get changed/fixed
yet if emptyPositions relies on position assignment, this would also "skew" the return

however emptyPositions also doesnt act like unassignedVehiclePositions as you can still order units to replaced the dead in the vehicle or player assigned positions

solid marten
solid marten
solid marten
#

all those ^^^ issues are long annoyances that were alleviated here and there with additions of the new commands over the years, if still true should get fixed finally

desert trench
#

(ran with 2.10 - so "turret" doesnt work yet)

#

BIS_fnc_countCrew also supports cargo. could be added to the overview as well

#

that said above checks only with empty vehicles. there is a slight chance if you had people get into a vehicle and leave again/getting killed inside, emptyPositions gets "confused"

desert trench
#

i guess desirable would be sth along the lines of:

  • total amount of free positions and per type akin to emptyPositions // or extend that command with an alive parameter
  • specific occupied like [driver,[turrets],[cargos]] with turrets and cargos to have the turretPath and cargoIndex respectively
desert trench
#

certainly some weirdness to emptyPositions

#

but also with BIS_fnc_crewCount (or just emptyPositions bugged/weird in multiple ways - probably more likely)

west onyx
#

what on earth are you working on kju

desert trench
#

to get AI to board vehicles again after respawn

azure crane
#

while we're at boarding vehicles, was the issue - where player's squad wouldn't board an IFV/APC if player was inside as a commander - ever addressed? It got pretty notorious recently but I was unable to reproduce it in 10/10 tries yet

solid marten
west onyx
#

@sterile nova what are the chances of getting these two objects (or clones) set up with "vehicle in vehicle" support?

sterile nova
#

they have no drivers so how would unload vehicles from it in vanilla?

west onyx
#

_child = cursorobject; objNull setVehicleCargo _child // child unloaded from parent

#

being able to natively load a pallet with a couple ammo crates and then sling load it, or load the HEMTT rack with bunch of stuff and then sling load it, would be pretty handy for vanilla

sterile nova
#

I know that are script commands for it

#

problem is that you would be able to lock your vehicle on such asset - without ability to unload unless there is script for it

#

it could be perhaps solved by disabling ViV on init (some vehicles are already using it) so there is a chance though

devout wave
#

Well, you can get into the vehicle that's loaded, and unload from there. You don't have to be the driver of the transporting vehicle to do it.

#

So you'd have to do something really incredible to get your vehicle stuck in one of those

#

Theoretically a crewless object like a supply crate would become stuck, since you can't get into those either, but you also can't load those in the first place without scripting, so that's not really a problem.

west onyx
#

child vehicle has an "UnloadVehicle" action from driver seat, ensuring the child vehicle wont get stuck. i believe this is native vanilla

wary mason
#

Would it be possible add so that weapons/muzzle attachments could effect submunitionConeAngle just like how muzzle attachments can effect dispersion with dispersionCoef. I guess sometime like coneAngleCoef

limpid rune
#

they have the same spread atleast I couldn't notice much of a difference with shots diag

limpid rune
wary mason
#

I remember mods like RHS had it, and its like fixed 9 pellets

#

with what I am asking, u could have a short barrel and a long barrle shotgun use the same mag, but the long barrel would have the spread be smaller

#

or add choke attachments

limpid rune
#

yeah I understood, I was suggesting reusing it to also affect submunition

#

the mention of contact is because their two shotguns have it set up (0.95 for the full barrel, 1.25 for the sawn off) but they don't do anything

alpine tulip
#

I mean, it is not that too annoying until I make a Mod that makes some changes into Eden

rose cloak
alpine tulip
#

Not-so-serious feedback be like! 😄

uncut briar
#

I remember it was quite annoying when I was working on SOGPF campaign. Still broken harold

solid marten
#

I will have a look no promises

calm smelt
#

It's almost it's forth birthday 🎂

desert trench
dreamy bane
#

I noticed if path finding distance is under 7k the path finding works but if its over 7k the pathing never works and car stays put, need repro/ticket?

#

Tested with setDestination command

sinful kettle
#

I'm pretty sure distance is irrelevant

dreamy bane
#

tested, its stuck alright

sinful kettle
#

I've tested it before and it doesn't get stuck blobdoggoshruggoogly

#

I meant at least not because of distance

#

even when you give them paths across the whole Altis it still works

sinful kettle
dreamy bane
#

wow I got this problem with VR

sinful kettle
#

VR's whole size is 8096

#

maybe you're giving them paths outside the terrain

dreamy bane
#

nope, all I gotta do is create the vehicle like 30 meters closer and it works

#

the car goes from player pos to cc marker pos

#

I'll return to this tomorrow

sinful kettle
unborn acorn
desert trench
#

setDestination can have problems for too large distance (aka vehicle wont move)

dreamy bane
azure crane
#

but that's only for agents, not normal units?

dreamy bane
#

looks like same problem with doMove. distances over 7k wont work

#

infantry moves though

alpine tulip
gray wharf
alpine tulip
#

u sure ur sayin dat word to me

gray wharf
#

…soz? 😄

#

well I meant I nuked it I mean I was not calling you nuked but omg who would do that and I swear I did not mean to offend you I'm so sorry really that's not who I am I mean—

alpine tulip
#

oki it doesn't work 🏳️

solid marten
gray wharf
solid marten
#

yes

gray wharf
#

…both 😄

solid marten
#

//--- Scene Init (ToDo: Move to engine?)

#

Lets try this ^^^

solid marten
#

Hard

#

The display exists but it doesnt

#

That's Arma

#

I fixed it locally but it wont make it to the dev for awhile as it needs both engine and data changes and data is under strict lock until 2.12 release

dreamy bane
#

did some more testing. in VR. man pathing works but not car when the distance is too long. So: (calculatePath ["man","SAFE",markerpos "st",markerpos "fi"]) works (calculatePath ["car","SAFE",markerpos "st",markerpos "fi"]) doesn't do anything

oak mauve
gray wharf
#

no

regal nimbus
#

Or probably ever, sadly.

#

I wanted to disable the amphibious flag for the Antistasi mod but it was vetoed because "players might want to joyride across lakes" :/

oak mauve
#

May I ask why? This is a pretty serious bug thonk

regal nimbus
#

I think the devs just feel ill when they consider looking at the pathfinding code :P

solid marten
#

Ah wait it is topic starter thought it was an assigned dev, then the answer is not, it wasn’t even assigned

gray wharf
#

LOLOLOLOLOLOLOLOLOLOLOLOLO—

azure crane
#

tbh all vehicles that are amphibious can't really detect obstacles, this includes boats too (numerous times I've seen them constantly trying to swim through a pier), I guess that's a cost of unit just being able to drive straight

near cedar
#

Tracked amphibious vehicles appear unable to cross rivers entirely

#

There are none in vanilla but it breaks stuff like GM, which being CDLC should probably get engine support 😛

#

They basically just wade into the water and sit in the middle of the river, and aren't able to cross

#

Repro is basically just "put down M113 on side of a river, give it a move order on the other side, watch it fail and get stuck in the river". I had tested on Livonia with GM tracked vehicles.

#

I don't have a feedback ticket for it unfortunately, although I can make one

#

(note speed)

vocal plover
#

hey I have arma 3 feedback

#

how about adding a 60 rounder mag for the mk-1 emr

devout wave
#

Because that topic turned out so well the last time you tried it

regal nimbus
#

@near cedar I think the RHS M113s get there eventually. Maybe the GM ones are lacking sufficient propulsion.

near cedar
near cedar
#

¯_(ツ)_/¯

west onyx
#

@solid marten small unrelated FYI, locking inventory does not remove the rearm user action

dreamy bane
gray wharf
dreamy bane
#

updated the zip..... forgot to save the mission

gray wharf
#

can repro - 3 vehicles

  • w/ 1 WP @ 4 km
  • w/ 2 WPs @ 4 & 8 km
  • w/ 1 WP @ 8 km

the first two move, the third doesn't - and isn't unitReady

dreamy bane
#

interesting, didnt try with WPs

#

Also PathCalculated EH doesn't trigger for the vehicle that is unable to move

vocal plover
gray wharf
dreamy bane
#

yes

solid marten
solid marten
solid marten
dreamy bane
solid marten
#

So from pos1 doMove pos2 which is 7K away? what if you have another wp in between?

solid marten
#

Could be engine limitation indeed

outer frigate
#

is 20 speed limit on ropeUnwind engine limitation or stupid people limitation?

gray wharf
outer frigate
#

ropeCut frequently doesn't work for one reason or another but its not too noticeable to me just wondering if there was a reason why

outer frigate
#

RopeBreak doesn't fire when rope is broken by being shot, bug or intentional for use with ropeDetach instead?

west onyx
#

yea i have noticed that too

#

the rope needs to be monitored

west onyx
#

<shooter> forgetTarget [<target>,<duration>];

#

-1/false to "remember" and cancel, true to apply permanently

#

the stealth mission makers would rejoice

gray wharf
#

nah - script it yourself 😛
and all the questions that would arise:
"forget for X time"

  • does the usual "forget" timer keeps on counting?
  • does the unit re-remembers them as if their knowledge had been suspended?
  • what if the unit sees them again in the meantime?

too specific for a command, too prone to error, I'd say use forgetTarget and knowsAbout to script it
I don't really see a useful application that would deserve this command

west onyx
#

im currently using "forgetTarget" to prevent AI from locking on to player vehicle through smoke countermeasure

gray wharf
#

maybe a "ignoreFor" then - visible physically but invisible on sensors and for AI

west onyx
#

yea something to that effect

gray wharf
#

so the AI is still alerted and they don't suddenly relax

west onyx
#

i dont script stealth/covert missions but i do have a use for brief periods of AI not targeting

#

i dont like fiddling with the groups/captive state to achieve stealth. seems to be an attack vector for MP bugs

#

and "forgetTarget" needs to be used in tight loop/PFH to be effective currently

#

many modern games have ability for AI to forget about the player after short time

gray wharf
#

disableAI?

west onyx
desert trench
#

rather a flag to make AI invisible for awareness could work

desert trench
west onyx
#

for repair its basically (needservice vehicle) == (damage vehicle)

#

for refuel its (needservice vehicle) == (1 - (fuel vehicle))

#

rearm is like "setvehicleammo" but it only tests the top most magazine

#

super basic. we just requested so that we can both detect and/or block vanilla service

desert trench
#

it says

Values are in range 0..1: 0: no need, 1: maximum need

#

so you are saying the docu is wrong?

#

ok so it is a range

limpid rune
#

ah allowService.. right I saw that, it being only on the ammotruck side is kinda annoying

alpine tulip
#

Workthought: onCommitted control EH

sinful kettle
#

another thought: createComposition ...

#

we need ways to spawn compositions outside of 3den and Zeus

fluid meteor
limpid rune
#

Well at least for me personally it's usually I want to stop particular vehicles from resupplying not particular resupply vehicles from being able to

near cedar
#

Hmm yeah i can think of cases in which both situations are possible, e.g. in my case i wanted to control which supply vehicle was used by an artillery vehicle. But the artillery vehicle would automatically go rearm to the nearest one, so my workaround was to use setAmmoCargo 0 on the supply trucks and manually control the resupply via script.

#

So I could just replace it with allowService, although the effect is the same as setAmmoCargo and thus redundant to have it work on the supply vehicle

#

It might make a difference to secondary explosions and stuff with mods like ACE though?

near cedar
west onyx
#

compared to bis fnc objectsgrabber/objectsmapper

solid marten
west onyx
#

@solid marten not worth it to rewrite. main thing is we can now detect and block. we can do the rewrite with custom script

near cedar
west onyx
#

selectCall could be a useful function. never liked how when using [A,B] select boolean that both A and B are evaluated

#

some syntax where only the selected value is evaluated, would be useful

limpid rune
#

Did the 'Service' eventhandler get added then?

#

oh yep:

Killzone_Kid — 29/12/2022 07:54
Next dev:
needService
allowService
allowedService
"Service" mission EH
documentation incoming

#

that was what I missed, I thought it was just the commands

uncut briar
west onyx
#

yea then we have the call overhead tho :\

#

i guess it would sort of be the same with selectcall

#

i just dont want both A and B evaluated

outer frigate
#

is there any chance of getting the ability for ground weapon holders (or any other "proximity" containers for that matter) to stop having their items appearing in inventories? enableSimulation false, setDamage 1, lock true all don't do anything like this, just stops it being able to be moved

devout wave
#

Did you try lockInventory?

outer frigate
#

Have just done that, doesn't work

#

Just ends up with it being red once you try transfer it and fail in doing so

west onyx
#

i mean thats pretty good if its red and cant transfer

desert trench
#

also cant override it (which is also good)

#

playSoundUI is the only way to play during briefing and debriefing phase any audio - quite unfortunate its not more flexible. its very powerful for voice over or music use in these phases
or also mid mission to make sure you have best volume to understand conversations

#

yet if people want to skip or mute, cant be done atm is seems 😦

solid marten
#

@desert trench sell it to me! There is no object for this kind of sound but it can be found. What are the benefits of this kind of sound vs all other sounds we have already?

desert trench
#

@solid marten as said only playSoundUI works in debriefing phase or debriefing phase, and its best for conversations atm - only downside is you cannot stop/cancel or adjust their volume (only with the next event)

gray wharf
desert trench
#

should yes (aka if same tech is used as playSoundUI is using)

west onyx
#

@solid marten which dev to look at broken weapons? PCML top attack mode is ineffective, most likely bugged

near cedar
#

honestly pcml is not working properly in general, it keeps hitting the ground because of its exaggerated sine-wave like trajectory

desert trench
#

probably something from reyhard in general. might be config setup or engine tho

#

is it a bug that dynamic sim only works of the canTrigger state of a vehicle or should it also check the crews canTrigger state?

solid marten
regal nimbus
#

It's kinda hard to tell. It looks visually like it's working but does very little damage.

#

Like the subprojectile is missing the target.

#

I don't really know how those things work though.

near cedar
#

Yeah. Subprojectile seems to go at an angle that either misses or hits sloped armour

#

It triggers potentially too quickly (easy to see with splendid cam)

#

And like I said, the trajectory is prone to hitting the ground, especially the first dip after launch in direct attack mode (and maybe top attack too but i don't remember). (easiest to see in VR)

west onyx
#

when i get home ill do some drawline3d stuff with the submunition if someone doesnt beat me to it

#

basically the top down mode does about 10% of the damage that regular mode does against armor, which seems counter intuitive

#

like just makes the missile do 90% less damage

west onyx
desert trench
#

is there a particular reason why createVehicleLocal does not have the newer createVehicle [] syntax which is way more efficient as the engine doesnt have to find a suitable position?

sinful kettle
#

laziness 😅

west onyx
#

i have thought about that a few times, but never brought it up. figured it was just my OCD

#

local flag in createVehicle so we can just ignore it entirely

solid marten
desert trench
#

yep would be great 👍

alpine tulip
#

Workthought: a command to make AI plane/heli go anywhere forcely, even if I order them to do kamikaze, will do

#

Like setDriveOnPath for more simulations

west onyx
#

id be happy if we can just set their Z axis offset so they dont ram the ground when strafing

#

they are aligned to ASL 0 on strafe, so performing a gun strafe at any elevation they will invariably ram the ground

dreamy bane
west onyx
#

no

#

when they are strafing, its like _targetpos = agltoasl getPos target and then alignment is ASL, so they crash into terrain

#

outside of strafe they can avoid terrain, but when attacking they do not

dreamy bane
#

since we are talking about this I have also seen plane crashing on the side of a aircraft carrier when using auto-landing

#

that happens if you start the landing from too low..

#

(starting landing above the carrier, but not high enough)

limpid rune
#

Here's a strange one I noticed.
'GetOut' eventhandler doesn't seem to fire when the 'Unload Incapacitated' action is used (ie. unconscious units are inside the vehicle)

getOutMan set on the units works but getOut on the vehicle does not

#

Can't seem to find an existing ticket on the feedback tracker

solid marten
#

Yeah make a ticket, that’s odd both EHs should be triggered by the same event, one could be missing or something else

outer frigate
#

is ropeBreak eh supposed to be fired when rope is cut by being shot out too as will send a ticket if so

solid marten
#

make a ticket with repro, sounds like it should fire

outer frigate
#

roger i shall do so later today unless @west onyx would like to

west onyx
#

maybe there should be a RopeCut one since the behaviour is slightly different. with RopeBreak the rope is dead, its almost like "Rope Killed" event

#

with RopeCut the rope is still alive, just not connected

#

the rope creation is handled, but it would be good to detect that a rope was cut but still exists

#

when a rope segment is destroyed a "RopeCut" event should fire with the rope as param, with ideally the old child object passed as well

#

so we can see what was disconnected

#

speaking of which, can rope segments take event handlers

gray wharf
#

*dun-dun-dunnn*

paper lichen
#

Why not add param in ropeBreak that's true/false depending if rope got cut?

west onyx
#

currently ropeBreak doesnt detect the rope being cut at all

#

ropebreak is just misnamed, it is more accurately "ropedestroyed" or "ropekilled"

paper lichen
#

Yea so why not add a param to it instead of creating a whole new event. Seems less work.

#

Well there are plenty of things mis-named.

west onyx
#

yea that could work. not sure how it would affect existing mods though. we would now have an event handler firing where it didnt used to

outer frigate
#

rope killed parameter added at the end sounds like itd be the easiest "fix"

paper lichen
#

As it's not existing right now no change as they wouldn't use that variable.

outer frigate
#

though cant you just check if rope object is objnull when its fired

paper lichen
west onyx
#

i just did some rope stuff a month or two ago and i couldnt tell you what would happen if the ropebreak started firing when rope segment is cut 😄 no idea at all, as rope guys have used it as more of a "ropekilled" event

paper lichen
#

Yea might be saver to make new event then. Only thing I'm thinking about what use does it give? As you are cutting it by function, so whatever happens after you can do. Sure it's more useful especially for script/mod compatibility.

outer frigate
#

ropes can be shot out which isnt easy to detect

paper lichen
#

Yea but that would be a ropeBreak right? Or is ropeCut not referencing to cutting via command?

west onyx
#

so ropecut just removes a rope segment, but doesnt destroy the rope

#

shooting a rope segment is just like ropecut

paper lichen
#

Ah so it leaves it on the ground

outer frigate
#

im confused where we are in this conversation

west onyx
#

yea just laying there

paper lichen
#

I see...

#

So ropeBreak is when rope is gone, and ropeCut when it's on the floor.

west onyx
#

yea so we have the ropedestroyed event (called ropebreak), but nothing for when the rope is cut by gunfire or whatever

#

so the parent vehicle can become detached from the child with no event detection

paper lichen
#

But shooting the rope cuts it then? I've never done it. But if that's the case yea the naming is weird and an new event would be useful.

solid marten
#

so if you attach rope and pull out and it detaches does rope break fire?

west onyx
#

killing a rope segment does not fire the RopeBreak event (for instance with gunfire). in my opinion its too late to make this change to RopeBreak due to mods relying on the Ropebreak to act more like a RopeDestroyed

solid marten
#

does ropeCut command trigger rope break EH now?

west onyx
#

i am testing now for the first time in 2.12 and it seems to be firing for both

#

when i was working on ropes in 2.10 it wasnt firing for the gunfire cut (never tested ropecut)

spring sorrel
#

Hi, since the 2.10, the thermal imaging became a little bit too buggy so i wanted to know if something was planned to patch these problems. Actually like this report : https://feedback.bistudio.com/T167451 the thermal imaging is now almost completely useless and i'm not the only one in that case.

When close to the ground, it's almost impossible to distinct a man in the grass from the grass, because the grass, glow more than a human and the time doesn't matter "day/night".

When far from the ground, it's very difficult or even impossible to distinct a man from a little rock. The terrain is loaded around your position, but start to be less detailed more further and i think this is a question of "performance", but this is a problem because you are not able to distinct a head from a little rock, because the rock exactly like the grass glow more than a head and the "day/night" doesn't matter.

In conclusion, since the 2.10, use the Thermal Imaging is almost completely useless and is even worst than the normal mode, because you don't have the time to compare the rocks to a human especially when you are viewing this through a drone. Suggestion : I think, you should add a new option in the difficulty called "Thermal Imaging Type" where we can select which type we want, so the users like me that want the 2.08 back will be happy and the others can still use the 2.10 version.

west onyx
#

TBH i dont have a problem with thermal nerfed. anywhere its available it gets abused

azure crane
#

only issue I have with new thermals is weird clipping/blinking on dust/smoke particles and that on longer distances it has a weird graphical artifacts like you would get with some textures when ambient occlussion is enabled (but this is somehow fixed when using A3TI)

devout wave
outer frigate
west onyx
dreamy bane
solid marten
#

you sure this is a bug?

dreamy bane
#

but definitely not a good thing

regal nimbus
#

I dunno, I feel like if your main problem is that vehicles won't path over 7km then you haven't been doing a lot of AI work :P

dreamy bane
regal nimbus
#

When you do, you will discover that vehicles cannot consistently drive a 500m road path

dreamy bane
#

oh yes that, i know....

#

well they move to some direction at least 🙂

regal nimbus
#

Well, sometimes

#

has this issue with some GM trucks...

#

Original Antistasi has a fairly simple workaround for the 7km thing. You define a handful of crossroad points on each map, and if a path is too long you throw in one or more of those.

#

We replaced that with some super fancy shit

dreamy bane
#

sounds like you got it working

regal nimbus
#

I didn't get the GM trucks working yet

#

Or bridges with CUP vehicles (and a few others). Or making amphibious APCs stop humping buildings. Or making an HEMTT drive down that road into Therisa without randomly swerving into a tree.

dreamy bane
#

yea not easy

desert trench
dreamy bane
desert trench
#

in what sense?

#

you can use the road network for the WPs

#

in the BIF there are couple of algorithms to find shortest route and such

dreamy bane
#

that's one option. i was thinking of the gulf in Altis map, need to make WPs around that

#

but that's only if the devs wont help here 🤞

solid marten
#

help how?

dreamy bane
solid marten
#

I am not going to go into much detail, there doesn't seem to be a limit on distance. There is however cost associated with path calculation that takes a lot of different params including even the gradient of the the road. So when the distance is great the cost goes up and if it goes over certain threshold it is rejected as too costly. Will devs fix this? No there is nothing to fix, it is not a bug.

dreamy bane
#

ok well I appreciate the answer KK

#

though I was hoping a script command to set that max cost

desert trench
#

There is a reason its not done - aka its too expensive calc

#

You can freeze the game if you have WPs too far part through complex terrain

dreamy bane
#

editor's decision 😄

solid marten
#

no

near cedar
#

There are cases when vanilla wheeled and tracked vehicles will stop randomly in the middle of a road and refuse to move further

#

It happens incredibly randomly and can behave differently between server and client

#

And issues when vehicles overshoot on turns and crash into kerbside objects

#

Honestly would be nice if devs/QA could make a substantial pass over AI driving logic, because it can be immensely frustrating at times

#

I've had GM M113s try and drive up house walls in Malden when left without waypoints

#

Vehicles also know exactly who shot them and from where, so if you shoot out a gunner then the driver will drive up all the way to find you and then park next to you in anger 😂

near cedar
west onyx
#

@solid marten unitIsUAV player will be able to detect if player is remote controlling a uav in 2.14?

west onyx
#

also is there a difference between the detection in cursorobject vs getcursorobjectparams ? there are times when getcursorobjectparams returns an object where cursorobject fails to

#

for instance when looking at the back rest of a camping chair

solid marten
desert trench
#

is blockAIVisibility (config value) 1 by default or did BI not able AI viewblock for any effect?

#

as in configs there is only =0 set (for all non smoke FX - which indicates =1 is the default if not set)

#

seems to be the case indeed

sinful kettle
#

idea: OOP in SQF with little effort using hashmaps, with destructor support:

_class = [
  ["constructor", 
    {
      _thisObj call ["SomeMethod", _this] 
    }
  ],
  ["SomeMethod", 
    {
    _someObj = createVehicle ["bla", [0,0,0]];
    _thisObj set ["mVehicle", _someObj];
    }
  ],
  ["Method", {...}],
  ["mVehicle", objNull],
  ["destructor", {deleteVehicle (_thisObj get "mVehicle");}
];

_obj = createObjectFromClass [_class, [_constArg1, _constArg2]];
_obj call ["Method", _args];

under the hood, _obj is just a hashmap (typeName _obj == "HASHMAP"). createObjectFromClass simply does this:

  1. createHashmapFromArray _class
  2. calls the "constructor" (see below for call behavior)
  3. sets a flag on the hashmap in the game data: map.treatAsObject = true

we also need an overload of call: _hashmap call ["method", args]. the only difference between this and normal call is that it also defines a magic variable _thisObj when it calls the method

and finally, when the game wants to destroy the hashmap, if map.treatAsObject is true, it calls the destructor (if it exists)

uncut briar
#

feels weird, arbitrary and can be done with macros / wrapper funcs.

sinful kettle
#

I know, except for the destructor

#

that was the sole reason I proposed this

#

I was actually gonna write this in like 10m using a couple of very simple macros and post it on the github. then I realized that without destructors it's just pointless

sinful kettle
uncut briar
#

some sort of EH to fire when variable is destructed would be more generic.

sinful kettle
#

yeah but that would add way too much overhead

#

thousands of variables are being destroyed in the game every second

sinful kettle
#

this one is not needed tho. we can do this ourselves

outer frigate
#

hiding gui in splendid camera doesn't hide script errors, intended or ticket time?

rose cloak
#

script errors aren't splendid camera gui, though. And not any other scriptable gui for that regard

near cedar
#

I would say intended and desirable

#

If you don't want script errors then turn off the launch flag

outer frigate
devout wave
#

If you don't want script errors just fix your script 5head

solid marten
#

script errors shouldn't show in stable only dev

devout wave
#

Not to cast doubt or anything but I've caused a lot of script errors in my time and almost all of them were on stable

gray wharf
outer frigate
#

tbh
script errors disabling without having to go back to launcher would be nice because i really dont care for other peoples script errors inside while true loops

#

buuut not a huge deal

gray wharf
outer frigate
solid marten
#

they should be disabled by default on stable

outer frigate
#

I never turned script errors on intentionally either but I would've done by now regardless

west onyx
#

i always nope out of a server if i get hit with a wall of script errors on join, usually a bad omen

outer frigate
#

this was splendid camera not being considered when the mod maker made the mod

solid marten
#

eh?

outer frigate
#

some error related to not having something equipped being looped over and over when in splendid camera

#

shrug

#

not the biggest issue in the world but it didnt seem intentional for splendid cameras hide gui to not hide script errors

#

if it is intentional for them to not be hidden then i can be ignored

sinful kettle
dreamy bane
#

i like it

#

i have seen some OO implementations for arma before

livid sleet
sinful kettle
#

after about ~16M / 1000 / 60 / 60 ~= 4.44 hours it won't be accurate enough to represent integers anymore

#

so there's not really anything to fix blobdoggoshruggoogly

livid sleet
#

Ah I see, it's the toFixed as well

#

Yeah, just going crazy over here lul

solid marten
#

what's the use of diag_frameNo on servers in this case

livid sleet
#

CBA uses it for CBA_fnc_execNextFrame but it seems like for the most part its fine as long as you don't make a destructive operation loosing precision, just being dumb not thinking about how it's precision works after X amount of time

desert trench
#

p:\a3\functions_f\debug\fn_isdebugconsoleallowed.sqf

#

has

#
// == SP MODE ==

if (!isMultiplayer) exitWith
{ 
    allDisplays find findDisplay 313 in [0, 1] // 3DEN preview
    ||
    {allDisplays find findDisplay 26 in [0, 1]} // 2DEN
    ||
    {(configFile >> "enableDebugConsole") call {isArray _this || {isNumber _this && {getNumber _this >= 1}}}} // allowed by mod
};```
#

why is the mission specific parameter (enableDebugConsole in desc.ext) not taken into account for SP?

#

this doesnt make sense to me. so you are forced to do testing via Eden, or need a config mod to enable the console globally

#

what am I missing with this design?

#

(the check is done below but just for MP)

desert trench
#
TARGET = XXX findNearestEnemy POSITION;
WAYPOINT = GROUP addWaypoint [position TARGET, 0, 1];
WAYPOINT setWaypointType "DESTROY";
WAYPOINT waypointAttachVehicle TARGET;```
#

is it considered a bug if the WP position remains on the initial location and doesnt follow the attached target? (even with knowsAbout level/direct view on the target)

west onyx
#
waitUntil {diag_frameno > _f}```
solid marten
#

since making string alternative is not an option due to performance

untold sky
#

Can't reset because that would break every mod that tries to use frame numbers for time reference 😄

sinful kettle
#

You'd still be conerting it to a float for comparison, etc.

#

You could use extensions but that too is meh

solid marten
untold sky
#

Mission makers shouldn't decide whether to break mods. neither the mod authors nor the people playing the mission would know why something impossible just happened and went wrong

#

string would be slower, but way fast enough still

#

I always kinda wanted to have 64bit int datatype. but implementing all the commands for it yuck

regal nimbus
#

You could wrap at 16M :P

solid marten
#

Right so we never added anything that had potential to break someone’s mod

regal nimbus
#

Like behaviour's probably broken there anyway.

#

(this is a pretty terrible idea)

untold sky
#

Wrapping is just as bad as manual reset command.
That would turn quiksilvers example into a (almost) endless loop.
16m would be brokenish- but quiksilvers code would still not break

regal nimbus
#

Yeah I think you'd need an extra command/syntax either way.

rugged nova
#

Hey can we get a similar alt syntax to canSlingLoad?

sleek scaffold
#

old Mods/missions break all the time anyway, the community will update them if they are still being used or if not active modders will upload a fixed version anyway, like it already happens with outdated mods like Enhanced movement which has several "community fixes"

#

Moving forward regarding performance and much needed features is far more important than old mod compatibility IMHO. "Old mods compatibility" can also be too easily used as an excuse

untold sky
#

There is a difference between "this is broken and doesn't work anymore and has to be fixed" and "when someone uses this script command (which is rare), some mods will break in a weird way that noone expected and that cannot be detected, diagnosed or work-arounded"

The first one is a clear issue, that is usually easy to figure out and then fix.
The second one happens randomly every few months and makes players angry at mod dev's who aren't at fault, and makes mod devs rip their hair out

So far I haven't seen anyone actually say that they have a problem that needs fixing. If that time comes and we actually have a usecase, we can think about solving for that usecase.

after running the game for 4+ hours
Quiksilver's example might wait a few more frames than desired, but his code is scheduled so it already does that anyway.
CBA example might make execNextFrame skip a few frames. ExecNextFrame is in vast majority used to just delay something by a short as possible time, it being delayed for a tiny bit longer won't affect most things. And if someone finds out that it does, it would be solved very easily with a variant that returns the number as string, which will not break any mods.
Actually if I see that right it doesn't even make it skip, or one frame at most.

#

Moving forward regarding performance and much needed features
None of that applies here

sleek scaffold
#

If none of that applies in this particular case then please disregard what I said

regal nimbus
#

Hmm. That one might explain why ACE actions get really slow after a few days of server uptime.

#

Although I'm not sure why they'd be using frame counts rather than time...

livid sleet
#

That would likely be CBA_missionTime which does have an open PR (that's been open for years at this point) attempting to fix the precision issues after a long period of uptime (7+days)
https://github.com/CBATeam/CBA_A3/pull/1324

wary mason
desert trench
#

Why not introduce a 2nd diag_tickTimePrecise ?

tropic jewel
#

diag_tockTime

west onyx
#

as a suggestion tho, “EachFrame” and “Draw3D” events should have frame number in params as special variable

#

“_thisframe”

untold sky
untold sky
#

We have the system time stuff already, doesn't that also return milliseconds?

#

I wonder what would happen if we just change the scalar type from float to double XD
notlikemeow
(Lots of things would convert back to float and loose precision) but for things like this, it may work 🤔

west onyx
#
addMissionEventHandler [
    'EachFrame',
    {
        hintsilent str _thisFrame
    
    
    }
];```
outer frigate
#

any chance in this being looked into or is there no possibility of it being added so no point in ticket?

desert trench
#

No alive in 10000 ms, exceeded timeout of 10000 ms
No alive in 21125 ms, exceeded timeout of 10000 ms
No alive in 31859 ms, exceeded timeout of 10000 ms

#

wasnt this timeout to be increased?

#

(at game start)

untold sky
#

there are multiple places with different timeouts

desert trench
#

alright. is this to be posted on the FT with logs?

untold sky
#

I need to know what it does during the freeze, and most likely need to reproduce it too

alpine tulip
#

Showerthought: Is it reasonable to update the engine so PhysX object can have collision with attached to object?

I just want this in more authentic way, currently we don't have a proper collision in such case notlikemeow
#general_chat_arma message

regal nimbus
#

Ran into this: https://feedback.bistudio.com/T123355
I suspect this is destructive for our use cases (large handleDamage functions on AIs, some fired EH hacks). Any chance of it getting fixed soon?

sinful kettle
#

pretty sure Dedmen fixed it

rugged nova
sinful kettle
#

no. he said so himself

rugged nova
#

Ah nice

rugged nova
alpine tulip
#

Hmmm. At least a function is good

rugged nova
#

Currently I have a function, but it's kinda bulky calling it every frame to clamp the angle.

sinful kettle
#
#define CLAMP(x,a,b) (((x) max (a)) min (b))
solid marten
#

clamp works too

#

Having said that, if the speed improvement is insignificant in comparison with macro provided by 🐆 we’ll just leave it

#

And since it would take array for the range, that alone might make it not worthy

rugged nova
#

as Angles need to be between 0 and 360

#

if you pass in angle of 400 the macro will return 360, which is not the correct angle of 40

sinful kettle
#

which is very easy to correct: (a % 360 + 360) % 360

#
#define CLAMPANGLE(x,a,b) (((((x) % 360 + 360) % 360) max (a)) min (b))
rose cloak
#

Well, i'm still not sure that would work with, say, -1000 🤔

sinful kettle
#

(-1000 % 360 + 360) % 360 = 80

regal nimbus
#

IIRC Arma usually does the periodic range adjustment itself so you can normally skip it.

rose cloak
#

a%b returning between -b and b is hella clunky

regal nimbus
#

You can always do a%180 :P

rose cloak
#

Well, the original question was to, say, clamp 1000 degrees between -25 and 40 degrees 🤷‍♂️

regal nimbus
#

That's kinda poorly defined. Like where would you want 190 degrees to end up?

sinful kettle
#

though when you think about it clamping an angle can be ambiguous

#

e.g. let's say I want to clamp 50 between 10 and 350

#

do you say it's 50, or 10?

#

it can be both depending on how you look at it

rugged nova
sinful kettle
#

that's subjective

sinful kettle
rugged nova
#

I have already implemented the commands I have requested, heck I even provided the source code in the feedback

rugged nova
rose cloak
#

🍿

sinful kettle
rugged nova
#
/*
 * @brief returns a value between 0 and 360 degrees
 * @param angle float angle in degrees to be AxisClamped
 * @return float clampedAxis
 */
float clampAxisInternal(float angle)
{
    angle = std::fmod(angle, 360);

    if (angle < 0)
    {
        angle = angle + 360.0f;
    }

    return angle;
}

/*
 * @brief returns a value between -180 and 180 degrees
 * @param angle float angle in degrees to be normalized
 * @return float normalized angle
 */
float normalizeAxisInternal(float angle)
{
    // make sure angle is with in (0,360)
    angle = clampAxisInternal(angle);

    if (angle > 180.0f)
    {
        angle = angle - 360.0f;     // in the range of -180,180 normalized
    }

    return angle;
}


/*
 * @brief clamps an angle in degrees between min angle and max angle.
 * @param angle float current angle measurement
 * @param minAngle float min allowed angle to clamp to
 * @param maxAngle float max allowed angle to clamp to
 * @return float normalized angle
 * @warning coterminal angles are handled, 400 -> 40
 */
float clampAngleInternal(float angle, float minAngle, float maxAngle)
{
    float deltaAngle = clampAxisInternal(maxAngle - minAngle) * 0.5f;
    float centerAngle = clampAxisInternal(minAngle + deltaAngle);
    float centerDisplacement = normalizeAxisInternal(angle - centerAngle);

    // clamp values here
    if (centerDisplacement > deltaAngle)
    {
        return normalizeAxisInternal(centerAngle + deltaAngle);
    }
    else if (centerDisplacement < -deltaAngle)
    {
        return normalizeAxisInternal(centerAngle - deltaAngle);
    }

    return normalizeAxisInternal(angle);
}


/*
* @brief clamps all components of a vec3 between 0 and 360
* @param x float x component
* @param y float y component
* @param z float z component
* @return vec3 clamped vec3
*/
vector3 clampInternal(float x, float y, float z)
{
    return vector3{clampAxisInternal(x), clampAxisInternal(y), clampAxisInternal(z)};
}
rugged nova
#

One on the reasons why linear conversions doesn't work well

#

it works if the angels are in the normal range of 0 to 360, but it fails once you go out of the range

#

oh, 10 and 350 are the same

#

not 10 and 50

sinful kettle
# rugged nova yes

no they're not. read what I said again. as I said, clamping an angle is subjective

rugged nova
#

I know, you said 10 and 50

#

I meant 10 and 350

#

also 10 and 350 aren't coterminal. it would be 10 and 370 that are

solid marten
#

how 10 and 350 are the same, one is 10 degrees one way another is 10 degrees another way

rugged nova
#

it's wrong (I'm wrong)

solid marten
#

what is wrong

rugged nova
#

also 10 and 350 aren't coterminal. it would be 10 and 370 that are

#

i messed up and said 10 and 350 are conterminal

#

which is incorrect,
10 and 370 are conterminal

sinful kettle
# sinful kettle

actually this thing is not so subjective if you define a direction. which naturally should be in the positive direction. so the answer is 50. clampAngle [50,350,10] would be 10

rugged nova
#

yes

devout wave
gray wharf
#

thanks - removed 😄

west onyx
#

way to get the "muted" state of a player

#
// from client
_muted = muted otherplayer;
#

would allow some ability to filter out text chat from the voice-muted player.. so player can apply both voice mute and text mute

gray wharf
#

isMuted* plz

untold sky
#

Do we have some command that returns playerinfo including pings and bandwidth values that are on map screen?
Can we add it to that?

sinful kettle
#

iirc it was called allUsersInfo or something

#

getUserInfo meowsweats

untold sky
#

sad, as mute is also on map screen next to these.. but ugly eh probably good to make separate command :sad:

west onyx
#

is there anything "getUserInfo" could return if called from client?

untold sky
#

Well client also displays the users ping and bandwidth info on map screen.
So client also has that info

#

not sure if client has headless,clientstate,adminstate info. But I think besides that it should have all the others

solid marten
#

getUserInfo would be a good candidate for it

west onyx
#

i would just allow "getUserInfo" to be called from client and insert nil returns to those server only values ... then add muted state on the end

west onyx
#

on the topic of players and such, this is a bit of code i see frequently and wish there were a better method...

#

issue is that headless clients appear in "allplayers" list

#
allPlayers - entities "HeadlessClient_F";```
#

ideally headless clients would be removed from the allplayers list

#

since we can more precisely access them with the entities "headlessclient_f"

untold sky
#

There might be code depending on them being in allPlayers though :/

devout wave
#

new command: allPlayersReal ...

rose cloak
#

allHeadedPlayers

vocal abyss
#

Aside from actual players and Headless Clients allPlayers also comes with Virtual Spectators and Virtual Curators, i.e. it returns all occupied slots in the lobby.
So technically you actually need something like allPlayers select {!(_x isKindOf "VirtualMan_F")} instead of allPlayers - entities "HeadlessClient_F". Of course, the latter usually works too, but only because except for Headless Clients, VirtualMan_F instances are rarely used by the community.
I probably should have updated the Wiki when I figured this out, but it's so niche ...

gray wharf
#

getPlayers [getRealUnits, getVirtualUnits, getHC] 😛

untold sky
#

I think the bots are utilizing AI to quote and reply to comments now 😄

gray wharf
#

human farms > AI :p

solid marten
#

AI can’t « but we can need to it ». Agree with Lou

vocal abyss
#

Interesing

solid marten
near cedar
west onyx
#

players west, players east

devout wave
#

Well, that was a joke about engine limitations and boundingBoxReal. I have no idea if a new command is really what's needed.

oak mauve
#

I found a bug, heavy vehicles don't skip waypoints they can't reach like light cars.
If, for example, you place several waypoints on the water and several on the ground, a light car will skip those on the water and start moving to those on the ground. But other vehicles, such as tanks or APCs, will simply stand idle

gray wharf
#

thanks, cleaned

outer frigate
#

Any chance of getting insert functionality modified to take -2 for example as inserting 1 value in from the back and so on?

private _arr = [1,2,3];
_arr insert [-2, [4], false];
_arr //[1,2,4,3]``` for example. currently returns `[1,2,3,4]`
#

cleaner than _arr insert [(count _arr) - 1, [4], false]; etc

west onyx
#

cant use set for that?

outer frigate
#

nope as want to preserve whats already in the array

west onyx
#

would it make sense for "EachFrame" mission event to have special variable with frame number

#
addMissionEventHandler [
    'EachFrame',
    {
        _thisframe  // 24792
    }
];```
alpine tulip
#

Isn't it diag_frameNo?

gray wharf
devout wave
#

insert works for them, they just want the same negative index syntax that was recently added to select, for convenience

outer frigate
#

^ it'd just be a nice feature that's all 🤷

gray wharf
#

I suggested a negative index for select and got denied, so don't keep your hopes up

devout wave
#

.........it was added in 2.12

outer frigate
#

clearly someone else needed to suggest it kekw

gray wharf
#

@solid marten you lied to me

#

(yet thanks for adding 😁)

west onyx
#

KK like a horse, need to know how to whisper to it

#

how to lead a horse to water, make it drink, etc

devout wave
#

I'm about to make a ticket asking for difficulty setting overrides in description.ext, but I just thought I'd check whether that's an "instant no" first. I know there are some things that are just not possible to do in mission config because of enginestuff.

untold sky
outer frigate
#

roger thank u i will do when im home

solid marten
outer frigate
#

is it possible to get grenade throwing re-enabled underwater or is this a design choice that wont be reverted?

#

it was a thing years ago but for some reason was removed and dont quite understand why

solid marten
#

have you ever tried to throw grenade under water?

devout wave
#

If you want to self-annihilate that's your business :U
I think the main issue is probably that it also stops you dropping chemlights

solid marten
#

or do you know someone who did and lived to tell the tale?

outer frigate
#

I also tried to enable it via modifying put config (or is it throw? either way was the correct one) and also did not work -- no chemlights underwater is quite annoying

solid marten
#

do they work under water?

outer frigate
#

yes

gray wharf
#

but can you throw a grenade above the surface?

#

also, popping a smoke from underwater is a nice thing to do too

#

bring back underwater grenade throwing! so people can accidentally kill themselves too!

outer frigate
#

those do not work underwater
but given you can just throw them into the water i dont really see why it's a thing to not be able to throw them underneath 🤷

solid marten
#

because the water won’t let you swing?

outer frigate
#

yeah it will

solid marten
#

ok

devout wave
#

There's no way you can throw them very far, but you should be able to basically drop them at your feet

solid marten
#

drop yes but please don’t change the subject of throwing

outer frigate
#

you could still "throw" it, it just wouldnt go very far

devout wave
#

I think "throwing" was used in the sense of "use the throw weapon to dispense a grenade" not in the sense of getting it to go further than 3 feet

outer frigate
#

your arm going over your head with a grenade in hand and grenade being able to leave said hand

tropic jewel
outer frigate
#

not lobbing it 50 meters

solid marten
#

no sorry we are not taking about « throwing » either

#

throw - swing and release

outer frigate
#

you can swing and release underwater it just doesnt go far 🤷

#

slower animation and lower range

solid marten
#

then you can’t call it a throw, dunno what it is

outer frigate
#

a slow throw

#

a weak throw

solid marten
#

dropping yeah could work

tropic jewel
#

put

outer frigate
#

either way
you are still capable of dropping objects underwater

solid marten
#

but no idea how it is handled in the engine and if simple to add

outer frigate
#

whether a new animation for that is possible at this stage in development i do not know which is why i said slower animation 🤷

outer frigate
gray wharf
#

I think the distinction is between "throw" (arm the grenade and make it live) and "drop" (inventory drop)
I don't mind if the animation remains the same, just that with water resistance the grenade should stop after 50cm 😄

solid marten
solid marten
outer frigate
#

fair

gray wharf
#

"just slow down the anim!" 😁

#

why do I have a red dot on my chest—

tropic jewel
#

literally let the put weapon use grenade mags? not even just underwater, all the time xD
can finally just drop a throwable.

devout wave
#

That's a nice idea in principle, but with how put works, the action menu being suddenly full of chemlights and smokes would be a potential concern

outer frigate
#

let throw use explosives too then 😇
||/s||

devout wave
#

I had assumed at the beginning of this discussion that grenades were already affected by water physics and would stop when entering it (by whatever means). Surprised to discover that they actually aren't, and instead behave basically the same as if they were in air. IMO that should be fixed, and if it was fixed then just enabling throw underwater would be fine. Obviously that's likely to be considerably more of a challenge, though.

outer frigate
#

in the absence of being able to alter drag underwater (which i assume wont happen given my request for being able to alter gravity was denied and its a similar principle) then just being able to throw shit underwater would be nice

uncut briar
#

Or basically when surfaceIsWater is true

#

You can't even place explosives i ankle deep water.

#

I had to script in water explosive placement for SOGPF.

near cedar
unborn acorn
stone tree
west onyx
hallow sun
west onyx
#

yea a formal method would be good

limpid rune
#

other way is animations can disableweapons but its not a good solution unless the idea is to like lock the player in place or something

untold sky
#

Underwater throwing with just a low power throw/drop might be enable-able in engine.
But then you still have the issue that we only have above land throwing animations?

tropic jewel
#

use put animation?

outer frigate
#

is there any interest in fixing icon config path requiring a preceding backslash too or is that too high effort for too little reward

untold sky
#

little reward

outer frigate
#

valid

west onyx
#

if distance commands took string and used markerpos when string detected

#

player distance "respawn_west"

west onyx
#

also handy, a sort param for "nearRoads"

#

player nearRoads [50,<sort>];

desert trench
#

What is the intended order AI should get into vehicles if you order them (get in) but without position?
I assumed its 1) driver 2) gunner 3) commander 4) other turrets 5) cargo

however it seems 1) driver 2) commander 3) other turrets 4) gunner 5) cargo

#

There seems to be no way to influence that via config values

#

Aka is it bugged? Or the get in order outline is intentional?

regal nimbus
#

moveInAny docs claim driver->commander->gunner->other turrets->cargo

#

But the getin waypoint could be completely different for all I know.

desert trench
#

i am testing with GL orders, but probably should behave the same way

near cedar
#

@desert trench fwiw if you move in units via 3den then it's always driver > commander > gunner > other turrets > cargo

#

although i might have seen exceptions with respect to gunner and other turrets when dealing with mod vehicles... unsure.

desert trench
#

for our tanks its

driver-commander-loader-gunner-other turrets (if available)-cargo (if available)
or even
driver-commander-loader-radio operator-gunner

#

my best guess its based on the turret setup structure/turret inheritance as there seems no config parameter to influence that (not via commanding or proxyIndex)

#

would it be possible please to check how the engine determines the logic, so it can be put into the wiki? 🙏 (moveInAny should be a good starting point to find it)

alpine tulip
#

Walkthought: is it a good idea to have an option for attachTo, which tries to follow the bone/memory point rotation?

Which I mean, not the bone that rotated but the axis of it. It is hard to explain using my poor vocab but, let's say,

If I have a door bone, which has no child bones, so currently it is not possible to rotate the attached object while I wanted to rotate it with the door (AFAIK)

#

Also, another suggestion: throw a selection (visual LOD?) and returns influenced bone/memory point

dreamy bane
#

The new groups command is nice ty for that devs. could it also be possible to have alternative syntax that can return groups of more than one side?

#

like groups [west,east]

sinful kettle
dreamy bane
sinful kettle
#

the perf won't be much different

dreamy bane
#

everything in engine side is bit faster though

alpine tulip
#

Thank you KK

daring wagon
#

Very nice indeed

solid marten
#

Someone posted awhile ago about enableEnvironment not muting wind on top of Tanoa volcano, should work from next dev test it please

#

Also script error on mission selection reported here should be fixed

dreamy bane
west onyx
#

players [west]

#

or to get headless clients players [sidelogic]

#

east and west players [east,west]

#

so we dont have to do this awkward line _players = allPlayers - entities "HeadlessClient_F";

dreamy bane
#

would also be nice if "players" command wasnt delayed like allPlayers is ("mission start in multiplayer"). not sure if that's possible though?

solid marten
gray wharf
#

setMarkerZIndex incoming? 😄

solid marten
#

setMarkerDrawPriority?

alpine tulip
#

Z is better IMO, priority could mean something else too

solid marten
#

could also be confused with x,y,z

alpine tulip
#

Hmm true

gray wharf
#

is it working with "layers" (0 1 2 3 99 165749) or providing an array of markers to draw them in that order? (also is there a getter?)

solid marten
#

float -....+ yes getter

sinful kettle
#

@untold sky

Would've been good if that watch field for the players position would contain the players position, and if I'd know which terrain this was on
any terrain is fine.

untold sky
#

but i wanna sample object

sinful kettle
#

ok wait one I'll get you one

untold sky
#

nvm first tree I found works

sinful kettle
#

well I told you any terrain is fine 😅

untold sky
#

You said some terrain objects, I didn't expect literally all trees

Only objects with config class supported. Trees don't have config class

#

though... I don't see why the type was requried.
It checks that type is present, but then doesn't use it for anything thonk

sinful kettle
#

yeah named props are stored in object model (p3d) itself

untold sky
#

I just removed that check, seems to be useless. Works now blobdoggoshruggoogly

#

[["canocclude","0"],["dammage","tree"],["map","tree"],["class","treesoft"],["shadow","hybrid"],["sbsource","explicit"],["prefershadowvolume","0"],["frequent","1"],["armor","1000"],["viewdensitycoef","10"]]

outer canopy
#

dammage? 😆

untold sky
alpine tulip
#

So possible to get if a model is an amphibious?

untold sky
#

wat

alpine tulip
#

I thought it is controlled by properties... or, just realized that if there is a valid Buoyancy LOD it is amphibious

untold sky
#

Ahhh now I see, well.. yes I guess then

untold sky
untold sky
gray wharf
#

don't forget to update BIS_fnc_vectorAdd with it 😁

untold sky
#

I generally don't update data so I will most likely forget
Sadly now you reminded me and I have put it on my todo

#

does it make sense to have vectorDot with arbitrary number of elements?
🤔 Would you want a dot product of Vector2/Vector4/Vector5/... ?

sinful kettle
#

what would the missing elements be? 0?

#

[1,2] dot [1,2,3,4] -> [1,4,0,0]?

untold sky
#

same for vectorMagnitude...

for add/subtract yes.
For Dot/Magnitude/Distance I would enforce both to be same size

sinful kettle
#

oh nvm I was confusing it with vec dot multi not dot product meowsweats

#

was there even a command for it?

sinful kettle
untold sky
#

multiply with other vector no. Only multiply by single number

sinful kettle
#

instead of vectorMultiply overload * (so we also have [1,2,3] * 2) 😛

untold sky
#

Yeah I'll add that too then..
Would that enforce same number of elements, or allow extra elements and substitute multiply by 1?
I think same sizes

sinful kettle
#

I'd say 1 is probably the safest? or 0?
I mean you can always resize if you don't need the rest think_turtle

untold sky
#

Well if people wanna be safe they can just pass same sized arrays
I'll use 1, aka do nothing and pass value straight through

#

Result:
0.0009 ms
Cycles:
10000/10000
Code:
[1,2] vectorMultiply [2,5]

Result:
0.0008 ms
Cycles:
10000/10000
Code:
[1,2] vectorMultiply 2

Barely slower than the old code

#

Hey I found my note from when I did this.
Dang my PC was slow xD

#

Now just the question. vectorDot and vectorDist and vectorMagnitude for arbitrary sizes too? 🤔

regal nimbus
#

I use the vector functions a lot and I've not had a need for them.

untold sky
#

dist is not needed because
vectorMagnitude (a-b) is distance anyway

regal nimbus
#

Unlike a quick function to set a vector's z to 0 :P

#

Common one is that you have a 3d vector and you want to make a normalized vector from two components. That's either two expressions or vectorNormalized [_v#0, _v#1, 0] at the moment.

#

Don't think there's a solution there except for adding a command though.

sinful kettle
#

you can implement vectorDist yourself with it too 😛

regal nimbus
#
  • and + overloads for vectorMultiply and vectorAdd would be nice though.
sinful kettle
#
  • is not possible meowsweats
#
  • I agree
regal nimbus
#

hmm. Why?

untold sky
#

array + already exists

regal nimbus
#

ah yeah

#

Reforger had better end up with a separate vector type :/

gray wharf
#

you would know if you blindly bought each and every BI titles

untold sky
#

Dang I had a bug in my code notlikemeow
When checking the input types, I was copying the type of every element, and even with that it was still just as fast as the original vector2/3 version
now its a 🤏 faster again

lean mica
#

All setPos* commands does not work on mines.(Only local effect)
Can it be fixed?
This issue makes mines, placed by ACE, invisible.

private _explosive = createVehicle [_ammo, _pos, [], 0, "NONE"];
_explosive setPosATL _pos;

createVehicle is not precise at placing. For example _pos with z-axis -0.06 will spawn object at ~ -0.148
Second line should fix that, but it have local effect only for player that placed mine. Everyone else does not see mine because it is under ground.
Moving mine 3km away also does not trigger pos sync over network.

near cedar
#

or setMarkerDrawOrder

#

or setMarkerLayer

untold sky
#

vectorNormalized [1,2,3,4,5,6,7]
now that's a bit extreme, or is it? 🤔
Welp doesn't hurt more than 10 minutes of my time so blobdoggoshruggoogly

#

diag_codePerformance [{vectorNormalized2 _this}, [1,2,3]]
[0.00048,100000]

diag_codePerformance [{vectorNormalized _this}, [1,2,3]]
[0.00059,100000]

The new one does more, and is consistently faster too.

diag_codePerformance [{vectorNormalized _this}, [1,2,3,4,5,6,7,8,9]]
[0.00059,100000]

diag_codePerformance [{vectorNormalized2 _this}, [1,2,3,4,5,6,7,8,9]]
[0.00063,100000]

Dang (ofc the old one is slower, because the old one only does 3 elements)

#

Now I have to rerun the old vectorAdd and see how much difference that is.
testing with the array creation removed from the measurement

#

diag_codePerformance [{_this vectorAdd _this}, [1,2,3]]
[0.00063,100000]

diag_codePerformance [{_this vectorAdd2 _this}, [1,2,3]]
[0.00055,100000]

well neato

sinful kettle
#

Why is it faster?

#

Does it not do some check or something?

west onyx
#

I do think "units <side>" and "groups <side>" should take array of sides

#

for my uses at least, factions are not fixed and often we are calculating

#

example: sqf (units (player call BIS_fnc_enemySides)) inAreaArray [<spawn point>,...];

#

could also take array of groups

#
units [grp1,grp2,grp3]```
#
units [east,west,resistance];```
sinful kettle
#
flatten ([grp1,grp2,grp3] apply {units _x})

meowsweats

west onyx
untold sky
# sinful kettle Why is it faster?

Its specialised code instead of abstracted general code.
instead
value.to_float
which does virtual function call to get thing. I know value is float type, so I can skip that and directly call the correct function

untold sky
#

[[2,2], 2] call BIS_fnc_vectorDivide
0.0069ms
[2,2] vectorMultiply 1/2
0.0008ms
😢

#

Actually... I wanted to replace BIS_fnc_vectorAdd and vectorDivide and vectorDiff with the new one.
But.. I can't because backwards compat 2D input must produce 3D output...
And the BIS functions return same number of outputs as they get inputs..
Well I guess I can always add a resize 🤔 Yeah that will still be faster but man, this one small change to (badly) implement 2D support back then now turns this fun project into pure hell.

#

_input call BIS_fnc_unitVector
0.017ms

_result = vectorNormalized _input;
if (count _input == 2) then {_result resize 2}; // vector commands need to return 3D result on 2D input due to backwards compatibility, but the script function doesn't
_result

0.0019ms

😠

sinful kettle
#

just ignore it 😅

#

return 2D 😛

untold sky
#

That's what I'd love to do

sinful kettle
#

must be faster

#

or _result resize [2 max count _input, 0]; (forcing it to be at least 2D)

untold sky
#

0.0015ms, is faster

sinful kettle
untold sky
#

wat

#

nu

sinful kettle
#

new command overload 😛

untold sky
#

Well I consulted, and decision has been made to break backwards compat

#

if you expect that 2D inputs to a addition results in 3D output, and you require that for your code to work then...
Sorry

This was only added in 2.00, so chances are the authors are still around to fix their stuff if affected

#

if we see something blow up on dev or profiling, we'll see if its needed

untold sky
#

BIS_fnc_pow
wow. A script function, to do something that we had a command for since OFP that is 7x slower. Why even

gray wharf
#

yeah, I didn't get that one either - did we miss a functionality that the command doesn't do?

untold sky
#

command doesn't have default values if you pass nil

gray wharf
#

"yay"

alpine tulip
#

#DedmenDoRemakeRVEngineForUs

#

#AndGetRidOfEveryFunctions

gray wharf
#

#ButKeepSetDammage

sinful kettle
#

btw Ded did you remove this error from log?

No point in selection

#

it's really slowing things down when using selVecDirUp or selPos meowsweats

#

if you don't want to remove it at least move it to diag exe meowsweats

#

actually I think you fixed selPos? but vdup is still throwing errors

untold sky
#

I think so

#

might be

#

i dunno what vdup is

sinful kettle
#

selectionVectorDirAndUp

untold sky
#

Its still there if you're looking for firstPoint, which you cannot specify in selectionVDAU

sinful kettle
#

remove it? meowsweats

untold sky
#

oh I see, found it

#

FT ticket?

#

was there one?

sinful kettle
#

there was one by POLPOX iirc, but for selectionPosition

untold sky
#

I don't want to go dig and search notlikemeow

sinful kettle
#

ok meowsweats

untold sky
#

I missed it because apparently I had the bright idea to copy-paste code, and then only update one of the copies 😠

sinful kettle
untold sky
#

❤️

sinful kettle
#

if you want another one let me know

untold sky
#

Ah well the copy paste makes sense so I shall be excused.
I'll just link to the old ticket

#

Won't make it to prof tho, big sad

sinful kettle
#

I only care about dev 😛

untold sky
#

The wait is on krtecek

sinful kettle
#

btw does the game store the list of bone/selection transformations, or does the command recalculate it all over again every time your run it? meowsweats

untold sky
#

the command animates the bones, and resets them again

untold sky
#

Leo
map call ["methodThatDoesNotExist"]

what do, silent ignore and return nil?

#

if method entry is non-code, it throws type error and returns nil

sinful kettle
sinful kettle
#

(also plz ping me next time 😅 )

untold sky
#

Leo
constructor can be called from the createObject command, but what about copying, copy constructor

sinful kettle
#

Copy brings up a question. How to handle the constructor on copy.
Have extra constructor for copying that just gets the old one as arg?
dunno. I mean you could just copy the map 😓

untold sky
#

I would. But I guess afterwards I'd call "CopyConstructor" method if it exists

#
_class = [ 
  ["Method", {"testo"}]
]; 

_hm = createHashMapFromArray _class;
_hm call ["Method"];

-> "testo"

Got this working, very simple

#
_class = [  
  ["Method", {_thisObj}]
]; 

_hm = createHashMapFromArray _class;
_hm call ["Method"];

-> [["Method",{_thisObj}]]
heh

sinful kettle
#

in something like C++ it makes sense

#

in SQF... think_turtle

untold sky
#

I don't know.
I think what killerswin meant is. He'd have one "template" class.
And everytime you create a instance of it you copy..
But.. No then you'd just call createObject on the template array thing so nevermind

#

Problem with your example.
If you create a temporary copy, the destructor would delete your vehicle, even though the main instance is still alive

So you would want a Copy handler, that either creates a new vehicle for the copy, or null's the vehicle on the copy

sinful kettle
#

If you create a temporary copy
I don't know what a temporary copy is 😅
in that example I just create a map then assign it. then engine shouldn't destroy the map then

untold sky
#

ObjectThingy = createobject...;

{
_cpy = +ObjectThingy;
do stuff
} // _cpy Destructor is called and deletes mVehicle that was owned by ObjectThingy, because the mVehicle value was copied over too

sinful kettle
#

ah 😓

untold sky
#

So you'd do
["CopyConstructor" {_thisObj set ["mVehicle", nullObj]; /*Don't copy mVehicle from source*/}]

#
MyMethod = {_thisObj};
_class = [  
  ["Method", MyMethod]
]; 

MyObject = createHashMapFromArray _class;
diag_codePerformance [{MyObject call ["Method"];}]
```[0.00107,100000]

`diag_codePerformance [{MyObject call MyMethod}]`
[0.00105,100000]

As expected I guess
sinful kettle
#

MyObject call MyMethod
_thisObj would be nil then?

untold sky
#

ye

sinful kettle
#

(like "moving" the obj ownership)

untold sky
#

ah yeah could

sinful kettle
#

(_this is what's copied)

untold sky
#

if you wanted a "move" copy you could do that
I assume most people will not handle copying at all.
Could also forbid copying 😄

#

I mena optionally forbid copying

#

have space for some flags

#

Currently hashmap value itself is 16 bytes.
If I add a bool, that'll pad to 24 bytes so I'll have plenty space to spare

sinful kettle
sinful kettle
untold sky
#

ye

#

uhhh. I have 4 bytes of padding space inside the refcount think_turtle
I really should not do that... :x

#

huh there is already 8 bytes of padding on the end 🤔
but why 🤔
OHHH the readonly flag,
Nevermind we have 7 bytes of free space without me having to use any more space meowheart

#

Well now readonly takes up one bit of 64, instead of a whole byte with 7 bytes of padding 🍿
Fun 🎉
If you have more ideas, shoot.
So far Readonly, IsObject
We can add forbid copy. Maybe I'll store there if we have constructor/destructor/copy to speed up a bit

sinful kettle
#

btw when do you set the readOnly and forbidCpy flags?

#

I mean in SQF

#

will there be a command for it?

untold sky
#

readOnly was a WIP thing I never finished.
Probably compileFinal _hashMap returns readOnly copy. Main idea for preStart loading of data that currently uses compileFinal of a func that usually returns a array.

forbidCpy will be some way to pass it into the createObject command. Maybe a specific "key" name for flags or special properties

sinful kettle
#

ah yeah that makes sense: createObjectFromClass [_class, _args, _flag1, _flag2, ...]

untold sky
#

I was thinking inside the class.
Because a no copy is more likely to be property of the class "template" itself, rather than just a thing you can choose when creating an instance

#

like
_class = [
["_flags", ["NoCopy"]],
["constructor", ...],
["Method", ...]
]

Like, "constructor" and "destructor" are basically already "reserved" words with special meaning, so we might add a "flags" reserved one too

dreamy bane
#

what about reading the class from config class rather than SQF?

#

oh wait it would have problems with code {}

untold sky
#

You can do that in SQF.
You can write yourself a script that transforms the config class, into the SQF side array
We can just list that script on wiki page, much easier than trying to add engine support