Jump to content

Search the Community

Showing results for tags 'waituntil'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • BOHEMIA INTERACTIVE
    • BOHEMIA INTERACTIVE - NEWS
    • BOHEMIA INTERACTIVE - JOBS
    • BOHEMIA INTERACTIVE - GENERAL
  • FEATURED GAMES
    • Vigor
    • DAYZ
    • ARMA 3
    • ARMA 2
    • YLANDS
  • MOBILE GAMES
    • ARMA MOBILE OPS
    • MINIDAYZ
    • ARMA TACTICS
    • ARMA 2 FIRING RANGE
  • BI MILITARY GAMES FORUMS
  • BOHEMIA INCUBATOR
    • PROJECT LUCIE
  • OTHER BOHEMIA GAMES
    • ARGO
    • TAKE ON MARS
    • TAKE ON HELICOPTERS
    • CARRIER COMMAND: GAEA MISSION
    • ARMA: ARMED ASSAULT / COMBAT OPERATIONS
    • ARMA: COLD WAR ASSAULT / OPERATION FLASHPOINT
    • IRON FRONT: LIBERATION 1944
    • BACK CATALOGUE
  • OFFTOPIC
    • OFFTOPIC
  • Die Hard OFP Lovers' Club's Topics
  • ArmA Toolmakers's Releases
  • ArmA Toolmakers's General
  • Japan in Arma's Topics
  • Arma 3 Photography Club's Discussions
  • The Order Of the Wolfs- Unit's Topics
  • 4th Infantry Brigade's Recruitment
  • 11th Marine Expeditionary Unit OFFICIAL | 11th MEU(SOC)'s 11th MEU(SOC) Recruitment Status - OPEN
  • Legion latina semper fi's New Server Legion latina next wick
  • Legion latina semper fi's https://www.facebook.com/groups/legionlatinasemperfidelis/
  • Legion latina semper fi's Server VPN LEGION LATINA SEMPER FI
  • Team Nederland's Welkom bij ons club
  • Team Nederland's Facebook
  • [H.S.O.] Hellenic Special Operations's Infos
  • BI Forum Ravage Club's Forum Topics

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Website URL


Yahoo


Jabber (xmpp)


Skype


Biography


Twitter


Google+


Youtube


Vimeo


Xfire


Steam url id


Raptr


MySpace


Linkedin


Tumblr


Flickr


XBOX Live


PlayStation PSN


Origin


PlayFire


SoundCloud


Pinterest


Reddit


Twitch.Tv


Ustream.Tv


Duxter


Instagram


Location


Interests


Interests


Occupation

Found 10 results

  1. Hello everyone. I have a script that I need to run on each frame. The problem is, it can get too heavy sometimes (it runs some code for each element of an array, and if the array gets too big, the code gets slow), enough to reach 1 ms or longer execution time in code performance. I think I read somewhere that codes that run in scheduled environment (such as those called by waitUntil) have a time limit of 3 ms before being stopped by the engine. What is the best way of balancing performance and making sure the code is executed correctly? 1. Using onEachFrame stacked EH 2. Using Draw3d mission EH 3. Using waitUntil (without sleep) I think the first two methods won't get interrupted if the execution time exceeds 3 ms. But it might also mean that the code will slow down the mission even more. I have tested all three methods but they all appear more or less the same. I'd appreciate any help with this.
  2. Hello, I wonder if is there a way of getting out of a waitUntil loop in the case when a script is remoteExec on the server in the init.sqf with player passed as argument and when the player disconnect from the server? I see on my linux server'screen when i disconnect from the server the error " Client: Remote object 4:0 not found " and the diag_log message continuing emmiting each second so the script never end. //init.sqf if (hasInterface) then { waitUntil {!isNull player}; [[player], "test.sqf"] remoteExec ["execVM", 2]; }; // test.sqf params ["_player"]; while {!isNull _player} do { waitUntil { diag_log "!!!!In waitUntil loop!!!!"; sleep 1; /*(condition code)*/ or isNull _player }; if (isNull _player) exitWith {}; //code... // // };
  3. So my script starts like this: _Join_East = creategroup EAST; call { _changing = allUnits select {(side _x isEqualTo civilian) && (!isPlayer _x) && (_x distance player < 100)}; _changing apply { units _x joinSilent _Join_East; [_Join_East, _Pos_1] call BIS_fnc_taskAttack; // Now all nearby Ai civilians turn hostile to the player! And that works like a charm! What I need is to put this two waitUntil conditions into a single waitUntil with an OR. waitUntil {sleep 1; ({alive _x} count units _Join_East) < 3;}; waitUntil {sleep 1; player distance units _Join_East > 500}; I can't seem to get both to work in an OR format. The final result should be: waitUntil { (The _Join_East group has less than 3 units) OR (The player got 500 meters away from the units in the _Join_East group). Thanks in advanced!
  4. Hi. I was wondering which one of these two commands has a bigger effect on performance: waitUntil { !cond }; or while {cond} do { sleep 0.5; }; Also, does the amount of sleep time matter? What about the condition? For example, if we have to check a series of conditions (e.g {alive _x} foreach Allunits) which one is better?
  5. Hello c",) first of love this forum, it has really helped me a lot ! . . . well over to my first post in here. Or this is more of a question; how do i get a chopper to wait untill it has been fully loaded before take off?.. "i meen not like if player is in, or if a spesific group is in. I only want a line to make the chopper wait untill every seat is full, or no more space in cargo." Maybe somthing like: waitUntil {heli is full} AND {!isNull player}; or waitUntil {heli fullcargo} AND {!isNull player}; Please help me you see i have made a mission where you must contact, rescue and finally load rescued civilian units on to a waiting chopper. "i started with a dream to count the rescued units onboard the heli, and then give score fore each. But seeing as this was a bit over my skill level i choose to have it only take of when fully loaded and the give a static score. I am using simple shop by HoverGuy i was hoping to give money for each rescued civilian loaded." Hope you are the right person to help me, i have really searched everywhere . . . Best regards RotaMafia.
  6. hello! i got a huge doubt about waituntil and sleep...here is an example (while (true) its not relevant, i just put it to better give the idea of a looping code): while {true} do { waitUntil {sleep 600;{alive _x} count allPlayers isEqualTo 0}; }; this looping code will wait 600 seconds for 1 single time and then check in loop every 0.5 seconds the "alive players" condition? OR the looping code will wait 600 seconds, check the "alive players" condition, then wait 600 seconds, then check "alive players" condition and so on ? if my ultimate goal is to check a condition every 600 seconds, what i should do ? thanks guys!
  7. I am executing this code in a .sqf using execVM via a trigger, but waitUntil isn't working. That is, after _cnt == 0 (after I kill all the units in the _ambushers group), the script does not continue. However, if after killing _ambushers, if I reexecute the script via the debug console in-game, then it seems to work just fine - it skips the first titleText and goes right into the code below waitUntil {_cnt == 0}. But the whole point of waitUntil is to NOT have to reexecute anything. What gives? Is it a waitUntil issue, or a count issue? What am I doing wrong? _ambushers = group ambusher; _cnt = count units _ambushers; if (_cnt > 0) then { titleText ["CREWMAN: TOOK YOU LONG ENOUGH! SHOOT THEM!", "PLAIN DOWN", 4]; titleFadeOut 1; }; waitUntil {_cnt == 0}; sleep 2; if (alive crewman) then { toolkitbox addItemCargo ["Toolkit",1]; titleText ["CREWMAN: Whew! Thanks for your help, guys.", "PLAIN DOWN", 4]; titleFadeOut 1; sleep 6; titleText ["CREWMAN: There is a repair kit in my equipment box. Take it for your truck. Just in case.", "PLAIN DOWN", 4]; titleFadeOut 1; sleep 6; ["tsk03","SUCCEEDED"] call BIS_fnc_taskSetState; sleep 3; ["tsk02b","ASSIGNED"] call BIS_fnc_taskSetState; } else { titleText ["PLAYER: He's dead. Looks like we failed.", "PLAIN DOWN", 4]; titleFadeOut 1; sleep 6; ["tsk03","FAILED"] call BIS_fnc_taskSetState; sleep 3; ["tsk02b","ASSIGNED"] call BIS_fnc_taskSetState; };
  8. I want to make a trigger which execVM an sqf file and wait until it finishes. But every time it gives me an error or it doesn't wait at all. I tried: myhandle = [] execVM "test.sqf"; waitUntil { scriptDone myhandle }; and it gave me this: waitUntil { |#|scriptDone my.. Generic error in expression also tried: myhandle = [] execVM "test.sqf"; null = [] spawn { waitUntil { scriptDone myhandle }}; then it does not wait at all. The trigger activates before the sqf finish. Inside the sqf, there is a variable at the end: test_sqf_running = nil I also tried: [] execVM "test.sqf"; waitUntil { sleep 1; isNil "test_sqf_running" }; and this happened: waitUntil { |#|sleep 1; is... Generic error in expression. also tried with spawn and it activates before the sql finish. Where is it wrong?
  9. Okey, i dont know if this has been up before, i couldnt find anything. iam trying to check if a marker has changed color.. it is for using EOS with tasks. MapClickEOS_Patrol = { // Create EOS Zone _Size = _this select 0; _groups = _this select 1; _grpSize = _this select 2; _Pos = _this select 3; // Create Marker Zone _m = createMarker [format ["Patrol%1", Random 1000],_pos]; _m setMarkerShape "ELLIPSE"; _m setMarkerSize [_size,_size]; _m setMarkerBrush "Solid"; _m setMarkerColor "ColorRed"; // Close map titletext ["Zone Created",""]; // Create EOS Zone null = [[_m],[0,0],[_groups,_grpSize,100],[0,0],[0],[0],[0,0],[5,0,300,EAST,TRUE]] call EOS_Spawn; sleep 5; waitUntil {sleep 5; getMarkerColor _m == "ColorGreen"}; hint "Area CLEAR"; }; i get expression error no matter what i do :( i know its probably something small but i cant figure it out, everything works as it should except the waituntil....
  10. Hi folks I've got an issue with trying to write a script that lets me keep doing an action until the point where I don't want to do the action any longer. A player has a camera in their gear. When they want to take a photo, the script fires up. The script makes them put away their current weapon, and an image of the back of a camera pops up on their screen. picture sharing Now the bit that has me stumped. I want to be able to have the player take as many photos as they want before putting the camera away. The script snippet I have for 'clicking' the camera is this: (The inputAction "Fire" is done by the player holding Left-Ctrl + Left mouse click). This works a treat in my script, but sadly can only be done once at the moment due to my lack of scripting know-how. I then have another script snippet which lets the rest of the script continue, thus closing the camera and letting the player get his weapon out again: (The inputAction "toggleRaiseWeapon" by default is a double tap of the Left-Ctrl key). The other problem here is that the player has to take a photo before the script continues on to the part where the player can put the camera away. What if the player opens the camera, but then decides to put it away without taking any shots. He/she can't in the script's current state. Here's the whole script currently: So in summery, I want the player to be able to point and 'click' the camera as many times and at as many objects as they want, then when they're ready, put the camera away. I hope that all makes sense. Any help with this is appreciated. Thanks heaps. Vapour
×