-
Content Count
2494 -
Joined
-
Last visited
-
Medals
Everything posted by sarogahtyp
-
initializtion Where to place my script
sarogahtyp replied to rkemsley's topic in ARMA 3 - MISSION EDITING & SCRIPTING
I dont know what the problem is, I can't see a mistake but you can try to add this at the very beginning of the code: waitUntil {sleep 1; not isNull player }; if this is not helping then just delete the line after testing.- 27 replies
-
- arma 3
- addcuratoreditingarea
- (and 6 more)
-
Deleting Vehicle Crew
sarogahtyp replied to FredTche's topic in ARMA 3 - MISSION EDITING & SCRIPTING
I doubt that this line hint _unitName; // return "heli1" gives you the hint of what this line did before unitName = vehicleVarName (thisList select 0); you mix global and local variables also for deleting you use heli1 and not the object from thisList. and it won't work is not the thing one can work with. its just too specific... maybe this works: private dummy = { deleteVehicleCrew _x; deleteVehicle _x; } count ( thisList apply {vehicleVarName _x} ); -
initializtion Where to place my script
sarogahtyp replied to rkemsley's topic in ARMA 3 - MISSION EDITING & SCRIPTING
pls get not too specific I may not be able to handle it- 27 replies
-
- 1
-
- arma 3
- addcuratoreditingarea
- (and 6 more)
-
Run a Post Processing Effect on one player
sarogahtyp replied to LiderrGaming's topic in ARMA 3 - MISSION EDITING & SCRIPTING
https://community.bistudio.com/wiki/Arma_3:_Event_Handlers#Multiplayer_Event_Handlers ... but there is no call for mst_fnc_ppe in your EH ... -
initializtion Where to place my script
sarogahtyp replied to rkemsley's topic in ARMA 3 - MISSION EDITING & SCRIPTING
No, he just checks if an independent is near and deletes the editing area if that is the case. but there is an ID conflict which I did not see... EDIT: conflict fixed now- 27 replies
-
- arma 3
- addcuratoreditingarea
- (and 6 more)
-
initializtion Where to place my script
sarogahtyp replied to rkemsley's topic in ARMA 3 - MISSION EDITING & SCRIPTING
I did not check every command of your script in biki because this is your own job but something like this should do what you want. Put it in onPlayerRespawn.sqf and read those event scripts description in biki. private _zeus_curator = objNull; private "_areaID"; switch (player) do { case BLUFOR_Player001: { _zeus_curator = ZeusBLUFOR001_Curator; _areaID = 1; }; case BLUFOR_Player002: { _zeus_curator = ZeusBLUFOR002_Curator; _areaID = 2; }; case BLUFOR_Player003: { _zeus_curator = ZeusBLUFOR003_Curator; _areaID = 3; }; case BLUFOR_Player004: { _zeus_curator = ZeusBLUFOR004_Curator; _areaID = 4; }; }; if (isNull _zeus_curator) exitWith {}; while { alive player } do { if ( { _x distance2D player < 40 && side _x isEqualTo independent } count allUnits > 0 ) then { _zeus_curator removeCuratorEditingArea _areaID; } else { _zeus_curator addCuratorEditingArea [ _areaID, (position player), 40 ]; }; sleep 0.5; };- 27 replies
-
- 1
-
- arma 3
- addcuratoreditingarea
- (and 6 more)
-
removing countermeasures
sarogahtyp replied to redarmy's topic in ARMA 3 - MISSION EDITING & SCRIPTING
https://community.bistudio.com/wiki/removeMagazinesTurret https://community.bistudio.com/wiki/magazinesAllTurrets -
Getting the total OPFOR/BluFor Players
sarogahtyp replied to JarrodsC's topic in ARMA 3 - MISSION EDITING & SCRIPTING
those random getpos has no relation to the vehicle spawn. its his way to teleport nato players to starting area after the round ended. At least is that what I guess here 🙂- 11 replies
-
- 1
-
- scripting
- createvehicle
-
(and 2 more)
Tagged with:
-
initializtion Where to place my script
sarogahtyp replied to rkemsley's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Thats what initPlayerLocal.sqf is for.- 27 replies
-
- arma 3
- addcuratoreditingarea
- (and 6 more)
-
script vDog Patrol and VDog Feral Multiplayer Scripts [v1.9 - updated 05/18/2020]
sarogahtyp replied to LSValmont's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Hey @LSValmont, am I allowed to create a version of your script which uses armas function library? I m willing to hand it over to you if its done and you can think about what you want to do with it. The reason is that I personally don't like to execute scripts which are not precompiled by function library. -
Getting the total OPFOR/BluFor Players
sarogahtyp replied to JarrodsC's topic in ARMA 3 - MISSION EDITING & SCRIPTING
_Pos = [11362,11442]; { _x setpos [11682 + random [-5,0,5],11917 + random [-5,0,5],1] } forEach NatoUnits; same as private _base_pos = [11682, 11917, 0]; private "_rnd_pos"; { _rnd_pos = _base_pos getPos [ (random 5), (random 360) ]; _x setPos _rnd_pos; } forEach NatoUnits; but faster and better readable, at least for me. ok, the speed advantage is negligible. I thought it would be more.- 11 replies
-
- scripting
- createvehicle
-
(and 2 more)
Tagged with:
-
Getting the total OPFOR/BluFor Players
sarogahtyp replied to JarrodsC's topic in ARMA 3 - MISSION EDITING & SCRIPTING
you can do this with a script which is executed one time by initServer.sqf All other things you mentioned have to be handled by your script...- 11 replies
-
- scripting
- createvehicle
-
(and 2 more)
Tagged with:
-
What am I doing Wrong?
sarogahtyp replied to nickcage's topic in ARMA 3 - MISSION EDITING & SCRIPTING
try the code I put in the spoiler of my last post ... and please use code block in forum posts. Again you can find the code block icon on the top of the post you are currently editing and its icon is: <> -
Getting the total OPFOR/BluFor Players
sarogahtyp replied to JarrodsC's topic in ARMA 3 - MISSION EDITING & SCRIPTING
initServer.sqf should be the right place for it.- 11 replies
-
- scripting
- createvehicle
-
(and 2 more)
Tagged with:
-
Battleye client not responding/query timeout
sarogahtyp replied to gears08's topic in ARMA 3 - TROUBLESHOOTING
post a .rpt file of those connection try pls. https://community.bistudio.com/wiki/Crash_Files#Location -
Getting the total OPFOR/BluFor Players
sarogahtyp replied to JarrodsC's topic in ARMA 3 - MISSION EDITING & SCRIPTING
if you run a script on one machine which spawns exactly one ifrit then you ll have one ifrit spawned. if you execute the same script on all connected machines then you have as many ifrits as many machines are connected... thats what @pierremgi is talking about and what has to be in mind if you want to create scripts for multiplayer. there is one more important link you should use: https://community.bistudio.com/wiki/Event_Scripts these are one tool for controling where/when a script gets executed.- 11 replies
-
- scripting
- createvehicle
-
(and 2 more)
Tagged with:
-
What am I doing Wrong?
sarogahtyp replied to nickcage's topic in ARMA 3 - MISSION EDITING & SCRIPTING
because I am sometimes a friendly person: _unit = player; _Crate = PlayerStorage; _playerweap = primaryWeapon player; _cash = Daddies; _cost = 120; Ak-12 = ["arifle_AK12_F"]; // square bracket never gets closed buttonSetAction [ 1601, { // assuming _playerweap shall be the same as playerweap - you are checking if player // has the weapon which he has in his hand already. Why? // playerweap is global here but some lines above you declared it local. Is this intended? if ( player hasWeapon "playerweap" ) then { _unit action ["PutWeapon", _Crate, primaryWeapon _unit]; Hint "Weapon Stored"; } //then without if will never work, must be else I guess then { if (_cash >= _cost) then { MoneySystem = MoneySystem - 120; player addweapon "arifle_AK12_F"; } else { Hint "Not Enough Dosh"; // last closing bracket of if then else statement needs a semicolon } }; //missing a curly bracket to close the code block and a square bracket to close your button action -
What am I doing Wrong?
sarogahtyp replied to nickcage's topic in ARMA 3 - MISSION EDITING & SCRIPTING
you did not get it. An example for readable code: the important things of the biki entry I linked prior: -
What am I doing Wrong?
sarogahtyp replied to nickcage's topic in ARMA 3 - MISSION EDITING & SCRIPTING
I guess first thing you did wrong is to post such piece of ... and ask for help for it. for readability (this is important for other people to read your code) : 1. use a code block in forum to post code, plz - you can find it in the icon bar on top and it has this icon: <> 2. indent lines after curly brackets, plz 3. use spaces between brackets and other things. Maybe others are but I m not willing to help before you did the formal basics... and I bet you ll find some mistakes yourself during that EDIT: Read this! https://community.bistudio.com/wiki/Code_Best_Practices#Best_practices EDIT2: Perhaps I was a little too harsh but if you didn't know 'bout above things then you know now, -
execVM can't find files in the same directory
sarogahtyp replied to legoman1313's topic in ARMA 3 - MISSION EDITING & SCRIPTING
where in that mission file? -
execVM can't find files in the same directory
sarogahtyp replied to legoman1313's topic in ARMA 3 - MISSION EDITING & SCRIPTING
execVM -
How to spawn Big Smoke Pillars?
sarogahtyp replied to marki980908's topic in ARMA 3 - MISSION EDITING & SCRIPTING
it has to be broadcasted to each client in multiplayer. dedicated Server does not need to execute it, machines with display have to. JIP is also a thing here. -
[SOLVED] Predict Target Position - Need some help with code optimization
sarogahtyp replied to sarogahtyp's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Hey @ZaellixA now I ll do a late reply 🙂 your first suggestion about lazy evaluation is a double-edged sword. The problem is that IF the part in curly brackets gets evaluated then it is slower than it would be without lazy evaluation. Therefore one has to think about how often that could happen and if there is a real performance gain if one uses LE or if the whole thing gets slower with LE because the curly brackets are evaluated too often... detailed comparison; true || {false} || {false} 0.0009 ms false || {true} || {false} 0.0014 ms false || {false} || {true} 0.0017 ms true || false || false 0.0012 ms false || true || false 0.0012 ms false || false || true 0.0012 ms false && {true} && {true} 0.001 ms true && {false} && {true} 0.0014 ms true && {true} && {false} 0.0018 ms what u can see is that without LE the execution time is always same. With LE you have only one case where it is faster as without LE. Therefore you have to care that your script triggers the best case mostly. or you just do it without LE... -
Easiest way to set up dedicated server on new PC
sarogahtyp replied to thirith's topic in ARMA 3 - SERVERS & ADMINISTRATION
what means "better" exactly? -
you don't need BIS_fnc_findSafePos to get a position in a random radius. getPos does the job much faster: _position = getMarkerPos "Marker1"; _radius = 100; _rand_pos = _position getPos [ ( random _radius ), ( random 360 ) ]; _wp = _group addWayPoint [ _rand_pos, 0, 1 ];