#arma3_scripting
1 messages · Page 403 of 1
No human-readable as not script/programming. More like markdown, but simpler.
And yeah. If you want to do stuff on the local player. Use the intended way to do it. aka initPlayerLocal.sqf
But why would you use the diary for that? It's super cumbersome.
@little eagle for what?
Showing a markdown-esque text.
Use ace self interaction or addaction with hintC
He is loading it from a markdown like file
No need for diary at all
Okay, why would you show the text in the diary?
Because dairy badary
I prefer not using initPlayerLocal.sqf to avoid initialization order conflicts. I only use init.sqf and manually "branch" from there.
I'm just saying that all problems with the diary would disappear if one didn't use the diary.
👆
@errant jasper So you don't want the probably fix for all your issues that multiple people recommend to you?
How is initPlayerLocal.sqf a "fix". It is basically waitUntil {local player} no?
No
not really.. no
lol
From the initialization order, it is clear that init.sqf is run after initPlayerLocal, so how would running stuff earlier make it work?
@errant jasper Just try the things recommended to you first and see if that fixes it. If not we can go further. Start with the easiest thing
I will try to what you guys suggest if I do not get it to work otherwise. But I think the reason is pretty clear. I neither run the server, nor am creating the mission, I just script for it. I unpacked the mission from the mpmissioncache from last nights session, and behold, the files were old.
So the guy making mission running the show, forgot to use the files I sent him.
@errant jasper That explains alot
how to remove the thermal vision of laser designators?
https://community.bistudio.com/wiki/disableTIEquipment maybe call this on player
hey you guys know A3PL's admin spawning fire script and the script to put it out with a fire extinguisher?
@peak plover ArmA3 Project Life
😄
Is there a way to make a script that lets you burn down builsings which are destroyed or left in a huge fire afterwards??
is it possible to retexture guns using scripts?
i dont think so
With a mod, sure
but he said with a script
Yes it would be a script
That cannot be a config
@unborn ibex yes
If he ment Without mods, then the answer is most likely no
don’t think so? you can’t reference the weapon object ?
Yep, thats why
With Config.cpp, maybe. But that's, as Nigel said, only possible with mod (IF)
I think "with a script" means "with a mission".
And the answer is no afaik.
Unless someone found something genius.
Like with the backpacks.
Yeah, the public modes would be all over this.
What was found with backpacks?
Retexture with mission.
Which obviously doesn't work with weapons, but when you're not used to how Arma operates, it's strange that this one can be retextured like that, and a weapon or vest and uniform can't.
Was ability to retexture backpacks a secret? Its separate entity after all.
What do you mean a secret? I can't remember BI ever talking about it, but I never paid much attention to mission only.
And uniforms and vests also have their container dummies, so they're also separate entities in a way.
If only we could get proxy models as entities into variables and set their textures.
Proxy compatible setObjectTexture supporting weapons.
But even that is shit compared to what could be. Referencing all items by ids or as entities.
That was a planned thing, iirc :/
It kinda exists for mag ids.
does removeWeaponTurret also remove all magazines that turret had?
and thats a negative :/
Question is if it removed the currently loaded one.
it should do that. but i mean if the turret is no longer a part of the vehicle all valid magazines for that should also be removed since what are you going to shoot them with
but maybe cause interchangable turrets having same mags
You don't remove the turret. You remove a weapon from the turret.
WeaponTurerr that’s what I meant
?
Yeah. "Turerr" tho 💦
iPhone autocorrect remembers incorrect spellings 😢
Auto"correct".
Korrekt!
Autoattempt.
yes
Jawoll
Hello everyone, quick question, if i want a player to execute just ONCE an action per reboot, how should i proceed
@compact maple reboot as in respawn, connection to server or game restart? 😄
connection to server, keep a var in missionNamespace
server restart
ah server restart, hm probably keep a variable onthe server then 😄
I mean,
X player do an action.
X player disconnect.
X player come back immediatly.
X player try to do the same action but he cant cause i dont want it
After the reboot, he can do it once
then he has to wait the reboot of the server to do ti again
use server time
impossible 🤥
or maybe i can put a persistent variable on a player ? even if hes disconnect ?
no
Save player uid on an array onthe server
Or just use his UID
check the uid when trying to action
^^
I've not worked with DB, but do the DB have functionality to save the current date?
that's the entire point of it
oh wait, DATE, not DATA
Depends on what DB.
There isn't just one DB you know?
Or do you mean DB as in Double Bingo? I don't think that can save anything
Or the Double Bollocks DB?
Or Dingo Bum?
You'll struggle to find one which doesn't have the ability @peak plover
Or Dinkel Berg?
Deutsche Bahn.
That one especially has problems with dates and times
True. They're always on time when they say it will be late, and always late if they say they're on time.
I'd like to extend 3rK's problem
How do you let player only do an action once irl day. During this time the server might restart multiple times
a database would work, but how do I get a date to the database?
CURRENT YEAR
Or just get a extension to give you the date and use that
instead of trying to hack around with databases
🇨 🇺 🇷 🇷 🇪 🇳 🇹 🇾 🇪 🇦 🇷
extdb3 will also return date/times with offsets
but sounds like saving it in an array variable on the server. is really what you are looking for.
During this time the server might restart multiple times
So...
profileNamespace along with date I guess
That needs a dll
how do you date without custom dll
not at all
[8:25 PM] 3rK: Hello everyone, quick question, if i want a player to execute just ONCE an action per reboot, how should i proceed
He wanted it once per server restart, no need for profilenamespace, normal variable serverside will do the trick
No need for extensions either, just an array with playeruid of who did the action
Yyeah, we found his fix. But now I want to know how to get a date without extensions?
Why do you think people made extensions just for the purpose of getting the date?
Because it's already possible without Extension? I don't think so
So only way to do it once per 12 hours would be db or extensions
But database without extension also doesn't work
You also don't have to make a date extension from scratch
? what extension are using for db?
not
KK has realtime Extension and extDB3 also has it
just question too many lol
Since we already have so many solutions to getting the real date into sqf, you obviously have to create your own one.
I thought it was too trival of an issue
It is. Which is why there are already tons of solutions for it
I'd welcome if this were an sqf command :/
.> :squirrel: <.<
While we're reinventing the wheel, you could have a batch script write it to a file and have the server loadFile it
hmm pretty sure i remember someone had rpt scanning in arma2 linux servers to implement a persistence system. pretty sure that was a thing
Error like the following doesn't cause any harm regarding your addon showing up in-game:
Updating base class <class>-><class>, by <addon>\config.cpp/Cfg<something>/<class>/
Into the trash the guide goes.
"ignore those 'errors', they just mean we don't know how configs work"
I blame BI for the bad ui configs normalizing it by having ~40 of these themselves.
Everything has errors if you dig deep enough, so no idea what you mean.
aah, I don't have it right now
But there was a new script error in the logs
like functions or ui_f
can't remember
Also
the splendid camera
{BIS_fnc_camera_keys select _x} count (actionkeys _this) > 0
21:10:53 Error position: <select _x} count (actionkeys _this) > 0
splendid camera has errors? NO way!
You know what would solve this?
Remember when you'd press forward and the game would crash?
I had a joystick key mapped to something that's used in slpendid
@little eagle hold shift so it does not close so you can fasster
But yeah
param would fixed that porlly
member when deleting a vehicle being lifted would crash the game?
Remember when closing a display in it's onLoad event would crash the game? Oh, wait.
member when littebird minguns had dispersion and were fun to use?
Well pretty much it would be great if there were less vanilla errors and rpt errors were shunned and made into the demon they really are
reviewed, deemed uselss
Shoot a unit that is in a vehicle. (You MUST shoot him, otherwise this bug will not work)
Kill the unit by SHOOTING him.
Try to delete the unit. {deleteVehicle _x}count allDeadMen (Seems to work ~75% of the time)
Good Evening , we are trying to get a small firework script up and running. Sadly we do not get the sleep command right. Can someone give ahint, what we did wrong? '''for "_x" from 1 to 20 step 1 do {
[getPos (selectRandom startpositions), 'random','random'] remoteExec ["GRAD_fireworks_fnc_prepareFireworks", 2];
sleep 2;
};'''
[getPos (selectRandom startpositions), 'random','random'] remoteExec ["GRAD_fireworks_fnc_prepareFireworks", 2];
sleep 2;
};```
that is the whole scrip we try to execute from the admin console
ALso, are you sure you want to remotely execute this on server?
Is the GRAD_fireworks_fnc_prepareFireworks whitelisted?
ignoring the sleep 2
If you don't loop will it also fire all at once?
remoteExec'ing that func only once?
then it will only fire once
it will run trough the loop, executing all 20 shots without delay
for "_x" from 1 to 20 step 1 do {
[getPos (selectRandom startpositions), 'random','random'] remoteExec ["GRAD_fireworks_fnc_prepareFireworks", 2];
sleep 2;
};
};```
That really did it
now it is working as intended
thanks for the quick help
Shouldn't trying to sleep in unscheduled cause a script error and abort the script? instead of running the whole loop at once?
from expirence i can tell you: it is running the whole loop at once . . .
You had a couple dozen jobs BI.. A couple dozen!
(I'd say "you had ONE job" but BI screwed up way more than one.)
the spawn puts it into scheduled enviroment doesnt it
yes it does
in code above there is step 1 what for ? if default is 1
to feel better about it
rgr
same reason he added a sleep in a for loop
To make sure the loop runs by 1 each time and not 1.0000000001
Or 0x3F000000
I feel kinda bad for knowing that in hex
How often is sleep checked?
several times per frame afaik
Best solution
slaps @lone glade with a rolled newspaper
WaitUntil loop or perframe EH
😭
That you hook all your code into
Once per frame. Just like any other suspended/scheduled scheduled suspendable script that is suspended/schedulended
waitUntil{
{
_x params ["_code",["_unscheduled",false]];
if (_unscheduled) then {
isNil {call _code};
} else {
call _code;
};
}forEach nig_main_scripts;
!isNil "nig_main_loop_cancel"
}
But be careful not to mix that up with a scheduled unscheduled unsuspendable suspended script with a sleep
But with a uiSleep it would be fine
@peak plover don't need a nil at end of isNil
can't be worse than my number that was technically a number but somehow ended up making x + n != x + n
🤔
Euwwwww... Don't remind me of that
Don't even wanna
already have tears in my eyes just thinking about it
a number that wasn't equal to itself.... I have no idea how I produced that
probably the worst bug I had to fix in ACE Arsenal
now i have to check if I documented the line that fixes it... just in case
yep, phew.
_maxLoad = parseNumber (_maxLoad toFixed 2); // Required to avoid an issue where even though the typename returns "SCALAR" it doesn't act as one.
10/10
Want me to make a fake scalar that is actually a string and code where the string doesn't even closely represent what the code does?
pls, no bulli
gives @lone glade a boulette
Quick question guys whats better for performance?
For Police lights everytime they are turned on they are remoteExeced to each player and ran in a loop
Which is better?
4 while loops handling individual cars (spawned) or
1 while loop that does all the lights in one big loop
both make no difference
if your perf is shit you have 3ms per frame regardless
switching between multiple spawned scripts has a tiny overhead. About equivalent to having an array with one element in the script
so... 1 while loop is theoretically better. but doesn't really matter
So... Whatever is easier for you
not using loops is better than optimizing one
And if you want the perfect answer. Use a time based animation. Which isn't a script at all
For lights?
yes?
doesn't BI have one for the van ?
Make a vehicle with lights by default?
Im not following, For example we have police lights on our SUVs
Yes.
How would you go about doing that?
doing what? Making a time based animation in the model.cfg of you custom police lights model?
Yeah we cant do that as we dont have models, were not a modded server
Well then use a script.
As you already do
I didn't say you'd have to use a animation. Just said that would be the perfect way
Yeah I understand that I was just seeing if there was a better way. Just problem is at the moment is when your turn the lights on every single person on the map 'knows' about them
Thanks for the help
You can detect if the vehicle is in range.. But that detection requires more processing than just turning on the lights would
Have an array of all police vehicles and check once every minute which of them are close enough to simulate their lights
should work fine if you don't have teleportation
Hi ! ✌
A friend of me is making a discharge crane but when the vechicle is attachTo to the magnet the vehicle is laggy. Here's the video to understand the problem : https://plays.tv/video/5a46d29c686504bade/casse Do you know how to make this smoother? Regards
Read wiki
Okey that might be a little unfair. It's not really in a place you'd look in
was going to say that we had already read from top to bottom
Ah overread it
I even overread that part in the note while I read it searching for that
probably broken sqf
The keyword is yank
considering this is a vehicle and their update interval is fairly small it should be smooth
oh wait
it's left floating
inb4 it's an object, that would explain it
nah, the detach was made 1 sec after the end of the vid'
the normal map is not the question :p How can this be the sqf if it's the vehicle that yank
not the vehicle, your code to move stuff around
objects will still look "laggy" due to their update interval anyways
but for vehicles it should be fine
It's a vehicle, that's the problem 😩
yeah, it's your code
Wait, i'll show u
I don't think i'm preparred for what i'm about to see
no, you're not
Or is it maybe what is written on biki about things being yanky?
yeah, but it's not that terrible
you could use ropeCreate as dedmen described in the center
https://hastebin.com/ijugepuwic.pl (Life_Target is the truck)
Does it happen with every vehicle?`
or only heavy ones?
Have you tried if it's the ropeCreate note issue
Also.. Someone who doesn't use indentation nor any uppercase letters. I doubt the not dumbness
the issue isn't in this code anyways
I don't see any ropeAttach / attachTo
nevermind saw it
attachTo line 34
The weight make no sense in attachTo
I'm currently guessing towards the rope
is it?
rope is in the crane
this is the code attaching stuff to the cranes thingy that is attached to the rope
wait
the rope isn't a "rope"
does the crane have a rope or is it moved by animation`
animation
Animation
Can you show me the model.cfg part of the animation
There's no createRope, only attachTo with 2 memoryPoint
try to create a tiny as fuck rope between the "attached" object and magnet
you'll bypass the issues related to network updates
u think ? mmmmh that look weird
try with a player inside the vehicle
you have a static (cannot move without driver) object attached to another static (also cannot move without driver, theoretically) object. So it sends very few updates which is probably why it's laggy
I have an Idea! Just make the crane lift slower
Solved!
Captain? I'm a Furry Fox Dedmen Kirby Magic Spider. Not a captain
do you know what's the most intensive simulation type dedmen?
ropeX, they eat frames for dinner
I could tell you what's the most simulated simulation type
thingX?
If my dev drive wouldn't be dead
I can also still read that drive.. kinda.. theoretically.. A bit
Right now it goes to 100% load and then disconnects after a couple minutes
I need a linux magic I guess
reminds me of my first external HDD ever, shipped dead
couldn't power it, I thought it was me having too many usb plugged in
nope, just dead
My HDD currently is connected via a connector thingy that I broke out of an external HDD enclosure after I broke the drive out of it and used it as internal drive. The drive belonging to that connector still works
😄
The best thing on this situation is that I can finally see my GPU's RGB
I turned it off, it's too annoying :/
I have closed side panel and blue LED fans
so.. I have hidden lighting that you only see when you open the side panel
Sooooooo, sorry to cut you but with a player in it, it doesn't lag anymore.
On my back exhaust fan all but one LED's are dead now.
exactly what I thought
As that's like.. 8 years old now
try to create a tiny rope between the object and the magnet
he'll
@glossy maple player in crane or vehicle you pull up?
in vehicle
both are vehicles :U
:kappa:
Crane isn't a vehicle
raises fist goddamn discord
Gotta get the newspaper again? 😄
kappa
Ouh..
If player in crane would work you would be fine because a crane wouldn't lift stuff by itself but...
ugh.. ugly
Or maybe make the crane a physx vehicle?
baer can probably go on for days about the fuckery that is vehicle ownership with ropes....
nah
it's the vehicle being attachedTo that doesn't update fast enuff
"physx" Abort mission !
Make a highly advanced Intercept based hack that changes the simulation interval on the fly?
or abuse how ropeX fucks with them :kappa:
Make a ropeXXX that simulates 10 times a frame instead of once?
I'm bored so I'm very happy for you guys to be here and ask question stuffz
Everyone feel free to ask stuff!
Please no Life shit tho
Wait... We are already ... crap
It's a Dedmen AMA
DAMA
Oh you don't like life roleplay ?
(except life)
I have dabbled in the life
out of sheer curiosity
and... let's say I was fascinated by how people could write such code
is listening carefully
you wouldn't believe how little effort some servers put for such amounts of money
also, kids, so many kids
Depends which server
that's why I have a unit to play with
:kappa:
Back when I was doing freelance stuff some guy wanted to pay me for a lotto script. I started and finished it in like half an hour. Then he asked me to implement it into their "framework" I gave up. I could make like 3x the money by just selling already detected hacks
hahahahahhaha
nice one
I still don't get what's the deal with those "mission making" frameworks
I actually didn't know that the hack was detected.. But I'm happy that that guy found out and even payed me for it
just have a template with 60 units and a properly documented description.ext, poof done
am still salty about having to download unsung just to realize that those backpacks have no empty base class
12GB
600KB/s
?
"600KB/s" for 12GB
yeah, takes about half a day
Lifer creates forum thread. He has a config error message. He already searched for hours and didn't find anything.
It says found " instead of , in line 69
God...
Hum... we have... dab animation on our server... Not my idea oc 😦
But we have this for the balance : https://www.youtube.com/watch?v=52KwV3D5Etg
Uhhh. That's nice. If the model isn't stolen that is.
That's probably the most awesome life thing I've ever seen
it was a free model oc
well whomever imported it did a good job
free model from a "free models" website?
oh god my sides, that pickaxe
Don't look at that alganthe
many Lifers using stolen stuff say either it was free or they bought it. In the end they got it from someone who ripped it without telling them
Arma isn't perfect for melee weapon 😦
well, you put effort in your stuff
@glossy maple You cannot know that's the problem.
so at least it's a tiiiiiny bit better
If a guy you pay for making a model takes a week to make a model and gives it to you. But in the end he just ripped it and did nothing for the rest of the time. How would you know
i'd be very, VERY supiscious of someone shitting a model in a week
I made CBA model in a day
clearly not the same level of complexity 😄
It's yours ?!
Yeah if for exemple we take a free 3D model in a website we can't be sure if the man who as upload is the author
lmao great job
LESS SHARPENING PLS
MORE GLOSSY
How download for that ?
Bright enough?
how many *
Download for what?
for this mod
which?
This logo in 3D
Not available
you....
:U
chhhhhht
man, i'll make research for that
I wonder why no one is triggered by CBA being GBR instead of RGB
because nobody cares 😛
My triggering is reserved for people with stupid ascii names 😦
UTF-16, GOTCHA
unicode
Dude. I'm a fur fox. Get real
dedmen are you just larping as furry or are you actually a furry?
Take a guess.
well he is german, so probably he's really a furry? 😦
https://dedmen.de/sharex/mspaint_2017-12-30_02-23-36.png I'd say you're good
Dunno if I'm a furry. But it luks cute
No It's @lone glade's line. I drew it onto him
Can we get some scripting questions to get back to topic
Just remembered I put noodles in the microwave 20 minutes ago.. oops
"hmmmm, moist noodles"
I ate a 1KG "bucket" of ice cream yesterday AMA
we wuz NUTCRAZCKER AND REDMEAT EATERS AND SHITTTT
What kind of ice cream?
vanilla
@lone glade count vs forEach
with much milk? Or cheap air icecream?
foreach
apply
iforeach3
yeah, with good amounts of milk
It's faster than count
getout!
around a 1000 calories
Count fater
if count is so fat, maybe it should do keto too uh
btw foreach could be about 40% faster if BI wouldn't check idiotic stuff at runtime that can be checked at compile time
I'm out, see ya guys and thx for the crane-magnet-power-rope-yank-3000
But.. Oh well
I'm like the worst veteran on here. Furry and Unicode crap. Right after ALLCAPS playerunknown and SNAKE_CASE T_D
Oh.. I forgot Dscha
The furry alone will give you first place, don't worry about it
Well .dscha is retarded, so it's mean to bully him
so there's that
I also dunno why no one is triggered that my avatar is slightly offcenter
it's not mean, it's inaproriate
gotta embrace the unsugared icecream special stuff
plus nigel, aren't you gomad?
we ontopic noaw
DEAD
Dozen Eggs A Day
@lone glade What's the state in france on Ice cream made from prepped sirup stuff?
banned
corn syrup / sugar is non existent here
syrup
not honey
and yes, everything is "real" sugar here
afaik corn based syrups are banned in the EU
due to the insane amounts of fructose they contain...
Not sure. We have lots of fake "self-made" ice cream in germany
Basically people just putting water/milk/air into pre-made sirup and done is the "self-made" icecream
holy fuck that's slimy
also we have limitations on what you can call yogurt here
not using one of the authorized bacterias? not a yogurt
What do you pay for a liter of milk?
Around 1 europe dollar
thaat's a good question since I buy them in packs of 6
I think in Germany we are under 50cent now
Whoa
Heard french people pay more for food. So wanna know something I can compare
Isn't the majority of german lactrose intolerent since the immigrant crysis?
about 70cent for a liter 1.5% fat
around 0.80, 0.85€
So not that different at all
I live near paris, so it's a bit more expensive
prices vary a lot between the north, south, and the "empty" regions
also fuck me raclettes are expensive
the cheese alone was around 15€ for 4 people T.T
😄 Have one in a box next to me. Two months ago I didn't even know what that is
like. a raclette grill in a box
no
search it and thank me later
properly done it's probably one of my favorite things to eat
Looks like Kartoffelauflauf with bacon ^^ Sadly I don't have a pan thingy to do that.. Uh.. google translate
pan? A PAN?
baking dish?
A glass dish thingy that you put in oven
yes, those long and deep ones
now I wanna port CSE rations or whatever the food module was called 😄
we're 4, so we make about 1KG of it everytime
i'm surprised 3 of us are still fit and not obese as fuck....
I should've gone to bed 3 hours ago
#arma3_scripting can't be worse than discussing milk prices in 2018
Hey guys, what would flagOwner be used for? Is it just for setting the locality of the flag to one object?
unused in arma3 afaik
oh wait, no, some RHS vehicles do use that
and yes, it's for the locality of the object
:/
i'd say test it, i'm not even sure RHS uses the flag commands anymore, it could also be an attachTo
Im more talking about setting flag side on a flag pole
I don't think it works on poles
considering flags are sideEmpty I doubt it
flagOwner, setFlagSide all works fine
On flagpole setFlagSide will add action also "to take that flag"
what would flagOwner be used for?
It will return carrier of the flag
That is like build in CTF game mode system
I need some help with altis life? does anyone know it kind of well?
what sort of help?
im having a problem with the spawn menu
Best place for questions about "life" things https://www.altisliferpg.com/
i have ported the mission from altis to Elaine County
i figured i would ask in the discord, thought it might be faster
yes they have discord
oh lol
i didnt know that
thank you
no one is responding over there so im going to post it over here too
0 Error in expression < displayCtrl 38502),1,0.1,getMarkerPos (_sp select 0)] call life_fnc_setMapPosit>
23:43:00 Error position: <_sp select 0)] call life_fnc_setMapPosit>
23:43:00 Error Undefined variable in expression: _sp
23:43:00 File dialog\function\fn_spawnMenu.sqf [life_fnc_spawnMenu], line 34
23:43:00 "Past Settings Init"
gl
Bye
@everyone as anyone ever heared of a arma 3 moddder called KangaroO
@limber rune No, and the everyone tag is disabled for a reason
sorry i didnt know
@limber rune Why would you want to tag every single person on this discord?
to see if anyone knows him and why are you being so hostile
@limber rune No, tagging everyone in the entire server would do zero good and all the bad
Dude like chill your being very hostile I'm sorry
I'm the most important one here, so if I have a question, everyone else has to stop doing what they're doing and pay attention to me.
Also, stop being hostile to me.
Yes feel free to tag 10k people any time and all will run to help you asap...
@here @everyone should results in instant kickban
Starting with you? 😄
Only blue names should be allowed to use them.
I never had problems with that FF or Chrome, Win 7 or 10.
what are you talking about?
"Discord name detection" - I thought you're talking about tagging people and how it always goes wrong for some people.
So you use the BrowserVersion, instead of the DesktopClient?
Yes.
urgs
electron apps -> utter shite
i've only installed the desktop app because the web one can't use anything other than my default (wrong) audio device
Electron apps are utter shite because..?
because javascript isn't fucking meant to write desktop apps
atom crashes when it tries to open """large files""" aka anything bigger than 5MB
🤔 I am wondering, what he is talking about
who, me ?
Yeah
So you use the BrowserVersion, instead of the DesktopClient?
Discord, Slack, etc -> Never crashed on me. No clue why you say "all of them are "utter shite""
because electron
🤦
🤦 electron might not be the best, but ive never had a discord crash. Atom is crashing cause its atom. VSC uses electron and never crashed on me so im not sure what you’re on about
@lone glade
Also, you say javascript isnt meant for desktop apps, yet you say it was an attempt to implement it in the first arma game 😂😂😂😂
VSC is using typescript
i'm surprised microsoft even made VSC and typescript
and yes, web containers are fucking stupid
A goddamn chat app shouldn't be 140+ MB nor take that much ressources
Are you dumb? VSC is built on Electron
it's less shitty due to typescript
🤦
stability > filesize almost every time
linux distro
I was thinking about os.js
or the other abominations that were created
It's funny because the last 10 years browser engines have been trying to implement and adopt things that are natural for desktop apps. Such as being able to save files on the user's computer. Drawing graphics, canvas and now webgl, and so on.
The internet is changing as we know it, these things will have its purpose one day.
All I can say about OS.JS is, must have been a fucking hazzle to write.
tbh we're moving inexorably towards OS agnostic applications that are web based
and I find that incredibly stupid
Nah I like having all my files and most of my applications work on everything
that doesn't require web based apps
THIS CHANNEL IS FOR SQF/ARMA. K THX BYE.
sure, it's harder and you need to learn other languages than js but some do it.
Hahaha
ROGER COMRADE COMMY, WHY ARE YOU YELLING SHIFTY?
Alright commy2. We need an OS in SQF.
^ this tbh
Buggy and behind schedule OS*
that's star citizen (sarcasm implied ™)
can't disagree
And shell scripts in this new OS will of course be pseudo C++ classes
everyone knows the best os is templeOS
Well, at least one person knows for sure.
stop please
we were discussing milk prices in europe yesterday
^^
so at least there's some improvement, we're talking about software 😄
I was directing it towards the action of spreading the existence of templeOS
😄
I'm fairly certain it's literal heresy
those youtube videos (and the language used in them, especially his favorite insult) are gold
Didn't you parents tell you to not knock it until you try it
his words "should" feel insulting, but coming from terry it just makes me laugh
HolyC is up there as one of the best puns I've ever witnessed
But to go through and actually develop it is artistry
A PUN?
You must be from the CIA
He seems like the kind of guy to only trust IRCs
I have made God's temple. He tells me what to fix. He wants it perfect.
God told me 640x480 16 color. I would have stupidly done higher resolutions. Now, do you see He is supernaturally intelligent?
God says... geometry dully answering stretched smarting txt whatever result reposing changed equally realities ill gosh revolution Sri_Lanka would-be drive PURPOSE chooses infinitely comfort shamelessness poison Windus unholy talkers
arma isn't god certified 😄
Wtf btt.
Televangelism & C++ my friend
Have you guys ever communicated arma with outside world like webpage?
Is it too bad for performance to run a loop that constantly checks for a variable change in DB?
the community i'm part of has an "armory" system
you buy gear on the website and retrieve it via a GUI in game
So for ex. run a function from a web page?
ah, nothing like that
Just read and write from DB?
It depends on how you implement it @peak plover
Db performance etc
If I want to call in a mortar strike by inserting coords on a page, is it stupid to have a
per frame loop that constantly checks for DB to see if (execute function) has something in it?
Naturally, it will affect performance, you'll just have to minimise that
Okay
Do you really need to check every frame
event
I didn't meant on the DB side
also, does it have to be on a webpage?
why can't it be an in game GUI?
Just wondering about shit is all
Web page works on phone
Open phone
Call in airstrike
or tablet
It's like bf4 tablet commander
Just think carefully about how often you need to check for the coordinates, you don't need to check every 20ms. Remember that callExt is completely blocking, regardless of its initial context
do as little callExt as possible
hmm
Using something like extDB3, the communication time is small, so quick and infrequent calls will be almost negligible
But are there alternatives to constant db variable check?
socket
Can't you write the extension in a way where it retrieves the whatever and doesn't block and just returns not ready until it's done with whatever it searches on the web?
Depends if you want speed or not
You could even fetch the contents of a webpage for it, but it'll be much slower
@little eagle Yes, exDB3 has an async API. But you still need to check whether the result is ready with more calls
Yeah, but that is negligible.
I could probably do it without DB
this nodejs extension would let you push event from web server to arma
And small results from any of the supported DBs are usually ready instantly
class faster_movement {
Init = "["Man", "init", {_this setAnimSpeedCoef 1.15}] call CBA_fnc_addClassEventHandler;";
};
};```
How to make it work properly? I want all characters to move a little bit faster, even ones that are spawned by scripts and such.
no idea
sec
isn't animSpeedCoef for the current anim anyways ?
class Extended_InitPost_EventHandlers {
class CAManBase {
class faster_movement {
Init = "(_this select 0) setAnimSpeedCoef 1.15;";
};
};
};
InitPost, not PostInit for events for objects.
DELTE THIS
🙀 🙀 🙀 🙀 😼
🇵 🇦 🇷 🇦 🇲
How could you commy
To use select in something as important as an event handler?
I'm 99% sure this will not work with advanced fatigue from ACE, because adv fatigue overwrites the anim speed coef all the time.
Because there are like 100 soldiers in a mission, and 100 select are nothing to worry about perf wise.
if ((getAnimSpeedCoef _unit) != 1) then {
_unit setAnimSpeedCoef 1;
};
That ace 😐
might be because of my azerty keyboard but it isn't 😦
Just make a macro for param [0]
should be
private _fat = _unit getVariable ["ace_customFat",(missionNamespace getVariable ["ace_customFat",1])];
if ((getAnimSpeedCoef _unit) != 1) then {
_unit setAnimSpeedCoef _fat;
};
So many small parts like this should have variables in ace
Make a PR.
^ this
*param
plus if they aren't documented good luck knowing they're here
I've added my own to aimcoef, jamming and dispersion
Makes for good customizability per mission
when i gather a helipad with nearestObjects i'll get this response.
127b65600# 1815999: helipadsquare_f.p3d REMOTE
my question now is: i expected an location like this [18444.2,18000.5,0.0000554]
so is "127b65600# 1815999" anything that i can work with?
that's not a position, it's a location*
getPosATL ?
@lone glade CBA settings. I don't really see how they would be "HARD" to document
but nearestObjects should give me an location isnt it?
It's called "position". LOCATION is something else.
locations aren't positions
nearestObjects gives you an ARRAY of OBJECTs
And getPosATL gives you an PosATL ARRAY of an OBJECT.
Like the example you posted.
e.g. [18444.2,18000.5,0.0000554]
ye
_objPosition = getPosATL nearestObjects [player, ["HeliH"], 200];
would this work then?
No.
You need OBJECT, not ARRAY
nearestObjects reports an ARRAY full of OBJECT
nearestObject reports one OBJECT
(no s)
_nObject = nearestObjects [player, ["HeliH"], 200];
_nObject = _nObject select 0;
_objPosition = getPosATL _nObject ;
Sure.
like that?
Though nearestObjects could report an empty array.
And then _nObject is undefined.
In case there is no helipad there.
_nObject = nearestObjects [player, ["HeliH"], 200];
if(_nObject != undefined) then {
_nObject = _nObject select 0;
_objPosition = getPosATL _nObject ;
}
undefined doesn't exist
how do i check on undefined then
!= or isEqualTo depending on the type and the need for case sensitivity
private _nObject = nearestObjects [player, ["HeliH"], 200] param [0, objNull];
private _objPosition = getPosATL _nObject;
Just avoid undefining the variable in the first place by using...
PARAM
k
I hate that I cannot use != with bools.
why the hell would you ever do that muzzleflash
If have two boolean variables I want to compare?
🤦
You never compared two boolean variables?
I have no words
Is it for an if statement?
isEqualTo
So I regularly check whether to keep a visual effect:
if (_effectIsActive != _effectShouldBeActive) then { //Toggle effect...};
if (_bool) then {
if !(_bool) then {
Either of these ^
Using isEqualTo true/false is a shootable offence.
Yes, but I don't do that
but before that you're poked near death by a crowd with pitchforks
electrom + isEqualTo true masterrace
Now it's a game.
if ([_effectIsActive, _effectShouldBeActive] in [[true,true],[false,false]]) then {
rate
we can go deeper
Lol. Of course I do if (not (_effectIsActive isEqualTo _effectShouldBeActive)). But I still think it is lame I have to do that.
if (_effectIsActive && _effectShouldBeActive || {!_effectShouldBeActive && !_effectShouldBeActive}) then {
I think i'm starting to develop dementia
I think you are on to something. I mean we can't confirm that anyone who got dementia, did not look at SQF code. Conclusion sqf code causes dementia.
Hold onto your butts:
if ([_effectIsActive, !_effectIsActive] select _effectShouldBeActive) then {
now wrap than in a ttc
That will work. And that is the best thing I can say about it
if (count (str _effectIsActive + str _effectShouldBeActive) % 2 == 0) then {
You making an obfuscator? 😛
I wouldn't call that obfuscation
I declared it a game. The dumbest solution wins.
I don't have the mental fortitude for this kind of exercise
You mean insanity?
He was being polite
? : should be implemented in sqf
? is in sqs I believe.
sqs 😮
Yes, sqs.
never used it. i thought it was pretty much never use that again?
It's dead and that's a good thing.
security
pff @lone glade
laughs are heard in the distance
they will do LUA arent they?
intercept
nah, enscript is C like afaik
C# im working on a mono implementation
@tough abyss games are created with scripting languages because it is faster to develop
They should just implement intercept tbh.
yea
right but now that armas pretty much done a lot shouldnt they just go ahead and export their API to C++?
anyone on dev branch can confirm the game takes significantly longer to "load" ?
you want to literally compile against arma your mission/addon each time you create one?
you cannot dynamically create missions with static compiled languages
unless you compile
like, the game doesn't start loading instantly after clicking play
no mods, it just takes much longer than stable right now
Maybe they have some unbinned configs on dev.
@queen cargo hmm? sorry i dont quiet understand what you mean by that? Compile it once and it should work fine?
or, take what is written in the first entry on google for that question that i linked above @tough abyss
In games, game logic and configuration are typically contained in script files. These scripts can easily be updated by non-programmers (like the designer) to tweak the gameplay. Script languages are easy and act in a forgiving manner for that purpose.```
huh, I wonder what happens if I unmount my P drive
true
designers are not programmers
i suppose
and that is the full story
The bike shed issue is real
Yeah, having a script and a code language is useful, though it's sad that the code part is not accessible as well for modders.
^+1
Aside from dll.
one thing is true though: in theory it could be possible to create a scripting language that can be later ported into actual c++ code
sqf for missions C for mod
Both for both and the creator chooses.
yes
perfect
also @lone glade System.Security.Permissions < saves a lot of hassle and security concerns
I have PTSD from windows permissions
kappa