Jump to content
  • Topics

  • Posts

    • I don't know what is your _originalGroup, so I let's say that if the leader (sometimes SL and TL) can't jump into a truck, some subordinates will not embark. I "join" the unit to make it sure this unit belongs to the right side. And that doesn't hurt. You can also use "CARGO" instead of "NONE" in createUnit if you want (not tested). For createUnit (as for any question about any command),  read BIKI from top to bottom.
    • Just a condition question. If I'm right, player is answering with the 2click addaction. So, you can pass a variable (temporary if needed) as condition. As you're in MP, broadcast it each time you change the value.
      Example: start in initPlayerLocal with: player setVariable ["answering",FALSE,TRUE];  // true (2nd boolean) is for broadcasting the variable of this player, everywhere then in 2click addAction: _caller (or player as you want) setVariable ["answering",TRUE,TRUE]; sleep 3; (or a waitUntil but be sure that can ends) _caller setVariable {"answering",FALSE,TRUE];     With "man" you could "call" rabbits and snakes. Use "CAManBase" instead. On the other hand, you have a side filter... no problem Use also nearEntities , faster. private _list = _caller nearEntities ["CAManBase",50] select {side _x == EAST && !(group _x isEqualTo group _caller) && !isPlayer _x };  // players can do what they want { [_x,clicker2] remoteExec ["say3D"]; sleep 2; [_x,getPos _caller] remoteExec ["move",_x]; } forEach _list;   That's for some details. This code can be written inside an addAction, that means for players who have the initiative (addAction). For AIs, you need to randomize some code, your scenario must have some behaviors: Ai's (ungrouped, alone)  for click? That means clicking from time to time (when? at night only? periodically? are they static or moving? how many concerned?)   Example for AI: _unit   _unit spawn { params ["_unit","_timer"]; while { alive _unit && lifeState _unit != "incapacitated" && units _unit isEqualTo [_unit] } do { sleep (30 + random 120); if !(alive _unit && lifeState _unit != "incapacitated" && units _unit isEqualTo [_unit]) exitWith {}; // something can be different after sleep [_unit,clicker] remoteExec ["say3D"]; _timer = diag_tickTime; waitUntil { allPlayers findIf {_x distance _unit < 50 && (_x getVariable ["answering",FALSE])} >-1 or diag_tickTime > _timer + 3 }; if (diag_tickTime <= _timer + 3) then { _leader = (allPlayers select {_x distance _unit < 50 && (_x getVariable ["answering",FALSE])} select 0); [_unit] join _leader; // because at least one close player has answered by clicker2 (variable answering in addAction of player). See also joinSilent }; }; };        
    • Question:

      What is the best way to check if the ooPdw database exists?
      I haven't figured out a good way to do this yet.

      My current workaround:

      1: On the first launch I run the server with a script that creates the vehicle DB and save all the editor placed vehicles. (Createdatabase.sqf).
      2: Replace 'createdatabase.sqf' with 'Getdata.sqf' (A script that loads and overwrites the db file with new data) and create a new .pbo.
      This method lets me save all the editor placed vehicles and the vehicles that are created during the mission.

      I'ts not optimal, but it works until I find a better solution.
    • at the moment not really/ You can keep the ships  a bit far away from each other so the other ship will not think that the missile is coming towards him. Evaluation of defence is based on the missiles direction and possible scan cone of the warhead. If friendly ship is not in this scan cone, it will not engage 
    • Do we have any update or workaround for this issue?
×