#arma3_scripting

1 messages ยท Page 289 of 1

jade abyss
#

Yeah, i also do like Banana.

still forum
#

Confucius is Konfuzius in German. So I saw confuzius in confuziused

little eagle
#

Dedmen, fix the duplicate newline

jade abyss
#

Yeah, do you job.

little eagle
#

You were supposed to put one there and made two

#

ffs

still forum
#

It's duplicate now? I need a better git tool :/

jade abyss
#

Yeah, fix that

little eagle
#

It's important for my OCD.

still forum
#

Done

jade abyss
#

You heard that? Its important for his LED

little eagle
#

Great. Now rename it to hashKeys and we're done.

still forum
#

I think he meant OLED LCD

jade abyss
#

Thats what i said.

#

Yeah, why you didn't renamed it to hashKeys, tztztz... schlampiger Workflow here, tztztz

#

(bored and hungry, bad mix)

civic maple
#

How do I load a rifle with ammo?

jade abyss
#

Yes

still forum
#

Why doesn't this discord have a #random channel

little eagle
#

press R

civic maple
#

...

jade abyss
#

๐Ÿ˜„

little eagle
#

?

jade abyss
#

AddMagazine -> AddWeapon -> MagazineWillBeInWeapon
AddWeapon -> AddMagazine -> MagazineWillBeInGear

little eagle
#

sometimes*

civic maple
#

Hmm, didn't work for me. I might've done something wrong

civic maple
#

Ah, thanks

jade abyss
#

doesn't load Magazines Commy

little eagle
#

Yes it does.

still forum
#

As of Arma 3 DEV 1.37, this command also supports weapon magazines.

civic maple
#

"As of Arma 3 DEV 1.37, this command also supports weapon magazines."

jade abyss
#

Yeha, just read that.

#

nvm

little eagle
#

I requested addXWeaponMagazine and this is what I got after a year of waiting.

jade abyss
#

Request for removeMagazine

#

(for Vehicles)

jade abyss
#

Nope

little eagle
#

I think you mean from cargo space?

jade abyss
#

Yep

little eagle
#

Too difficult : (

civic maple
#

):

little eagle
#

Arma 4

jade abyss
#

removing of SingleItems is not possible, without workaround (caching everything, removing the desired one, readding)

little eagle
#

for sure

jade abyss
#

Arma 5

#

or 6

#

(it wasn't in OFP, soo... ๐Ÿ˜„ )

little eagle
#

But KK added LIS reporting multiple intersections a few hours after I mentioned that it would be useful.

#

I feel like they're listening to me now.

jade abyss
#

You can call me god now.

little eagle
#

They're also looking into that eventhandler recompile issue.

jade abyss
#

(i am just talking the same nonsense as you, right now ๐Ÿ˜„ Like BI would listen to you.. thats... cmon, be realistic ๐Ÿ˜„ )

little eagle
#

No one listens to you, Dscha. That is nothing specific to BI.

jade abyss
#

The same as... idk... Gabe would finance HL3.. thats stuff... idk... that will never happen.

#

Some do listen to me! They regret it afterwards, but there are always new ones!

little eagle
#

HL 1 & 2 sucks

jade abyss
#

so does... no, i am quiet. afk.

tough abyss
#

@jade abyss hey, sorry pal, just understand something wrong. Language barrier.

jade abyss
#

rgr

little eagle
#

It would help if he didn't use so many ellipses.

#

I liked them, but the internet ruined them.

#

The channel description is still not fixed.

#
if (_condition isEqualTo call compileFinal str if not (1 ^ random 9999 != random 4444 ^ 0)) then {
jade abyss
#

I repeat myself: ๐Ÿ’ฉ ๐Ÿคฆ

tough abyss
#

@little eagle he who?

little eagle
#

He who used 5 ellipses in one sentence.

tough abyss
#

Me? Lol

little eagle
#

The same as... idk... Gabe would finance HL3.. thats stuff... idk... that will never happen.

tough abyss
#

Ah

jade abyss
#

(hint: It's just 4, so it can't be me)

little eagle
#

It's just 4
No, it's five

tough abyss
#

Put your glasses ehhe

jade abyss
#

4

little eagle
#

The same as...idk... Gabe would finance HL3.. thats stuff... idk... that will never happen.

#

The same as...

#

1

jade abyss
#

I count 4

little eagle
#

idk...

#

2

#

Gabe would finance HL3..

#

3

jade abyss
#

only 2 .

#

doesn't count

little eagle
#

thats stuff...

#

4

jade abyss
#

-1

little eagle
#

idk...

#

5

jade abyss
#

-1

#

=4

plucky beacon
#

Dscha, the namespace setvariable broke my timer :<

jade abyss
#

And the error is?

plucky beacon
#

well aint that the problem, no error but it's not showing up

#

to the logs

plucky beacon
#

god I need to rewrite this timer, it's a fuckn mess

jade abyss
#

We can't tell, since.. you know... our glasbowls are in maintenance-mode.

plucky beacon
#
            _time = serverTime - Tag_MyStartTime;
            _finish_time_minutes = floor(_time / 60);
            _finish_time_seconds = floor(_time) - (60 * _finish_time_minutes);
            if(_finish_time_seconds < 10) then
            {
                _finish_time_seconds = format ["0%1", _finish_time_seconds];
            };
            if(_finish_time_minutes < 10) then
            {
                _finish_time_minutes = format ["0%1", _finish_time_minutes];
            };
            _formatted_time = format ["%1:%2", _finish_time_minutes, _finish_time_seconds];
``` the problem is all this shit is needed for the format
jade abyss
#

eh

plucky beacon
#

there's got to be a better way

jade abyss
#

Okay, delete it. Rewrite it, i assume i've never seen it. Okay? Okay ๐Ÿ˜„

plucky beacon
#

GAH

#

that doesn't help

#

.<

#

I'll be back

jade abyss
#

gl hf

plucky beacon
#

Pbtbtbtbtb

#

does serverTime use simulation or ui time?

little eagle
#

@plucky beacon Please do yourself a favor and use a function to format that time.

plucky beacon
#

That's the plan fam

#

thanks

little eagle
#
[_time1, "H:MM:SS"] call CBA_fnc_formatElapsedTime
#

Maybe BI has something like that too

plucky beacon
#

I'll have to look around, I find it hard to believe nobody else has tried formatting time before

jade abyss
#

Example:

format["Time until Respawn available: %1",[(_WaitTime - diag_tickTime),"MM:SS.MS"] call BIS_fnc_secondsToString];```
plucky beacon
#

is that a thing?

jade abyss
#

It outputs the format "00:00.00"
So just test it out ๐Ÿ˜‰

plucky beacon
#

You know I was wondering if I would be able to make a countdown in mm:ss.ms but wasn't sure if it would hog resources for a loop like that

jade abyss
#

Not rly

plucky beacon
#

I mean i guess it's not like I'm calling the script over and over, I could set a thread on a loop?

jade abyss
#

Example

waitUntil
{
     _Ctrl_Timer ctrlSetText format["Time until Respawn available: %1",[(_WaitTime - diag_tickTime),"MM:SS.MS"] call BIS_fnc_secondsToString];

     round(_WaitTime - diag_tickTime) <= 0 OR
     isNull AnotherVariable
};```
_Ctrl_Timer = ctrl in the center of the screen, loaded with RscTitles.
plucky beacon
#

right

#

also

#
Disable saving of script containing this command. After this script can work with the data types which do not support serialization (UI types). 

what does disableSerialization mean? It sounds like you can't assign stuff or maybe I'm reading it wrong.

jade abyss
#

search the Wiki for that

plucky beacon
#

That's what the definition on wiki is

plucky beacon
#

already there brah

#

disable saving of script containing this command, soooo no returns? no assighnments? what are you saving? I don't get it

jade abyss
#

Its just needed, let me say it that way, when playing around in the UI ๐Ÿ˜„

plucky beacon
#

I know but why and why wouldn't it just be used in everything if there isn't a disadvantage

jade abyss
#

Remember rule #1:
Don't ask, just accept. Its Arma.

plucky beacon
#

hmph, fine

chilly surge
#

So I was planning on making a Mission, and wanted to give a live drone feed on a monitor, so the tropps can see and plan everything. Is there a "easy" way of doing that?

plucky beacon
#

There are scripts available I've seen

#

search around for it

#

they include instructions

little eagle
#

Don't just accept things. disableSerialization does exactly what the command says it does.

plucky beacon
#

I guess I'm just kinda lost on the definition, what can't I do when I disableSerialization?

little eagle
#

Just don't ever use the scheduled environment and you wouldn't even have to worry about this.

plucky beacon
#

oh, okay

little eagle
#

Script serialization is responsible for keeping your script pseudo threads alive when you save and reload a mission.

#

If you disable it, the script will die when you save and quit.

#

It's necessary every time you store DISPLAY or CONTROL values inside local variables.

#

Since these ui types don't survive when you close down the game.

plucky beacon
#

huh, interesting, so data actually stays around when you quit a mission

little eagle
#

When you save it, yeah.

#

Obviously.

plucky beacon
#

oh I gtocha now

#

so it just ensure the ui is reset every time

little eagle
#

Or you can just do what everybody else does and just say fuck savegames

plucky beacon
#

fucksavegames

#

best missions don't need breaks

little eagle
#
_missionAlive = 0 spawn {
    disableSerialization;

    sleep 1e9; // forever
};

_missionAlive spawn {
    waitUntil {scriptDone _this};

    hint "mission was loaded!";
};
#

This should explain it.

plucky beacon
#

wait until sleep 1e9 XD

little eagle
#

It's just a 1 with nine zeroes.

plucky beacon
#

I know!

#

That's a long time!

little eagle
#

Well, you don't know how long the first session will last.

#

The script has to never finish, except for when you save and quit.

plucky beacon
#

2775 years apparently

#

I see

dusk sage
#

I hope that isn't 2775 years

#

D:

plucky beacon
#

it is

dusk sage
#

We haven't got long left to live then

plucky beacon
#

but that's why it's //forever

little eagle
#

That is how "mission loaded" event handlers were done before BI added an actual event for that.

dusk sage
#

We live around like 3 billion seconds

little eagle
#

30000 days only : (

dusk sage
#

shh

plucky beacon
#

Lol

#

i do Arma scripting in class because I'm bored

scarlet spoke
#

When using hex numbers in SQF code... Are they case-sensitive?

plucky beacon
#

No

scarlet spoke
#

Allright... Thx

plucky beacon
#

Np :>

scarlet spoke
#

How does it come that 3.4028235e38 is a valid inpput as a number when I can't find e listed as an operator? Is it an undocumented one or does it work differently?

dusk sage
#

Google scientific notation

scarlet spoke
#

I know what it means... I'm just wondering how the game handles it

#

Does it simply accept this as a form of number notation then?

dusk sage
#

yes

#

If it didn't, it wouldn't work ๐Ÿ™ƒ

scarlet spoke
#

Okay... I just thought it would make sense for it to be an operator similar to exp ^^

velvet merlin
#
Something related to discuss:
 - what else would you expect in minimap? (navigation, units)
 - do you need something else for custom scripted display?
 - something else you miss?```

https://forums.bistudio.com/topic/200468-jets-custom-info/?page=3#comment-3153306
#

@little eagle @tough abyss

little eagle
#

@scarlet spoke for the same reason 0xFF is a valid number.

#

@velvet merlin I don't get it.

scarlet spoke
#

Yeah makes sense if you put it that way ๐Ÿ™ƒ

velvet merlin
#

@little eagle maybe ACE ppl have some wishes/requests for custom displays

#

as the tech might/should become available also to tanks/ground vehicles, i would assume you guys should be interested

dusk sage
#

Not quite the same idea though @little eagle

little eagle
#

How so?

#

Both notifications use letters and still represent numbers.

scarlet spoke
#

But the interpretation is different

little eagle
#

Of course. One time it's hexadecimals, the other time it's big numbers.

#

Yet both are just different ways of writing down numbers.

dusk sage
#

Well, the 0x is particular for a compiler to denote that it's hexadec

little eagle
#

You could represent both by just using numbers as characters, but it's more convenient this way.

#

And eN is for adding *10^N

#

That is also done by the compiler.

dusk sage
#

Whereas all numbers internally use s.notation, that's how they are handled and displayed

little eagle
#

But the compiler still replaces your scientific notation with a completely different one most of the time

dusk sage
#

Well, it's here is a number as you'd expect it vs heres a hexadecimal number FF

little eagle
#

No

#

8 is internally something like
00001000
And 0x8 is the same
And so is 8e0

#

Btw, would be nice if they added support for binary numbers

jade abyss
#

Commy is speaking in R2D2 again.

dusk sage
#

Don't consider the internals working in binary, were moving away from lowest level here. You could write 8, or 8e0, they are equivalent. But 0x is an explicit note to the the compiler

jade abyss
#

its spreading!

little eagle
#

What do you think the e is?

jade abyss
#

C3PO, beep beep boop bib?

dusk sage
#

If you were to cout a large number, it'd display it with s.notation, it's natural. Your hexa number will come out in decimal, how it's handled

little eagle
#

There is absolutely no difference between 255 and 0xFF

dusk sage
#

You're missing the point ๐Ÿ˜›

little eagle
#

But your logic, any number from 0 to 9 is a "compiler directive" to read a number.

dusk sage
#

You said for the same reason 0xFF is a valid number.. It just so happens you can tell the compiler your number is in hexadecimal. Versus the other case, just a number in its standard form

#

But doesn't matter, off topic

little eagle
#

e is a compiler directive to resolve the scientific notation

#

ยฏ_(ใƒ„)_/ยฏ

#

We don't even know the internals, so there is no point in even talking about "compiler directives"

#

10
1e1
0xA

#

Three ways to write down a number

#

The last two actually use letters

#

That was my point. Nothing more.

plucky beacon
#

timer.sqf

Timer_Length = 300; //When mission should end in seconds

if!(isDedicated) then
{
    disableSerialization;
    2 cutRsc ["NitroInfo","PLAIN"];
    waitUntil {!isNull (uiNameSpace getVariable "NitroInfo")};
    _display = uiNameSpace getVariable "NitroInfo";
    _setText = _display displayCtrl 1010;
    _setText ctrlSetBackgroundColor [0,0,0,0.3];
    
        _elapsed_time  = 0;
        _start_time = diag_tickTime;//will change to serverTime when working

        while {Timer_Length > _elapsed_time} do 
        {
            _elapsed_time = diag_tickTime - _start_time;//will change to serverTime when working
            _setText ctrlSetText format["%1",[(_elapsed_time),"MM:SS.MS"] call BIS_fnc_secondsToString];
        };
    2 cutRsc ["default","PLAIN"];
    [[],"BluforFailure_time.sqf"] remoteExec ["execVM",-2,false];//gotta make global 
};
#

pfft okay so right when I posed it, it started working, but it's counting up instead of down

#

the milliseconds are kinda jittery, gotta align to the left side

scarlet spoke
#

For alignment of the numbres it works fine by setting their decimals to the same length

#

I have done this by transforming the number into a string first and then add or remove segments as needed

plucky beacon
#

decimal to the same length? isn't the kerning defined by the font?

scarlet spoke
#

The what?

#

Oh wait... Is your problem the one that the numbers don't line up because they have a different length?

#

Like 4.5 vs 3.576

plucky beacon
#

even with 1 digit on the end, the string still jitters

#

even if ya got rid of milliseconds, it still moves around

scarlet spoke
#

Oh okay then forget my comment on that... I misunderstood your problem xD

leaden summit
#

Hey is anyone able to write what I assume is a relatively simple script, which will check the assets on the map and put a map marker next to any that are part of the expansion?

We've started to strike a problem where we've had an influx of new players, and many of them don't have APEX yet as they're just getting into the game. Unfortunately as I found out last night, they can't play a lot of the missions we have because they contain a "number > 1" of apex assets, like a simple piece of fence stops them from joining the mission.

Problem is when everything's already laid into the mission it's hard to find what's from the expansion even judging from the error messages they get.

I thought if someone could come up with a script that can check for APEX locked assets and even just drop a map marker so it can be found that would be really helpful. Unfortunately my scripting ability is very minimal

little eagle
#

wtf am I looking at. Why is a ui script also using remoteExec

dusk sage
#

@little eagle
if (first char is 0 && first char is x)... vs just parsing the float more than likely ๐Ÿ˜„

little eagle
#

@leaden summit
tl;dr
You want a script that reports the current number of objects that require APEX?

leaden summit
#

Well ideally it would mark them somehow (maybe on the map) so it's easier to go back into a mission I made months ago and know what to take out

little eagle
#

I see. Do you have any examples of objects it would have to detect, so I can properly debug it?

#

I can only think of some tanoa soldiers and those new jeeps

leaden summit
#

There's a fence and gate, I think it's acalled a back alley fence

#

Or even the big crane/digger prop

little eagle
#

there are multiple fences in the game ...

leaden summit
#

Yeah sorry just trying to find a pic

little eagle
#

Land_Church_01_ruins_F

#

I will try with this one

leaden summit
#

Stuck at work at the moment else I'd find you the classname

little eagle
#

It's a ruin of the church in Tanoa

#

I think it should be alright with this one.

leaden summit
#

pennyworth mentioned the following in the mission makers channel

The restriction only applied to objects and buildings from the expansion that aren't "props". I don't think they'll have "exp", but a way to check that with scripting would be to look at https://community.bistudio.com/wiki/allMissionObjects and look if thi returns expansion from it https://community.bistudio.com/wiki/configSourceMod

plucky beacon
#

sorry commy I'm a bad little script writer.

jade abyss
#

Nah, ignore his ranting

dusk sage
#

that almost sounds kinky

plucky beacon
#

oopsie

little eagle
#
#define DLC_APEX 395180

commy_allTanoaMarkers = [];

addMissionEventHandler ["Map", {
    params ["_isOpened"];

    if (_isOpened) then {
        private _tanoaObjects = allMissionObjects "" select {getObjectDLC _x isEqualTo DLC_APEX};

        {
            private _marker = createMarkerLocal [format ["commy_tanoaMarker_#%1", _forEachIndex], _x];
            _marker setMarkerShapeLocal "ICON";
            _marker setMarkerTypeLocal "mil_warning";
            _marker setMarkerColorLocal "ColorRed";
            _marker setMarkerTextLocal typeOf _x;

            commy_allTanoaMarkers pushBack _marker;
        } forEach _tanoaObjects;
    } else {
        {
            deleteMarkerLocal _x;
        } forEach commy_allTanoaMarkers;

        commy_allTanoaMarkers = [];
    };
}];

@leaden summit
put this into the init.sqf

#

It didn't pick up the Gendarmerie (sp?) jeep, but apparently that's just a retexture, so anyone can use it.

#

Found the church ruins and the soldier

leaden summit
#

Awesome thanks man

plucky beacon
#

Imma save this, could be useful

little eagle
#

hoarding scripts, because "they could be useful"

plucky beacon
#

You have no idea how many people come to me saying "Does my mission have Apex objects?"

little eagle
#

Tell them to write a script to find out real quick

plucky beacon
#

You give people too much credit

#

These are people who haven't scripted more than a "allowDamage false;"

leaden summit
#

Also floated the issue with R3vo to see if that's not something his 3den enhanced mod could add. It really frustrating as a mission maker to have people not be able to join because of one asset you had no idea about

plucky beacon
#

yay, I even made the timer turn red when there is only ten seconds remaining

native hemlock
#

Isn't there an option somewhere in the Eden editor that lets you see the required addons?

little eagle
#

Yeah, but they wanted to see where they are placed on the map.

plucky beacon
#

What's the best way to force a dialog to remain open until conditions are met, I know you can script it to waituntil the dialog is closed to open it again but I want to know if that's the only way, or if there is just a way to prevent someone from pressing escape to exit the menu

jade abyss
#
    (findDisplay 123456) displaySetEventHandler ["KeyDown","if((_this select 1) isEqualTo 1) then {true}"];        //Disable ESC```
ESC is only disabled, as long as Display 123456 is active
tough abyss
#

So say if i was trying to modify vehicle inventory space via mod. What exactly would i have to do in order to over ride the class and change the inventory space.

jade abyss
#

Search google for CfgPatch (or CfgPatches, on of them is correct, can't remember anymore)

tough abyss
#

will do

civic maple
#

It's CfgPatches

tough abyss
#

maximumLoad would that be inventory?

jade abyss
#

uh, think so, yeah

jade abyss
#

\ Don't mind stuff like MaxMagazine*****/MaxWeapon***** and MaxItemCargo

#

Or something similar, they don't work, but are still in the Cfg, sometimes

little eagle
#

markdown ยฏ_(ใƒ„)_/ยฏ

jade abyss
#

fk discord

#

FFS

#

I give up

tough abyss
#

its fine i get it. thank you

ember vector
#

ios there a program for ARGB colers to find easely? because am noob ad this kind of things, theres a program i can use that will give the colors ..

civic maple
#

There's a ton of things online that give you RGBA colors

jade abyss
#

google <- ?! quicker then here?

dusk sage
#

how do I google?

civic maple
#

yes

ember vector
#

hah yeah i know but i dont understand how to put it in u know? am dom as fuck so for example
rgb(193, 66, 66) .. this from colertool

and this is arma "#(argb,8,8,3)color(0.05,0.05,0.05,1)", ... where do i put the numbers :p

civic maple
#

#(format,width,height,number of mipmaps)color(r,g,b,a,texture type)

plucky beacon
#

Can you set allignment anywhere but the .hpp?

#

I don't see a command for it

jade abyss
#

parseText stuff

ember vector
#

yeah my english is shit to i know, argb 8 8 3 <:::: change this? or change 0.05,0.05,0.05,1 <<:::?

civic maple
#

the latter

#

it's in a scale from 0 - 1, so to get the value you'll need to divide the value by 255

#

So for example the red is 193, which will be 193 / 255

plucky beacon
#

oh parseText

#

okay

ember vector
#

owkey il try that

plucky beacon
#
_setText ctrlSetText parseText format[" <t align='Left'>%1</t>",[(Timer_Length - _elapsed_time),"SS.MS"] call BIS_fnc_secondsToString];
_setText ctrlSetText format["%1",[(Timer_Length - _elapsed_time),"SS.MS"] call BIS_fnc_secondsToString];

These two are outputting the same, I don't know if parsetext will work here

jade abyss
#

ctrlSetParseText or something like that, iirc

#

+You might have to change the control

plucky beacon
#

it's like there are controls for literally everythign but alighnment

#

fonts and header sizes

jade abyss
#
_Ctrl_AreaPts ctrlSetStructuredText parseText format["<t align='center' color='#%1'>%2</t>", _Color, _Area_Trend];```
plucky beacon
#

STRUCTURED

#

of course

jade abyss
#

told ya ๐Ÿ˜„

#

ctrlSetParseText or something like that, iirc

plucky beacon
#

;P

jade abyss
#

I mention it again: Most of the stuff i write here is taken from the very back of my brain, the examples are from file i did, when i was actively coding. Thats more then 6 months ago^^

plucky beacon
#

well you got a good memory

tough abyss
#

nice i got my mod working. that wasnt hard at all

jade abyss
#

Yep Cloud.

#

There are aloooot of examples out there, a short google session will find almost everything.

plucky beacon
#

I usually have a million follow ups though

#

Even if I find the answer I like to know why it's the answer

little eagle
#
private _test = 1; 
systemChat str [_test]; 

private "_test"; 
systemChat str [_test];
#

result:

[1]
[1]
#

___________________-

#
private _test = 1;

call {
    systemChat str [_test];

    private "_test";
    systemChat str [_test];
};
#

result:

[1]
[any]
#

๐Ÿค”

jade abyss
#

Yep

#

iirc private clears the entry in _test

little eagle
#

It doesn't in example 1

jade abyss
#

ffs? oO

#

another "Scope" (call)?

dusk sage
#

it's already private in the scope

#

does it do anything?

little eagle
#
_test = 1; 
systemChat str [_test]; 
 
private "_test"; 
 systemChat str [_test]; 
#

same result

#
[1]
[1]
jade abyss
#
private _test = 1;

call {
    systemChat str [_test];

    private "_test"; // <- Gets cleared here, because: Was call'd before?
    systemChat str [_test];
};```
little eagle
#

stop thinkng about this

jade abyss
#

no

little eagle
#

check out this mindfuck instead:

jade abyss
#

force me

little eagle
#
call { 
    _test = 2;
    systemChat str [_test]; 
 
    private "_test"; 
    systemChat str [_test]; 
};

result:

[2]
[2]
#
_test = 1;
call { 
    _test = 2;
    systemChat str [_test]; 
 
    private "_test"; 
    systemChat str [_test]; 
};

result:

[2]
[any]
jade abyss
#

Yeah, correct.

#

Top: Same "scope"

#

Bottom: _test was defined BEFORE the different "scope"

#

Scope is not the right word... hmpf...

#

Bottom: _test = 2; is kinda useless, since _test existed before.

little eagle
#

You are immediately agreeing with the example that makes the least sense to me. And you're confused about those that make the most sense to me.

jade abyss
#

It still gets buttfkd by private again

#

I dreamed of SQF once.

#

Oh btw.: Why it does that -> Makes no sense to me too. I just explain what i think is happening!

little eagle
#

You'd think having an identical scope in two scenarios would lead to the same result no matter what you did in the previous scope.

jade abyss
#

Arma ยฏ_(ใƒ„)_/ยฏ

little eagle
#

All I can say is: always set your variables to private.

jade abyss
#

Yep. In the beginning of the file.

little eagle
#

But people will still say "I don't need it, I don't see why"

jade abyss
#

Needs more work, but that was my habbit.
First Line in every Script:

private["_a","_b"];```
little eagle
#

keyword is fine too...

#

My first line is:
#include "script_component.hpp"

#

๐Ÿ˜›

jade abyss
#

Macros, pfff

#

๐Ÿ˜›

little eagle
#

Actual first line is:
// by commy2

#

But everything with QC won't allow me to use that

jade abyss
#

qc?

little eagle
#

quality control

#

the reviewers on Github

jade abyss
#

hu? oO

#

I used that soooooo often.

little eagle
#

... we usually have PRs reviewed before merging them by at least one maintainer or whoever feels like it

dusk sage
#

review your own, // by comm2, reviewed by commy 2 โœ…

little eagle
#

And hope no one notices. And hope nothing broke.

plucky beacon
#

//by commy2 reviewed by commy 2 love commy 2 <3

little eagle
#

review process is fun. I made dedmen do 20 commits in a PR where he added one basically one liner function.

plucky beacon
#

haha

#

gotta be thorough

jade abyss
#

Good ๐Ÿ˜„

plucky beacon
#

where da heck is text fields in the gui editor :I

dusk sage
#

double click them

#

or right click

#

cant remember

plucky beacon
#

nonono

#

I mean I want a gui with my own text field

#

but I can't find that type of element in thie editor

dusk sage
#

? RscText?

plucky beacon
#

can you type in rscText?

#

if you can I don't know about it :I

snow pecan
#

RscEditBox

#

Not sure of its in GUI Editor

dusk sage
#

You can yeh

#

Oh you mean text box

plucky beacon
#

ya but text box is kind of ambiguous

plush cargo
#

You're looking for a box that players can type in when gui is open?

plucky beacon
#

ya

#

then press a button and send a value to the server

plush cargo
#

class RscEdit
{
deletable = 0;
fade = 0;
access = 0;
type = 2;
x = 0;
y = 0;
h = 0.04;
w = 0.2;
colorBackground[] = {0,0,0,1};
colorText[] = {0.95,0.95,0.95,1};
colorDisabled[] = {1,1,1,0.25};
colorSelection[] =
{
"(profilenamespace getvariable ['GUI_BCG_RGB_R',0.77])",
"(profilenamespace getvariable ['GUI_BCG_RGB_G',0.51])",
"(profilenamespace getvariable ['GUI_BCG_RGB_B',0.08])",
1
};
autocomplete = "";
text = "";
size = 0.2;
style = "00x02";
font = "PuristaMedium";
shadow = 2;
sizeEx = 0.045;
canModify = 1;
tooltipColorText[] = {1,1,1,1};
tooltipColorBox[] = {1,1,1,1};
tooltipColorShade[] = {0,0,0,0.65};
};

#

I don't use the GUI editor for my UI's so not sure where it is in there but thats it

#

then you'll need a button that gets the value of the rscEdit ctrl when you press it and does what you want with that info

plucky beacon
#

Ya so basically you type in an integer and hit a button to confirm

plush cargo
#

pretty sure when you try to call whatever text is in the editbox, it will come in a string ("1")so you will have change it to an integer ? not sure

plucky beacon
#

I'm having issues defining it

#

hmmm

#

I'm gunna have to come back to working on the GUI stuff, I always have a lot of trouble finding things for defines.hpp

plush cargo
#

has almost all of them

plucky beacon
#

ya I got the default here

#

okay so it is RscEdit just hard to tell from the editor

plucky beacon
#

late night scripting

#

no rest for the code

plucky beacon
#

At some point I'd like to reverse engineer the BIS upload boxes

distant egret
#

Any way to get all units classnames from a group from config?
eg.
You got the "OI_reconPatrol" group, and I want to get all the classnames of the units that are in that group. Without spawning it of-course.

proven crystal
#

Rightclic group, log classes to clipboard, paste somewhere

rancid ruin
#

configfile >> "CfgGroups" >> "East" >> "OPF_F" >> "Infantry" >> "OI_reconPatrol" >> "Unit0"

#

it goes up to Unit3

#

add >> "vehicle" for the entry containing that unit's classname

#

think that's how it works

proven crystal
#

Ah sorry, i thought from the editor

rotund cypress
#

Hey guys, is there any list of what positions selectionPosition can be used with?

civic maple
#

How would I go about checking if a config entry has a certain property?

jade abyss
#

if( (getText (configFile >> Path)) == "" )then{hint "nope"};
if( (getArray (configFile >> Path)) isEqualTo [] )then{hint "nope"};
*Edit

#

etc. blablabla

polar folio
#

isEqualTo []

#

right?

jade abyss
#

Doesn't matter

polar folio
#

why not? sorry, i'm bored

jade abyss
#

In this case, it doesn't matter what you choose. == or isEqualTo can be used

polar folio
#

can you even compare arrays with ==?

jade abyss
#

*edited above blub

polar folio
#

there you go then ๐Ÿ˜„

jade abyss
#

And?

#

if( (getArray (configFile >> Path)) iqEqualTo [] )then{hint "nope"} ->

if "(configFile >> Path)" has no Array -> getArray answers with []
*fix0rd

civic maple
#

Ok, thanks a lot (:

thin pine
#

_fact = Dscha iqEqualTo 40;

jade abyss
#

Did you just assumed my age?

#

*triggered*

#

(Ha! won! Take that Discord!)

dusk sage
#

he put

#

iqEqualTo

#

iq

#

He's assuming your intelligence

#

triggered

jade abyss
#

@thin pine How DARE YOU!11oneoneone

thin pine
#

๐Ÿ˜„

#

you typesors very goet mi comrad

jade abyss
#

yo wot m8?

thin pine
#

sori mi no understand

jade abyss
#

aye caramba Tequilla wall trump.

snow pecan
#

Ho Lee Fuk

plucky beacon
#

More triggers than a rifle squad

tough abyss
#

hey guys any way to disable the kill messages when Zeus is remote controlling a unit?

plucky beacon
#

kill messages?

#

I haven't had that issue, we disable them in the server configs :/

polar folio
#

hm. i thought default behavior was NO kill message because the unit is remote controlled. did that change maybe?

tough abyss
#

it used to be that no message would be shown

#

but since a week or two every Zeus kill shows the Zeus name as killed by

polar folio
#

ah cool. i think in the bigger picture that is actually good

tough abyss
#

how so

polar folio
#

for your purpose i feel it would be best to do what Nitro suggested and disable all kill messages and if you need them for other stuff you could use a scritped way

#

it's better for mods in general

tough abyss
#

AI can be so stupid that Zeus has to take over

polar folio
#

not fully switching into a unit but jsut remote controlling can break mods that rely on knowing who the player is etc

plucky beacon
#

Hay Dscha, remember when you posted how to set a variable based on the text in rscEdit box?

polar folio
#

ctrlText?

plucky beacon
#

is that what it is?

polar folio
#

that's how you get the text of a control including edit boxes. as far as i remember

plucky beacon
#
onButtonClick = "missionNameSpace setVariable ['VarName', (ctrlText 12345), true];";

got it

jade abyss
#

Top right in Discord -> "Search" -> "TheWordYourSearchFor" -> Enter ๐Ÿ˜„

plucky beacon
#

I know I just did that to find the code block :P

#

I just didn't know which ctrl it was

#

I was trying all the wrong ones

jade abyss
#

rgr

plucky beacon
#

I'm getting errors from a file I didn't even edit

#

createEnemy.sqf

private ["_newUnit","_markerPos","_tempUnit"];

if (_this == null) exitWith{};

_newUnit = (group OpGrpLead) createUnit [_this, getMarkerPos "East_Start", [], 0, "NONE"];

called from getUnits

{     
    diag_log format ["|getUnits|--!--This is the unit: %1",_x];

    _LowerClassname = (toLower (typeOf (_x)));
    _caseResult = switch (_LowerClassname) do {
        case "b_officer_f": {"O_Soldier_SL_F"};
        case "b_soldier_sl_f": {"O_Soldier_SL_F"};
        case "b_soldier_tl_f": {"O_Soldier_TL_F"};
        case "b_soldier_uav_f": {"O_Soldier_UAV_F"};
        case "b_medic_f": {"O_Medic_F"};
        case "b_soldier_ar_f": {"O_Soldier_AR_F"};
        case "b_soldier_aar_f": {"O_Soldier_AAR_F"};
        case "b_soldier_gl_f": {"O_Soldier_GL_F"};
        case "b_soldier_m_f": {"O_Soldier_M_F"};
        case "b_soldier_lite_f": {"O_Soldier_lite_F"};
        default {null};
    };
    diag_log format ["|getUnits|--!--This is the classname: %1",_LowerClassname];
    _caseResult call missionStarter_fnc_createEnemy;
} forEach BluforPlayers;
dusk sage
#

if (_this == null) exitWith{};

#

๐Ÿค”

plucky beacon
#

okay so then I comment that out

jade abyss
#

if (_this == null) exitWith{};
->
if(isNull _this)exitWith{};

plucky beacon
#

How do you even get a type script?

#

okay so I fixed that, but I still get an error after

jade abyss
#

You tried starting it, with the fix?

plucky beacon
#

I tried with it commented out earlier

jade abyss
#

(If you receive Error Msgs, only fix the first one! Some can be followup Errors)

#

Means, when its commented out -> It continue to call a script, that expects an Object, right?

plucky beacon
#

What I don't get is why changing stuff in the timer script made this come up :/

jade abyss
#
  • check createUnit in the Biki again
plucky beacon
#

wat now I'm really lost

jade abyss
#

+is OpGrpLead already a group, or is it false naming?

dusk sage
#

so _this is a string

plucky beacon
#

yes

#

classname specifically

dusk sage
#

so it's never null

jade abyss
#

String can't be Null

plucky beacon
#

wat

jade abyss
#

if(_this == "") for example

#

but never NULL

dusk sage
#

default {null}; make that default {""};

plucky beacon
#

oaky well I gotta go to class but I'll commit these edits

dusk sage
#

then check == "" as Dscha said

plucky beacon
#

Ya I don't know how that even changed, last time I edited that file was a while ago

#

Now that I'm running my changes through git it should help me keep track

polar folio
#

ye don't waste time on these kind of thoughts. i did that way too much in the past. "but this should work...". just fix it. be happy it's an error that gives you a descriptive error message. that's a privilege. check your privilege bro

plucky beacon
#

TRIGGERED

jade abyss
#

TRIGGERED

#

(Tell me, why are we triggered? Nitro)

plucky beacon
#

because I didn't check my privelage

#

my coding privelage

jade abyss
#

oh, then not triggered.

plucky beacon
#

haha

#

I print out ascii art in the log because it's funny

#

I have to say I'm pretty happy I got this git setup that updates straight to my mission folder, so I can work on it from other computers

#

only set it up on a whim

thin pine
#

And we're all happy for you Nitro

tough abyss
#

is -filepatching still required to find the files in userconfig?

#

for a server

thin pine
#

That sounds extremely sarcastic and bitchy but im srs tho ๐Ÿ˜„

plucky beacon
#

I dunno I using bitbucket

#

lol thanks sanchez

#

oh I'm not using the git for a dedicated server stalk3r

#

It's just to my missions folder

tough abyss
#

??

#

what xD

plucky beacon
#

oh you're not talking about what I was doing

#

I mean that's technically a #server_admins question, but I'm pretty sure you don't need filepatching unless it was on my server without my knowledge

tough abyss
#

ah right cause I am trying out VCOM AI for the server and it requires filepatching enabled but I thought it was a security hazard to have it enabled

plucky beacon
#

well it is which is why it's mainly used on private servers

#

why not use the mod version?

#

sorry, I mean the script version

#

the configuration file can be inside the mission

tough abyss
#

Because the server has multiple mission files in /mpmissions

plucky beacon
#

You can unpack the addon and edit the defaults?

tough abyss
#

yes but when I load in another mission, it won't have the same VCOM AI settings

thin pine
#

he means modifying the vcom pbo to adjust the defaults.

plucky beacon
#

ya so basically, harder to edit but you can set what you want still

#

also

#

when using cutRsc, what diffrence does it make when they're on a diffrent layer, is being on a layer higher value or lower value affect anything other than it's identifying number?

dusk sage
#

visually think of layers ๐Ÿ˜›

plucky beacon
#

like photoshop

plucky beacon
#

is cutRsc always behind a createDiolag?

polar folio
#

good question. you could always use ctrlcreate on that dialog. afaik the control created last should be ontop like it does with the ones created from config

plucky beacon
#

I'm having a bug where two almost identical rsc layers, one is working and staying visible, the other one flashes for a frame and dissapears when the script calls.

disableSerialization;

20 cutRsc ["NitroBlu","PLAIN"];

waitUntil {!isNull (uiNameSpace getVariable "NitroBlu")};
    _display = uiNameSpace getVariable "NitroBlu";
        _setText = _display displayCtrl 1015;
            ((uiNameSpace getVariable "NitroBlu") displayCtrl 1015) ctrlSetStructuredText (parseText format ["<t size='2' color='#006296'>%1 | BLUFOR</t>",(_this select 0)]);

blufor works

disableSerialization;

21 cutRsc ["NitroOp","PLAIN"];

waitUntil {!isNull (uiNameSpace getVariable "NitroOp")};
    _display = uiNameSpace getVariable "NitroOp";
        _setText = _display displayCtrl 1020;
            ((uiNameSpace getVariable "NitroOp") displayCtrl 1020) ctrlSetStructuredText (parseText format ["<t size='2' color='#960000'>OPFOR | %1</t>",(_this select 0)]);

opfor doesn't

I'm doing some debugging logs now but it's not the display ctrl or the layer I'm using right?

#

and I can see it flashes with the right number and format so it's definately working almost

#

also works in singleplayer

little eagle
#

The waitUntil is pointless

plucky beacon
#

is it?

#

okay

little eagle
#

They're both identical, aren't they?

#

The both snippets.

#

Just different numbers and a different RscTitle

plucky beacon
#

ya

#

and text obviously

little eagle
#

Are their configs different?

plucky beacon
#

I copied one from the other so let me be sure (and yes changed the idcs

#

ya they are

#

maybe there is a mod or something using the layer or idd

little eagle
#

Your idd is > 1e7

#

1000030

#

Could be problems with float precision

plucky beacon
#

I'll remove 3 zeros

little eagle
#

As for the layers

#

Instead of

#

21 cutRsc ["NitroOp","PLAIN"];

#

try the alternative syntax

#

"NitroOp" cutRsc ["NitroOp","PLAIN"];

#

last one will be on top

#

Unless the layer name was already used

plucky beacon
#

nah, that should work

#

I wonder why it's a MP issue only

little eagle
#

You're not supposed to use numbers there

#

Either you generate your layer via

#

BIS_fnc_rscLayer

#

Or you use the alternative syntax of cutRsc.

#

Which is the same thing.

#

Do not use you own numbers...

plucky beacon
#

okay

little eagle
#

Yeah, it might be a conflict with two layers colliding

plucky beacon
#

I have a bunch of cutRsc s so I should probably change all of them to alternate syntax

little eagle
#

I mean, you can use really big numbers

#

like 90001

#

and hope no one else uses them...

#

or you do it the intended way

#

idk

plucky beacon
#

I'll just take your advice :>

#

well it's working

#

so it must have been a conflict

#

ya know what? might have been tfar

little eagle
#

Could be anything.

#

Keep in mind that these layers aren't necessarily the same every time

#

21 could be different things

#

Depending on loading order

#

"weak random" so to speak

plucky beacon
#

so if I were to edit or get rid of them it has to be like "NitroOp" cutRsc ["default","PLAIN"];

little eagle
#

"NitroOp" cutRsc ["NitroOp","PLAIN"];

plucky beacon
#

so the name essenitally becomes the "layer"

little eagle
#

The layer id is replaced with an unique layer name

#

Same concept. It's an id too, but you can name it

plucky beacon
#

that also sounds easier for documentation too

little eagle
#

Yeah, with strings you can use tags and you're set.

dusk sage
#

You're letting it automate the layer, but you have to have a way to reference it in the future

little eagle
#

If you need to have them in any specific order, just use the string id with an empty cutText at mission start.

plucky beacon
#

ya the good news is I don't have to worry about layering, nothing is on top of anything else right now

#

Although I was having that problem earlier where a cutRsc was hidden behind a diolag?

little eagle
#

I hate these cutX thingies. I just use the controls and displays

#

More freedom.

plucky beacon
#

the ctrls and displays certainly have more editing options

dusk sage
#

Just make sure you don't forget the layer, or you'll have a mighty headache ๐Ÿ˜›

little eagle
#

onLoad = "with uiNameSpace do { NitroOp = _this select 0 }";

#

hah, creative use of with

#

The guy that came up with that initially probably struggled with escaping quote marks for an hour or something.

plucky beacon
#

I was having that issue earlier

little eagle
#

onLoad = "uiNamespace setVariable ['NitroOp', _this select 0]";

plucky beacon
#

ya using single quotes

tough abyss
#

_playerUnit switchCamera "..." don't work with units in vehicles, even (vehicle _playerUnit) switchCamera "..." don't work. Anyone can help me?

little eagle
#

Should work, what exactly are you doing?

tough abyss
#

spectator mode

#

@little eagle when the unit enter a vehicle the camera stops in air

#

and if i runb the command again, it not work

little eagle
#

repro:
switchCamera to unit1
make unit1 enter vehicle1
switchCamera to vehicle1

#

right?

tough abyss
#

can be only that:

#

make unit1 enter vehicle1
switchCamera to vehicle1

#

but unit1 is a player

#

not sure if matters

#

on Eden editor console i was able to switch to a agent in a vehicle

#

with agent switchCamera "INTERNAL"

#

But had no success in my dedicated server

#

with 2 players

#

one switching to the other inside a vehicle

little eagle
#
0 = 0 spawn {
unit1 switchCamera "EXTERNAL";
sleep 4;
unit1 moveInDriver vehicle1;
waitUntil {unit1 in vehicle1};
vehicle1 switchCamera "EXTERNAL";
};

works for me

tough abyss
#

in eden editor?

little eagle
#

yeah, editor

tough abyss
#

_this is the player spected

#

the function run on the spectator machine

#

Not waste so much time with it...

little eagle
#

while {!camCommitted _cam} do {};
bad idea

tough abyss
#

probably some "pig" code

#

๐Ÿ˜›

little eagle
#

this loops runs 1000 times per frame

tough abyss
#

But its for precision

little eagle
#

That makes no sense

#

The value will not change during the frame

#

check 1000 times or even more and the result will never change

tough abyss
#

i see

#

Changing....

#

but waitUntil is not garanted to run each frame

little eagle
#

nothing is if you use the scheduled enviroment

#

At least waitUntil doesn't check multiple (1k+) times a frame.

#

Your current while loop eats up all 3 ms guaranteed and pushes your pseudo thread at the end of the scheduler stack

#

So much for precission

#

I have some while loops that don't need a sleep, but that is only really viable if your check changes every time I guess.

#

I'm pretty sure one could use eventhandlers for all this stuff tbh. They have nice stuff with getOutMan and getInMan now.

tough abyss
#

i will test it with waitUntil, if the camera movement get blocky

#

because if the camera commit ends, and another one don't come right after, the camera will stop to move for instants

little eagle
#

It's not the player. It's a spectated unit.

#

Dunno if playerViewChanged works for that.

#

Donnovan, you have that problem either way.

#

with while-sleep

#

or with waitUntil

#

And you current "sleepless" while only makes it worse

#

You guarantee to be the last in the scheduler stack by eating up 3ms every time you get your thread to run

tough abyss
#

i understand. just wrong assumption from me, like many lol

#

but its the way to learn the "inside" of it

#

This code have zoom when the player is on foot

#

because it uses a camera positioned in the head of the spected unit

little eagle
#

I'm trying to figure out how it works so I can get back to your original problem.

#

switchCamera definitely works for me on vehicles.

tough abyss
#

there is also the code that put the fov in "fov" and the effect in "cmv"

little eagle
#

y thy so shrt?

tough abyss
#

this must run in loop on all clients that can be spected:```sqf
//SETUP
player setVariable ["cmv",cameraView,true];

//IN A LOOP
_cameraView = if (cameraView == "EXTERNAL") then {"EXTERNAL"} else {"INTERNAL"};
if (_cameraView != player getVariable "cmv") then {
player setVariable ["cmv",_cameraView,true];
};```

#

this records the view effect of the player in playerNameSpace

little eagle
#

oh that is pretty bad too. You have a lot of network traffic with that.

tough abyss
#

not really

#

it only set the var when it changes

little eagle
#

ok

#

sooo, which line doesn't work again?

tough abyss
#

and this to record the fov:

#
//SETUP
KK_fnc_trueZoom = {...};
player setVariable ["fov",call KK_fnc_trueZoom,true];
BRPVP_changedZoom = false;

//ON EACH FRAME
_fov = player getVariable "fov";
_fovNew = call KK_fnc_trueZoom;
if (abs((_fovNew - _fov)/_fov) > 0.001) then {
    player setVariable ["fov",_fovNew,false];
    BRPVP_changedZoom = true;
} else {
    if (BRPVP_changedZoom) then {
        player setVariable ["fov",_fovNew,true];
        BRPVP_changedZoom = false;
    };
};
#

@little eagle no errors

#

but the the spected player enters a vehicle

#

the spectator vision get stuck outside the vehicle

#

the vehicle can go away and the spected vision stay there, stoped

#

not sure if i was clear

#

language barrier sorry ๐Ÿ˜ฆ

#

KK_fnc_trueZoom is a function from killzonekid

dusk sage
#

Why do you broadcast fov on setup, but not OEF?

tough abyss
#

OEF?

dusk sage
#

on each frame

tough abyss
#

i broadcast it again in the line 4 from bottom to top

dusk sage
#

ah yes

#

so if they are constantly doing something (moving, zooming? whatever)

#

You're pvar'ing every other frame?

tough abyss
#

it only broadcast when it change and then stop to change

#

when it stop to change it get broadcasted

#

so when someone zoom with a sniper, the code see zoom changed and start to monitore it for when it stop to change

#

when it stop to change the code get the current fov and broadcast it

#

@dusk sage got it?

little eagle
#

Pretty sure the zoom changes all the time even if just slightly.

#

Because of the way it's calculated.

tough abyss
#

yes it changes, but not enough to make abs((_fovNew - _fov)/_fov) > 0.001 true.

little eagle
#

ok

#

but the the spected player enters a vehicle
the spectator vision get stuck outside the vehicle(bearbeitet)
the vehicle can go away and the spected vision stay there, stoped

tough abyss
#

but on a machine running the game with 10000 fps, it will not be true also

#

when the spected unit leave the vehicle, the camera back to hin and works ok again

#

switchCamera is not working

dusk sage
#

abs((_fovNew - _fov)/_fov) > 0.001 is detecting a 0.1% chance in fov

#

That seems like it's going to change a lot?

tough abyss
#

its only is true on real zoom

dusk sage
#

D:?

tough abyss
#

its not because it is true that i will broadcast something

#

when its true i use setVariable ["fov",...,false];

little eagle
#

switchCamera is not working
Again, works for me

tough abyss
#

ok, i will test again tomorow

#

good night

little eagle
#

Must be something with your script.

tough abyss
#

yes

little eagle
#

If you think you got an error

#

Try to reproduce it with a simple repro script.

#

I don't use switchCamera much or any time at all really, so idk if there are problems with it on remote units.

tough abyss
#

i will try the most simple use of swithCamera

#

may be

#

bye!

ionic orchid
#

can anyone remember how to directly call a Control event handler?

#

for example onCheckedChanged

#

I have it defined in the class, and it gets called and that's cool, but when I do 'cbSetChecked' it isn't called, so I'd like to call that code in onCheckedChanged directly

#

okay, I think ctrlActivate was what I was thinking of

#

(doesn't work for Checkbox, so nm I'll figure something else out)

little eagle
#

Why would you need an eventhandler when you're already running a script that does cbSetChecked ๐Ÿค”

ionic orchid
#

I have a textfield beside the checkbox, and want it to toggle the checkbox when I click on the text (just for convenience)

#

I can duplicate the code that gets called in the checkbox, I'd just hoped there was a way to not have to dupe it

#

it's not the end of the world

little eagle
#

Put it inside a function.

#

I think some of these ui eventhandlers don't trigger when the state of the control was changed from inside another ui event script.

#

Otherwise you could lock up the game or something like that.

little eagle
#

code with 8 levels of indentation ๐Ÿค•

little eagle
#

People already produce horrible code with SQF.
Imagine what shit they will come up with when they get Enscript (or whatever the name) with OO crap.

dusk sage
#

Atleast they'll be forced to write with some standards

little eagle
#

Why d you think that?

#

It's fucking OO. And people will use that at every opportunity they get.

dusk sage
#

Because they won't be aimlessly writing words in N++

#

It'll give them a kick up the backside when they are goofing

little eagle
#

How so?

dusk sage
#

Well from what we can see for Enscript, it's C++ NET style

#

C++/CLI blah

#

So we already have something statically typed

little eagle
#

You're way too optimistic about that, but I'm always skeptical about new things which then turn out not so bad.

dusk sage
#

I'm just hoping they leave in something like SQF as well

#

Or they'll cut out a large portion of the community from development

little eagle
#

I would've focused on developing SQF further. Replace the internals completely and leave the syntax. Or maybe expand it.
I don't see anything conceptually wrong with it for the purpose it has.

#

I'm probably biased though.

dusk sage
#

Well something powerful and fast would be a good start ๐Ÿ˜‰ It would've been wise to use something already available in the first place but hey

#

It's very very different, from what there is to see

cerulean whale
#

Wait, what is going on?

cedar kindle
#

dayz dev tweeted that sqf is dead, they're going with enforce from take on mars

cerulean whale
#

Damn lol. Now I gotta learn new crap

dusk sage
#

Where did they say SQF is dead @cedar kindle ?

cerulean whale
#

Time to start learning

cedar kindle
#

there's no official statement if it'll be in a3/a4 tho

cerulean whale
#

No . But I want to mod dayz xD

chilly wigeon
#

I'm terrified of Enforce

#

Could be good

#

But, and I say this with the utmost respect

dusk sage
#

Something not patched together with glue ๐Ÿ™

chilly wigeon
#

SQF started out pretty janky

#

and it's kind of sorted now

#

I'm afraid Enforce will start life much the same

#

not that I have any real basis for those fears

dusk sage
#

I'm afraid Enforce will start life much the same
It seems they are using something already well established, not some scripting lang they chucked together though

#

Which is ten fold more hopeful

#

More power, faster, hopefully better in every way

#

From what it seems it's C++ / C++/CLI

#

If it's the same as TKOM

#

But that in itself can ramp the difficulty up far beyond that of SQF

#

Don't need a CS background at all

#

But certainly a programming orientated one

#

It's all well and good learning SQF, become good with it, but it's far away from a proper language

cedar kindle
#

i think it's easier to get into for beginners tho

#

which was probably the main intention

dusk sage
#

It couldn't be easier for a beginner to get into. Everything is on the wiki

#

Whether that is good or not, is another matter. Can encourage those questionable questions ๐Ÿ˜„

scarlet spoke
#

I think it would be nice if they maintained SQF for backwards compability and newcomers and at the same time offer a proper OO language for the more experienced guys

dusk sage
#

Well, for a mission maker it's a huge issue

#

The performance of SQF can be detrimental

#

Sure, there is perf issues with ArmA itself, but adding SQF on top can completely bomb that

#

And that's a major issue

#

Two battles

#

It's not really due to it being interpreted, although of course there is downsides to that. It's still incredibly slow

meager granite
#

footprints are fully local

#

Have 20 players on empty map in one place, check FPS, tell everyone to shoot up in the sky at same time, watch FPS tank

#

Hard to say, I've been wanting to do some measuring with prof clients for quite a while but I'm always lazy to do it and find people to help

#

Honestly Arma multiplayer sometimes feels like SAMP \ MTA, as in singleplayer hacked to work in multiplayer

#

Which is not far from reality

#

Considering OFP was singleplayer-only and then made to work with like 4 players for coop on LAN

#

weak foundation

#

or it was 8 players, can't recall it all now

#

Collecting them peaches is very fun indeed

dusk sage
#

๐Ÿ”ฅ

meager granite
#

@tough abyss It is round based now, 3 full rounds and then serverCommand restart

#

2-3 hours usually

#

server_shutdownServerPassword serverCommand "#shutdown";

#

session lost, its proper server closure

#

@dusk sage I once wanted to make my own Life mission with actual peaches and apples on trees as UserTexture1m_F with flat textures of these peaches and apples under different angles

#

Now its even more doable with createSimpleObject actually

dusk sage
#

Hehe, trying to visualise the textures around a tree, would certainly look funky

#

@tough abyss Point is though, it's meant to be mod free

meager granite
#

I also had idea of random household contents of Altis houses that you can break into, rob and then sell somewhere

dusk sage
#

Maybe doable now we can use our own models with simpleObj, but not before

meager granite
#

Fully local to each client

#

when you pick something up, it becomes networked

dusk sage
#

Random house hold contents, like pretend pre owned houses?

meager granite
#

And just setVariable indexes of objects missing from each house

dusk sage
#

Would be a neat idea

meager granite
#

Populate entire altis with it

#

When client approaches house, contents generate by some pattern so it would be same everywhere, when item is taken, index is setVariable'd so next generation doesn't show it

dusk sage
#

Get some AI in the houses that shout at you ๐Ÿ˜‰

little eagle
#

It's not America.

meager granite
#

They'd have guns and shoot at you if it was

#

The idea was kinda shot down with Tanoa's majority of closed buildings

dusk sage
#

Have a trash can Carla of Altis ?

#

๐Ÿ˜„

little eagle
#

Omg. I read "shout" as "shoot" ๐Ÿ˜

dusk sage
#

Tbh though, it seems Tanoa went down like a sack of bricks with the life community

#

Nobody really plays it

little eagle
#

paywall?

dusk sage
#

Nah, people just prefer Altis

meager granite
#

Tanoa seemed ideal for Life mission

dusk sage
#

Most servers I've seen that went Tanoa, have moved back

#

Minimal servers up in the grand scheme

little eagle
#

Tanoa seems like a fun place to hang around casually. It's unusable if you're milsim and operate with IFV and MBTs

#

But paywall is what would hold it back I'd think.

#

For life.

dusk sage
#

It's all jungle though, not really more encounters

meager granite
#

Why wheeled APCs in Arma 3 are so terrible and go like 20kmh up 5 degree hill?

#

I can understand tanks but wheeled APCs?

little eagle
#

PhysX sucks. It simply doesn't work with anything that isn't a four wheeled car.

#

Still better than anything with tracks. Tracked vehicles just flip over when you turn them in place.

#

Yeah, server owners want to include as many people as possible.

#

This is why DLC don't work.

meager granite
#

Wish they had low res versions like in OA

dusk sage
#

I've seen Tanoa Life servers with 100 pop die within 2 weeks

#

It just didn't go down well at all

#

Odd really

little eagle
#

I did my part and voted against the current DLC model every time the community was asked. Oh well.

dusk sage
#

Will always be a paywall, but they just genuinely don't seem to like it

little eagle
#

low res version would not have been a paywall.

meager granite
#

I really want to finish that idea household stuff now that I told everyone about it, so I will be first to implement it and never actually use anywhere.

little eagle
#

Now people come in this chat and ask for scripts to detect and remove DLC content from their missions.

#

ยฏ_(ใƒ„)_/ยฏ

#

What a waste.

meager granite
#

Wish they'd let you have like 1 hour a day use of DLC content

#

Then all this annoying shit starts popping up like it does now

#

So people could enjoy the content without being obstructed

dusk sage
#

Can people remove it from requiredAddons, so people can still connect?

meager granite
#

Not disappears, only these current notifications start showing up

little eagle
#

BoGuu, they don't physically have the assets on their machines.

dusk sage
#

Yeah, I mean purely connect

meager granite
#

Atm I see people in Wasteland run up to DLC gun and get FUCK YOU when trying to take it in a middle of a firefight

#

Must be fun for them and good incentive to keep playing

little eagle
#

That is the problem though. They connect and don't see the assets, can shoot and walk through them etcc.

dusk sage
#

Lol

little eagle
#

And then the mission makers come in here and ask for removal scripts.

dusk sage
#

Yeh, ignore that for a moment. Just wondering if it's possible

little eagle
#

To fix that.

meager granite
#

Oh yeah, why on earth Tanoa assets are not available is beyond me

dusk sage
#

Never tried removing from the list

meager granite
#

Do they fear someone would make Tanoa on Altis and make people don't buy the expansion or something?

dusk sage
#

Yeh

#

Tanoa on Altis ๐Ÿ˜„

tough abyss
#

Enforce have ifs and whiles and for, forEach? lol sorry for nonsense question.

dusk sage
#

Paint the floor blue to make islands

#

Make lots of trees

meager granite
#

Well take some island, hideObjectGlobal everything on it, spawn Tanoa trees and rocks and here you go you got yourself a mini Tanoa ๐Ÿ˜ƒ

dusk sage
#

@tough abyss yes yes yes, maybe

tough abyss
#

@dusk sage it have arrays?

dusk sage
#

Ofcourse

cerulean whale
#

Lol

dusk sage
#

Maybe not in the same sense you're thinking though, if it is C++ based

cerulean whale
#

Ye, quite different

dusk sage
#

I mean I know nothing about it whatsoever, but I can assure you it'll have the basics which make up any language, regardless what it turns out to be ๐Ÿ˜›

little eagle
#

forEach is a SQF staple, but I'm pretty sure it won't be in anything C++

dusk sage
#

You can forEach in some senses in C++

cerulean whale
#

forEach is used in other languages

dusk sage
#

But certainly not in the same manner

little eagle
#

^

cerulean whale
#

Quite different tho

little eagle
#

^

cerulean whale
#

Beat me to it lol

little eagle
#

^

#

SQF has so many commands that iterate through arrays now.

cerulean whale
#

Ye

dusk sage
#

select?

#

Oh right, alt syntax

little eagle
#

select CODE

dusk sage
#

True that

tough abyss
#

Cant we look at DayZ files to find code from Enforce scripting?

#

I will do that

cerulean whale
#

Well first off it would be in an encrypted format. ...

tough abyss
#

Ahh

cerulean whale
#

Second, as far as I am aware it is not really in use

dusk sage
#

If it's the same as TKOM, there is a snippet on BI forums

cerulean whale
#

Idk lol

little eagle
#

something something Free software

little eagle
#

like half of it is commented out. probably the part that doesn't work

dusk sage
#

๐Ÿ™ƒ

little eagle
#

Also, 6 indentation levels ๐Ÿ˜

#

All of them if's, so not even an excuse for it being OO shit.

dusk sage
#

What's it with you and indentation

little eagle
#

I want to be able to read it afterwards.

dusk sage
#

Hey

#

Atleast you don't have to use lazy eval anymore

little eagle
#

or then

#

Okay

#

Here's the deal

#

Whether I like Enscript or not

#

Depends entirely on this one thing:

#

Does it have elseif

#

?

dusk sage
#

If it's C++ based, yes

little eagle
#

weeelll

dusk sage
#

Hoping it doesn't

#

So you have to have loads of indentation

#

๐Ÿ‘ฟ

little eagle
#

fu2

dusk sage
#

You have more indentation then needed

#

Commy is going to eat you

little eagle
#

than*

dusk sage
#

๐Ÿ’ค

#

I've not slept in over 24 hours

little eagle
#

Why is a variable holding a number named "_isX"?

tough abyss
#

Strange... but if its less niche, i will be learning sonething for life

dusk sage
#

Hopefully come enscript we can become normal again, and do if (1) instead of checking equality

little eagle
#
private _isBackpack = getNumber (configFile >> 'CfgVehicles' >> (typeOf _inventory) >> 'isBackpack') == 1;
#

literally I line I wrote before

#

well double quotes like a normal person

#

And less parenthesis

#

Also naming an item "_inventory" is strange

#

lol

dusk sage
#
if (getNumber (configFile >> 'CfgVehicles' >> typeOf _inventory >> 'isBackpack'))
#

Hopefully that in enscript ๐Ÿ™

little eagle
#

No, if will only accept booleans and you will like it

dusk sage
#

Nu uh

#

Gimme those scalars

tough abyss
#

Not that learn a niche language dont have their goods, can mean that you is proeminent and this can be presented as a good thing

dusk sage
#

D:

tough abyss
#

I want to be a master in... oseudo code lol

#

So i can master any language

#

I want to be a master in... oseudo code lol

little eagle
#

(needs (more parenthesis))

dusk sage
#

Especially when it reads it character by character ๐Ÿ˜„

#

They are speed boosts, like sonic

little eagle
#

They do kinda resemble wings.

dusk sage
#

The last one is most triggering

#

Because people don't use if !() ever

#

Yeh

little eagle
#
if (currentWeapon player != "") then {
dusk sage
#

if !(currentWeapon player isEqualTo '')

little eagle
#

Why do you use single quotes?

dusk sage
#

Runaway

little eagle
#

Why do you SCREAM your booleans?

dusk sage
#

WHAT

little eagle
#

I know style is subjective, but D:

dusk sage
#

Enscript case sensitivity incoming

#

Feel the burn

little eagle
#

I'm fine with that.

dusk sage
#

TRUE

little eagle
#

1

#

Told you to toLower everything

dusk sage
#

== for them classes

little eagle
#

in and find are the problems

#

BIS_fnc_inArray or something like that

dusk sage
#

Bah, functions

little eagle
#

we do and also find

#

f1Nd

dusk sage
#

That'll be good when the language is case insensitive

#

๐Ÿ˜„

#

It'll probably be more overhead